org.gnu.gtk

Class Range

public abstract class Range extends Widget

Deprecated: This class is part of the java-gnome 2.x family of libraries, which, due to their inefficiency and complexity, are no longer being maintained and have been abandoned by the java-gnome project. This class may in the future have an equivalent in java-gnome 4.0, try looking for org.gnome.gtk.Range. You should be aware that there is a considerably different API in the new library: the architecture is completely different and most notably internals are no longer exposed to public view.

This is the base class for the group of widgets that involve graphic display and manipulation of a vale bounded within a specific minumum and maximum value.

See Also: HScale HScrollBar VScale

Method Summary
voidaddListener(RangeListener listener)
Register an object to handle range events.
voidaddRangeListener(RangeListener listener)
Register an object to handle range events.
AdjustmentgetAdjustment()
Get the Adjustment which is the "model" object for Range.
ClassgetEventListenerClass(String signal)
EventTypegetEventType(String signal)
booleangetInverted()
Gets the vaue set by Range.
static TypegetType()
Retrieve the runtime type used by the GLib library.
UpdateTypegetUpdatePolicy()
Gets the update policy
doublegetValue()
Gets the current value of the range.
voidremoveRangeListener(RangeListener listener)
Removes a listener
voidsetAdjustment(Adjustment adjustment)
Sets the adjustment to be used as the "model" object for this range widget.
voidsetIncrements(double step, double page)
Sets the step and page sizes for the range.
voidsetInverted(boolean setting)
Ranges normally move from lower to higher values as the slider moves from top to bottom or left to right.
voidsetRange(double min, double max)
Sets the allowable values in the Range, and clamps the range value to be between min and max.
voidsetUpdatePolicy(UpdateType policy)
Sets the update policy for the Adjustment
voidsetValue(double value)
Sets the current value of the range; if the value is outside the minimum or maximum range values, it will be clamped to fit inside them.

Method Detail

addListener

public void addListener(RangeListener listener)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Register an object to handle range events.

See Also: RangeListener

addRangeListener

public void addRangeListener(RangeListener listener)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Register an object to handle range events.

See Also: RangeListener

getAdjustment

public Adjustment getAdjustment()

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Get the Adjustment which is the "model" object for Range.

Returns: The adjustment model

getEventListenerClass

public Class getEventListenerClass(String signal)

getEventType

public EventType getEventType(String signal)

getInverted

public boolean getInverted()

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Gets the vaue set by Range.

Returns: True of the slider is inverted

getType

public static Type getType()

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Retrieve the runtime type used by the GLib library.

getUpdatePolicy

public UpdateType getUpdatePolicy()

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Gets the update policy

Returns: The current update policy

getValue

public double getValue()

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Gets the current value of the range.

Returns: Current value of the range.

removeRangeListener

public void removeRangeListener(RangeListener listener)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Removes a listener

See Also: addRangeListener

setAdjustment

public void setAdjustment(Adjustment adjustment)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Sets the adjustment to be used as the "model" object for this range widget. The adjustment indicates the current range value, the minimum and maximum range values, the step/page increments used for keybindings and scrolling, and the page size. The page size is normally 0 for Scale and nonzero for ScrollBar, and indicates the size of the visible area of the widget being scrolled. The page size affects the size of the scrollbar slider.

Parameters: adjustment The model to use

setIncrements

public void setIncrements(double step, double page)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Sets the step and page sizes for the range. The step size is used when the user clicks the ScrollBar arrows or moves Scale via arrow keys. The page size is used for example when moving via Page Up or Page Down keys.

Parameters: step Step size page Page size

setInverted

public void setInverted(boolean setting)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Ranges normally move from lower to higher values as the slider moves from top to bottom or left to right. Inverted ranges have higher values at the top or on the right rather than on the bottom or left.

Parameters: setting TRUE to invert the range

setRange

public void setRange(double min, double max)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Sets the allowable values in the Range, and clamps the range value to be between min and max. (If the range has a non-zero page size, it is clamped between min and max - page-size.)

Parameters: min Minimum range value max Maximum range value

setUpdatePolicy

public void setUpdatePolicy(UpdateType policy)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Sets the update policy for the Adjustment

setValue

public void setValue(double value)

Deprecated: Superceeded by java-gnome 4.0; a method along these lines may well exist in the new bindings, but if it does it likely has a different name or signature due to the shift to an algorithmic mapping of the underlying native libraries.

Sets the current value of the range; if the value is outside the minimum or maximum range values, it will be clamped to fit inside them. An event is called if the value changes.

Parameters: value The new value of the range