AdwSplitButton

A combined button and dropdown widget.

<picture> <source srcset="split-button-dark.png" media="(prefers-color-scheme: dark)"> <img src="split-button.png" alt="split-button"> </picture>

adw.split_button.SplitButton 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 gtk.button.Button and gtk.menu_button.MenuButton, see their documentation for details.

CSS nodes

splitbutton[.image-button][.text-button]
├── button
│   ╰── <content>
├── separator
╰── menubutton
    ╰── button.toggle
        ╰── arrow

adw.split_button.SplitButton's CSS node is called splitbutton. It contains the css nodes: button, separator, menubutton. See gtk.menu_button.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.

Accessibility

adw.split_button.SplitButton uses the gtk.types.AccessibleRole.Group role.

struct AdwSplitButton