Logo ROOT   6.18/05
Reference Guide
List of all members | Public Member Functions | Private Attributes | List of all members
TGLRect Class Reference

Viewport (pixel base) 2D rectangle class.

Definition at line 420 of file TGLUtil.h.

Public Member Functions

 TGLRect ()
 Positive width/height. More...
 
 TGLRect (Int_t x, Int_t y, Int_t width, Int_t height)
 Construct rect object, corner (x,y), dimensions 'width', 'height'. More...
 
 TGLRect (Int_t x, Int_t y, UInt_t width, UInt_t height)
 Construct rect object, corner (x,y), dimensions 'width', 'height'. More...
 
virtual ~TGLRect ()
 Destroy rect object. More...
 
Double_t Aspect () const
 
Int_t Bottom () const
 
Int_tCArr ()
 
const Int_tCArr () const
 
Int_t CenterX () const
 
Int_t CenterY () const
 
Int_t Diagonal () const
 Return the diagonal of the rectangle. More...
 
void Expand (Int_t x, Int_t y)
 Expand the rect to encompass point (x,y) More...
 
Int_tHeight ()
 
Int_t Height () const
 
Int_t Left () const
 
Int_t Longest () const
 
void Offset (Int_t dX, Int_t dY)
 
Rgl::EOverlap Overlap (const TGLRect &other) const
 Return overlap result (kInside, kOutside, kPartial) of this rect with 'other'. More...
 
Int_t Right () const
 
void Set (Int_t x, Int_t y, Int_t width, Int_t height)
 
void SetCorner (Int_t x, Int_t y)
 
Int_t Top () const
 
Int_tWidth ()
 
Int_t Width () const
 
Int_tX ()
 
Int_t X () const
 
Int_tY ()
 
Int_t Y () const
 

Private Attributes

Int_t fHeight
 
Int_t fWidth
 Corner. More...
 
Int_t fX
 
Int_t fY
 

#include <TGLUtil.h>

Constructor & Destructor Documentation

◆ TGLRect() [1/3]

TGLRect::TGLRect ( )

Positive width/height.

Construct empty rect object, corner (0,0), width/height 0.

Definition at line 230 of file TGLUtil.cxx.

◆ TGLRect() [2/3]

TGLRect::TGLRect ( Int_t  x,
Int_t  y,
Int_t  width,
Int_t  height 
)

Construct rect object, corner (x,y), dimensions 'width', 'height'.

Definition at line 238 of file TGLUtil.cxx.

◆ TGLRect() [3/3]

TGLRect::TGLRect ( Int_t  x,
Int_t  y,
UInt_t  width,
UInt_t  height 
)

Construct rect object, corner (x,y), dimensions 'width', 'height'.

Definition at line 246 of file TGLUtil.cxx.

◆ ~TGLRect()

TGLRect::~TGLRect ( )
virtual

Destroy rect object.

Definition at line 255 of file TGLUtil.cxx.

Member Function Documentation

◆ Aspect()

Double_t TGLRect::Aspect ( ) const
inline

Definition at line 499 of file TGLUtil.h.

◆ Bottom()

Int_t TGLRect::Bottom ( ) const
inline

Definition at line 458 of file TGLUtil.h.

◆ CArr() [1/2]

Int_t * TGLRect::CArr ( )
inline

Definition at line 443 of file TGLUtil.h.

◆ CArr() [2/2]

const Int_t * TGLRect::CArr ( ) const
inline

Definition at line 442 of file TGLUtil.h.

◆ CenterX()

Int_t TGLRect::CenterX ( ) const
inline

Definition at line 453 of file TGLUtil.h.

◆ CenterY()

Int_t TGLRect::CenterY ( ) const
inline

Definition at line 454 of file TGLUtil.h.

◆ Diagonal()

Int_t TGLRect::Diagonal ( ) const

Return the diagonal of the rectangle.

Definition at line 287 of file TGLUtil.cxx.

◆ Expand()

void TGLRect::Expand ( Int_t  x,
Int_t  y 
)

Expand the rect to encompass point (x,y)

Definition at line 262 of file TGLUtil.cxx.

◆ Height() [1/2]

Int_t & TGLRect::Height ( )
inline

Definition at line 452 of file TGLUtil.h.

◆ Height() [2/2]

Int_t TGLRect::Height ( ) const
inline

Definition at line 451 of file TGLUtil.h.

◆ Left()

Int_t TGLRect::Left ( ) const
inline

Definition at line 455 of file TGLUtil.h.

◆ Longest()

Int_t TGLRect::Longest ( ) const
inline

Definition at line 493 of file TGLUtil.h.

◆ Offset()

void TGLRect::Offset ( Int_t  dX,
Int_t  dY 
)
inline

Definition at line 486 of file TGLUtil.h.

◆ Overlap()

Rgl::EOverlap TGLRect::Overlap ( const TGLRect other) const

Return overlap result (kInside, kOutside, kPartial) of this rect with 'other'.

Definition at line 298 of file TGLUtil.cxx.

◆ Right()

Int_t TGLRect::Right ( ) const
inline

Definition at line 456 of file TGLUtil.h.

◆ Set()

void TGLRect::Set ( Int_t  x,
Int_t  y,
Int_t  width,
Int_t  height 
)
inline

Definition at line 470 of file TGLUtil.h.

◆ SetCorner()

void TGLRect::SetCorner ( Int_t  x,
Int_t  y 
)
inline

Definition at line 479 of file TGLUtil.h.

◆ Top()

Int_t TGLRect::Top ( ) const
inline

Definition at line 457 of file TGLUtil.h.

◆ Width() [1/2]

Int_t & TGLRect::Width ( )
inline

Definition at line 450 of file TGLUtil.h.

◆ Width() [2/2]

Int_t TGLRect::Width ( ) const
inline

Definition at line 449 of file TGLUtil.h.

◆ X() [1/2]

Int_t & TGLRect::X ( )
inline

Definition at line 446 of file TGLUtil.h.

◆ X() [2/2]

Int_t TGLRect::X ( ) const
inline

Definition at line 445 of file TGLUtil.h.

◆ Y() [1/2]

Int_t & TGLRect::Y ( )
inline

Definition at line 448 of file TGLUtil.h.

◆ Y() [2/2]

Int_t TGLRect::Y ( ) const
inline

Definition at line 447 of file TGLUtil.h.

Member Data Documentation

◆ fHeight

Int_t TGLRect::fHeight
private

Definition at line 425 of file TGLUtil.h.

◆ fWidth

Int_t TGLRect::fWidth
private

Corner.

Definition at line 425 of file TGLUtil.h.

◆ fX

Int_t TGLRect::fX
private

Definition at line 424 of file TGLUtil.h.

◆ fY

Int_t TGLRect::fY
private

Definition at line 424 of file TGLUtil.h.


The documentation for this class was generated from the following files: