gi-adwaita-1.0.5: Adwaita bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Adw.Objects.Leaflet

Description

An adaptive container acting like a box or a stack.

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

The AdwLeaflet widget can display its children like a Box does or like a Stack does, adapting to size changes by switching between the two modes.

When there is enough space the children are displayed side by side, otherwise only one is displayed and the leaflet is said to be “folded”. The threshold is dictated by the preferred minimum sizes of the children. When a leaflet is folded, the children can be navigated using swipe gestures.

The “over” and “under” transition types stack the children one on top of the other, while the “slide” transition puts the children side by side. While navigating to a child on the side or below can be performed by swiping the current child away, navigating to an upper child requires dragging it from the edge where it resides. This doesn't affect non-dragging swipes.

CSS nodes

AdwLeaflet has a single CSS node with name leaflet. The node will get the style classes .folded when it is folded, .unfolded when it's not, or none if it hasn't computed its fold yet.

Synopsis

Exported types

newtype Leaflet Source #

Memory-managed wrapper type.

Constructors

Leaflet (ManagedPtr Leaflet) 

Instances

Instances details
Eq Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

Methods

(==) :: Leaflet -> Leaflet -> Bool #

(/=) :: Leaflet -> Leaflet -> Bool #

GObject Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

ManagedPtrNewtype Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

Methods

toManagedPtr :: Leaflet -> ManagedPtr Leaflet

TypedObject Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

Methods

glibType :: IO GType

HasParentTypes Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

IsGValue (Maybe Leaflet) Source #

Convert Leaflet to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.Adw.Objects.Leaflet

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe Leaflet -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe Leaflet)

type ParentTypes Leaflet Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

type ParentTypes Leaflet = '[Widget, Object, Swipeable, Accessible, Buildable, ConstraintTarget, Orientable]

class (GObject o, IsDescendantOf Leaflet o) => IsLeaflet o Source #

Type class for types which can be safely cast to Leaflet, for instance with toLeaflet.

Instances

Instances details
(GObject o, IsDescendantOf Leaflet o) => IsLeaflet o Source # 
Instance details

Defined in GI.Adw.Objects.Leaflet

toLeaflet :: (MonadIO m, IsLeaflet o) => o -> m Leaflet Source #

Cast to Leaflet, 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

Expand

Methods

actionSetEnabled, activate, activateAction, activateDefault, addController, addCssClass, addMnemonicLabel, addTickCallback, allocate, append, bindProperty, bindPropertyFull, childFocus, computeBounds, computeExpand, computePoint, computeTransform, contains, createPangoContext, createPangoLayout, disposeTemplate, dragCheckThreshold, errorBell, forceFloating, freezeNotify, getv, grabFocus, hasCssClass, hasDefault, hasFocus, hasVisibleFocus, hide, inDestruction, initTemplate, insertActionGroup, insertAfter, insertBefore, insertChildAfter, isAncestor, isDrawable, isFloating, isFocus, isSensitive, isVisible, keynavFailed, listMnemonicLabels, map, measure, mnemonicActivate, navigate, notify, notifyByPspec, observeChildren, observeControllers, pick, prepend, queueAllocate, queueDraw, queueResize, realize, ref, refSink, remove, removeController, removeCssClass, removeMnemonicLabel, removeTickCallback, reorderChildAfter, resetProperty, resetRelation, resetState, runDispose, shouldLayout, show, sizeAllocate, snapshotChild, stealData, stealQdata, thawNotify, translateCoordinates, triggerTooltipQuery, unmap, unparent, unrealize, unref, unsetStateFlags, updateNextAccessibleSibling, updateProperty, updateRelation, updateState, watchClosure.

Getters

