|
pdfmm 0.9.20
|
#include <PdfRect.h>
Public Member Functions | |
| PdfRect () | |
| PdfRect (double left, double bottom, double width, double height) | |
| PdfRect (const PdfArray &inArray) | |
| PdfRect (const PdfRect &rhs) | |
| void | ToArray (PdfArray &arr) const |
| std::string | ToString () const |
| void | FromArray (const PdfArray &arr) |
| void | Intersect (const PdfRect &rect) |
| double | GetRight () const |
| double | GetTop () const |
| double | GetBottom () const |
| void | SetBottom (double bottom) |
| double | GetLeft () const |
| void | SetLeft (double left) |
| double | GetWidth () const |
| void | SetWidth (double width) |
| double | GetHeight () const |
| void | SetHeight (double height) |
Static Public Member Functions | |
| static PdfRect | FromCorners (double x1, double y1, double x2, double y2) |
A rectangle as defined by the PDF reference
| PdfRect::PdfRect | ( | ) |
Create an empty rectangle with bottom=left=with=height=0
| PdfRect::PdfRect | ( | double | left, |
| double | bottom, | ||
| double | width, | ||
| double | height | ||
| ) |
Create a rectangle with a given size and position All values are in PDF units NOTE: since PDF is bottom-left origined, we pass the bottom instead of the top
| PdfRect::PdfRect | ( | const PdfArray & | inArray | ) |
Create a rectangle from an array All values are in PDF units
| PdfRect::PdfRect | ( | const PdfRect & | rhs | ) |
Copy constructor
| void PdfRect::FromArray | ( | const PdfArray & | arr | ) |
Assigns the values of this PdfRect from the 4 values in the array
| inArray | the array to load the values from |
|
static |
|
inline |
Get the bottom coordinate of the rectangle
|
inline |
Get the height of the rectangle
|
inline |
Get the left coordinate of the rectangle
| double PdfRect::GetRight | ( | ) | const |
Get the right coordinate of the rectangle
| double PdfRect::GetTop | ( | ) | const |
Get the top coordinate of the rectangle
|
inline |
Get the width of the rectangle
| void PdfRect::Intersect | ( | const PdfRect & | rect | ) |
Intersect with another rect
| rect | the rect to intersect with |
|
inline |
Set the bottom coordinate of the rectangle
| bottom |
|
inline |
Set the height of the rectangle
| lHeight | in PDF units |
|
inline |
Set the left coordinate of the rectangle
| left | in PDF units |
|
inline |
Set the width of the rectangle
| lWidth | in PDF units |
| void PdfRect::ToArray | ( | PdfArray & | arr | ) | const |
Converts the rectangle into an array based on PDF units
| var | the array to store the Rect |
| string PdfRect::ToString | ( | ) | const |
Returns a string representation of the PdfRect