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 |
The GridLayout
structure contains only private data
and should be accessed using the provided API
Since: 1.12
Synopsis
- newtype GridLayout = GridLayout (ManagedPtr GridLayout)
- class (GObject o, IsDescendantOf GridLayout o) => IsGridLayout o
- toGridLayout :: (MonadIO m, IsGridLayout o) => o -> m GridLayout
- gridLayoutAttach :: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b) => a -> b -> Int32 -> Int32 -> Int32 -> Int32 -> m ()
- gridLayoutAttachNextTo :: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b, IsActor c) => a -> b -> Maybe c -> GridPosition -> Int32 -> Int32 -> m ()
- gridLayoutGetChildAt :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Int32 -> Int32 -> m Actor
- gridLayoutGetColumnHomogeneous :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> m Bool
- gridLayoutGetColumnSpacing :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> m Word32
- gridLayoutGetOrientation :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> m Orientation
- gridLayoutGetRowHomogeneous :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> m Bool
- gridLayoutGetRowSpacing :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> m Word32
- gridLayoutInsertColumn :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Int32 -> m ()
- gridLayoutInsertNextTo :: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b) => a -> b -> GridPosition -> m ()
- gridLayoutInsertRow :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Int32 -> m ()
- gridLayoutNew :: (HasCallStack, MonadIO m) => m GridLayout
- gridLayoutSetColumnHomogeneous :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Bool -> m ()
- gridLayoutSetColumnSpacing :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Word32 -> m ()
- gridLayoutSetOrientation :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Orientation -> m ()
- gridLayoutSetRowHomogeneous :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Bool -> m ()
- gridLayoutSetRowSpacing :: (HasCallStack, MonadIO m, IsGridLayout a) => a -> Word32 -> m ()
- constructGridLayoutColumnHomogeneous :: (IsGridLayout o, MonadIO m) => Bool -> m (GValueConstruct o)
- getGridLayoutColumnHomogeneous :: (MonadIO m, IsGridLayout o) => o -> m Bool
- setGridLayoutColumnHomogeneous :: (MonadIO m, IsGridLayout o) => o -> Bool -> m ()
- constructGridLayoutColumnSpacing :: (IsGridLayout o, MonadIO m) => Word32 -> m (GValueConstruct o)
- getGridLayoutColumnSpacing :: (MonadIO m, IsGridLayout o) => o -> m Word32
- setGridLayoutColumnSpacing :: (MonadIO m, IsGridLayout o) => o -> Word32 -> m ()
- constructGridLayoutOrientation :: (IsGridLayout o, MonadIO m) => Orientation -> m (GValueConstruct o)
- getGridLayoutOrientation :: (MonadIO m, IsGridLayout o) => o -> m Orientation
- setGridLayoutOrientation :: (MonadIO m, IsGridLayout o) => o -> Orientation -> m ()
- constructGridLayoutRowHomogeneous :: (IsGridLayout o, MonadIO m) => Bool -> m (GValueConstruct o)
- getGridLayoutRowHomogeneous :: (MonadIO m, IsGridLayout o) => o -> m Bool
- setGridLayoutRowHomogeneous :: (MonadIO m, IsGridLayout o) => o -> Bool -> m ()
- constructGridLayoutRowSpacing :: (IsGridLayout o, MonadIO m) => Word32 -> m (GValueConstruct o)
- getGridLayoutRowSpacing :: (MonadIO m, IsGridLayout o) => o -> m Word32
- setGridLayoutRowSpacing :: (MonadIO m, IsGridLayout o) => o -> Word32 -> m ()
Exported types
newtype GridLayout Source #
Memory-managed wrapper type.
GridLayout (ManagedPtr GridLayout) |
Instances
Eq GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout (==) :: GridLayout -> GridLayout -> Bool # (/=) :: GridLayout -> GridLayout -> Bool # | |
GObject GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout | |
ManagedPtrNewtype GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout toManagedPtr :: GridLayout -> ManagedPtr GridLayout | |
TypedObject GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout | |
HasParentTypes GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout | |
IsGValue (Maybe GridLayout) Source # | Convert |
Defined in GI.Clutter.Objects.GridLayout gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe GridLayout -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe GridLayout) | |
type ParentTypes GridLayout Source # | |
Defined in GI.Clutter.Objects.GridLayout |
class (GObject o, IsDescendantOf GridLayout o) => IsGridLayout o Source #
Type class for types which can be safely cast to GridLayout
, for instance with toGridLayout
.
Instances
(GObject o, IsDescendantOf GridLayout o) => IsGridLayout o Source # | |
Defined in GI.Clutter.Objects.GridLayout |
toGridLayout :: (MonadIO m, IsGridLayout o) => o -> m GridLayout Source #
Cast to GridLayout
, 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
allocate, attach, attachNextTo, beginAnimation, bindProperty, bindPropertyFull, childGetProperty, childSetProperty, endAnimation, findChildProperty, forceFloating, freezeNotify, getv, insertColumn, insertNextTo, insertRow, isFloating, layoutChanged, listChildProperties, notify, notifyByPspec, ref, refSink, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getAnimationProgress, getChildAt, getChildMeta, getColumnHomogeneous, getColumnSpacing, getData, getOrientation, getPreferredHeight, getPreferredWidth, getProperty, getQdata, getRowHomogeneous, getRowSpacing.
Setters
setColumnHomogeneous, setColumnSpacing, setContainer, setData, setDataFull, setOrientation, setProperty, setRowHomogeneous, setRowSpacing.
attach
:: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b) | |
=> a |
|
-> b |
|
-> Int32 |
|
-> Int32 |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Adds a widget to the grid.
The position of child
is determined by left
and top
. The
number of 'cells' that child
will occupy is determined by
width
and height
.
Since: 1.12
attachNextTo
gridLayoutAttachNextTo Source #
:: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b, IsActor c) | |
=> a |
|
-> b |
|
-> Maybe c |
|
-> GridPosition |
|
-> Int32 |
|
-> Int32 |
|
-> m () |
Adds a actor to the grid.
The actor is placed next to sibling
, on the side determined by
side
. When sibling
is Nothing
, the actor is placed in row (for
left or right placement) or column 0 (for top or bottom placement),
at the end indicated by side
.
Attaching widgets labeled [1], [2], [3] with sibling
== Nothing
and
side
== GridPositionLeft
yields a layout of [3][2][1].
Since: 1.12
getChildAt
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Int32 |
|
-> Int32 |
|
-> m Actor | Returns: the child at the given position, or |
Gets the child of layout
whose area covers the grid
cell whose upper left corner is at left
, top
.
Since: 1.12
getColumnHomogeneous
gridLayoutGetColumnHomogeneous Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> m Bool | Returns: whether all columns of |
Returns whether all columns of layout
have the same width.
getColumnSpacing
gridLayoutGetColumnSpacing Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> m Word32 | Returns: the spacing between coluns of |
Retrieves the spacing set using gridLayoutSetColumnSpacing
Since: 1.12
getOrientation
gridLayoutGetOrientation Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> m Orientation | Returns: the orientation of the layout |
Retrieves the orientation of the layout
.
Since: 1.12
getRowHomogeneous
gridLayoutGetRowHomogeneous Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> m Bool | Returns: whether all rows of |
Returns whether all rows of layout
have the same height.
Since: 1.12
getRowSpacing
gridLayoutGetRowSpacing Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> m Word32 | Returns: the spacing between rows of |
Retrieves the spacing set using gridLayoutSetRowSpacing
Since: 1.12
insertColumn
gridLayoutInsertColumn Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Int32 |
|
-> m () |
Inserts a column at the specified position.
Children which are attached at or to the right of this position are moved one column to the right. Children which span across this position are grown to span the new column.
Since: 1.12
insertNextTo
gridLayoutInsertNextTo Source #
:: (HasCallStack, MonadIO m, IsGridLayout a, IsActor b) | |
=> a |
|
-> b |
|
-> GridPosition |
|
-> m () |
Inserts a row or column at the specified position.
The new row or column is placed next to sibling
, on the side
determined by side
. If side
is GridPositionLeft
or
GridPositionBottom
, a row is inserted. If side
is
GridPositionLeft
of GridPositionRight
,
a column is inserted.
Since: 1.12
insertRow
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Int32 |
|
-> m () |
Inserts a row at the specified position.
Children which are attached at or below this position are moved one row down. Children which span across this position are grown to span the new row.
Since: 1.12
new
:: (HasCallStack, MonadIO m) | |
=> m GridLayout | Returns: the new |
Creates a new GridLayout
setColumnHomogeneous
gridLayoutSetColumnHomogeneous Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether all columns of layout
will have the same width.
Since: 1.12
setColumnSpacing
gridLayoutSetColumnSpacing Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Word32 |
|
-> m () |
Sets the spacing between columns of layout
Since: 1.12
setOrientation
gridLayoutSetOrientation Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Orientation |
|
-> m () |
Sets the orientation of the layout
.
GridLayout
uses the orientation as a hint when adding
children to the Actor
using it as a layout manager via
actorAddChild
; changing this value will not have
any effect on children that are already part of the layout.
Since: 1.12
setRowHomogeneous
gridLayoutSetRowHomogeneous Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether all rows of layout
will have the same height.
Since: 1.12
setRowSpacing
gridLayoutSetRowSpacing Source #
:: (HasCallStack, MonadIO m, IsGridLayout a) | |
=> a |
|
-> Word32 |
|
-> m () |
Sets the spacing between rows of layout
Since: 1.12
Properties
columnHomogeneous
Whether all columns of the layout should have the same width
Since: 1.12
constructGridLayoutColumnHomogeneous :: (IsGridLayout o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “column-homogeneous
” property. This is rarely needed directly, but it is used by new
.
getGridLayoutColumnHomogeneous :: (MonadIO m, IsGridLayout o) => o -> m Bool Source #
Get the value of the “column-homogeneous
” property.
When overloading is enabled, this is equivalent to
get
gridLayout #columnHomogeneous
setGridLayoutColumnHomogeneous :: (MonadIO m, IsGridLayout o) => o -> Bool -> m () Source #
Set the value of the “column-homogeneous
” property.
When overloading is enabled, this is equivalent to
set
gridLayout [ #columnHomogeneous:=
value ]
columnSpacing
The amount of space in pixels between two consecutive columns
Since: 1.12
constructGridLayoutColumnSpacing :: (IsGridLayout o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “column-spacing
” property. This is rarely needed directly, but it is used by new
.
getGridLayoutColumnSpacing :: (MonadIO m, IsGridLayout o) => o -> m Word32 Source #
Get the value of the “column-spacing
” property.
When overloading is enabled, this is equivalent to
get
gridLayout #columnSpacing
setGridLayoutColumnSpacing :: (MonadIO m, IsGridLayout o) => o -> Word32 -> m () Source #
Set the value of the “column-spacing
” property.
When overloading is enabled, this is equivalent to
set
gridLayout [ #columnSpacing:=
value ]
orientation
The orientation of the layout, either horizontal or vertical
Since: 1.12
constructGridLayoutOrientation :: (IsGridLayout o, MonadIO m) => Orientation -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “orientation
” property. This is rarely needed directly, but it is used by new
.
getGridLayoutOrientation :: (MonadIO m, IsGridLayout o) => o -> m Orientation Source #
Get the value of the “orientation
” property.
When overloading is enabled, this is equivalent to
get
gridLayout #orientation
setGridLayoutOrientation :: (MonadIO m, IsGridLayout o) => o -> Orientation -> m () Source #
Set the value of the “orientation
” property.
When overloading is enabled, this is equivalent to
set
gridLayout [ #orientation:=
value ]
rowHomogeneous
Whether all rows of the layout should have the same height
Since: 1.12
constructGridLayoutRowHomogeneous :: (IsGridLayout o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “row-homogeneous
” property. This is rarely needed directly, but it is used by new
.
getGridLayoutRowHomogeneous :: (MonadIO m, IsGridLayout o) => o -> m Bool Source #
Get the value of the “row-homogeneous
” property.
When overloading is enabled, this is equivalent to
get
gridLayout #rowHomogeneous
setGridLayoutRowHomogeneous :: (MonadIO m, IsGridLayout o) => o -> Bool -> m () Source #
Set the value of the “row-homogeneous
” property.
When overloading is enabled, this is equivalent to
set
gridLayout [ #rowHomogeneous:=
value ]
rowSpacing
The amount of space in pixels between two consecutive rows
Since: 1.12
constructGridLayoutRowSpacing :: (IsGridLayout o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “row-spacing
” property. This is rarely needed directly, but it is used by new
.
getGridLayoutRowSpacing :: (MonadIO m, IsGridLayout o) => o -> m Word32 Source #
Get the value of the “row-spacing
” property.
When overloading is enabled, this is equivalent to
get
gridLayout #rowSpacing
setGridLayoutRowSpacing :: (MonadIO m, IsGridLayout o) => o -> Word32 -> m () Source #
Set the value of the “row-spacing
” property.
When overloading is enabled, this is equivalent to
set
gridLayout [ #rowSpacing:=
value ]