Class: Gtk::SpinButton
- Inherits:
-
Object
- Object
- Gtk::SpinButton
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#adjustment ⇒ Gtk::Adjustment
Adjustment.
- #adjustment=(adjustment) ⇒ Gtk::Adjustment
-
#climb_rate ⇒ Float
Climb-rate.
- #climb_rate=(climb_rate) ⇒ Float
-
#configure(adjustment, climb_rate, digits) ⇒ nil
Changes the properties of an existing spin button.
-
#digits ⇒ Integer
Digits.
- #digits=(digits) ⇒ Integer
-
#get_increments(step, page) ⇒ nil
Gets the current step and page the increments used by spin_button.
-
#get_range(min, max) ⇒ nil
Gets the range allowed for spin_button.
-
#new(adjustment, climb_rate, digits) ⇒ Gtk::Widget
Creates a new Gtk::SpinButton.
-
#new_with_range(min, max, step) ⇒ Gtk::Widget
This is a convenience constructor that allows creation of a numeric Gtk::SpinButton without manually creating an adjustment.
-
#numeric ⇒ TrueClass
Returns whether non-numeric text can be typed into the spin button.
- #numeric=(numeric) ⇒ TrueClass
-
#numeric? ⇒ TrueClass
Numeric.
-
#set_increments(step, page) ⇒ nil
Sets the step and page increments for spin_button.
-
#set_range(min, max) ⇒ nil
Sets the minimum and maximum allowable values for spin_button.
-
#snap_to_ticks ⇒ TrueClass
Returns whether the values are corrected to the nearest step.
- #snap_to_ticks=(snap_to_ticks) ⇒ TrueClass
-
#snap_to_ticks? ⇒ TrueClass
Snap-to-ticks.
-
#spin(direction, increment) ⇒ nil
Increment or decrement a spin button’s value in a specified direction by a specified amount.
-
#update ⇒ nil
Manually force an update of the spin button.
-
#update_policy ⇒ Gtk::SpinButtonUpdatePolicy
Update-policy.
- #update_policy=(update_policy) ⇒ Gtk::SpinButtonUpdatePolicy
-
#value ⇒ Float
Value.
- #value=(value) ⇒ Float
-
#value_as_int ⇒ Integer
Get the value spin_button represented as an integer.
-
#wrap ⇒ TrueClass
Returns whether the spin button’s value wraps around to the opposite limit when the upper or lower limit of the range is exceeded.
- #wrap=(wrap) ⇒ TrueClass
-
#wrap? ⇒ TrueClass
Wrap.
Instance Method Details
#adjustment ⇒ Gtk::Adjustment
Returns adjustment.
#adjustment=(adjustment) ⇒ Gtk::Adjustment
#climb_rate ⇒ Float
Returns climb-rate.
#climb_rate=(climb_rate) ⇒ Float
#configure(adjustment, climb_rate, digits) ⇒ nil
Changes the properties of an existing spin button. The adjustment, climb rate, and number of decimal places are updated accordingly.
#digits ⇒ Integer
Returns digits.
#digits=(digits) ⇒ Integer
#get_increments(step, page) ⇒ nil
Gets the current step and page the increments used by spin_button. See gtk_spin_button_set_increments().
#get_range(min, max) ⇒ nil
Gets the range allowed for spin_button. See gtk_spin_button_set_range().
#new(adjustment, climb_rate, digits) ⇒ Gtk::Widget
Creates a new Gtk::SpinButton.
#new_with_range(min, max, step) ⇒ Gtk::Widget
This is a convenience constructor that allows creation of a numeric Gtk::SpinButton without manually creating an adjustment. The value is initially set to the minimum value and a page increment of 10 * step is the default. The precision of the spin button is equivalent to the precision of step.
Note that the way in which the precision is derived works best if step is a power of ten. If the resulting precision is not suitable for your needs, use gtk_spin_button_set_digits() to correct it.
#numeric ⇒ TrueClass
Returns whether non-numeric text can be typed into the spin button. See gtk_spin_button_set_numeric().
#numeric=(numeric) ⇒ TrueClass
#numeric? ⇒ TrueClass
Returns numeric.
#set_increments(step, page) ⇒ nil
Sets the step and page increments for spin_button. This affects how quickly the value changes when the spin button’s arrows are activated.
#set_range(min, max) ⇒ nil
Sets the minimum and maximum allowable values for spin_button.
If the current value is outside this range, it will be adjusted to fit within the range, otherwise it will remain unchanged.
#snap_to_ticks ⇒ TrueClass
Returns whether the values are corrected to the nearest step. See gtk_spin_button_set_snap_to_ticks().
#snap_to_ticks=(snap_to_ticks) ⇒ TrueClass
#snap_to_ticks? ⇒ TrueClass
Returns snap-to-ticks.
#spin(direction, increment) ⇒ nil
Increment or decrement a spin button’s value in a specified direction by a specified amount.
#update ⇒ nil
Manually force an update of the spin button.
#update_policy ⇒ Gtk::SpinButtonUpdatePolicy
Returns update-policy.
#update_policy=(update_policy) ⇒ Gtk::SpinButtonUpdatePolicy
#value ⇒ Float
Returns value.
#value=(value) ⇒ Float
#value_as_int ⇒ Integer
Get the value spin_button represented as an integer.
#wrap ⇒ TrueClass
Returns whether the spin button’s value wraps around to the opposite limit when the upper or lower limit of the range is exceeded. See gtk_spin_button_set_wrap().
#wrap=(wrap) ⇒ TrueClass
#wrap? ⇒ TrueClass
Returns wrap.