Next Previous Up Top Contents Index

7.2.6 Range gadgets

7.2.6.2 Scroll bars

The <scroll-bar> class is the most common type of value range gadget. Interestingly, it is probably also the class that is explicitly used the least. Because most gadgets that make use of scroll bars support the scroll-bars: init-keyword; you rarely need to explicitly create an instance of <scroll-bar> and attach it to another gadget.

define variable *my-scroll-bar* := 
  contain(make(<scroll-bar>, 
               value-range: range(from: 0, to: 50)));

On the occasions when you do need to place scroll bars around a gadget explicitly, use the scrolling macro.

scrolling (scroll-bars: #"vertical")
  make(<radio-box>,
  orientation: #"vertical",
  items: range(from: 1, to: 50))
end


Building Applications Using DUIM - 26 May 1999

Next Previous Up Top Contents Index