SplitButton
A combined button and dropdown widget.
AdwSplitButton
is typically used to present a set of actions in a menu, but allow access to one of them with a single click.
The API is very similar to class@Gtk.Button and class@Gtk.MenuButton, see their documentation for details.
CSS nodes
splitbutton[.image-button][.text-button]
├── button
│ ╰── <content>
├── separator
╰── menubutton
╰── button.toggle
╰── arrow
AdwSplitButton
's CSS node is called splitbutton
. It contains the css nodes: button
, separator
, menubutton
. See class@Gtk.MenuButton documentation for the menubutton
contents.
The main CSS node will contain the .image-button
or .text-button
style classes matching the button contents. The nested button nodes will never contain them.
Style classes
AdwSplitButton
can use some of the same style classes as class@Gtk.Button:
style-classes.html#suggested-action
style-classes.html#destructive-action
style-classes.html#flat
style-classes.html#raised
Other style classes, like .pill
, cannot be used.
Accessibility
AdwSplitButton
uses the GTK_ACCESSIBLE_ROLE_GROUP
role.
Skipped during bindings generation
method
icon-name
: Property TypeInfo of getter and setter do not matchmethod
label
: Property TypeInfo of getter and setter do not match
Constructors
Properties
Functions
Emitted to animate press then release.
Emitted when the button has been activated (pressed and released).
gets whether the button can be smaller than the natural size of its contents.
Gets the direction in which the popup will be popped up.
Gets the tooltip of the dropdown button of @self.
Gets the name of the icon used to automatically populate the button.
Gets the menu model from which the popup will be created.
Gets the popover that will be popped up when the dropdown is clicked.
Gets whether an underline in the text indicates a mnemonic.
Sets whether the button can be smaller than the natural size of its contents.
Sets the direction in which the popup will be popped up.
Sets the tooltip of the dropdown button of @self.
Sets the name of the icon used to automatically populate the button.
Sets the menu model from which the popup will be created.
Sets the popover that will be popped up when the dropdown is clicked.
Sets whether an underline in the text indicates a mnemonic.