gi-clutter-1.0.2: clutter GObject bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Clutter.Objects.CairoTexture

Description

The CairoTexture struct contains only private data.

Since: 1.0

Synopsis

Exported types

class (GObject o, IsDescendantOf CairoTexture o) => IsCairoTexture o Source #

Type class for types which can be safely cast to CairoTexture, for instance with toCairoTexture.

Instances

Instances details
(GObject o, IsDescendantOf CairoTexture o) => IsCairoTexture o Source # 
Instance details

Defined in GI.Clutter.Objects.CairoTexture

toCairoTexture :: (MonadIO m, IsCairoTexture o) => o -> m CairoTexture Source #

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

addAction, addActionWithName, addActor, addChild, addConstraint, addConstraintWithName, addEffect, addEffectWithName, addTransition, allocate, allocateAlignFill, allocateAvailableSize, allocatePreferredSize, animateProperty, animateWithAlphav, animateWithTimelinev, animatev, applyRelativeTransformToPoint, applyTransformToPoint, bindModel, bindProperty, bindPropertyFull, childGetProperty, childNotify, childSetProperty, clear, clearActions, clearConstraints, clearEffects, contains, continuePaint, create, createChildMeta, createPangoContext, createPangoLayout, createRegion, destroy, destroyAllChildren, destroyChildMeta, detachAnimation, event, findChildByName, findProperty, forceFloating, foreach, foreachWithInternals, freezeNotify, getv, grabKeyFocus, hasActions, hasAllocation, hasClip, hasConstraints, hasEffects, hasKeyFocus, hasOverlaps, hasPointer, hide, hideAll, insertChildAbove, insertChildAtIndex, insertChildBelow, interpolateValue, invalidate, invalidateRectangle, isFloating, isInClonePaint, isMapped, isRealized, isRotated, isScaled, isVisible, lower, lowerBottom, lowerChild, map, moveAnchorPoint, moveAnchorPointFromGravity, moveBy, needsExpand, notify, notifyByPspec, paint, parseCustomNode, popInternal, pushInternal, queueRedraw, queueRedrawWithClip, queueRelayout, raise, raiseChild, raiseTop, realize, ref, refSink, removeAction, removeActionByName, removeActor, removeAllChildren, removeAllTransitions, removeChild, removeClip, removeConstraint, removeConstraintByName, removeEffect, removeEffectByName, removeTransition, reparent, replaceChild, restoreEasingState, runDispose, saveEasingState, shouldPickPaint, show, showAll, sortDepthOrder, stealData, stealQdata, thawNotify, transformStagePoint, unmap, unparent, unrealize, unref, unsetFlags, watchClosure.

Getters

getAbsAllocationVertices, getAccessible, getAction, getActions, getAllocationBox, getAllocationGeometry, getAllocationVertices, getAnchorPoint, getAnchorPointGravity, getAnimation, getAutoResize, getBackgroundColor, getBaseSize, getChildAtIndex, getChildMeta, getChildTransform, getChildren, getClip, getClipToAllocation, getCoglMaterial, getCoglTexture, getConstraint, getConstraints, getContent, getContentBox, getContentGravity, getContentRepeat, getContentScalingFilters, getData, getDefaultPaintVolume, getDepth, getEasingDelay, getEasingDuration, getEasingMode, getEffect, getEffects, getFilterQuality, getFirstChild, getFixedPositionSet, getFlags, getGeometry, getGid, getHeight, getId, getInitialState, getKeepAspectRatio, getLastChild, getLayoutManager, getLoadAsync, getLoadDataAsync, getMargin, getMarginBottom, getMarginLeft, getMarginRight, getMarginTop, getMaxTileWaste, getNChildren, getName, getNextSibling, getOffscreenRedirect, getOpacity, getPaintBox, getPaintOpacity, getPaintVisibility, getPaintVolume, getPangoContext, getParent, getPickWithAlpha, getPivotPoint, getPivotPointZ, getPixelFormat, getPosition, getPreferredHeight, getPreferredSize, getPreferredWidth, getPreviousSibling, getProperty, getQdata, getReactive, getRepeat, getRequestMode, getRotation, getRotationAngle, getScale, getScaleCenter, getScaleGravity, getScaleZ, getShader, getSize, getStage, getSurfaceSize, getSyncSize, getTextDirection, getTransform, getTransformationMatrix, getTransformedPaintVolume, getTransformedPosition, getTransformedSize, getTransition, getTranslation, getWidth, getX, getXAlign, getXExpand, getY, getYAlign, getYExpand, getZPosition, getZRotationGravity.

Setters