getAccessibleParent, getAccessibleRole, getAdjacentChild, getAllocatedBaseline, getAllocatedHeight, getAllocatedWidth, getAllocation, getAncestor, getAtContext, getBounds, getBuildableId, getCanFocus, getCanNavigateBack, getCanNavigateForward, getCanTarget, getCanUnfold, getCancelProgress, getChildByName, getChildTransitionParams, getChildTransitionRunning, getChildVisible, getClipboard, getColor, getCssClasses, getCssName, getCursor, getData, getDirection, getDisplay, getDistance, getFirstAccessibleChild, getFirstChild, getFocusChild, getFocusOnClick, getFocusable, getFoldThresholdPolicy, getFolded, getFontMap, getFontOptions, getFrameClock, getHalign, getHasTooltip, getHeight, getHexpand, getHexpandSet, getHomogeneous, getLastChild, getLayoutManager, getMapped, getMarginBottom, getMarginEnd, getMarginStart, getMarginTop, getModeTransitionDuration, getName, getNative, getNextAccessibleSibling, getNextSibling, getOpacity, getOrientation, getOverflow, getPage, getPages, getPangoContext, getParent, getPlatformState, getPreferredSize, getPrevSibling, getPrimaryClipboard, getProgress, getProperty, getQdata, getRealized, getReceivesDefault, getRequestMode, getRoot, getScaleFactor, getSensitive, getSettings, getSize, getSizeRequest, getSnapPoints, getStateFlags, getStyleContext, getSwipeArea, getTemplateChild, getTooltipMarkup, getTooltipText, getTransitionType, getValign, getVexpand, getVexpandSet, getVisible, getVisibleChild, getVisibleChildName, getWidth.

Setters

setAccessibleParent, setCanFocus, setCanNavigateBack, setCanNavigateForward, setCanTarget, setCanUnfold, setChildTransitionParams, setChildVisible, setCssClasses, setCursor, setCursorFromName, setData, setDataFull, setDirection, setFocusChild, setFocusOnClick, setFocusable, setFoldThresholdPolicy, setFontMap, setFontOptions, setHalign, setHasTooltip, setHexpand, setHexpandSet, setHomogeneous, setLayoutManager, setMarginBottom, setMarginEnd, setMarginStart, setMarginTop, setModeTransitionDuration, setName, setOpacity, setOrientation, setOverflow, setParent, setProperty, setReceivesDefault, setSensitive, setSizeRequest, setStateFlags, setTooltipMarkup, setTooltipText, setTransitionType, setValign, setVexpand, setVexpandSet, setVisible, setVisibleChild, setVisibleChildName.

append

leafletAppend Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b) 
=> a

self: a leaflet

-> b

child: the widget to add

-> m LeafletPage

Returns: the [classleafletPage] for child

Adds a child to self.

getAdjacentChild

leafletGetAdjacentChild Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> NavigationDirection

direction: the direction

-> m (Maybe Widget)

Returns: the previous or next child

Finds the previous or next navigatable child.

This will be the same child [methodleaflet.navigate] or swipe gestures will navigate to.

If there's no child to navigate to, NULL will be returned instead.

See [propertyleafletPage:navigatable].

getCanNavigateBack

leafletGetCanNavigateBack Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: Whether gestures and shortcuts are enabled.

Gets whether gestures and shortcuts for navigating backward are enabled.

getCanNavigateForward

leafletGetCanNavigateForward Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: Whether gestures and shortcuts are enabled.

Gets whether gestures and shortcuts for navigating forward are enabled.

getCanUnfold

leafletGetCanUnfold Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: whether self can unfold

Gets whether self can unfold.

getChildByName

leafletGetChildByName Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Text

name: the name of the child to find

-> m (Maybe Widget)

Returns: the requested child of self

Finds the child of self with name.

Returns NULL if there is no child with this name.

See [propertyleafletPage:name].

getChildTransitionParams

leafletGetChildTransitionParams Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m SpringParams

Returns: the child transition parameters

Gets the child transition spring parameters for self.

getChildTransitionRunning

leafletGetChildTransitionRunning Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: whether a transition is currently running

Gets whether a child transition is currently running for self.

getFoldThresholdPolicy

leafletGetFoldThresholdPolicy Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m FoldThresholdPolicy 

Gets the fold threshold policy for self.

getFolded

leafletGetFolded Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: whether self is folded.

Gets whether self is folded.

The leaflet will be folded if the size allocated to it is smaller than the sum of the minimum or natural sizes of the children (see [propertyleaflet:fold-threshold-policy]), it will be unfolded otherwise.

