Base class for GtkHScale and GtkVScale
Class GtkScale
A GtkScale is a slider control used to select a numeric value. To use it, you'll probably want to investigate the methods on its base class, GtkRange, in addition to the methods for GtkScale itself. To set the value of a scale, you would normally use gtk_range_set_value(). To detect changes to the value, you would normally use the "value_changed" signal.
The GtkScale widget is an abstract class, used only for deriving the subclasses GtkHScale and GtkVScale. To create a scale widget, call gtk_hscale_new_with_range() or gtk_vscale_new_with_range().
Methods | |
get_digits | Gets the number of decimal places that are displayed in the value. |
get_draw_value | Returns whether the current value is displayed as a string next to the slider. |
get_value_pos | Gets the position in which the current value is displayed. |
set_digits | Sets the number of decimal places that are displayed in the value. |
set_draw_value | Specifies whether the current value is displayed as a string next to the slider. |
set_value_pos | Sets the position in which the current value is displayed. |
signal_format_value | Signal which allows you to change how the scale value is displayed. |
signal_text_popped | Is emitted whenever a new message is popped off a statusbar's stack. |
signal_text_pushed | Is emitted whenever a new message gets pushed onto a statusbar's stack. |
Gets the number of decimal places that are displayed in the value.
GtkScale.get_digits()
Return | the number of decimal places that are displayed |
Returns whether the current value is displayed as a string next to the slider.
GtkScale.get_draw_value()
Return | whether the current value is displayed as a string |
Gets the position in which the current value is displayed.
GtkScale.get_value_pos()
Return | the position in which the current value is displayed (GtkPositionType). |
Sets the number of decimal places that are displayed in the value.
GtkScale.set_digits( digits )
digits | the number of decimal places to display, e.g. use 1 to display 1.0, 2 to display 1.00, etc |
Also causes the value of the adjustment to be rounded off to this number of digits, so the retrieved value matches the value the user saw.
Specifies whether the current value is displayed as a string next to the slider.
GtkScale.set_draw_value( TRUE )
TRUE | to draw the value |
Sets the position in which the current value is displayed.
GtkScale.set_value_pos( pos )
pos | the position in which the current value is displayed (GtkPositionType). |
Signal which allows you to change how the scale value is displayed.
GtkScale.signal_format_value()
Connect a signal handler which returns a string representing value. That string will then be used to display the scale's value.
Is emitted whenever a new message is popped off a statusbar's stack.
GtkScale.signal_text_popped()
Is emitted whenever a new message gets pushed onto a statusbar's stack.
GtkScale.signal_text_pushed()