Geometry

Geometry provides a convenient means to specify a geometry argument.

Constructors

this
this(string geometry)

Create a Geometry form a Imagemagick / X11 geometry string.

this
this(size_t width, size_t height, ssize_t xOffset = 0, ssize_t yOffset = 0)

Initialize with width heigt and offsets.

this
this(RectangleInfo rectangle)

Members

Functions

opCmp
size_t opCmp(ref const Geometry geometry)
rectangleInfo
RectangleInfo rectangleInfo()
toAbsolute
Geometry toAbsolute(size_t width, size_t height)

Calculate the absolute width and height based on the flags, and the profided width and height.

toString
string toString()

Convert Geometry into a Imagemagick geometry string.

Variables

greater
bool greater;

Resize only if the image is greater than the width and/or height.

height
size_t height;
keepAspect
bool keepAspect;

Retain the aspect ratio.

less
bool less;

Resize only if the image is smaller than the width and/or height.

minimum
bool minimum;

The specified width and/or height is the minimum value.

percent
bool percent;

The width and/or height are percentages of the original.

width
size_t width;
xOffset
ssize_t xOffset;
yOffset
ssize_t yOffset;

Meta