ADTF_DISPLAY_TOOLBOX  3.8.0 (ADTF 3.14.3)
cRect

Rectangle class. More...

Inheritance diagram for cRect:
[legend]

Public Member Functions

 cRect ()
 default constructor
 
 cRect (const IRect *pRect)
 constructor from IRect More...
 
 cRect (tInt l, tInt t, tInt r, tInt b)
 constructor with parameter More...
 
tVoid Release ()
 
tVoid Set (tInt l, tInt t, tInt r, tInt b)
 sets the rect More...
 
tInt GetWidth () const
 returns the width of the rectangle More...
 
tInt GetHeight () const
 returns the height of the rectangle More...
 
const cPointGetTopLeft () const
 returns the top left point of the rectangle More...
 
const cPointGetBottomRight () const
 returns the bottom right point of the rectangle More...
 
tInt GetLeft () const
 
tVoid SetLeft (tInt nLeft)
 
tInt GetTop () const
 
tVoid SetTop (tInt nTop)
 
tInt GetRight () const
 
tVoid SetRight (tInt nRight)
 
tInt GetBottom () const
 
tVoid SetBottom (tInt nBottom)
 
 operator IRect * ()
 instance of IRect More...
 
- Public Member Functions inherited from IRect
virtual ~IRect ()
 virtual destructor to ensure proper cleanup.
 

Public Attributes

tInt m_nLeft
 left border of the rect
 
tInt m_nTop
 top border of the rect
 
tInt m_nRight
 right border of the rect
 
tInt m_nBottom
 bottom border of the rect
 

Detailed Description

Rectangle class.

Definition at line 29 of file rect.h.

Constructor & Destructor Documentation

◆ cRect() [1/2]

cRect ( const IRect pRect)

constructor from IRect

Parameters
[in]pRectRectangle

◆ cRect() [2/2]

cRect ( tInt  l,
tInt  t,
tInt  r,
tInt  b 
)

constructor with parameter

Parameters
[in]lleft border
[in]ttop border
[in]rright border
[in]bbottom border

Member Function Documentation

◆ GetBottom()

tInt GetBottom ( ) const
virtual

gets the bottom border of the rectangle

Returns
tInt value of the bottom border

Implements IRect.

◆ GetBottomRight()

const cPoint* GetBottomRight ( ) const
virtual

returns the bottom right point of the rectangle

Returns
bottom right point

Implements IRect.

◆ GetHeight()

tInt GetHeight ( ) const
virtual

returns the height of the rectangle

Returns
height

Implements IRect.

◆ GetLeft()

tInt GetLeft ( ) const
virtual

Gets the left border of the rectangle

Returns
tInt value of the left border

Implements IRect.

◆ GetRight()

tInt GetRight ( ) const
virtual

Gets the right border of the rectangle

Returns
tInt value of the right border

Implements IRect.

◆ GetTop()

tInt GetTop ( ) const
virtual

Gets the top border of the rectangle

Returns
tInt value of the top border

Implements IRect.

◆ GetTopLeft()

const cPoint* GetTopLeft ( ) const
virtual

returns the top left point of the rectangle

Returns
top left point

Implements IRect.

◆ GetWidth()

tInt GetWidth ( ) const
virtual

returns the width of the rectangle

Returns
width

Implements IRect.

◆ operator IRect *()

operator IRect * ( )
inlineexplicit

instance of IRect

Returns
object

Definition at line 176 of file rect.h.

◆ Release()

tVoid Release ( )
virtual

Releases this rectangle

Returns
void

Implements IRect.

◆ Set()

tVoid Set ( tInt  l,
tInt  t,
tInt  r,
tInt  b 
)

sets the rect

Parameters
[in]lleft border
[in]ttop border
[in]rright border
[in]bbottom border
Returns
void

◆ SetBottom()

tVoid SetBottom ( tInt  nBottom)
virtual

Sets the bottom border of the rectangle with the given value

Parameters
nBottom[in] bottom border value
Returns
void

Implements IRect.

◆ SetLeft()

tVoid SetLeft ( tInt  nLeft)
virtual

Sets the left border of the rectangle with the given value

Parameters
nLeft[in] left border value
Returns
void

Implements IRect.

◆ SetRight()

tVoid SetRight ( tInt  nRight)
virtual

Sets the right border of the rectangle with the given value

Parameters
nRight[in] right border value
Returns
void

Implements IRect.

◆ SetTop()

tVoid SetTop ( tInt  nTop)
virtual

Sets the top border of the rectangle with the given value

Parameters
nTop[in] top border value
Returns
void

Implements IRect.