ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
cloudViewer::visualization::gui::Rect Struct Reference

#include <Gui.h>

Public Member Functions

 Rect ()
 
 Rect (int x_, int y_, int w_, int h_)
 
int GetTop () const
 
int GetBottom () const
 
int GetLeft () const
 
int GetRight () const
 
bool Contains (int x, int y) const
 
bool Contains (const Point &pt) const
 
Rect UnionedWith (const Rect &r) const
 
bool operator== (const Rect &other) const
 
bool operator!= (const Rect &other) const
 

Public Attributes

int x
 
int y
 
int width
 
int height
 

Detailed Description

Definition at line 30 of file Gui.h.

Constructor & Destructor Documentation

◆ Rect() [1/2]

cloudViewer::visualization::gui::Rect::Rect ( )

Definition at line 26 of file Gui.cpp.

Referenced by UnionedWith().

◆ Rect() [2/2]

cloudViewer::visualization::gui::Rect::Rect ( int  x_,
int  y_,
int  w_,
int  h_ 
)

Definition at line 28 of file Gui.cpp.

Member Function Documentation

◆ Contains() [1/2]

bool cloudViewer::visualization::gui::Rect::Contains ( const Point pt) const

◆ Contains() [2/2]

bool cloudViewer::visualization::gui::Rect::Contains ( int  x,
int  y 
) const

Definition at line 39 of file Gui.cpp.

References GetBottom(), GetRight(), x, and y.

Referenced by Contains(), and cloudViewer::visualization::gui::Window::OnMouseEvent().

◆ GetBottom()

int cloudViewer::visualization::gui::Rect::GetBottom ( ) const

◆ GetLeft()

int cloudViewer::visualization::gui::Rect::GetLeft ( ) const

Definition at line 35 of file Gui.cpp.

References x.

Referenced by cloudViewer::visualization::gui::pybind_gui_classes().

◆ GetRight()

int cloudViewer::visualization::gui::Rect::GetRight ( ) const

◆ GetTop()

int cloudViewer::visualization::gui::Rect::GetTop ( ) const

Definition at line 31 of file Gui.cpp.

References y.

Referenced by cloudViewer::visualization::gui::pybind_gui_classes().

◆ operator!=()

bool cloudViewer::visualization::gui::Rect::operator!= ( const Rect other) const

Definition at line 59 of file Gui.cpp.

References operator==().

◆ operator==()

bool cloudViewer::visualization::gui::Rect::operator== ( const Rect other) const

Definition at line 54 of file Gui.cpp.

References height, width, x, and y.

Referenced by operator!=().

◆ UnionedWith()

Rect cloudViewer::visualization::gui::Rect::UnionedWith ( const Rect r) const

Definition at line 46 of file Gui.cpp.

References GetBottom(), GetRight(), max(), min(), Rect(), x, and y.

Referenced by cloudViewer::visualization::gui::Window::CalcPreferredSize().

Member Data Documentation

◆ height

◆ width

◆ x

◆ y


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