setAllocation, setAnchorPoint, setAnchorPointFromGravity, setAreaFromRgbData, setAutoResize, setBackgroundColor, setChildAboveSibling, setChildAtIndex, setChildBelowSibling, setChildTransform, setClip, setClipToAllocation, setCoglMaterial, setCoglTexture, setContent, setContentGravity, setContentRepeat, setContentScalingFilters, setCustomProperty, setData, setDataFull, setDepth, setEasingDelay, setEasingDuration, setEasingMode, setFilterQuality, setFinalState, setFixedPositionSet, setFlags, setFromFile, setFromRgbData, setFromYuvData, setGeometry, setHeight, setId, setKeepAspectRatio, setLayoutManager, setLoadAsync, setLoadDataAsync, setMargin, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setName, setOffscreenRedirect, setOpacity, setParent, setPickWithAlpha, setPivotPoint, setPivotPointZ, setPosition, setProperty, setReactive, setRepeat, setRequestMode, setRotation, setRotationAngle, setScale, setScaleFull, setScaleWithGravity, setScaleZ, setShader, setShaderParam, setShaderParamFloat, setShaderParamInt, setSize, setSurfaceSize, setSyncSize, setTextDirection, setTransform, setTranslation, setWidth, setX, setXAlign, setXExpand, setY, setYAlign, setYExpand, setZPosition, setZRotationFromGravity.

clear

cairoTextureClear Source #

Arguments

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

self: a CairoTexture

-> m () 

Deprecated: (Since version 1.12)Use Canvas instead

Clears self's internal drawing surface, so that the next upload will replace the previous contents of the CairoTexture rather than adding to it.

Calling this function from within a draw signal handler will clear the invalidated area.

Since: 1.0

create

cairoTextureCreate Source #

Arguments

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

self: a CairoTexture

-> m Context

Returns: a newly created Cairo context. Use cairo_destroy() to upload the contents of the context when done drawing

Deprecated: (Since version 1.8)Use the draw signal and the cairoTextureInvalidate function to obtain a Cairo context for 2D drawing.

Creates a new Cairo context for the cairo texture. It is similar to using cairoTextureCreateRegion with xOffset and yOffset of 0, width equal to the cairo texture surface width and height equal to the cairo texture surface height.

Do not call this function within the paint virtual function or from a callback to the paint signal.

Since: 1.0

createRegion

cairoTextureCreateRegion Source #

Arguments

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

self: a CairoTexture

-> Int32

xOffset: offset of the region on the X axis

-> Int32

yOffset: offset of the region on the Y axis

-> Int32

width: width of the region, or -1 for the full surface width

-> Int32

height: height of the region, or -1 for the full surface height

-> m Context

Returns: a newly created Cairo context. Use cairo_destroy() to upload the contents of the context when done drawing

Deprecated: (Since version 1.8)Use the draw signal and cairoTextureInvalidateRectangle to obtain a clipped Cairo context for 2D drawing.

Creates a new Cairo context that will updat the region defined by xOffset, yOffset, width and height.

Do not call this function within the paint virtual function or from a callback to the paint signal.

Since: 1.0

getAutoResize

cairoTextureGetAutoResize Source #

Arguments

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

self: a CairoTexture

-> m Bool

Returns: True if the CairoTexture should track the allocation, and False otherwise

Deprecated: (Since version 1.12)Use Canvas instead

Retrieves the value set using cairoTextureSetAutoResize.

Since: 1.8

getSurfaceSize

cairoTextureGetSurfaceSize Source #

Arguments

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

self: a CairoTexture

-> m (Word32, Word32) 

Deprecated: (Since version 1.12)Use Canvas instead

Retrieves the surface width and height for self.

Since: 1.0

invalidate

cairoTextureInvalidate Source #

Arguments

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

self: a CairoTexture

-> m () 

Deprecated: (Since version 1.12)Use Canvas instead

Invalidates the whole surface of a CairoTexture.

This function will cause the draw signal to be emitted.

See also: cairoTextureInvalidateRectangle

Since: 1.8

invalidateRectangle

cairoTextureInvalidateRectangle Source #

Arguments

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

self: a CairoTexture

-> Maybe RectangleInt

rect: a rectangle with the area to invalida, or Nothing to perform an unbounded invalidation

-> m () 

Deprecated: (Since version 1.12)Use Canvas instead

Invalidates a rectangular region of a CairoTexture.

The invalidation will cause the draw signal to be emitted.

See also: cairoTextureInvalidate

Since: 1.8

new

cairoTextureNew Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> Word32

width: the width of the surface

-> Word32

height: the height of the surface

-> m CairoTexture

Returns: the newly created CairoTexture actor

Deprecated: (Since version 1.12)Use Canvas instead

Creates a new CairoTexture actor, with a surface of width by height pixels.

Since: 1.0

setAutoResize

cairoTextureSetAutoResize Source #

Arguments

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

self: a CairoTexture

-> Bool

value: True if the CairoTexture should bind the surface size to the allocation

-> m () 

Deprecated: (Since version 1.12)Use Canvas instead

