Matrix

A pango.matrix.Matrix specifies a transformation between user-space and device coordinates.

The transformation is given by

x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0;
y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0;

Constructors

this
this(double xx, double xy, double yx, double yy, double x0, double y0)

Create a matrix.Matrix boxed type.

this
this(void* ptr, Flag!"Take" take)

Members

Functions

_cPtr
void* _cPtr(Flag!"Dup" dup)
concat
void concat(pango.matrix.Matrix newMatrix)

Changes the transformation represented by matrix to be the transformation given by first applying transformation given by new_matrix then applying the original transformation.

copy
pango.matrix.Matrix copy()

Copies a pango.matrix.Matrix.

getFontScaleFactor
double getFontScaleFactor()

Returns the scale factor of a matrix on the height of the font.

getFontScaleFactors
void getFontScaleFactors(double xscale, double yscale)

Calculates the scale factor of a matrix on the width and height of the font.

getSlantRatio
double getSlantRatio()

Gets the slant ratio of a matrix.

rotate
void rotate(double degrees)

Changes the transformation represented by matrix to be the transformation given by first rotating by degrees degrees counter-clockwise then applying the original transformation.

scale
void scale(double scaleX, double scaleY)

Changes the transformation represented by matrix to be the transformation given by first scaling by sx in the X direction and sy in the Y direction then applying the original transformation.

self
Matrix self()

Returns this, for use in with statements.

transformDistance
void transformDistance(double dx, double dy)

Transforms the distance vector (dx,dy) by matrix.

transformPixelRectangle
void transformPixelRectangle(pango.types.Rectangle rect)

First transforms the rect using matrix, then calculates the bounding box of the transformed rectangle.

transformPoint
void transformPoint(double x, double y)

Transforms the point (x, y) by matrix.

transformRectangle
void transformRectangle(pango.types.Rectangle rect)

First transforms rect using matrix, then calculates the bounding box of the transformed rectangle.

translate
void translate(double tx, double ty)

Changes the transformation represented by matrix to be the transformation given by first translating by (tx, ty) then applying the original transformation.

Properties

_gType
GType _gType [@property getter]
x0
double x0 [@property getter]

Get x0 field.

x0
double x0 [@property setter]

Set x0 field.

xx
double xx [@property getter]

Get xx field.

xx
double xx [@property setter]

Set xx field.

xy
double xy [@property getter]

Get xy field.

xy
double xy [@property setter]

Set xy field.

y0
double y0 [@property getter]

Get y0 field.

y0
double y0 [@property setter]

Set y0 field.

yx
double yx [@property getter]

Get yx field.

yx
double yx [@property setter]

Set yx field.

yy
double yy [@property getter]

Get yy field.

yy
double yy [@property setter]

Set yy field.

Static functions

_getGType
GType _getGType()

Inherited Members

From Boxed

cInstancePtr
void* cInstancePtr;

Pointer to the C boxed value

_getGType
GType _getGType()

Get the GType of this boxed type.

_gType
GType _gType [@property getter]

Boxed GType property.

self
Boxed self()

Convenience method to return this cast to a type. For use in D with statements.

copy_
void* copy_()

Make a copy of the wrapped C boxed data.

boxedCopy
void* boxedCopy(void* cBoxed)

Copy a C boxed value using g_boxed_copy.

boxedFree
void boxedFree(void* cBoxed)

Free a C boxed value using g_boxed_free.