Result = ScrollBarGadget3D(#Gadget3D, x, y, Width, Height, Minimum, Maximum, PageLength [, Flags])Description
Creates a scrollbar gadget in the current GadgetList. It's widely used when displaying only a part of an object.
#Gadget3D A number to identify the new 3D gadget. #PB_Any can be used to auto-generate this number. x, y, Width, Height The position and dimensions of the new gadget. Minimum, Maximum The range of values that the scrollbar can take. These values should be between 0 and 10,000 to avoid limitations on some operating systems. PageLength The amount of values that are part of the current displayed "page".
For example you can have a picture which is 100 pixels width and you only see 25 pixels. What you see is a called a 'page', in this example, the page length will be 25, the Minimum will be 0 and the Maximum will be 100.
Flags (optional) It can be a combination of the following values:#PB_ScrollBar3D_Vertical : The scrollbar is vertical (instead of horizontal, which is the default).
Nonzero on success, zero otherwise. If #PB_Any was used as the #Gadget3D parameter then the return-value is the auto-generated gadget number on success.
To add a 'mini help' to this gadget, use GadgetToolTip3D().
The following functions can be used to act on this gadget:
- GetGadgetState3D(): Returns the current slider position (value between the Minimum-Maximum range).
- SetGadgetState3D(): Changes the current slider position.
- GetGadgetAttribute3D(): With one of the following attributes:#PB_ScrollBar3D_Minimum : Returns the minimum scroll position. #PB_ScrollBar3D_Maximum : Returns the maximum scroll position. #PB_ScrollBar3D_PageLength: Returns the PageLength value.- SetGadgetAttribute3D(): With one of the following attributes:#PB_ScrollBar3D_Minimum : Changes the minimum scroll position. #PB_ScrollBar3D_Maximum : Changes the maximum scroll position. #PB_ScrollBar3D_PageLength: Changes the PageLength value.