public class Scale extends Range
HScale
) and vertical (VScale
)
implementation for you to choose from.
The default
position for the value to be displayed is TOP
which may not be quite what you want. Use
setValuePosition()
to change
it.
Otherwise, most of the useful methods (notably those relating to the value)
are inherited from the parent class, Range
.
Range.ValueChanged
Widget.ButtonPressEvent, Widget.ButtonReleaseEvent, Widget.Destroy, Widget.Draw, Widget.EnterNotifyEvent, Widget.FocusInEvent, Widget.FocusOutEvent, Widget.Hide, Widget.KeyPressEvent, Widget.KeyReleaseEvent, Widget.LeaveNotifyEvent, Widget.MapEvent, Widget.MotionNotifyEvent, Widget.PopupMenu, Widget.QueryTooltip, Widget.ScrollEvent, Widget.SizeAllocate, Widget.UnmapEvent, Widget.VisibilityNotifyEvent
Constructor and Description |
---|
Scale(Orientation orientation,
Adjustment adjustment)
Construct a Scale of the given orientation and supplying an Adjustment.
|
Modifier and Type | Method and Description |
---|---|
boolean |
getDrawValue()
Is the Scale presently displaying text indicating its value?
|
void |
setDigits(int places)
Specify the number of decimal places that will be shown in the value.
|
void |
setDrawValue(boolean draw)
Specify if the text displaying the value will be shown.
|
void |
setValuePosition(PositionType position)
Specify where the value will be drawn.
|
connect, getInverted, getOrientation, getValue, setInverted, setOrientation, setValue
activate, addEvents, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, connect, destroy, getAllocatedHeight, getAllocatedWidth, getAllocation, getCanDefault, getCanFocus, getHasFocus, getName, getParent, getPreferredHeightForWidthMinimum, getPreferredHeightForWidthNatural, getPreferredHeightMinimum, getPreferredHeightNatural, getPreferredWidthForHeightMinimum, getPreferredWidthForHeightNatural, getPreferredWidthMinimum, getPreferredWidthNatural, getRequestMode, getRequisition, getSensitive, getStyleContext, getToplevel, getWindow, grabAdd, grabDefault, grabFocus, grabRemove, hide, isSensitive, overrideBackground, overrideColor, overrideFont, queueDraw, queueDrawArea, realize, setAlignHorizontal, setAlignVertical, setCanDefault, setCanFocus, setEvents, setExpandHorizontal, setExpandVertical, setName, setSensitive, setSizeRequest, setTooltipMarkup, setTooltipText, show, showAll
public Scale(Orientation orientation, Adjustment adjustment)
public boolean getDrawValue()
public void setDigits(int places)
public void setDrawValue(boolean draw)
true
.public void setValuePosition(PositionType position)
TOP
is
the default.