getHomogeneous

leafletGetHomogeneous Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Bool

Returns: whether self is homogeneous

Gets whether self is homogeneous.

getModeTransitionDuration

leafletGetModeTransitionDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m Word32

Returns: the mode transition duration, in milliseconds.

Gets the mode transition animation duration for self.

getPage

leafletGetPage Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b) 
=> a

self: a leaflet

-> b

child: a child of self

-> m LeafletPage

Returns: the page object for child

Returns the [classleafletPage] object for child.

getPages

leafletGetPages Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m SelectionModel

Returns: a GtkSelectionModel for the leaflet's children

Returns a ListModel that contains the pages of the leaflet.

This can be used to keep an up-to-date view. The model also implements SelectionModel and can be used to track and change the visible page.

getTransitionType

leafletGetTransitionType Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m LeafletTransitionType

Returns: the current transition type of self

Gets the type of animation used for transitions between modes and children.

getVisibleChild

leafletGetVisibleChild Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m (Maybe Widget)

Returns: the visible child

Gets the widget currently visible when the leaflet is folded.

getVisibleChildName

leafletGetVisibleChildName Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> m (Maybe Text)

Returns: the name of the visible child

Gets the name of the currently visible child widget.

insertChildAfter

leafletInsertChildAfter Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b, IsWidget c) 
=> a

self: a leaflet

-> b

child: the widget to insert

-> Maybe c

sibling: the sibling after which to insert child

-> m LeafletPage

Returns: the [classleafletPage] for child

Inserts child in the position after sibling in the list of children.

If sibling is NULL, inserts child at the first position.

navigate

leafletNavigate Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> NavigationDirection

direction: the direction

-> m Bool

Returns: whether the visible child was changed

Navigates to the previous or next child.

The child must have the [propertyleafletPage:navigatable] property set to TRUE, otherwise it will be skipped.

This will be the same child as returned by [methodleaflet.get_adjacent_child] or navigated to via swipe gestures.

new

leafletNew Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> m Leaflet

Returns: the new created AdwLeaflet

Creates a new AdwLeaflet.

prepend

leafletPrepend Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b) 
=> a

self: a leaflet

-> b

child: the widget to prepend

-> m LeafletPage

Returns: the [classleafletPage] for child

Inserts child at the first position in self.

remove

leafletRemove Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b) 
=> a

self: a leaflet

-> b

child: the child to remove

-> m () 

Removes a child widget from self.

reorderChildAfter

leafletReorderChildAfter Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b, IsWidget c) 
=> a

self: a leaflet

-> b

child: the widget to move, must be a child of self

-> Maybe c

sibling: the sibling to move child after

-> m () 

Moves child to the position after sibling in the list of children.

If sibling is NULL, moves child to the first position.

setCanNavigateBack

leafletSetCanNavigateBack Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Bool

canNavigateBack: the new value

-> m () 

Sets whether gestures and shortcuts for navigating backward are enabled.

The supported gestures are:

  • One-finger swipe on touchscreens
  • Horizontal scrolling on touchpads (usually two-finger swipe)
  • Back/forward mouse buttons

The keyboard back/forward keys are also supported, as well as the <kbd>Alt</kbd>+<kbd>←</kbd> shortcut for horizontal orientation, or <kbd>Alt</kbd>+<kbd>↑</kbd> for vertical orientation.

If the orientation is horizontal, for right-to-left locales, gestures and shortcuts are reversed.

Only children that have [propertyleafletPage:navigatable] set to TRUE can be navigated to.

setCanNavigateForward

leafletSetCanNavigateForward Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Bool

canNavigateForward: the new value

-> m () 

Sets whether gestures and shortcuts for navigating forward are enabled.

The supported gestures are:

  • One-finger swipe on touchscreens
  • Horizontal scrolling on touchpads (usually two-finger swipe)
  • Back/forward mouse buttons

The keyboard back/forward keys are also supported, as well as the <kbd>Alt</kbd>+<kbd>→</kbd> shortcut for horizontal orientation, or <kbd>Alt</kbd>+<kbd>↓</kbd> for vertical orientation.

