LayOut C API
|
#include <LayOutAPI/common.h>
#include <LayOutAPI/geometry/geometry.h>
#include <LayOutAPI/model/defs.h>
Go to the source code of this file.
Enumerations | |
enum | LORectangleType { LORectangleType_Normal = 0, LORectangleType_Rounded, LORectangleType_Lozenge, LORectangleType_Bulged, LONumRectangleTypes } |
Defines the shape of the rectangle within its boundaries. More... | |
Functions | |
LO_RESULT | LORectangleCreate (LORectangleRef *rectangle, const LOAxisAlignedRect2D *bounds) |
Creates a 'normal' rectangle with 90 degree corners. More... | |
LO_RESULT | LORectangleCreateRounded (LORectangleRef *rectangle, const LOAxisAlignedRect2D *bounds, double corner_radius) |
Creates a 'rounded' rectangle with arcs in each corner. More... | |
LO_RESULT | LORectangleCreateLozenge (LORectangleRef *rectangle, const LOAxisAlignedRect2D *bounds) |
Creates a 'Lozenge' rectangle with the shorter side curved. More... | |
LO_RESULT | LORectangleCreateBulged (LORectangleRef *rectangle, const LOAxisAlignedRect2D *bounds, double bulge_distance) |
Creates a 'bulged' rectangle with the vertical sides curved. More... | |
LO_RESULT | LORectangleAddReference (LORectangleRef rectangle) |
Adds a reference to a rectangle object. More... | |
LO_RESULT | LORectangleRelease (LORectangleRef *rectangle) |
Releases a rectangle object. The object will be invalidated if releasing the last reference. More... | |
LO_EXPORT LORectangleRef | LORectangleFromEntity (LOEntityRef entity) |
Converts from a LOEntityRef to a LORectangleRef. This is essentially a downcast operation so the given LOEntityRef must be convertible to a LORectangleRef. More... | |
LO_EXPORT LOEntityRef | LORectangleToEntity (LORectangleRef rectangle) |
Converts from a LORectangleRef to a LOEntityRef. This is essentially an upcast operation. More... | |
LO_RESULT | LORectangleGetTopLeftPoint (LORectangleRef rectangle, LOPoint2D *point) |
Gets the point that was originally defined as the upper left point. Transforms to this object may have moved it so that it is no longer the top left point geometrically on the page. More... | |
LO_RESULT | LORectangleGetTopRightPoint (LORectangleRef rectangle, LOPoint2D *point) |
Gets the point that was originally defined as the upper right point. Transforms to this object may have moved it so that it is no longer the top right point geometrically on the page. More... | |
LO_RESULT | LORectangleGetBottomLeftPoint (LORectangleRef rectangle, LOPoint2D *point) |
Gets the point that was originally defined as the bottom left point. Transforms to this object may have moved it so that it is no longer the bottom left point geometrically on the page. More... | |
LO_RESULT | LORectangleGetBottomRightPoint (LORectangleRef rectangle, LOPoint2D *point) |
Gets the point that was originally defined as the bottom right point. Transforms to this object may have moved it so that it is no longer the bottom right point geometrically on the page. More... | |
LO_RESULT | LORectangleGetRectangleType (LORectangleRef rectangle, LORectangleType *type) |
Gets the type of a rectangle. More... | |
LO_RESULT | LORectangleSetRectangleType (LORectangleRef rectangle, LORectangleType type) |
Gets the type of a rectangle. More... | |
LO_RESULT | LORectangleGetRadius (LORectangleRef rectangle, double *radius) |
Returns the radius that defines the shape of a bulged or rounded rectangle. More... | |
LO_RESULT | LORectangleSetRadius (LORectangleRef rectangle, double radius) |
Sets the radius that defines the shape of a bulged or rounded rectangle. More... | |
enum LORectangleType |
Defines the shape of the rectangle within its boundaries.
LO_RESULT LORectangleAddReference | ( | LORectangleRef | rectangle | ) |
Adds a reference to a rectangle object.
[in] | rectangle | The rectangle object. |
LO_RESULT LORectangleCreate | ( | LORectangleRef * | rectangle, |
const LOAxisAlignedRect2D * | bounds | ||
) |
Creates a 'normal' rectangle with 90 degree corners.
[out] | rectangle | The rectangle object. |
[in] | bounds | The starting dimensions of the rectangle. |
LO_RESULT LORectangleCreateBulged | ( | LORectangleRef * | rectangle, |
const LOAxisAlignedRect2D * | bounds, | ||
double | bulge_distance | ||
) |
Creates a 'bulged' rectangle with the vertical sides curved.
[out] | rectangle | The rectangle object. |
[in] | bounds | The starting dimensions of the rectangle. |
[in] | bulge_distance | The size of the bulge, from the outer edge of the rectangle in. |
LO_RESULT LORectangleCreateLozenge | ( | LORectangleRef * | rectangle, |
const LOAxisAlignedRect2D * | bounds | ||
) |
Creates a 'Lozenge' rectangle with the shorter side curved.
[out] | rectangle | The rectangle object. |
[in] | bounds | The starting dimensions of the rectangle. |
LO_RESULT LORectangleCreateRounded | ( | LORectangleRef * | rectangle, |
const LOAxisAlignedRect2D * | bounds, | ||
double | corner_radius | ||
) |
Creates a 'rounded' rectangle with arcs in each corner.
[out] | rectangle | The rectangle object. |
[in] | bounds | The starting dimensions of the rectangle. |
[in] | corner_radius | The radius of the circles in the corners in inches. |
LO_EXPORT LORectangleRef LORectangleFromEntity | ( | LOEntityRef | entity | ) |
Converts from a LOEntityRef to a LORectangleRef. This is essentially a downcast operation so the given LOEntityRef must be convertible to a LORectangleRef.
[in] | entity | The entity object. |
LO_RESULT LORectangleGetBottomLeftPoint | ( | LORectangleRef | rectangle, |
LOPoint2D * | point | ||
) |
Gets the point that was originally defined as the bottom left point. Transforms to this object may have moved it so that it is no longer the bottom left point geometrically on the page.
[in] | rectangle | The rectangle object. |
[out] | point | The position of the original bottom left point. |
LO_RESULT LORectangleGetBottomRightPoint | ( | LORectangleRef | rectangle, |
LOPoint2D * | point | ||
) |
Gets the point that was originally defined as the bottom right point. Transforms to this object may have moved it so that it is no longer the bottom right point geometrically on the page.
[in] | rectangle | The rectangle object. |
[out] | point | The position of the original bottom right point. |
LO_RESULT LORectangleGetRadius | ( | LORectangleRef | rectangle, |
double * | radius | ||
) |
Returns the radius that defines the shape of a bulged or rounded rectangle.
[in] | rectangle | The rectangle object. |
[out] | radius | The radius for bulged and rounded rectangles. |
LO_RESULT LORectangleGetRectangleType | ( | LORectangleRef | rectangle, |
LORectangleType * | type | ||
) |
Gets the type of a rectangle.
[in] | rectangle | The rectangle object. |
[out] | type | The type of the rectangle. |
LO_RESULT LORectangleGetTopLeftPoint | ( | LORectangleRef | rectangle, |
LOPoint2D * | point | ||
) |
Gets the point that was originally defined as the upper left point. Transforms to this object may have moved it so that it is no longer the top left point geometrically on the page.
[in] | rectangle | The rectangle object. |
[out] | point | The position of the original top left point. |
LO_RESULT LORectangleGetTopRightPoint | ( | LORectangleRef | rectangle, |
LOPoint2D * | point | ||
) |
Gets the point that was originally defined as the upper right point. Transforms to this object may have moved it so that it is no longer the top right point geometrically on the page.
[in] | rectangle | The rectangle object. |
[out] | point | The position of the original top right point. |
LO_RESULT LORectangleRelease | ( | LORectangleRef * | rectangle | ) |
Releases a rectangle object. The object will be invalidated if releasing the last reference.
[in] | rectangle | The rectangle object. |
LO_RESULT LORectangleSetRadius | ( | LORectangleRef | rectangle, |
double | radius | ||
) |
Sets the radius that defines the shape of a bulged or rounded rectangle.
[in] | rectangle | The rectangle object. |
[out] | radius | The radius for bulged and rounded rectangles. |
LO_RESULT LORectangleSetRectangleType | ( | LORectangleRef | rectangle, |
LORectangleType | type | ||
) |
Gets the type of a rectangle.
[in] | rectangle | The rectangle object. |
[in] | type | The type of the rectangle. |
LO_EXPORT LOEntityRef LORectangleToEntity | ( | LORectangleRef | rectangle | ) |
Converts from a LORectangleRef to a LOEntityRef. This is essentially an upcast operation.
[in] | rectangle | The rectangle object. |