zenilib: Zeni::Widget_Rectangle Class Reference

zenilib 0.5.3.0

- Main Page
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | List of all members
Zeni::Widget_Rectangle Class Reference
Zenilib

Rectangle positioning. More...

`#include <Widget.h>`

Inherited by Zeni::Selector::Selector_Slider, and Zeni::Widget_Button.

## Public Member Functions

| Widget_Rectangle (const Point2f &upper_left_, const Point2f &lower_right_)
virtual | ~Widget_Rectangle ()
Point2f | get_center () const
float | get_height () const
Point2f | get_lower_left () const
const Point2f & | get_lower_right () const
const Point2f & | get_upper_left () const
Point2f | get_upper_right () const
float | get_width () const
bool | is_inside (const Point2i &pos) const
virtual void | set_lower_right (const Point2f &lower_right_)
virtual void | set_upper_left (const Point2f &upper_left_)

## Detailed Description

Rectangle positioning.

Any Widget occupying a rectangle should inherit from this class and offer its interface.

Author
  bazald

Contact: bazal.nosp@m.d@ze.nosp@m.nipex.nosp@m..com

Definition at line 430 of file Widget.h.

## Constructor & Destructor Documentation

Zeni::Widget_Rectangle::Widget_Rectangle | ( | const Point2f & | upper_left_,
|  | const Point2f & | lower_right_
| ) |  |

inline

Definition at line 142 of file Widget.hxx.

virtual Zeni::Widget_Rectangle::~Widget_Rectangle | ( |  | ) |

inlinevirtual

Definition at line 433 of file Widget.h.

## Member Function Documentation

Point2f Zeni::Widget_Rectangle::get_center | ( |  | ) | const

inline

Definition at line 172 of file Widget.hxx.

References Zeni::Point2f::x, and Zeni::Point2f::y.

Referenced by Zeni::Widget_Renderer_Text::render_to().

float Zeni::Widget_Rectangle::get_height | ( |  | ) | const

inline

Definition at line 164 of file Widget.hxx.

References Zeni::Point2f::y.

Referenced by Zeni::Text_Box::get_max_lines().

Point2f Zeni::Widget_Rectangle::get_lower_left | ( |  | ) | const

inline

Definition at line 152 of file Widget.hxx.

References Zeni::Point2f::x, and Zeni::Point2f::y.

Referenced by Zeni::Widget_Renderer_Color::render_to(), Zeni::Widget_Renderer_Texture::render_to(), and Zeni::Widget_Renderer_Check_Box::render_to().

const Point2f & Zeni::Widget_Rectangle::get_lower_right | ( |  | ) | const

inline

Definition at line 156 of file Widget.hxx.

Referenced by Zeni::Text_Box::on_accept(), Zeni::Text_Box::render_impl(), Zeni::Widget_Renderer_Color::render_to(), Zeni::Widget_Renderer_Texture::render_to(), and Zeni::Widget_Renderer_Check_Box::render_to().

const Point2f & Zeni::Widget_Rectangle::get_upper_left | ( |  | ) | const

inline

Definition at line 148 of file Widget.hxx.

Referenced by Zeni::Text_Box::on_accept(), Zeni::Text_Box::on_mouse_button(), Zeni::Text_Box::render_impl(), Zeni::Widget_Renderer_Color::render_to(), Zeni::Widget_Renderer_Texture::render_to(), and Zeni::Widget_Renderer_Check_Box::render_to().

Point2f Zeni::Widget_Rectangle::get_upper_right | ( |  | ) | const

inline

Definition at line 160 of file Widget.hxx.

References Zeni::Point2f::x, and Zeni::Point2f::y.

Referenced by Zeni::Widget_Renderer_Color::render_to(), Zeni::Widget_Renderer_Texture::render_to(), and Zeni::Widget_Renderer_Check_Box::render_to().

float Zeni::Widget_Rectangle::get_width | ( |  | ) | const

inline

Definition at line 168 of file Widget.hxx.

References Zeni::Point2f::x.

bool Zeni::Widget_Rectangle::is_inside | ( | const Point2i & | pos | ) | const

inline

Definition at line 177 of file Widget.hxx.

References Zeni::Point2i::x, Zeni::Point2f::x, Zeni::Point2i::y, and Zeni::Point2f::y.

Referenced by Zeni::Widget_Button::on_mouse_button(), and Zeni::Widget_Button::on_mouse_motion().

void Zeni::Widget_Rectangle::set_lower_right | ( | const Point2f & | lower_right_ | ) |

virtual

Reimplemented in Zeni::Text_Box.

Definition at line 49 of file Widget.cpp.

Referenced by Zeni::Text_Box::set_lower_right().

void Zeni::Widget_Rectangle::set_upper_left | ( | const Point2f & | upper_left_ | ) |

virtual

Reimplemented in Zeni::Text_Box.

Definition at line 45 of file Widget.cpp.

Referenced by Zeni::Text_Box::set_upper_left().

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

- zenilib/jni/external/zenilib/zeni_rest/Zeni/Widget.h
- zenilib/jni/external/zenilib/zeni_rest/Widget.cpp
- zenilib/jni/external/zenilib/zeni_rest/Zeni/Widget.hxx