GimpUi.ScaleEntry¶
- Subclasses:
 
Methods¶
- Inherited:
 GimpUi.LabelSpin (6), GimpUi.Labeled (3), Gtk.Grid (21), Gtk.Container (35), Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10), Gtk.Orientable (2)
- Structs:
 Gtk.ContainerClass (5), Gtk.WidgetClass (12), GObject.ObjectClass (5)
class  | 
  | 
  | 
|
  | 
|
  | 
Virtual Methods¶
Properties¶
Child Properties¶
- Inherited:
 
Style Properties¶
- Inherited:
 
Signals¶
Fields¶
- Inherited:
 GimpUi.LabelSpin (1), GimpUi.Labeled (1), Gtk.Container (4), Gtk.Widget (69), GObject.Object (1)
Name  | 
Type  | 
Access  | 
Description  | 
|---|---|---|---|
parent_instance  | 
r  | 
Class Details¶
- class GimpUi.ScaleEntry(**kwargs)¶
 - Bases:
 - Abstract:
 No
- Structure:
 
This widget is a
Gtk.Gridshowing aGtk.SpinButtonand aGtk.Scalebound together. It also displays aGtk.Labelwhich is used as mnemonic on theGtk.SpinButton.- classmethod new(text, value, lower, upper, digits)¶
 - Parameters:
 - Returns:
 The new
GimpUi.ScaleEntry.- Return type:
 
This function creates a
Gtk.Label, aGtk.HScaleand aGtk.SpinButtonand attaches them to a 3-columnGtk.Grid.
- get_logarithmic()¶
 - Returns:
 Trueif self's scale widget will behave in logarithmic fashion,Falsefor linear behavior.- Return type:
 
New in version 2.2.
- get_range()¶
 - 
This function returns the
Gtk.Rangepacked in self. This can be useful if you need to customize some aspects of the widgetBy default, it is a
Gtk.Scale, but it can be any other type ofGtk.Rangeif a subclass overrode the new_range_widget() protected method. 
- set_bounds(lower, upper, limit_scale)¶
 - Parameters:
 lower (
float) – the lower value for the whole widget if limit_scale isFalse, or only for theGtk.ScaleifTrue.upper (
float) – the upper value for the whole widget if limit_scale isFalse, or only for theGtk.SpinButtonifTrue.limit_scale (
bool) – Whether the range should only apply to theGtk.Scaleor if it should share its #GtkAdjustement with theGtk.SpinButton. IfTrue, both lower and upper must be included in currentGtk.SpinButtonrange.
By default the
Gtk.SpinButtonandGtk.Scalewill have the same range. In some case, you want to set a different range. In particular when the finale range is huge, theGtk.Scalemight become nearly useless as every tiny slider move would dramatically update the value. In this case, it is common to set theGtk.Scaleto a smaller common range, while theGtk.SpinButtonwould allow for the full allowed range. This function allows this. Obviously theGtk.Adjustmentof both widgets would be synced but if the set value is out of theGtk.Scalerange, the slider would simply show at one extreme.If limit_scale is
Falsethough, it would sync back both widgets range to the new values.Note that the step and page increments are updated when the range is updated according to some common usage algorithm which should work if you don’t have very specific needs. If you want to customize the step increments yourself, you may call
GimpUi.LabelSpin.set_increments()
- set_logarithmic(logarithmic)¶
 - Parameters:
 logarithmic (
bool) – a boolean value to set or reset logarithmic behavior of the scale widget
Sets whether self's scale widget will behave in a linear or logarithmic fashion. Useful when an entry has to attend large ranges, but smaller selections on that range require a finer adjustment.
New in version 2.2.