If the orientation is horizontal, for right-to-left locales, gestures and shortcuts are reversed.

Only children that have [propertyleafletPage:navigatable] set to TRUE can be navigated to.

setCanUnfold

leafletSetCanUnfold Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Bool

canUnfold: whether self can unfold

-> m () 

Sets whether self can unfold.

setChildTransitionParams

leafletSetChildTransitionParams Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> SpringParams

params: the new parameters

-> m () 

Sets the child transition spring parameters for self.

The default value is equivalent to:

c code

adw_spring_params_new (1, 0.5, 500)

setFoldThresholdPolicy

leafletSetFoldThresholdPolicy Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> FoldThresholdPolicy

policy: the policy to use

-> m () 

Sets the fold threshold policy for self.

If set to ADW_FOLD_THRESHOLD_POLICY_MINIMUM, it will only fold when the children cannot fit anymore. With ADW_FOLD_THRESHOLD_POLICY_NATURAL, it will fold as soon as children don't get their natural size.

This can be useful if you have a long ellipsizing label and want to let it ellipsize instead of immediately folding.

setHomogeneous

leafletSetHomogeneous Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Bool

homogeneous: whether to make self homogeneous

-> m () 

Sets self to be homogeneous or not.

If set to FALSE, different children can have different size along the opposite orientation.

setModeTransitionDuration

leafletSetModeTransitionDuration Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Word32

duration: the new duration, in milliseconds

-> m () 

Sets the mode transition animation duration for self.

setTransitionType

leafletSetTransitionType Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> LeafletTransitionType

transition: the new transition type

-> m () 

Sets the type of animation used for transitions between modes and children.

The transition type can be changed without problems at runtime, so it is possible to change the animation based on the mode or child that is about to become current.

setVisibleChild

leafletSetVisibleChild Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a, IsWidget b) 
=> a

self: a leaflet

-> b

visibleChild: the new child

-> m () 

Sets the widget currently visible when the leaflet is folded.

The transition is determined by [propertyleaflet:transition-type] and [propertyleaflet:child-transition-params]. The transition can be cancelled by the user, in which case visible child will change back to the previously visible child.

setVisibleChildName

leafletSetVisibleChildName Source #

Arguments

:: (HasCallStack, MonadIO m, IsLeaflet a) 
=> a

self: a leaflet

-> Text

name: the name of a child

-> m () 

Makes the child with the name name visible.

See [propertyleaflet:visible-child].

Properties

canNavigateBack

Whether gestures and shortcuts for navigating backward are enabled.

The supported gestures are:

  • One-finger swipe on touchscreens
  • Horizontal scrolling on touchpads (usually two-finger swipe)
  • Back/forward mouse buttons

The keyboard back/forward keys are also supported, as well as the <kbd>Alt</kbd>+<kbd>←</kbd> shortcut for horizontal orientation, or <kbd>Alt</kbd>+<kbd>↑</kbd> for vertical orientation.

If the orientation is horizontal, for right-to-left locales, gestures and shortcuts are reversed.

Only children that have [propertyleafletPage:navigatable] set to TRUE can be navigated to.

