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.Gdk.Objects.CairoContext
Contents
Description
GdkCairoContext
is an object representing the platform-specific
draw context.
GdkCairoContext
s are created for a surface using
surfaceCreateCairoContext
, and the context
can then be used to draw on that surface.
Synopsis
- newtype CairoContext = CairoContext (ManagedPtr CairoContext)
- class (GObject o, IsDescendantOf CairoContext o) => IsCairoContext o
- toCairoContext :: (MonadIO m, IsCairoContext o) => o -> m CairoContext
- type family ResolveCairoContextMethod (t :: Symbol) o where ...
- data CairoContextCairoCreateMethodInfo
- cairoContextCairoCreate :: (HasCallStack, MonadIO m, IsCairoContext a) => a -> m (Maybe Context)
Exported types
newtype CairoContext Source #
Memory-managed wrapper type.
Constructors
CairoContext (ManagedPtr CairoContext) |
Instances
class (GObject o, IsDescendantOf CairoContext o) => IsCairoContext o Source #
Type class for types which can be safely cast to CairoContext
, for instance with toCairoContext
.
Instances
(GObject o, IsDescendantOf CairoContext o) => IsCairoContext o Source # | |
Defined in GI.Gdk.Objects.CairoContext |
toCairoContext :: (MonadIO m, IsCairoContext o) => o -> m CairoContext Source #
Cast to CairoContext
, 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
beginFrame, bindProperty, bindPropertyFull, cairoCreate, endFrame, forceFloating, freezeNotify, getv, isFloating, isInFrame, notify, notifyByPspec, ref, refSink, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getData, getDisplay, getFrameRegion, getProperty, getQdata, getSurface.
Setters
type family ResolveCairoContextMethod (t :: Symbol) o where ... Source #
Equations
cairoCreate
data CairoContextCairoCreateMethodInfo Source #
Instances
(signature ~ m (Maybe Context), MonadIO m, IsCairoContext a) => OverloadedMethod CairoContextCairoCreateMethodInfo a signature Source # | |
Defined in GI.Gdk.Objects.CairoContext Methods overloadedMethod :: a -> signature # | |
OverloadedMethodInfo CairoContextCairoCreateMethodInfo (a :: Type) Source # | |
Defined in GI.Gdk.Objects.CairoContext Methods |
cairoContextCairoCreate Source #
Arguments
:: (HasCallStack, MonadIO m, IsCairoContext a) | |
=> a |
|
-> m (Maybe Context) | Returns: a Cairo context to draw on `GdkSurface |
Retrieves a Cairo context to be used to draw on the GdkSurface
of context
.
A call to drawContextBeginFrame
with this
context
must have been done or this function will return Nothing
.
The returned context is guaranteed to be valid until
drawContextEndFrame
is called.