Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
An object handling composite title bars.
The HdyHeaderGroup
object handles the header bars of a composite title bar.
It splits the window decoration across the header bars, giving the left side
of the decorations to the leftmost header bar, and the right side of the
decorations to the rightmost header bar. See
[methodheaderBar
.set_decoration_layout].
The [propertyheaderGroup
:decorate-all] property can be used in conjunction
with [propertyleaflet
:folded] when the title bar is split across the pages
of a [classleaflet
] to automatically display the decorations on all the
pages when the leaflet is folded.
You can nest header groups, which is convenient when you nest leaflets too:
xml code
<object class="HdyHeaderGroup" id="inner_header_group"> <property name="decorate-all" bind-source="inner_leaflet" bind-property="folded" bind-flags="sync-create"/> <headerbars> <headerbar name="inner_header_bar_1"/> <headerbar name="inner_header_bar_2"/> </headerbars> </object> <object class="HdyHeaderGroup" id="outer_header_group"> <property name="decorate-all" bind-source="outer_leaflet" bind-property="folded" bind-flags="sync-create"/> <headerbars> <headerbar name="inner_header_group"/> <headerbar name="outer_header_bar"/> </headerbars> </object>
Since: 1.0
Synopsis
- newtype HeaderGroup = HeaderGroup (ManagedPtr HeaderGroup)
- class (GObject o, IsDescendantOf HeaderGroup o) => IsHeaderGroup o
- toHeaderGroup :: (MonadIO m, IsHeaderGroup o) => o -> m HeaderGroup
- headerGroupAddGtkHeaderBar :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) => a -> b -> m ()
- headerGroupAddHeaderBar :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) => a -> b -> m ()
- headerGroupAddHeaderGroup :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroup b) => a -> b -> m ()
- headerGroupGetChildren :: (HasCallStack, MonadIO m, IsHeaderGroup a) => a -> m [HeaderGroupChild]
- headerGroupGetDecorateAll :: (HasCallStack, MonadIO m, IsHeaderGroup a) => a -> m Bool
- headerGroupNew :: (HasCallStack, MonadIO m) => m HeaderGroup
- headerGroupRemoveChild :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroupChild b) => a -> b -> m ()
- headerGroupRemoveGtkHeaderBar :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) => a -> b -> m ()
- headerGroupRemoveHeaderBar :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) => a -> b -> m ()
- headerGroupRemoveHeaderGroup :: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroup b) => a -> b -> m ()
- headerGroupSetDecorateAll :: (HasCallStack, MonadIO m, IsHeaderGroup a) => a -> Bool -> m ()
- constructHeaderGroupDecorateAll :: (IsHeaderGroup o, MonadIO m) => Bool -> m (GValueConstruct o)
- getHeaderGroupDecorateAll :: (MonadIO m, IsHeaderGroup o) => o -> m Bool
- setHeaderGroupDecorateAll :: (MonadIO m, IsHeaderGroup o) => o -> Bool -> m ()
- type HeaderGroupUpdateDecorationLayoutsCallback = IO ()
- afterHeaderGroupUpdateDecorationLayouts :: (IsHeaderGroup a, MonadIO m) => a -> ((?self :: a) => HeaderGroupUpdateDecorationLayoutsCallback) -> m SignalHandlerId
- onHeaderGroupUpdateDecorationLayouts :: (IsHeaderGroup a, MonadIO m) => a -> ((?self :: a) => HeaderGroupUpdateDecorationLayoutsCallback) -> m SignalHandlerId
Exported types
newtype HeaderGroup Source #
Memory-managed wrapper type.
HeaderGroup (ManagedPtr HeaderGroup) |
Instances
Eq HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup (==) :: HeaderGroup -> HeaderGroup -> Bool # (/=) :: HeaderGroup -> HeaderGroup -> Bool # | |
GObject HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup | |
ManagedPtrNewtype HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup toManagedPtr :: HeaderGroup -> ManagedPtr HeaderGroup | |
TypedObject HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup | |
HasParentTypes HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup | |
IsGValue (Maybe HeaderGroup) Source # | Convert |
Defined in GI.Handy.Objects.HeaderGroup gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe HeaderGroup -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe HeaderGroup) | |
type ParentTypes HeaderGroup Source # | |
Defined in GI.Handy.Objects.HeaderGroup type ParentTypes HeaderGroup = '[Object, Buildable] |
class (GObject o, IsDescendantOf HeaderGroup o) => IsHeaderGroup o Source #
Type class for types which can be safely cast to HeaderGroup
, for instance with toHeaderGroup
.
Instances
(GObject o, IsDescendantOf HeaderGroup o) => IsHeaderGroup o Source # | |
Defined in GI.Handy.Objects.HeaderGroup |
toHeaderGroup :: (MonadIO m, IsHeaderGroup o) => o -> m HeaderGroup Source #
Cast to HeaderGroup
, for types for which this is known to be safe. For general casts, use castTo
.
Methods
Click to display all available methods, including inherited ones
Methods
addChild, addGtkHeaderBar, addHeaderBar, addHeaderGroup, bindProperty, bindPropertyFull, constructChild, customFinished, customTagEnd, customTagStart, forceFloating, freezeNotify, getv, isFloating, notify, notifyByPspec, parserFinished, ref, refSink, removeChild, removeGtkHeaderBar, removeHeaderBar, removeHeaderGroup, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getChildren, getData, getDecorateAll, getInternalChild, getName, getProperty, getQdata.
Setters
setBuildableProperty, setData, setDataFull, setDecorateAll, setName, setProperty.
addGtkHeaderBar
headerGroupAddGtkHeaderBar Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) | |
=> a |
|
-> b |
|
-> m () |
Adds headerBar
to self
.
When the widget is destroyed or no longer referenced elsewhere, it will be removed from the header group.
Since: 1.0
addHeaderBar
headerGroupAddHeaderBar Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) | |
=> a |
|
-> b |
|
-> m () |
Adds headerBar
to self
.
When the widget is destroyed or no longer referenced elsewhere, it will be removed from the header group.
Since: 1.0
addHeaderGroup
headerGroupAddHeaderGroup Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroup b) | |
=> a |
|
-> b |
|
-> m () |
Adds headerGroup
to self
.
When the nested group is no longer referenced elsewhere, it will be removed from the header group.
Since: 1.0
getChildren
headerGroupGetChildren Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a) | |
=> a |
|
-> m [HeaderGroupChild] | Returns: the list of children |
Returns the list of children associated with self
.
Since: 1.0
getDecorateAll
headerGroupGetDecorateAll Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a) | |
=> a |
|
-> m Bool | Returns: whether the elements of the group should all receive the full decoration |
Gets whether the elements of the group should all receive the full decoration.
Since: 1.0
new
:: (HasCallStack, MonadIO m) | |
=> m HeaderGroup | Returns: the newly created |
Creates a new HdyHeaderGroup
.
Since: 1.0
removeChild
headerGroupRemoveChild Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroupChild b) | |
=> a |
|
-> b |
|
-> m () |
Removes child
from self
.
Since: 1.0
removeGtkHeaderBar
headerGroupRemoveGtkHeaderBar Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) | |
=> a |
|
-> b |
|
-> m () |
Removes headerBar
from self
.
Since: 1.0
removeHeaderBar
headerGroupRemoveHeaderBar Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderBar b) | |
=> a |
|
-> b |
|
-> m () |
Removes headerBar
from self
.
Since: 1.0
removeHeaderGroup
headerGroupRemoveHeaderGroup Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a, IsHeaderGroup b) | |
=> a |
|
-> b |
|
-> m () |
Removes a nested HdyHeaderGroup
from self
.
Since: 1.0
setDecorateAll
headerGroupSetDecorateAll Source #
:: (HasCallStack, MonadIO m, IsHeaderGroup a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether the elements of the group should all receive the full decoration.
Since: 1.0
Properties
decorateAll
Whether the elements of the group should all receive the full decoration.
This is useful in conjunction with [propertyleaflet
:folded] when the
leaflet contains the header bars of the group, as you want them all to
display the complete decoration when the leaflet is folded.
Since: 1.0
constructHeaderGroupDecorateAll :: (IsHeaderGroup o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “decorate-all
” property. This is rarely needed directly, but it is used by new
.
getHeaderGroupDecorateAll :: (MonadIO m, IsHeaderGroup o) => o -> m Bool Source #
Get the value of the “decorate-all
” property.
When overloading is enabled, this is equivalent to
get
headerGroup #decorateAll
setHeaderGroupDecorateAll :: (MonadIO m, IsHeaderGroup o) => o -> Bool -> m () Source #
Set the value of the “decorate-all
” property.
When overloading is enabled, this is equivalent to
set
headerGroup [ #decorateAll:=
value ]
Signals
updateDecorationLayouts
type HeaderGroupUpdateDecorationLayoutsCallback = IO () Source #
This signal is emitted before updating the decoration layouts.
Since: 1.0
afterHeaderGroupUpdateDecorationLayouts :: (IsHeaderGroup a, MonadIO m) => a -> ((?self :: a) => HeaderGroupUpdateDecorationLayoutsCallback) -> m SignalHandlerId Source #
Connect a signal handler for the updateDecorationLayouts signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after
headerGroup #updateDecorationLayouts callback
By default the object invoking the signal is not passed to the callback.
If you need to access it, you can use the implit ?self
parameter.
Note that this requires activating the ImplicitParams
GHC extension.
onHeaderGroupUpdateDecorationLayouts :: (IsHeaderGroup a, MonadIO m) => a -> ((?self :: a) => HeaderGroupUpdateDecorationLayoutsCallback) -> m SignalHandlerId Source #
Connect a signal handler for the updateDecorationLayouts signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on
headerGroup #updateDecorationLayouts callback