FlatUI
An open source project by FPL.
 All Classes Namespaces Files Functions Variables Enumerations Groups Pages
flatui::FontBufferAttributes Class Reference

A structure holding attribute information of texts in a FontBuffer. More...

#include <font_buffer.h>

Detailed Description

A structure holding attribute information of texts in a FontBuffer.

Classes

struct  UnderlineInfo
 

Public Member Functions

 FontBufferAttributes (bool underline, uint32_t color)
 The constructor to set default values. More...
 
bool operator== (const FontBufferAttributes &other) const
 The equal-to operator for comparing FontBufferAttributes for equality. More...
 
size_t operator() (const FontBufferAttributes &key) const
 The hash function for FontBufferAttributes. More...
 
bool operator() (const FontBufferAttributes &lhs, const FontBufferAttributes &rhs) const
 The compare operator for FontBufferAttributes.
 
uint32_t get_color () const
 
bool get_underline () const
 
const std::vector
< UnderlineInfo > & 
get_underline_info () const
 
int32_t get_slice_index () const
 
void set_slice_index (int32_t slice_index)
 

Constructor & Destructor Documentation

flatui::FontBufferAttributes::FontBufferAttributes ( bool  underline,
uint32_t  color 
)
inline

The constructor to set default values.

Parameters
[in]underlineA flag indicating if the attribute has underline.
[in]colorA color value of the attribute in RGBA8888.

Member Function Documentation

size_t flatui::FontBufferAttributes::operator() ( const FontBufferAttributes key) const
inline

The hash function for FontBufferAttributes.

Parameters
[in]keyA FontBufferAttributes to use as the key for hashing.
Returns
Returns a size_t of the hash of the FontBufferAttributes.
bool flatui::FontBufferAttributes::operator== ( const FontBufferAttributes other) const
inline

The equal-to operator for comparing FontBufferAttributes for equality.

Parameters
[in]otherThe other FontBufferAttributes to check against for equality.
Returns
Returns true if the two FontBufferAttributes are equal. Otherwise it returns false.

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