TwiceAsNice  2019-02-18
lipclAtomic Class Reference

A size is specified by a width() and a height(). It can be set in the constructor and changed using the setWidth(), setHeight(), or scale() functions, or using arithmetic operators. A size can also be manipulated directly by retrieving references to the width and height using the rwidth() and rheight() functions. Finally, the width and height can be swapped using the transpose() function. More...

#include <Size.h>

Collaboration diagram for lipclAtomic:
Collaboration graph

Detailed Description

A size is specified by a width() and a height(). It can be set in the constructor and changed using the setWidth(), setHeight(), or scale() functions, or using arithmetic operators. A size can also be manipulated directly by retrieving references to the width and height using the rwidth() and rheight() functions. Finally, the width and height can be swapped using the transpose() function.

Author
Florian Briegel
Version
11.02.04
Date
2012-08-10 11:04:58 AM The isValid() function determines if a size is valid. A valid size has both width and height greater than or equal to zero. The isEmpty() function returns true if either of the width and height is less than (or equal to) zero, while the isNull() function returns true only if both the width and the height is zero.

Use the expandedTo() function to retrieve a size which holds the maximum height and width of this size and a given size. Similarly, the boundedTo() function returns a size which holds the minimum height and width of this size and a given size.

The Nice::Size class also provides the toSizeVar() function returning a niceSize copy of this size, constructed by rounding the width and height to the nearest integers.

Nice::Size objects can be streamed as well as compared.


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