HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Enumerations | Functions
alignment.hpp File Reference
#include "assert.hpp"

Go to the source code of this file.

Enumerations

enum class  tt::vertical_alignment { top , middle , bottom }
 Vertical alignment. More...
 
enum class  tt::horizontal_alignment { left , center , right }
 Horizontal alignment. More...
 
enum class  tt::alignment {
  top_left , top_center , top_right , middle_left ,
  middle_center , middle_right , bottom_left , bottom_center ,
  bottom_right
}
 Vertical and horizontal alignment. More...
 

Functions

constexpr alignment tt::operator| (vertical_alignment lhs, horizontal_alignment rhs) noexcept
 Combine vertical and horizontal alignment.
 
constexpr alignment tt::operator| (horizontal_alignment lhs, vertical_alignment rhs) noexcept
 Combine vertical and horizontal alignment.
 
constexpr bool tt::operator== (alignment lhs, horizontal_alignment rhs) noexcept
 Check if the horizontal alignments are equal.
 
constexpr bool tt::operator== (alignment lhs, vertical_alignment rhs) noexcept
 Check if the vertical alignments are equal.
 

Enumeration Type Documentation

◆ alignment

enum class tt::alignment
strong

Vertical and horizontal alignment.

Enumerator
top_left 

Align to the top and left.

top_center 

Align to the top and horizontal-center.

top_right 

Align to the top and right.

middle_left 

Align to the vertical-middle and left.

middle_center 

Align to the vertical-middle and horizontal-center.

middle_right 

Align to the vertical-middle and right.

bottom_left 

Align to the bottom and left.

bottom_center 

Align to the bottom and horizontal-center.

bottom_right 

Align to the bottom and right.

◆ horizontal_alignment

enum class tt::horizontal_alignment
strong

Horizontal alignment.

Enumerator
left 

Align to the left.

center 

Align to the horizontal-center.

right 

Align to the right.

◆ vertical_alignment

enum class tt::vertical_alignment
strong

Vertical alignment.

Enumerator
top 

Align to the top.

middle 

Align to the vertical-middle.

bottom 

Align to the bottom.

Function Documentation

◆ operator==() [1/2]

constexpr bool tt::operator== ( alignment lhs,
horizontal_alignment rhs )
constexprnoexcept

Check if the horizontal alignments are equal.

Parameters
lhsA combined vertical and horizontal alignment.
rhsA horizontal alignment.
Returns
True when the horizontal alignment of both lhs and rhs are equal.

◆ operator==() [2/2]

constexpr bool tt::operator== ( alignment lhs,
vertical_alignment rhs )
constexprnoexcept

Check if the vertical alignments are equal.

Parameters
lhsA combined vertical and horizontal alignment.
rhsA vertical alignment.
Returns
True when the vertical alignment of both lhs and rhs are equal.

◆ operator|() [1/2]

constexpr alignment tt::operator| ( horizontal_alignment lhs,
vertical_alignment rhs )
constexprnoexcept

Combine vertical and horizontal alignment.

Parameters
lhsA horizontal alignment.
rhsA vertical alignment.
Returns
A combined vertical and horizontal alignment.

◆ operator|() [2/2]

constexpr alignment tt::operator| ( vertical_alignment lhs,
horizontal_alignment rhs )
constexprnoexcept

Combine vertical and horizontal alignment.

Parameters
lhsA vertical alignment.
rhsA horizontal alignment.
Returns
A combined vertical and horizontal alignment.