Class
AdwViewSwitcherBar
Description [src]
final class Adw.ViewSwitcherBar : Gtk.Widget {
/* No available fields */
}
A view switcher action bar.
An action bar letting you switch between multiple views contained in a
AdwViewStack, via an AdwViewSwitcher. 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.
AdwViewSwitcherBar is intended to be used together with
AdwViewSwitcherTitle.
A common use case is to bind the AdwViewSwitcherBar:reveal property
to AdwViewSwitcherTitle:title-visible to automatically reveal the
view switcher bar when the title label is displayed in place of the view
switcher, as follows:
<object class="GtkWindow">
<child type="titlebar">
<object class="AdwHeaderBar">
<property name="centering-policy">strict</property>
<child type="title">
<object class="AdwViewSwitcherTitle" id="title">
<property name="stack">stack</property>
</object>
</child>
</object>
</child>
<child>
<object class="GtkBox">
<property name="orientation">vertical</property>
<child>
<object class="AdwViewStack" id="stack"/>
</child>
<child>
<object class="AdwViewSwitcherBar">
<property name="stack">stack</property>
<binding name="reveal">
<lookup name="title-visible">title</lookup>
</binding>
</object>
</child>
</object>
</child>
</object>
CSS nodes
AdwViewSwitcherBar has a single CSS node with nameviewswitcherbar.
| Available since: | 1.0 |
Instance methods
adw_view_switcher_bar_get_reveal
Gets whether self should be revealed or hidden.
Available since: 1.0
adw_view_switcher_bar_set_reveal
Sets whether self should be revealed or hidden.
Available since: 1.0