![]() |
Hot Door CORE 0.8.3
Adobe® Illustrator® Plug-in Library
|
Describes a rectangular area on the Illustrator artboard. More...
#include <hdicoreArtboardRect.h>

Public Member Functions | |
| ArtboardRect () | |
| Default ArtboardRect constructor, sets the top-left to (0,0) and the width and height to 0. | |
| ArtboardRect (const ArtboardRect &rect_) | |
| ArtboardRect copy constructor. | |
| ArtboardRect (const ArtboardPoint &pt_, const Size &size_) | |
| Constructor to create an ArtboardRect from an ArtboardPoint object and Size object. | |
| ArtboardRect (const ArtboardPoint &tl_, const ArtboardPoint &br_) | |
| Constructor to create an ArtboardRect object from top-left and bottom-right ArtboardPoint objects. | |
| virtual | ~ArtboardRect () |
| ArtboardRect destructor. | |
| virtual ArtboardRect & | operator= (const ArtboardRect &rhs_) |
| Allows one ArtboardRect object to be assigned from another. | |
| virtual bool | operator== (const ArtboardRect &rhs_) const |
| Tests whether a given ArtboardRect object is the same as another. | |
| virtual bool | operator!= (const ArtboardRect &rhs_) const |
| Tests whether a given ArtboardRect object is not the same as another. | |
| virtual double | left () const |
| Gets the position of the left bounding edge of the rectangle along the x-axis. | |
| virtual double | top () const |
| Gets the position of the top bounding edge of the rectangle along the y-axis. | |
| virtual double | right () const |
| Gets the position of the right bounding edge of the rectangle along the x-axis. | |
| virtual double | bottom () const |
| Gets the position of the bottom bounding edge of the rectangle along the y-axis. | |
| virtual void | setLeft (const double left_) |
| Sets the position of the left bounding edge of the rectangle along the x-axis. | |
| virtual void | setTop (const double top_) |
| Sets the position of the top bounding edge of the rectangle along the y-axis. | |
| virtual void | setRight (const double right_) |
| Sets the position of the right bounding edge of the rectangle along the x-axis. | |
| virtual void | setBottom (const double bottom_) |
| Sets the position of the bottom bounding edge of the rectangle along the y-axis. | |
| virtual ArtboardRect | inset (const double x_, const double y_) const |
| Insets a rect by given amounts on the x- and y-axes (or expands if negative) | |
| virtual ArtboardPoint | topLeft () const |
| Gets the top-left point of the rect. | |
| virtual ArtboardPoint | topCenter () const |
| Gets the top-center point of the rect. | |
| virtual ArtboardPoint | topRight () const |
| Gets the top-right point of the rect. | |
| virtual ArtboardPoint | midLeft () const |
| Gets the mid-left point of the rect. | |
| virtual ArtboardPoint | midCenter () const |
| Gets the mid-center point of the rect. | |
| virtual ArtboardPoint | midRight () const |
| Gets the mid-right point of the rect. | |
| virtual ArtboardPoint | bottomLeft () const |
| Gets the bottom-left point of the rect. | |
| virtual ArtboardPoint | bottomCenter () const |
| Gets the bottom-center point of the rect. | |
| virtual ArtboardPoint | bottomRight () const |
| Gets the bottom-right point of the rect. | |
| virtual ArtboardPoint | pointFromPinPoint (const BoundsPinPointType pinPt_) const |
| Gets a "pin point" from the rect bounds. | |
| virtual double | area () const |
| Gets the area of the rect. | |
| virtual double | perimeter () const |
| Gets the perimeter of the rect. | |
| virtual bool | equalWithinTol (const ArtboardRect &compare_, const double tol_) const |
| Gets whether a given rect is equal to the target rect, within a given tolerance. | |
| virtual bool | containsPoint (const ArtboardPoint &pt_) const |
| Gets whether a given point lies inside the target rect. | |
| virtual bool | overlaps (const ArtboardRect &rect2_) const |
| Checks whether the target rect overlaps a given rect. | |
| virtual bool | enclosePoint (const ArtboardPoint &pt_) |
| Enlarges the target rect, if necessary, to enclose a given point. | |
| virtual ArtboardRect | unionRects (const ArtboardRect &rect2_) const |
| Unions two rects, forming a rect that has bounds sufficient to enclose both initial rects. | |
| virtual ArtboardRect | scale (const double xScaler_, const double yScaler_) const |
| Scales the width and height of a rect by given amounts on the x- and y- axes. | |
| virtual bool | intersection (const ArtboardRect &rect2_, ArtboardRect &iRect__) const |
| Gets the intersection between two rects. | |
| virtual void | enclosingEllipse (double &width__, double &height__) const |
| Gets the width and height of an ellipse that would enclose the rect. | |
| virtual RectLineIntersectionType | lineIntersectionPoints (const ArtboardPoint &a_, const ArtboardPoint &b_, ArtboardPoint &iPt1__, ArtboardPoint &iPt2__) const |
| Finds the intersection points on a rectangle that a line has with it. | |
| virtual RectLineIntersectionType | lineIntersectionPoints (const ArtboardPoint &a_, const ArtboardPoint &b_, const Angle &angle_, ArtboardPoint &iPt1__, ArtboardPoint &iPt2__) const |
| Finds the intersection points on a rectangle, were it rotated, that a line has with it. | |
Static Public Member Functions | |
| static ArtboardRect | XYWidthHeight (const double x_, const double y_, const double width_, const double height_) |
| "Named constructor" to create an ArtboardRect from an (x,y) top-left point and a width and height | |
| static ArtboardRect | LeftTopRightBottom (const double left_, const double top_, const double right_, const double bottom_) |
| "Named constructor" to create an ArtboardRect from the values of its bounding edges | |
Public Attributes | |
| ArtboardPoint | origin |
| Origin point for the rect (top-left, when size.width and size.height are positive) | |
| Size | size |
| Dimensions of the rect. | |
Friends | |
| aip::ArtboardRect * | __accessImpl (const ArtboardRect &) |
| ArtboardRect | __accessCtor (const aip::ArtboardRect &) |
Describes a rectangular area on the Illustrator artboard.
| hdi::core::ArtboardRect::ArtboardRect | ( | ) |
Default ArtboardRect constructor, sets the top-left to (0,0) and the width and height to 0.
| hdi::core::ArtboardRect::ArtboardRect | ( | const ArtboardRect & | rect_ | ) |
| hdi::core::ArtboardRect::ArtboardRect | ( | const ArtboardPoint & | pt_, |
| const Size & | size_ | ||
| ) |
Constructor to create an ArtboardRect from an ArtboardPoint object and Size object.
| pt_ | Top-left point of the rectangle |
| size_ | Size (width and height of the rectangle) |
| hdi::core::ArtboardRect::ArtboardRect | ( | const ArtboardPoint & | tl_, |
| const ArtboardPoint & | br_ | ||
| ) |
Constructor to create an ArtboardRect object from top-left and bottom-right ArtboardPoint objects.
| tl_ | Top-left point of the rectangle |
| br_ | Bottom-right point of the rectangle |
|
virtual |
ArtboardRect destructor.
|
virtual |
Gets the area of the rect.
|
virtual |
Gets the position of the bottom bounding edge of the rectangle along the y-axis.
|
virtual |
Gets the bottom-center point of the rect.
|
virtual |
Gets the bottom-left point of the rect.
|
virtual |
Gets the bottom-right point of the rect.
|
virtual |
Gets whether a given point lies inside the target rect.
| pt_ | Point to test |
|
virtual |
Enlarges the target rect, if necessary, to enclose a given point.
| pt_ | Point the rect should enclose |
|
virtual |
Gets the width and height of an ellipse that would enclose the rect.
| width__ | Return-by-reference for the ellipse width |
| height__ | Return-by-reference for the ellipse height |
|
virtual |
Gets whether a given rect is equal to the target rect, within a given tolerance.
| compare_ | Rect to compare to the target |
| tol_ | Tolerance about the sides of the rect |
|
virtual |
Insets a rect by given amounts on the x- and y-axes (or expands if negative)
| x_ | Amount to inset the rect on the left and right sides |
| y_ | Amount to inset the rect on the top and bottom sides |
|
virtual |
Gets the intersection between two rects.
| rect2_ | Second rect to test for an intersection with the target rect |
| iRect__ | Return-by-reference for the intersection rect |
|
virtual |
Gets the position of the left bounding edge of the rectangle along the x-axis.
|
static |
"Named constructor" to create an ArtboardRect from the values of its bounding edges
| left_ | Position of the left of the rect along the x-axis |
| top_ | Position of the top of the rect along the y-axis |
| right_ | Position of the right of the rect along the x-axis |
| bottom_ | Position of the bottom of the rect along the y-axis |
|
virtual |
Finds the intersection points on a rectangle that a line has with it.
| a_ | Start point for the line |
| b_ | End point for the line |
| iPt1__ | Return-by-reference for the first intersection point found |
| iPt2__ | Return-by-reference for the second intersection point found |
|
virtual |
Finds the intersection points on a rectangle, were it rotated, that a line has with it.
| a_ | Start point for the line |
| b_ | End point for the line |
| angle_ | Amount the rectangle is rotated |
| iPt1__ | Return-by-reference for the first intersection point found |
| iPt2__ | Return-by-reference for the second intersection point found |
|
virtual |
Gets the mid-center point of the rect.
|
virtual |
Gets the mid-left point of the rect.
|
virtual |
Gets the mid-right point of the rect.
|
virtual |
Tests whether a given ArtboardRect object is not the same as another.
| rhs_ | ArtboardRect to compare against (righthand side of inequality operator) |
|
virtual |
Allows one ArtboardRect object to be assigned from another.
| rhs_ | Righthand side of the = operator; the object to copy values from |
|
virtual |
Tests whether a given ArtboardRect object is the same as another.
| rhs_ | ArtboardRect to compare against (righthand side of equality operator) |
|
virtual |
Checks whether the target rect overlaps a given rect.
| rect2_ | Rect to compare against for overlapping boundaries |
|
virtual |
Gets the perimeter of the rect.
|
virtual |
Gets a "pin point" from the rect bounds.
| pinPt_ | Pin point which will be turned into an absolute point from the rect |
|
virtual |
Gets the position of the right bounding edge of the rectangle along the x-axis.
|
virtual |
Scales the width and height of a rect by given amounts on the x- and y- axes.
| xScaler_ | Multiplier for scaling horizontally (e.g. 0.75 is 75% of the current size) |
| yScaler_ | Multiplier for scaling vertically (e.g. 0.75 is 75% of the current size) |
|
virtual |
Sets the position of the bottom bounding edge of the rectangle along the y-axis.
| bottom_ | New bottom edge of the rect |
|
virtual |
Sets the position of the left bounding edge of the rectangle along the x-axis.
| left_ | New left edge of the rect |
|
virtual |
Sets the position of the right bounding edge of the rectangle along the x-axis.
| right_ | New right edge of the rect |
|
virtual |
Sets the position of the top bounding edge of the rectangle along the y-axis.
| top_ | New top edge of the rect |
|
virtual |
Gets the position of the top bounding edge of the rectangle along the y-axis.
|
virtual |
Gets the top-center point of the rect.
|
virtual |
Gets the top-left point of the rect.
|
virtual |
Gets the top-right point of the rect.
|
virtual |
Unions two rects, forming a rect that has bounds sufficient to enclose both initial rects.
| rect2_ | Second rect to consider in the union |
|
static |
"Named constructor" to create an ArtboardRect from an (x,y) top-left point and a width and height
| x_ | Position of the left of the rect along the x-axis |
| y_ | Position of the top of the rect along the y-axis |
| width_ | Width of the rect |
| height_ | Height of the rect |