Gtk_Tool_Buttons are Gtk_Tool_Items containing buttons.
Use Gtk.Tool_Button.Gtk_New to create a new Gtk.Tool_Button.Gtk_Tool_Button.
The label of a Gtk.Tool_Button.Gtk_Tool_Button is determined by the properties Gtk.Tool_Button.Gtk_Tool_Button:label-widget, Gtk.Tool_Button.Gtk_Tool_Button:label, and Gtk.Tool_Button.Gtk_Tool_Button:stock-id. If Gtk.Tool_Button.Gtk_Tool_Button:label-widget is non-null, then that widget is used as the label. Otherwise, if Gtk.Tool_Button.Gtk_Tool_Button:label is non-null, that string is used as the label. Otherwise, if Gtk.Tool_Button.Gtk_Tool_Button:stock-id is non-null, the label is determined by the stock item. Otherwise, the button does not have a label.
The icon of a Gtk.Tool_Button.Gtk_Tool_Button is determined by the properties Gtk.Tool_Button.Gtk_Tool_Button:icon-widget and Gtk.Tool_Button.Gtk_Tool_Button:stock-id. If Gtk.Tool_Button.Gtk_Tool_Button:icon-widget is non-null, then that widget is used as the icon. Otherwise, if Gtk.Tool_Button.Gtk_Tool_Button:stock-id is non-null, the icon is determined by the stock item. Otherwise, the button does not have a icon.
# CSS nodes
GtkToolButton has a single CSS node with name toolbutton.
function "+"
(Widget : access Gtk_Tool_Button_Record'Class)
return Gtk.Actionable.Gtk_Actionable
function "+"
(Widget : access Gtk_Tool_Button_Record'Class)
return Gtk.Activatable.Gtk_Activatable
function "+"
(Widget : access Gtk_Tool_Button_Record'Class)
return Gtk.Buildable.Gtk_Buildable
function "-"
(Interf : Gtk.Actionable.Gtk_Actionable)
return Gtk_Tool_Button
function "-"
(Interf : Gtk.Activatable.Gtk_Activatable)
return Gtk_Tool_Button
function "-"
(Interf : Gtk.Buildable.Gtk_Buildable)
return Gtk_Tool_Button
type Cb_GObject_Void is not null access procedure
(Self : access Glib.Object.GObject_Record'Class);
type Cb_Gtk_Tool_Button_Void is not null access procedure
(Self : access Gtk_Tool_Button_Record'Class);
procedure Do_Set_Related_Action
(Self : not null access Gtk_Tool_Button_Record;
Action : not null access Gtk.Action.Gtk_Action_Record'Class)
function Get_Action_Name
(Self : not null access Gtk_Tool_Button_Record) return UTF8_String
function Get_Action_Target_Value
(Self : not null access Gtk_Tool_Button_Record)
return Glib.Variant.Gvariant
function Get_Icon_Name
(Button : not null access Gtk_Tool_Button_Record) return UTF8_String
Returns the name of the themed icon for the tool button, see Gtk.Tool_Button.Set_Icon_Name. Since: gtk+ 2.8
the icon name or null if the tool button has no themed icon
function Get_Icon_Widget
(Button : not null access Gtk_Tool_Button_Record)
return Gtk.Widget.Gtk_Widget
Return the widget used as icon widget on Button. See Gtk.Tool_Button.Set_Icon_Widget. Since: gtk+ 2.4
The widget used as icon on Button, or null.
function Get_Label
(Button : not null access Gtk_Tool_Button_Record) return UTF8_String
Returns the label used by the tool button, or null if the tool button doesn't have a label. or uses a the label from a stock item. The returned string is owned by GTK+, and must not be modified or freed. Since: gtk+ 2.4
The label, or null
function Get_Label_Widget
(Button : not null access Gtk_Tool_Button_Record)
return Gtk.Widget.Gtk_Widget
Returns the widget used as label on Button. See Gtk.Tool_Button.Set_Label_Widget. Since: gtk+ 2.4
The widget used as label on Button, or null.
function Get_Related_Action
(Self : not null access Gtk_Tool_Button_Record)
return Gtk.Action.Gtk_Action
function Get_Stock_Id
(Button : not null access Gtk_Tool_Button_Record) return UTF8_String
Returns the name of the stock item. See Gtk.Tool_Button.Set_Stock_Id. The returned string is owned by GTK+ and must not be freed or modifed. Since: gtk+ 2.4 Deprecated since 3.10, 1
the name of the stock item for Button.
function Get_Type return Glib.GType
function Get_Use_Action_Appearance
(Self : not null access Gtk_Tool_Button_Record) return Boolean
function Get_Use_Underline
(Button : not null access Gtk_Tool_Button_Record) return Boolean
Returns whether underscores in the label property are used as mnemonics on menu items on the overflow menu. See Gtk.Tool_Button.Set_Use_Underline. Since: gtk+ 2.4
True if underscores in the label property are used as mnemonics on menu items on the overflow menu.
procedure Gtk_New
(Button : out Gtk_Tool_Button;
Icon_Widget : Gtk.Widget.Gtk_Widget := null;
Label : UTF8_String := "")
Creates a new Gtk.Tool_Button.Gtk_Tool_Button using Icon_Widget as contents and Label as label. Since: gtk+ 2.4 Initialize does nothing if the object was already created with another call to Initialize* or G_New.
a widget that will be used as the button contents, or null
a string that will be used as label, or null
procedure Gtk_New_From_Stock
(Button : out Gtk_Tool_Button;
Stock_Id : UTF8_String)
Creates a new Gtk.Tool_Button.Gtk_Tool_Button containing the image and text from a stock item. Some stock ids have preprocessor macros like GTK_STOCK_OK and GTK_STOCK_APPLY. It is an error if Stock_Id is not a name of a stock item. Since: gtk+ 2.4 Initialize_From_Stock does nothing if the object was already created with another call to Initialize* or G_New.
the name of the stock item
type Gtk_Tool_Button is access all Gtk_Tool_Button_Record'Class;
function Gtk_Tool_Button_New
(Icon_Widget : Gtk.Widget.Gtk_Widget := null;
Label : UTF8_String := "") return Gtk_Tool_Button
Creates a new Gtk.Tool_Button.Gtk_Tool_Button using Icon_Widget as contents and Label as label. Since: gtk+ 2.4
a widget that will be used as the button contents, or null
a string that will be used as label, or null
function Gtk_Tool_Button_New_From_Stock
(Stock_Id : UTF8_String) return Gtk_Tool_Button
Creates a new Gtk.Tool_Button.Gtk_Tool_Button containing the image and text from a stock item. Some stock ids have preprocessor macros like GTK_STOCK_OK and GTK_STOCK_APPLY. It is an error if Stock_Id is not a name of a stock item. Since: gtk+ 2.4
the name of the stock item
type Gtk_Tool_Button_Record is new Gtk_Tool_Item_Record with null record;
Icon_Name_Property : constant Glib.Properties.Property_String;
The name of the themed icon displayed on the item. This property only has an effect if not overridden by Gtk.Tool_Button.Gtk_Tool_Button:label-widget, Gtk.Tool_Button.Gtk_Tool_Button:icon-widget or Gtk.Tool_Button.Gtk_Tool_Button:stock-id properties.
Icon_Widget_Property : constant Glib.Properties.Property_Object;
Type: Gtk.Widget.Gtk_Widget
package Implements_Gtk_Actionable is new Glib.Types.Implements
(Gtk.Actionable.Gtk_Actionable, Gtk_Tool_Button_Record, Gtk_Tool_Button);
package Implements_Gtk_Activatable is new Glib.Types.Implements
(Gtk.Activatable.Gtk_Activatable, Gtk_Tool_Button_Record, Gtk_Tool_Button);
package Implements_Gtk_Buildable is new Glib.Types.Implements
(Gtk.Buildable.Gtk_Buildable, Gtk_Tool_Button_Record, Gtk_Tool_Button);
procedure Initialize
(Button : not null access Gtk_Tool_Button_Record'Class;
Icon_Widget : Gtk.Widget.Gtk_Widget := null;
Label : UTF8_String := "")
Creates a new Gtk.Tool_Button.Gtk_Tool_Button using Icon_Widget as contents and Label as label. Since: gtk+ 2.4 Initialize does nothing if the object was already created with another call to Initialize* or G_New.
a widget that will be used as the button contents, or null
a string that will be used as label, or null
procedure Initialize_From_Stock
(Button : not null access Gtk_Tool_Button_Record'Class;
Stock_Id : UTF8_String)
Creates a new Gtk.Tool_Button.Gtk_Tool_Button containing the image and text from a stock item. Some stock ids have preprocessor macros like GTK_STOCK_OK and GTK_STOCK_APPLY. It is an error if Stock_Id is not a name of a stock item. Since: gtk+ 2.4 Initialize_From_Stock does nothing if the object was already created with another call to Initialize* or G_New.
the name of the stock item
Label_Property : constant Glib.Properties.Property_String;
Label_Widget_Property : constant Glib.Properties.Property_Object;
Type: Gtk.Widget.Gtk_Widget
procedure On_Clicked
(Self : not null access Gtk_Tool_Button_Record;
Call : Cb_GObject_Void;
Slot : not null access Glib.Object.GObject_Record'Class;
After : Boolean := False)
This signal is emitted when the tool button is clicked with the mouse or activated with the keyboard.
procedure On_Clicked
(Self : not null access Gtk_Tool_Button_Record;
Call : Cb_Gtk_Tool_Button_Void;
After : Boolean := False)
This signal is emitted when the tool button is clicked with the mouse or activated with the keyboard.
procedure Set_Action_Name
(Self : not null access Gtk_Tool_Button_Record;
Action_Name : UTF8_String := "")
procedure Set_Action_Target_Value
(Self : not null access Gtk_Tool_Button_Record;
Target_Value : Glib.Variant.Gvariant)
procedure Set_Detailed_Action_Name
(Self : not null access Gtk_Tool_Button_Record;
Detailed_Action_Name : UTF8_String)
procedure Set_Icon_Name
(Button : not null access Gtk_Tool_Button_Record;
Icon_Name : UTF8_String := "")
Sets the icon for the tool button from a named themed icon. See the docs for Gtk.Icon_Theme.Gtk_Icon_Theme for more details. The Gtk.Tool_Button.Gtk_Tool_Button:icon-name property only has an effect if not overridden by non-null Gtk.Tool_Button.Gtk_Tool_Button:label-widget, Gtk.Tool_Button.Gtk_Tool_Button:icon-widget and Gtk.Tool_Button.Gtk_Tool_Button:stock-id properties. Since: gtk+ 2.8
the name of the themed icon
procedure Set_Icon_Widget
(Button : not null access Gtk_Tool_Button_Record;
Icon_Widget : access Gtk.Widget.Gtk_Widget_Record'Class)
Sets Icon as the widget used as icon on Button. If Icon_Widget is null the icon is determined by the Gtk.Tool_Button.Gtk_Tool_Button:stock-id property. If the Gtk.Tool_Button.Gtk_Tool_Button:stock-id property is also null, Button will not have an icon. Since: gtk+ 2.4
the widget used as icon, or null
procedure Set_Label
(Button : not null access Gtk_Tool_Button_Record;
Label : UTF8_String := "")
Sets Label as the label used for the tool button. The Gtk.Tool_Button.Gtk_Tool_Button:label property only has an effect if not overridden by a non-null Gtk.Tool_Button.Gtk_Tool_Button:label-widget property. If both the Gtk.Tool_Button.Gtk_Tool_Button:label-widget and Gtk.Tool_Button.Gtk_Tool_Button:label properties are null, the label is determined by the Gtk.Tool_Button.Gtk_Tool_Button:stock-id property. If the Gtk.Tool_Button.Gtk_Tool_Button:stock-id property is also null, Button will not have a label. Since: gtk+ 2.4
a string that will be used as label, or null.
procedure Set_Label_Widget
(Button : not null access Gtk_Tool_Button_Record;
Label_Widget : access Gtk.Widget.Gtk_Widget_Record'Class)
Sets Label_Widget as the widget that will be used as the label for Button. If Label_Widget is null the Gtk.Tool_Button.Gtk_Tool_Button:label property is used as label. If Gtk.Tool_Button.Gtk_Tool_Button:label is also null, the label in the stock item determined by the Gtk.Tool_Button.Gtk_Tool_Button:stock-id property is used as label. If Gtk.Tool_Button.Gtk_Tool_Button:stock-id is also null, Button does not have a label. Since: gtk+ 2.4
the widget used as label, or null
procedure Set_Related_Action
(Self : not null access Gtk_Tool_Button_Record;
Action : not null access Gtk.Action.Gtk_Action_Record'Class)
procedure Set_Stock_Id
(Button : not null access Gtk_Tool_Button_Record;
Stock_Id : UTF8_String := "")
Sets the name of the stock item. See Gtk.Tool_Button.Gtk_New_From_Stock. The stock_id property only has an effect if not overridden by non-null Gtk.Tool_Button.Gtk_Tool_Button:label-widget and Gtk.Tool_Button.Gtk_Tool_Button:icon-widget properties. Since: gtk+ 2.4 Deprecated since 3.10, 1
a name of a stock item, or null
procedure Set_Use_Action_Appearance
(Self : not null access Gtk_Tool_Button_Record;
Use_Appearance : Boolean)
procedure Set_Use_Underline
(Button : not null access Gtk_Tool_Button_Record;
Use_Underline : Boolean)
If set, an underline in the label property indicates that the next character should be used for the mnemonic accelerator key in the overflow menu. For example, if the label property is "_Open" and Use_Underline is True, the label on the tool button will be "Open" and the item on the overflow menu will have an underlined "O". Labels shown on tool buttons never have mnemonics on them; this property only affects the menu item on the overflow menu. Since: gtk+ 2.4
whether the button label has the form "_Open"
Signal_Clicked : constant Glib.Signal_Name := "clicked";
This signal is emitted when the tool button is clicked with the mouse or activated with the keyboard.
Stock_Id_Property : constant Glib.Properties.Property_String;
procedure Sync_Action_Properties
(Self : not null access Gtk_Tool_Button_Record;
Action : access Gtk.Action.Gtk_Action_Record'Class)
Use_Underline_Property : constant Glib.Properties.Property_Boolean;