Sets whether the CairoTexture should ensure that the backing Cairo surface used matches the allocation assigned to the actor. If the allocation changes, the contents of the CairoTexture will also be invalidated automatically.

Since: 1.8

setSurfaceSize

cairoTextureSetSurfaceSize Source #

Arguments

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

self: a CairoTexture

-> Word32

width: the new width of the surface

-> Word32

height: the new height of the surface

-> m () 

Deprecated: (Since version 1.12)Use Canvas instead

Resizes the Cairo surface used by self to width and height.

This function will not invalidate the contents of the Cairo texture: you will have to explicitly call either cairoTextureInvalidateRectangle or cairoTextureInvalidate.

Since: 1.0

Properties

autoResize

Controls whether the CairoTexture should automatically resize the Cairo surface whenever the actor's allocation changes. If :auto-resize is set to True the surface contents will also be invalidated automatically.

Since: 1.8

constructCairoTextureAutoResize :: (IsCairoTexture o, MonadIO m) => Bool -> m (GValueConstruct o) Source #

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

getCairoTextureAutoResize :: (MonadIO m, IsCairoTexture o) => o -> m Bool Source #

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

get cairoTexture #autoResize

setCairoTextureAutoResize :: (MonadIO m, IsCairoTexture o) => o -> Bool -> m () Source #

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

set cairoTexture [ #autoResize := value ]

surfaceHeight

The height of the Cairo surface used by the CairoTexture actor, in pixels.

Since: 1.0

constructCairoTextureSurfaceHeight :: (IsCairoTexture o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #

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

getCairoTextureSurfaceHeight :: (MonadIO m, IsCairoTexture o) => o -> m Word32 Source #

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

get cairoTexture #surfaceHeight

setCairoTextureSurfaceHeight :: (MonadIO m, IsCairoTexture o) => o -> Word32 -> m () Source #

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

set cairoTexture [ #surfaceHeight := value ]

surfaceWidth

The width of the Cairo surface used by the CairoTexture actor, in pixels.

Since: 1.0

constructCairoTextureSurfaceWidth :: (IsCairoTexture o, MonadIO m) => Word32 -> m (GValueConstruct o) Source #

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

getCairoTextureSurfaceWidth :: (MonadIO m, IsCairoTexture o) => o -> m Word32 Source #

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

get cairoTexture #surfaceWidth

setCairoTextureSurfaceWidth :: (MonadIO m, IsCairoTexture o) => o -> Word32 -> m () Source #

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

set cairoTexture [ #surfaceWidth := value ]

Signals

createSurface

type CairoTextureCreateSurfaceCallback Source #

Arguments

 = Word32

width: the width of the surface to create

-> Word32

height: the height of the surface to create

-> IO Surface

Returns: the newly created Surface for the texture

Deprecated: (Since version 1.12)

The createSurface signal is emitted when a CairoTexture news its surface (re)created, which happens either when the Cairo context is created with cairoTextureCreate or cairoTextureCreateRegion, or when the surface is resized through cairoTextureSetSurfaceSize.

The first signal handler that returns a non-Nothing, valid surface will stop any further signal emission, and the returned surface will be the one used.

Since: 1.6

afterCairoTextureCreateSurface :: (IsCairoTexture a, MonadIO m) => a -> ((?self :: a) => CairoTextureCreateSurfaceCallback) -> m SignalHandlerId Source #

Connect a signal handler for the createSurface signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after cairoTexture #createSurface 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.

onCairoTextureCreateSurface :: (IsCairoTexture a, MonadIO m) => a -> ((?self :: a) => CairoTextureCreateSurfaceCallback) -> m SignalHandlerId Source #

Connect a signal handler for the createSurface signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on cairoTexture #createSurface callback

draw

type CairoTextureDrawCallback Source #

Arguments

 = Context

cr: the Cairo context to use to draw

-> IO Bool

Returns: True if the signal emission should stop, and False to continue

Deprecated: (Since version 1.12)

The draw signal is emitted each time a CairoTexture has been invalidated.

The passed Cairo context passed will be clipped to the invalidated area.

It is safe to connect multiple callbacks to this signals; the state of the Cairo context passed to each callback is automatically saved and restored, so it's not necessary to call cairo_save() and cairo_restore().

Since: 1.8

afterCairoTextureDraw :: (IsCairoTexture a, MonadIO m) => a -> ((?self :: a) => CairoTextureDrawCallback) -> m SignalHandlerId Source #

Connect a signal handler for the draw signal, to be run after the default handler. When overloading is enabled, this is equivalent to

after cairoTexture #draw 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.

onCairoTextureDraw :: (IsCairoTexture a, MonadIO m) => a -> ((?self :: a) => CairoTextureDrawCallback) -> m SignalHandlerId Source #

Connect a signal handler for the draw signal, to be run before the default handler. When overloading is enabled, this is equivalent to

on cairoTexture #draw callback