PoDoFo 0.9.6
|
#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 | ToVariant (PdfVariant &var) const |
std::string | ToString () const |
void | FromArray (const PdfArray &inArray) |
void | Intersect (const PdfRect &rRect) |
double | GetBottom () const |
void | SetBottom (double dBottom) |
double | GetLeft () const |
void | SetLeft (double lLeft) |
double | GetWidth () const |
void | SetWidth (double lWidth) |
double | GetHeight () const |
void | SetHeight (double lHeight) |
A rectangle as defined by the PDF reference
PoDoFo::PdfRect::PdfRect | ( | ) |
Create an empty rectangle with bottom=left=with=height=0
PoDoFo::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
PoDoFo::PdfRect::PdfRect | ( | const PdfArray & | inArray | ) |
Create a rectangle from an array All values are in PDF units
PoDoFo::PdfRect::PdfRect | ( | const PdfRect & | rhs | ) |
Copy constructor
void PoDoFo::PdfRect::FromArray | ( | const PdfArray & | inArray | ) |
Assigns the values of this PdfRect from the 4 values in the array
inArray | the array to load the values from |
|
inline |
Get the bottom coordinate of the rectangle
|
inline |
Get the height of the rectangle
|
inline |
Get the left coordinate of the rectangle
|
inline |
Get the width of the rectangle
void PoDoFo::PdfRect::Intersect | ( | const PdfRect & | rRect | ) |
Intersect with another rect
rRect | the rect to intersect with |
|
inline |
Set the bottom coordinate of the rectangle
dBottom |
|
inline |
Set the height of the rectangle
lHeight | in PDF units |
|
inline |
Set the left coordinate of the rectangle
lLeft | in PDF units |
|
inline |
Set the width of the rectangle
lWidth | in PDF units |
std::string PoDoFo::PdfRect::ToString | ( | ) | const |
Returns a string representation of the PdfRect
void PoDoFo::PdfRect::ToVariant | ( | PdfVariant & | var | ) | const |
Converts the rectangle into an array based on PDF units and adds the array into an variant.
var | the variant to store the Rect |