|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.eclipse.swt.widgets.Widget | +--org.eclipse.swt.widgets.Control | +--org.eclipse.swt.widgets.Scale
Unsafe: Instances of the receiver represent a selectable user interface object that present a range of continuous numeric values.
Note: Only one of the styles HORIZONTAL and VERTICAL may be specified.
IMPORTANT: This class is intended to be subclassed only within the SWT implementation.
Field Summary | |
(package private) static org.eclipse.swt.internal.win32.TCHAR |
TrackBarClass
|
(package private) static int |
TrackBarProc
|
Fields inherited from class org.eclipse.swt.widgets.Control |
ACCENTS, accessible, background, drawCount, foreground, handle, hCursor, layoutData, menu, parent, toolTipText |
Fields inherited from class org.eclipse.swt.widgets.Widget |
CANVAS, COMCTL32_MAJOR, COMCTL32_MINOR, data, DEFAULT_HEIGHT, DEFAULT_WIDTH, DISABLED, DISPOSED, eventTable, HIDDEN, keys, MAJOR, MINOR, Mnemonic, state, style, values |
Constructor Summary | |
Scale(Composite parent,
int style)
Enabled: Constructs a new instance of this class given its parent and a style value describing its behavior and appearance. |
Method Summary | |
void |
addSelectionListener(SelectionListener listener)
Enabled: Adds the listener to the collection of listeners who will be notified when the receiver's value changes, by sending it one of the messages defined in the SelectionListener
interface. |
(package private) int |
callWindowProc(int msg,
int wParam,
int lParam)
|
(package private) static int |
checkStyle(int style)
|
Point |
computeSize(int wHint,
int hHint,
boolean changed)
Enabled: |
(package private) void |
createHandle()
|
(package private) int |
defaultForeground()
|
int |
getIncrement()
Enabled: Returns the amount that the receiver's value will be modified by when the up/down (or right/left) arrows are pressed. |
int |
getMaximum()
Enabled: Returns the maximum value which the receiver will allow. |
int |
getMinimum()
Enabled: Returns the minimum value which the receiver will allow. |
int |
getPageIncrement()
Enabled: Returns the amount that the receiver's value will be modified by when the page increment/decrement areas are selected. |
int |
getSelection()
Enabled: Returns the single selection that is the receiver's position. |
void |
removeSelectionListener(SelectionListener listener)
Enabled: Removes the listener from the collection of listeners who will be notified when the receiver's value changes. |
(package private) void |
setBackgroundPixel(int pixel)
|
void |
setIncrement(int increment)
Enabled: Sets the amount that the receiver's value will be modified by when the up/down (or right/left) arrows are pressed to the argument, which must be at least one. |
void |
setMaximum(int value)
Enabled: Sets the maximum value which the receiver will allow to be the argument which must be greater than or equal to zero. |
void |
setMinimum(int value)
Enabled: Sets the minimum value which the receiver will allow to be the argument which must be greater than or equal to zero. |
void |
setPageIncrement(int pageIncrement)
Enabled: Sets the amount that the receiver's value will be modified by when the page increment/decrement areas are selected to the argument, which must be at least one. |
void |
setSelection(int value)
Enabled: Sets the single selection that is the receiver's value to the argument which must be greater than or equal to zero. |
(package private) int |
widgetStyle()
|
(package private) org.eclipse.swt.internal.win32.TCHAR |
windowClass()
|
(package private) int |
windowProc()
|
(package private) org.eclipse.swt.internal.win32.LRESULT |
wmScrollChild(int wParam,
int lParam)
|
Methods inherited from class org.eclipse.swt.widgets.Widget |
addDisposeListener, addListener, checkBits, checkParent, checkSubclass, checkWidget, dispose, error, filters, getData, getData, getName, getNameText, getStyle, hooks, isListening, isValidSubclass, isValidThread, mbcsToWcs, mbcsToWcs, notifyListeners, postEvent, postEvent, releaseChild, releaseResources, removeDisposeListener, removeListener, removeListener, sendEvent, sendEvent, sendEvent, sendEvent, setData, setData, setInputState, setKeyState, toString, wcsToMbcs, wcsToMbcs |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
static final int TrackBarProc
static final org.eclipse.swt.internal.win32.TCHAR TrackBarClass
Constructor Detail |
public Scale(Composite parent, int style)
The style value is either one of the style constants defined in
class SWT
which is applicable to instances of this
class, or must be built by bitwise OR'ing together
(that is, using the int
"|" operator) two or more
of those SWT
style constants. The class description
lists the style constants that are applicable to the class.
Style bits are also inherited from superclasses.
parent
- a composite control which will be the parent of the new instance (cannot be null)style
- the style of control to constructSWT.HORIZONTAL
,
SWT.VERTICAL
,
Widget.checkSubclass()
,
Widget.getStyle()
Method Detail |
public void addSelectionListener(SelectionListener listener)
SelectionListener
interface.
listener
- the listener which should be notifiedSelectionListener
,
removeSelectionListener(org.eclipse.swt.events.SelectionListener)
int callWindowProc(int msg, int wParam, int lParam)
callWindowProc
in class Control
static int checkStyle(int style)
public Point computeSize(int wHint, int hHint, boolean changed)
computeSize
in class Control
wHint
- the width hint (can be SWT.DEFAULT
)hHint
- the height hint (can be SWT.DEFAULT
)changed
- true
if the control's contents have changed, and false
otherwise
Layout
,
Control.getBorderWidth()
,
Control.getBounds()
,
Control.getSize()
,
Control.pack()
,
"computeTrim, getClientArea for controls that implement them"void createHandle()
createHandle
in class Control
int defaultForeground()
defaultForeground
in class Control
public int getIncrement()
public int getMaximum()
public int getMinimum()
public int getPageIncrement()
public int getSelection()
public void removeSelectionListener(SelectionListener listener)
listener
- the listener which should no longer be notifiedSelectionListener
,
addSelectionListener(org.eclipse.swt.events.SelectionListener)
void setBackgroundPixel(int pixel)
setBackgroundPixel
in class Control
public void setIncrement(int increment)
public void setMaximum(int value)
value
- the new maximum (must be zero or greater)public void setMinimum(int value)
value
- the new minimum (must be zero or greater)public void setPageIncrement(int pageIncrement)
public void setSelection(int value)
value
- the new selection (must be zero or greater)int widgetStyle()
widgetStyle
in class Control
org.eclipse.swt.internal.win32.TCHAR windowClass()
windowClass
in class Control
int windowProc()
windowProc
in class Control
org.eclipse.swt.internal.win32.LRESULT wmScrollChild(int wParam, int lParam)
wmScrollChild
in class Control
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |