ViewSwitcherBar
Object Hierarchy:
Description:
[ Version ( since = "1.0" ) ]
public sealed class ViewSwitcherBar : Bin, Implementor, Buildable
A view switcher action bar.
An action bar letting you switch between multiple views offered by a [class@Gtk.Stack], via an [class@ViewSwitcher]. It is designed to be put at the bottom of a window and to be revealed only on really narrow windows e.g. on mobile phones. It can't be revealed if there are less than two pages.
`HdyViewSwitcherBar` is intended to be used together with [class@ViewSwitcherTitle].
A common use case is to bind the [property@ViewSwitcherBar:reveal] property to [property@ViewSwitcherTitle:title-visible] to automatically reveal the view switcher bar when the title label is displayed in place of the view switcher, as follows:
```xml <object class="GtkWindow"/> <child type="titlebar"> <object class="HdyHeaderBar"> <property name="centering-policy">strict</property> <child type="title"> <object class="HdyViewSwitcherTitle" id="view_switcher_title"> <property name="stack">stack</property> </object> </child> </object> </child > <child> <object class="GtkBox"> <child> <object class="GtkStack" id="stack"/> </child> <child> <object class="HdyViewSwitcherBar"> <property name="stack">stack</property> <property name="reveal" bind-source="view_switcher_title" bind-property="title-visible" bind-flags="sync-create"/> </object> </child> </object > </child> </object> ```
CSS nodes
`HdyViewSwitcherBar` has a single CSS node with name `viewswitcherbar`.