Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
The GtkStackSwitcher widget acts as a controller for a
Stack
; it shows a row of buttons to switch between
the various pages of the associated stack widget.
All the content for the buttons comes from the child properties
of the Stack
; the button visibility in a StackSwitcher
widget is controlled by the visibility of the child in the
Stack
.
It is possible to associate multiple StackSwitcher
widgets
with the same Stack
widget.
The GtkStackSwitcher widget was added in 3.10.
CSS nodes
GtkStackSwitcher has a single CSS node named stackswitcher and style class .stack-switcher.
When circumstances require it, GtkStackSwitcher adds the .needs-attention style class to the widgets representing the stack pages.
Synopsis
- newtype StackSwitcher = StackSwitcher (ManagedPtr StackSwitcher)
- class GObject o => IsStackSwitcher o
- toStackSwitcher :: (MonadIO m, IsStackSwitcher o) => o -> m StackSwitcher
- noStackSwitcher :: Maybe StackSwitcher
- stackSwitcherGetStack :: (HasCallStack, MonadIO m, IsStackSwitcher a) => a -> m (Maybe Stack)
- stackSwitcherNew :: (HasCallStack, MonadIO m) => m StackSwitcher
- stackSwitcherSetStack :: (HasCallStack, MonadIO m, IsStackSwitcher a, IsStack b) => a -> Maybe b -> m ()
- constructStackSwitcherIconSize :: IsStackSwitcher o => Int32 -> IO (GValueConstruct o)
- getStackSwitcherIconSize :: (MonadIO m, IsStackSwitcher o) => o -> m Int32
- setStackSwitcherIconSize :: (MonadIO m, IsStackSwitcher o) => o -> Int32 -> m ()
- clearStackSwitcherStack :: (MonadIO m, IsStackSwitcher o) => o -> m ()
- constructStackSwitcherStack :: (IsStackSwitcher o, IsStack a) => a -> IO (GValueConstruct o)
- getStackSwitcherStack :: (MonadIO m, IsStackSwitcher o) => o -> m (Maybe Stack)
- setStackSwitcherStack :: (MonadIO m, IsStackSwitcher o, IsStack a) => o -> a -> m ()
Exported types
newtype StackSwitcher Source #
Memory-managed wrapper type.
Instances
GObject StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher gobjectType :: StackSwitcher -> IO GType # | |
IsImplementorIface StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsObject StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsBuildable StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsOrientable StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsBox StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsContainer StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsWidget StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsStackSwitcher StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher |
class GObject o => IsStackSwitcher o Source #
Type class for types which can be safely cast to StackSwitcher
, for instance with toStackSwitcher
.
Instances
(GObject a, (UnknownAncestorError StackSwitcher a :: Constraint)) => IsStackSwitcher a Source # | |
Defined in GI.Gtk.Objects.StackSwitcher | |
IsStackSwitcher StackSwitcher Source # | |
Defined in GI.Gtk.Objects.StackSwitcher |
toStackSwitcher :: (MonadIO m, IsStackSwitcher o) => o -> m StackSwitcher Source #
Cast to StackSwitcher
, for types for which this is known to be safe. For general casts, use castTo
.
noStackSwitcher :: Maybe StackSwitcher Source #
A convenience alias for Nothing
:: Maybe
StackSwitcher
.
Methods
getStack
stackSwitcherGetStack Source #
:: (HasCallStack, MonadIO m, IsStackSwitcher a) | |
=> a |
|
-> m (Maybe Stack) | Returns: the stack, or |
Retrieves the stack.
See stackSwitcherSetStack
.
Since: 3.10
new
:: (HasCallStack, MonadIO m) | |
=> m StackSwitcher | Returns: a new |
Create a new StackSwitcher
.
Since: 3.10
setStack
stackSwitcherSetStack Source #
:: (HasCallStack, MonadIO m, IsStackSwitcher a, IsStack b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets the stack to control.
Since: 3.10
Properties
iconSize
Use the "icon-size" property to change the size of the image displayed
when a StackSwitcher
is displaying icons.
Since: 3.20
constructStackSwitcherIconSize :: IsStackSwitcher o => Int32 -> IO (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “icon-size
” property. This is rarely needed directly, but it is used by new
.
getStackSwitcherIconSize :: (MonadIO m, IsStackSwitcher o) => o -> m Int32 Source #
Get the value of the “icon-size
” property.
When overloading is enabled, this is equivalent to
get
stackSwitcher #iconSize
setStackSwitcherIconSize :: (MonadIO m, IsStackSwitcher o) => o -> Int32 -> m () Source #
Set the value of the “icon-size
” property.
When overloading is enabled, this is equivalent to
set
stackSwitcher [ #iconSize:=
value ]
stack
No description available in the introspection data.
clearStackSwitcherStack :: (MonadIO m, IsStackSwitcher o) => o -> m () Source #
Set the value of the “stack
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#stack
constructStackSwitcherStack :: (IsStackSwitcher o, IsStack a) => a -> IO (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “stack
” property. This is rarely needed directly, but it is used by new
.
getStackSwitcherStack :: (MonadIO m, IsStackSwitcher o) => o -> m (Maybe Stack) Source #
Get the value of the “stack
” property.
When overloading is enabled, this is equivalent to
get
stackSwitcher #stack
setStackSwitcherStack :: (MonadIO m, IsStackSwitcher o, IsStack a) => o -> a -> m () Source #
Set the value of the “stack
” property.
When overloading is enabled, this is equivalent to
set
stackSwitcher [ #stack:=
value ]