gtkmm  3.3.20
Public Member Functions | Protected Member Functions | Related Functions
Gtk::ScaleButton Class Reference

A button which pops up a scale widget. More...

Inheritance diagram for Gtk::ScaleButton:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual ~ScaleButton ()
GtkScaleButton* gobj ()
 Provides access to the underlying C GtkObject.
const GtkScaleButton* gobj () const
 Provides access to the underlying C GtkObject.
 ScaleButton (IconSize size, double min, double max, double step, const std::vector< Glib::ustring >& icons)
void set_icons (const std::vector< Glib::ustring >& icons)
 Sets the icons to be used by the scale button.
double get_value () const
 Gets the current value of the scale button.
void set_value (double value)
 Sets the current value of the scale; if the value is outside the minimum or maximum range values, it will be clamped to fit inside them.
Glib::RefPtr< Adjustmentget_adjustment ()
 Gets the Gtk::Adjustment associated with the Gtk::ScaleButton's scale.
Glib::RefPtr< const Adjustmentget_adjustment () const
 Gets the Gtk::Adjustment associated with the Gtk::ScaleButton's scale.
void set_adjustment (const Glib::RefPtr< Adjustment >& adjustment)
 Sets the Gtk::Adjustment to be used as a model for the Gtk::ScaleButton's scale.
Widgetget_plus_button ()
 Retrieves the plus button of the Gtk::ScaleButton.
const Widgetget_plus_button () const
 Retrieves the plus button of the Gtk::ScaleButton.
Widgetget_minus_button ()
 Retrieves the minus button of the Gtk::ScaleButton.
const Widgetget_minus_button () const
 Retrieves the minus button of the Gtk::ScaleButton.
Gtk::Widgetget_popup ()
 Retrieves the popup of the Gtk::ScaleButton.
const Gtk::Widgetget_popup () const
 Retrieves the popup of the Gtk::ScaleButton.
Glib::SignalProxy1< void, double > signal_value_changed ()
Glib::PropertyProxy< double > property_value ()
 The value of the scale.
Glib::PropertyProxy_ReadOnly
< double > 
property_value () const
 The value of the scale.
Glib::PropertyProxy< IconSizeproperty_size ()
 The icon size.
Glib::PropertyProxy_ReadOnly
< IconSize
property_size () const
 The icon size.
Glib::PropertyProxy< Adjustment* > property_adjustment ()
 The GtkAdjustment that contains the current value of this scale button object.
Glib::PropertyProxy_ReadOnly
< Adjustment* > 
property_adjustment () const
 The GtkAdjustment that contains the current value of this scale button object.
Glib::PropertyProxy
< std::vector< Glib::ustring > > 
property_icons ()
 List of icon names.
Glib::PropertyProxy_ReadOnly
< std::vector< Glib::ustring > > 
property_icons () const
 List of icon names.

Protected Member Functions

virtual void on_value_changed (double value)
 This is a default handler for the signal signal_value_changed().

Related Functions

(Note that these are not member functions.)

Gtk::ScaleButtonwrap (GtkScaleButton* object, bool take_copy=false)
 A Glib::wrap() method for this object.

Detailed Description

A button which pops up a scale widget.

This kind of widget is commonly used for volume controls in multimedia applications, and there is a Gtk::VolumeButton subclass that is tailored for this use case.

Since gtkmm 2.12:

Constructor & Destructor Documentation

virtual Gtk::ScaleButton::~ScaleButton ( ) [virtual]
Gtk::ScaleButton::ScaleButton ( IconSize  size,
double  min,
double  max,
double  step,
const std::vector< Glib::ustring > &  icons 
) [explicit]

Member Function Documentation

Gets the Gtk::Adjustment associated with the Gtk::ScaleButton's scale.

See Gtk::Range::get_adjustment() for details.

Since gtkmm 2.12:
Returns:
The adjustment associated with the scale.

Gets the Gtk::Adjustment associated with the Gtk::ScaleButton's scale.

See Gtk::Range::get_adjustment() for details.

Since gtkmm 2.12:
Returns:
The adjustment associated with the scale.

Retrieves the minus button of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The minus button of the Gtk::ScaleButton.

Retrieves the minus button of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The minus button of the Gtk::ScaleButton.

Retrieves the plus button of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The plus button of the Gtk::ScaleButton.

Retrieves the plus button of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The plus button of the Gtk::ScaleButton.

Retrieves the popup of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The popup of the Gtk::ScaleButton.

Retrieves the popup of the Gtk::ScaleButton.

Since gtkmm 2.14:
Returns:
The popup of the Gtk::ScaleButton.
double Gtk::ScaleButton::get_value ( ) const

Gets the current value of the scale button.

Since gtkmm 2.12:
Returns:
Current value of the scale button.
GtkScaleButton* Gtk::ScaleButton::gobj ( ) [inline]

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Button.

Reimplemented in Gtk::VolumeButton.

const GtkScaleButton* Gtk::ScaleButton::gobj ( ) const [inline]

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::Button.

Reimplemented in Gtk::VolumeButton.

virtual void Gtk::ScaleButton::on_value_changed ( double  value) [protected, virtual]

This is a default handler for the signal signal_value_changed().

The GtkAdjustment that contains the current value of this scale button object.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

The GtkAdjustment that contains the current value of this scale button object.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

List of icon names.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

List of icon names.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

The icon size.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

The icon size.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

The value of the scale.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

The value of the scale.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Sets the Gtk::Adjustment to be used as a model for the Gtk::ScaleButton's scale.

See Gtk::Range::set_adjustment() for details.

Since gtkmm 2.12:
Parameters:
adjustmentA Gtk::Adjustment.

Sets the icons to be used by the scale button.

For details, see the Gtk::ScaleButton::property_icons() property.

Since gtkmm 2.12:
Parameters:
iconsA 0-terminated array of icon names.
void Gtk::ScaleButton::set_value ( double  value)

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

The scale button emits the Gtk::ScaleButton::signal_value_changed() signal if the value changes.

Since gtkmm 2.12:
Parameters:
valueNew value of the scale button.
Slot Prototype:
void on_my_value_changed(double value)

The signal_value_changed() signal is emitted when the value field has changed.

Since gtkmm 2.12:
Parameters:
valueThe new value.

Friends And Related Function Documentation

Gtk::ScaleButton* wrap ( GtkScaleButton *  object,
bool  take_copy = false 
) [related]

A Glib::wrap() method for this object.

Parameters:
objectThe C instance.
take_copyFalse if the result should take ownership of the C instance. True if it should take a new copy or ref.
Returns:
A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file: