lecui 1.0.0-alpha.20
lecui C++ user interface library
|
Resize parameters. More...
#include <lecui.h>
Public Member Functions | |
resize_params () | |
Constructor. More... | |
resize_params (const float x_rate, const float y_rate, const float width_rate, const float height_rate) | |
Constructor that allows initializing the most important properties. More... | |
float & | x_rate () |
Get or set the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved. More... | |
float | get_x_rate () const |
Get the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved. More... | |
resize_params & | x_rate (const float &x_rate) |
Set the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved. More... | |
float & | y_rate () |
Get or set the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved. More... | |
float | get_y_rate () const |
Get the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved. More... | |
resize_params & | y_rate (const float &y_rate) |
Set the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved. More... | |
float & | width_rate () |
Get or set the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container. More... | |
float | get_width_rate () const |
Get the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container. More... | |
resize_params & | width_rate (const float &width_rate) |
Set the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container. More... | |
float & | height_rate () |
Get or set the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container. More... | |
float | get_height_rate () const |
Get the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container. More... | |
resize_params & | height_rate (const float &height_rate) |
Set the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container. More... | |
float & | min_x () |
Get or set the minimum x-coordinate permitted as widget moves. More... | |
const float | get_min_x () const |
Get the minimum x-coordinate permitted as widget moves. More... | |
resize_params & | min_x (const float &min_x) |
Set the minimum x-coordinate permitted as widget moves. More... | |
float & | min_y () |
Get or set the minimum y-coordinate permitted as widget moves. More... | |
float | get_min_y () const |
Get minimum y-coordinate permitted as widget moves. More... | |
resize_params & | min_y (const float &min_y) |
Set the minimum y-coordinate permitted as widget moves. More... | |
float & | max_x () |
Get or set the maximum x-coordinate permitted as widget moves. More... | |
float | get_max_x () const |
Get the maximum x-coordinate permitted as widget moves. More... | |
resize_params & | max_x (const float &max_x) |
Set the maximum x-coordinate permitted as widget moves. More... | |
float & | max_y () |
Get or set the maximum y-coordinate permitted as widget moves. More... | |
float | get_max_y () const |
Get maximum y-coordinate permitted as widget moves. More... | |
resize_params & | max_y (const float &max_y) |
Set the maximum y-coordinate permitted as widget moves. More... | |
float & | min_width () |
Get or set the minimum width permitted as widget is resized. More... | |
float | get_min_width () const |
Get the minimum width permitted as widget is resized. More... | |
resize_params & | min_width (const float &min_width) |
Set the minimum width permitted as widget is resized. More... | |
float & | min_height () |
Get or set the minimum height permitted as widget is resized. More... | |
float | get_min_height () const |
Get the minimum height permitted as widget is resized. More... | |
resize_params & | min_height (const float &min_height) |
Set the minimum height permitted as widget is resized. More... | |
float & | max_width () |
Get or set the maximum width permitted as widget is resized. More... | |
float | get_max_width () const |
Get the maximum width permitted as widget is resized. More... | |
resize_params & | max_width (const float &max_width) |
Set the maximum width permitted as widget is resized. More... | |
float & | max_height () |
Get or set the maximum height permitted as widget is resized. More... | |
float | get_max_height () const |
Get the maximum height permitted as widget is resized. More... | |
resize_params & | max_height (const float &max_height) |
Set the maximum height permitted as widget is resized. More... | |
bool | operator== (const resize_params ¶m) |
Check whether two resize parameter objects are equal. All properties are considered. More... | |
bool | operator!= (const resize_params ¶m) |
Check whether two resize parameter objects are NOT equal. All properties are considered. More... | |
Resize parameters.
Affects how the widget behaves when the immediate container's dimensions change.
liblec::lecui::resize_params::resize_params | ( | ) |
Constructor.
Initializes with all fields set to zero.
liblec::lecui::resize_params::resize_params | ( | const float | x_rate, |
const float | y_rate, | ||
const float | width_rate, | ||
const float | height_rate | ||
) |
Constructor that allows initializing the most important properties.
x_rate | The percentage rate for following the container's right border. |
y_rate | The percentage rate for following the container's bottom border. |
width_rate | The percentage rate for following the container's change in width. |
height_rate | The percentage rate for following the container's change in height. |
Initializes the rest of the fields set to zero.
float liblec::lecui::resize_params::get_height_rate | ( | ) | const |
Get the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container.
float liblec::lecui::resize_params::get_max_height | ( | ) | const |
Get the maximum height permitted as widget is resized.
float liblec::lecui::resize_params::get_max_width | ( | ) | const |
Get the maximum width permitted as widget is resized.
float liblec::lecui::resize_params::get_max_x | ( | ) | const |
Get the maximum x-coordinate permitted as widget moves.
float liblec::lecui::resize_params::get_max_y | ( | ) | const |
Get maximum y-coordinate permitted as widget moves.
float liblec::lecui::resize_params::get_min_height | ( | ) | const |
Get the minimum height permitted as widget is resized.
float liblec::lecui::resize_params::get_min_width | ( | ) | const |
Get the minimum width permitted as widget is resized.
const float liblec::lecui::resize_params::get_min_x | ( | ) | const |
Get the minimum x-coordinate permitted as widget moves.
float liblec::lecui::resize_params::get_min_y | ( | ) | const |
Get minimum y-coordinate permitted as widget moves.
float liblec::lecui::resize_params::get_width_rate | ( | ) | const |
Get the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container.
float liblec::lecui::resize_params::get_x_rate | ( | ) | const |
Get the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved.
float liblec::lecui::resize_params::get_y_rate | ( | ) | const |
Get the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved.
float & liblec::lecui::resize_params::height_rate | ( | ) |
Get or set the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container.
resize_params & liblec::lecui::resize_params::height_rate | ( | const float & | height_rate | ) |
Set the percentage rate for following the container's change in height. 0 = doesn't follow change in container's height, 100 = height changes at same rate as that of container.
height_rate | The value of the property. |
float & liblec::lecui::resize_params::max_height | ( | ) |
Get or set the maximum height permitted as widget is resized.
resize_params & liblec::lecui::resize_params::max_height | ( | const float & | max_height | ) |
Set the maximum height permitted as widget is resized.
max_height | The value of the property. |
float & liblec::lecui::resize_params::max_width | ( | ) |
Get or set the maximum width permitted as widget is resized.
resize_params & liblec::lecui::resize_params::max_width | ( | const float & | max_width | ) |
Set the maximum width permitted as widget is resized.
max_width | The value of the property. |
float & liblec::lecui::resize_params::max_x | ( | ) |
Get or set the maximum x-coordinate permitted as widget moves.
resize_params & liblec::lecui::resize_params::max_x | ( | const float & | max_x | ) |
Set the maximum x-coordinate permitted as widget moves.
max_x | The value of the property. |
float & liblec::lecui::resize_params::max_y | ( | ) |
Get or set the maximum y-coordinate permitted as widget moves.
resize_params & liblec::lecui::resize_params::max_y | ( | const float & | max_y | ) |
Set the maximum y-coordinate permitted as widget moves.
max_y | The value of the property. |
float & liblec::lecui::resize_params::min_height | ( | ) |
Get or set the minimum height permitted as widget is resized.
resize_params & liblec::lecui::resize_params::min_height | ( | const float & | min_height | ) |
Set the minimum height permitted as widget is resized.
min_height | The value of the property. |
float & liblec::lecui::resize_params::min_width | ( | ) |
Get or set the minimum width permitted as widget is resized.
resize_params & liblec::lecui::resize_params::min_width | ( | const float & | min_width | ) |
Set the minimum width permitted as widget is resized.
min_width | The value of the property. |
float & liblec::lecui::resize_params::min_x | ( | ) |
Get or set the minimum x-coordinate permitted as widget moves.
resize_params & liblec::lecui::resize_params::min_x | ( | const float & | min_x | ) |
Set the minimum x-coordinate permitted as widget moves.
min_x | The value of the property. |
float & liblec::lecui::resize_params::min_y | ( | ) |
Get or set the minimum y-coordinate permitted as widget moves.
resize_params & liblec::lecui::resize_params::min_y | ( | const float & | min_y | ) |
Set the minimum y-coordinate permitted as widget moves.
min_y | The value of the property. |
bool liblec::lecui::resize_params::operator!= | ( | const resize_params & | param | ) |
Check whether two resize parameter objects are NOT equal. All properties are considered.
param | The object to compare to. |
bool liblec::lecui::resize_params::operator== | ( | const resize_params & | param | ) |
Check whether two resize parameter objects are equal. All properties are considered.
param | The object to compare to. |
float & liblec::lecui::resize_params::width_rate | ( | ) |
Get or set the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container.
resize_params & liblec::lecui::resize_params::width_rate | ( | const float & | width_rate | ) |
Set the percentage rate for following the container's change in width. 0 = doesn't follow change in container's width, 100 = width changes at same rate as that of container.
width_rate | The value of the property. |
float & liblec::lecui::resize_params::x_rate | ( | ) |
Get or set the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved.
resize_params & liblec::lecui::resize_params::x_rate | ( | const float & | x_rate | ) |
Set the percentage rate for following the container's right border. 0 = doesn't move horizontally, 100 = moves same number of pixels horizontally that the container's right border has moved.
x_rate | The value of the property. |
float & liblec::lecui::resize_params::y_rate | ( | ) |
Get or set the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved.
resize_params & liblec::lecui::resize_params::y_rate | ( | const float & | y_rate | ) |
Set the percentage rate for following the container's bottom border. 0 = doesn't move vertically, 100 = moves same number of pixels vertically that the container's bottom border has moved.
y_rate | The value of the property. |