gi-gsk-4.0.9: Gsk bindings

Copyright | Will Thompson and Iñaki García Etxebarria
License | LGPL-2.1
Maintainer | Iñaki García Etxebarria
Safe Haskell | None
Language | Haskell2010

GI.Gsk.Objects.ClipNode

Contents

- Exported types
- Methods
  - getChild
  - getClip
  - new

Description

A render node applying a rectangular clip to its single child node.

Synopsis

- newtype ClipNode = ClipNode (ManagedPtr ClipNode)
- class (BoxedPtr o, TypedObject o, IsDescendantOf ClipNode o) => IsClipNode o
- toClipNode :: (MonadIO m, IsClipNode o) => o -> m ClipNode
- clipNodeGetChild :: (HasCallStack, MonadIO m, IsClipNode a) => a -> m RenderNode
- clipNodeGetClip :: (HasCallStack, MonadIO m, IsClipNode a) => a -> m Rect
- clipNodeNew :: (HasCallStack, MonadIO m, IsRenderNode a) => a -> Rect -> m ClipNode

# Exported types

newtype ClipNode Source #

Memory-managed wrapper type.

Constructors

ClipNode (ManagedPtr ClipNode) |

#### Instances

Instances details

Eq ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode Methods (==) :: ClipNode -> ClipNode -> Bool Source # (/=) :: ClipNode -> ClipNode -> Bool Source #
BoxedPtr ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode Methods boxedPtrCopy :: ClipNode -> IO ClipNode Source # boxedPtrFree :: ClipNode -> IO () Source #
ManagedPtrNewtype ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode Methods toManagedPtr :: ClipNode -> ManagedPtr ClipNode Source #
TypedObject ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode Methods glibType :: IO GType Source #
HasParentTypes ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode
type ParentTypes ClipNode Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode type ParentTypes ClipNode = '[RenderNode]

class (BoxedPtr o, TypedObject o, IsDescendantOf ClipNode o) => IsClipNode o Source #

Type class for types which can be safely cast to `ClipNode`, for instance with `toClipNode`.

#### Instances

Instances details

(BoxedPtr o, TypedObject o, IsDescendantOf ClipNode o) => IsClipNode o Source # |
Instance details Defined in GI.Gsk.Objects.ClipNode

toClipNode :: (MonadIO m, IsClipNode o) => o -> m ClipNode Source #

Cast to `ClipNode`, 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

draw, ref, serialize, unref, writeToFile.

#### Getters

getBounds, getChild, getClip, getNodeType, getOpaqueRect.

#### Setters

None.

## getChild

clipNodeGetChild Source #

Arguments

:: (HasCallStack, MonadIO m, IsClipNode a) |
=> a | `node`: a clip `gskRenderNode`
-> m RenderNode | Returns: The child that is getting clipped

Gets the child node that is getting clipped by the given `node`.

## getClip

clipNodeGetClip Source #

Arguments

:: (HasCallStack, MonadIO m, IsClipNode a) |
=> a | `node`: a `GskClipNode`
-> m Rect | Returns: a clip rectangle

Retrieves the clip rectangle for `node`.

## new

clipNodeNew Source #

Arguments

:: (HasCallStack, MonadIO m, IsRenderNode a) |
=> a | `child`: The node to draw
-> Rect | `clip`: The clip to apply
-> m ClipNode | Returns: A new `GskRenderNode`

Creates a `GskRenderNode` that will clip the `child` to the area given by `clip`.