constructLeafletCanNavigateBack :: (IsLeaflet o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “can-navigate-back” property. This is rarely needed directly, but it is used by new.

getLeafletCanNavigateBack :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “can-navigate-back” property. When overloading is enabled, this is equivalent to

get leaflet #canNavigateBack

setLeafletCanNavigateBack :: (MonadIO m, IsLeaflet o) => o -> Bool -> m () Source #

Set the value of the “can-navigate-back” property. When overloading is enabled, this is equivalent to

set leaflet [ #canNavigateBack := value ]

canNavigateForward

Whether gestures and shortcuts for navigating forward are enabled.

The supported gestures are:

  • One-finger swipe on touchscreens
  • Horizontal scrolling on touchpads (usually two-finger swipe)
  • Back/forward mouse buttons

The keyboard back/forward keys are also supported, as well as the <kbd>Alt</kbd>+<kbd>→</kbd> shortcut for horizontal orientation, or <kbd>Alt</kbd>+<kbd>↓</kbd> for vertical orientation.

If the orientation is horizontal, for right-to-left locales, gestures and shortcuts are reversed.

Only children that have [propertyleafletPage:navigatable] set to TRUE can be navigated to.

constructLeafletCanNavigateForward :: (IsLeaflet o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “can-navigate-forward” property. This is rarely needed directly, but it is used by new.

getLeafletCanNavigateForward :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “can-navigate-forward” property. When overloading is enabled, this is equivalent to

get leaflet #canNavigateForward

setLeafletCanNavigateForward :: (MonadIO m, IsLeaflet o) => o -> Bool -> m () Source #

Set the value of the “can-navigate-forward” property. When overloading is enabled, this is equivalent to

set leaflet [ #canNavigateForward := value ]

canUnfold

Whether or not the leaflet can unfold.

constructLeafletCanUnfold :: (IsLeaflet o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “can-unfold” property. This is rarely needed directly, but it is used by new.

getLeafletCanUnfold :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “can-unfold” property. When overloading is enabled, this is equivalent to

get leaflet #canUnfold

setLeafletCanUnfold :: (MonadIO m, IsLeaflet o) => o -> Bool -> m () Source #

Set the value of the “can-unfold” property. When overloading is enabled, this is equivalent to

set leaflet [ #canUnfold := value ]

childTransitionParams

The child transition spring parameters.

The default value is equivalent to:

c code

adw_spring_params_new (1, 0.5, 500)

constructLeafletChildTransitionParams :: (IsLeaflet o, MonadIO m) => SpringParams -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “child-transition-params” property. This is rarely needed directly, but it is used by new.

getLeafletChildTransitionParams :: (MonadIO m, IsLeaflet o) => o -> m (Maybe SpringParams) Source #

Get the value of the “child-transition-params” property. When overloading is enabled, this is equivalent to

get leaflet #childTransitionParams

setLeafletChildTransitionParams :: (MonadIO m, IsLeaflet o) => o -> SpringParams -> m () Source #

Set the value of the “child-transition-params” property. When overloading is enabled, this is equivalent to

set leaflet [ #childTransitionParams := value ]

childTransitionRunning

Whether a child transition is currently running.

getLeafletChildTransitionRunning :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “child-transition-running” property. When overloading is enabled, this is equivalent to

get leaflet #childTransitionRunning

foldThresholdPolicy

Determines when the leaflet will fold.

If set to ADW_FOLD_THRESHOLD_POLICY_MINIMUM, it will only fold when the children cannot fit anymore. With ADW_FOLD_THRESHOLD_POLICY_NATURAL, it will fold as soon as children don't get their natural size.

This can be useful if you have a long ellipsizing label and want to let it ellipsize instead of immediately folding.

constructLeafletFoldThresholdPolicy :: (IsLeaflet o, MonadIO m) => FoldThresholdPolicy -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “fold-threshold-policy” property. This is rarely needed directly, but it is used by new.

getLeafletFoldThresholdPolicy :: (MonadIO m, IsLeaflet o) => o -> m FoldThresholdPolicy Source #

Get the value of the “fold-threshold-policy” property. When overloading is enabled, this is equivalent to

get leaflet #foldThresholdPolicy

setLeafletFoldThresholdPolicy :: (MonadIO m, IsLeaflet o) => o -> FoldThresholdPolicy -> m () Source #

Set the value of the “fold-threshold-policy” property. When overloading is enabled, this is equivalent to

set leaflet [ #foldThresholdPolicy := value ]

folded

Whether the leaflet is folded.

The leaflet will be folded if the size allocated to it is smaller than the sum of the minimum or natural sizes of the children (see [propertyleaflet:fold-threshold-policy]), it will be unfolded otherwise.

getLeafletFolded :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “folded” property. When overloading is enabled, this is equivalent to

get leaflet #folded

homogeneous

Whether the leaflet allocates the same size for all children when folded.

If set to FALSE, different children can have different size along the opposite orientation.

constructLeafletHomogeneous :: (IsLeaflet o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “homogeneous” property. This is rarely needed directly, but it is used by new.

getLeafletHomogeneous :: (MonadIO m, IsLeaflet o) => o -> m Bool Source #

Get the value of the “homogeneous” property. When overloading is enabled, this is equivalent to

get leaflet #homogeneous

setLeafletHomogeneous :: (MonadIO m, IsLeaflet o) => o -> Bool -> m () Source #

Set the value of the “homogeneous” property. When overloading is enabled, this is equivalent to

set leaflet [ #homogeneous := value ]

modeTransitionDuration

The mode transition animation duration, in milliseconds.

constructLeafletModeTransitionDuration :: (IsLeaflet o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “mode-transition-duration” property. This is rarely needed directly, but it is used by new.

getLeafletModeTransitionDuration :: (MonadIO m, IsLeaflet o) => o -> m Word32 Source #

Get the value of the “mode-transition-duration” property. When overloading is enabled, this is equivalent to

get leaflet #modeTransitionDuration

setLeafletModeTransitionDuration :: (MonadIO m, IsLeaflet o) => o -> Word32 -> m () Source #

Set the value of the “mode-transition-duration” property. When overloading is enabled, this is equivalent to

set leaflet [ #modeTransitionDuration := value ]

pages

A selection model with the leaflet's pages.

This can be used to keep an up-to-date view. The model also implements SelectionModel and can be used to track and change the visible page.

getLeafletPages :: (MonadIO m, IsLeaflet o) => o -> m (Maybe SelectionModel) Source #

Get the value of the “pages” property. When overloading is enabled, this is equivalent to

get leaflet #pages

transitionType

The type of animation used for transitions between modes and children.

The transition type can be changed without problems at runtime, so it is possible to change the animation based on the mode or child that is about to become current.

constructLeafletTransitionType :: (IsLeaflet o, MonadIO m) => LeafletTransitionType -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “transition-type” property. This is rarely needed directly, but it is used by new.

getLeafletTransitionType :: (MonadIO m, IsLeaflet o) => o -> m LeafletTransitionType Source #

Get the value of the “transition-type” property. When overloading is enabled, this is equivalent to

get leaflet #transitionType

setLeafletTransitionType :: (MonadIO m, IsLeaflet o) => o -> LeafletTransitionType -> m () Source #

Set the value of the “transition-type” property. When overloading is enabled, this is equivalent to

set leaflet [ #transitionType := value ]

visibleChild

The widget currently visible when the leaflet is folded.

The transition is determined by [propertyleaflet:transition-type] and [propertyleaflet:child-transition-params]. The transition can be cancelled by the user, in which case visible child will change back to the previously visible child.

constructLeafletVisibleChild :: (IsLeaflet o, MonadIO m, IsWidget a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “visible-child” property. This is rarely needed directly, but it is used by new.

getLeafletVisibleChild :: (MonadIO m, IsLeaflet o) => o -> m (Maybe Widget) Source #

Get the value of the “visible-child” property. When overloading is enabled, this is equivalent to

get leaflet #visibleChild

setLeafletVisibleChild :: (MonadIO m, IsLeaflet o, IsWidget a) => o -> a -> m () Source #

Set the value of the “visible-child” property. When overloading is enabled, this is equivalent to

set leaflet [ #visibleChild := value ]

visibleChildName

The name of the widget currently visible when the leaflet is folded.

See [propertyleaflet:visible-child].

constructLeafletVisibleChildName :: (IsLeaflet o, MonadIO m) => Text -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “visible-child-name” property. This is rarely needed directly, but it is used by new.

getLeafletVisibleChildName :: (MonadIO m, IsLeaflet o) => o -> m (Maybe Text) Source #

Get the value of the “visible-child-name” property. When overloading is enabled, this is equivalent to

get leaflet #visibleChildName

setLeafletVisibleChildName :: (MonadIO m, IsLeaflet o) => o -> Text -> m () Source #

Set the value of the “visible-child-name” property. When overloading is enabled, this is equivalent to

set leaflet [ #visibleChildName := value ]