Position Class Reference

Note: Even if the object is tied to its direct container rectangle, the coordinates returned by getLeft(), getTop(), getRight() and getBottom() are not relative to the direct container (which is usually a panel or the layout) but to the root container (i.e. More...

Inheritance diagram for Position:

Inheritance graph
[legend]
Collaboration diagram for Position:

Collaboration graph
[legend]

Public Types

enum  Ref_t { kLeftTop, kRightTop, kLeftBottom, kRightBottom }
 Type for reference edge/corner. More...

Public Member Functions

 Position (int left, int top, int right, int bottom, const GenericRect &rRect, Ref_t refLeftTop, Ref_t refRightBottom, bool xKeepRatio, bool yKeepRatio)
 Create a new position relative to the given box.
 ~Position ()
virtual int getLeft () const
 Get the position relative to the left top corner of the box.
virtual int getTop () const
int getRight () const
int getBottom () const
virtual int getWidth () const
 Get the size of the rectangle.
virtual int getHeight () const
Ref_t getRefLeftTop () const
 Get the reference corners.
Ref_t getRefRightBottom () const

Detailed Description

Note: Even if the object is tied to its direct container rectangle, the coordinates returned by getLeft(), getTop(), getRight() and getBottom() are not relative to the direct container (which is usually a panel or the layout) but to the root container (i.e.

the layout).


Member Enumeration Documentation

enum Position::Ref_t

Type for reference edge/corner.

Enumerator:
kLeftTop  Coordinates are relative to the upper left corner.
kRightTop  Coordinates are relative to the upper right corner.
kLeftBottom  Coordinates are relative to the lower left corner.
kRightBottom  Coordinates are relative to the lower right corner.


Constructor & Destructor Documentation

Position::Position ( int  left,
int  top,
int  right,
int  bottom,
const GenericRect rRect,
Ref_t  refLeftTop,
Ref_t  refRightBottom,
bool  xKeepRatio,
bool  yKeepRatio 
)

Create a new position relative to the given box.

Position::~Position (  )  [inline]


Member Function Documentation

int Position::getLeft (  )  const [virtual]

Get the position relative to the left top corner of the box.

Implements GenericRect.

int Position::getTop (  )  const [virtual]

Implements GenericRect.

int Position::getRight (  )  const

int Position::getBottom (  )  const

int Position::getWidth (  )  const [virtual]

Get the size of the rectangle.

Implements Box.

int Position::getHeight (  )  const [virtual]

Implements Box.

Ref_t Position::getRefLeftTop (  )  const [inline]

Get the reference corners.

Ref_t Position::getRefRightBottom (  )  const [inline]


The documentation for this class was generated from the following files:
Generated on Wed Aug 13 09:41:41 2008 for VLC by  doxygen 1.5.1