Android-cuttlefish cvd tool
Classes | Public Member Functions | Private Types | Private Attributes | List of all members
teeui::LabelImpl Class Reference

#include <label.h>

Inheritance diagram for teeui::LabelImpl:
Inheritance graph
[legend]
Collaboration diagram for teeui::LabelImpl:
Collaboration graph
[legend]

Classes

struct  LineInfo
 

Public Member Functions

 LabelImpl ()
 
 LabelImpl (pxs fontSize, pxs lineHeight, text_t text, Alignment horizontal, Alignment verticalJustified, Color textColor, FontBuffer font, uint64_t textId)
 
pxs fontSize () const
 
void setText (text_t text)
 
void setTextColor (Color color)
 
text_t text () const
 
uint64_t textId () const
 
Error draw (const PixelDrawer &drawPixel, const Box< pxs > &bounds, LineInfo *lineInfo)
 
void setCB (CallbackEvent cbEvent)
 
optional< CallbackEventgetCB ()
 
Error hit (const Event &event, const Box< pxs > &bounds)
 

Private Types

using text_t = UTF8Range< const char * >
 

Private Attributes

pxs fontSize_
 
pxs lineHeight_
 
text_t text_
 
Alignment horizontalTextAlignment_
 
Alignment verticalTextAlignment_
 
Color textColor_
 
FontBuffer font_
 
uint64_t textId_
 
optional< CallbackEventcbEvent_
 

Member Typedef Documentation

◆ text_t

using teeui::LabelImpl::text_t = UTF8Range<const char*>
private

Constructor & Destructor Documentation

◆ LabelImpl() [1/2]

teeui::LabelImpl::LabelImpl ( )
inline

◆ LabelImpl() [2/2]

teeui::LabelImpl::LabelImpl ( pxs  fontSize,
pxs  lineHeight,
text_t  text,
Alignment  horizontal,
Alignment  verticalJustified,
Color  textColor,
FontBuffer  font,
uint64_t  textId 
)
inline

Member Function Documentation

◆ draw()

Error teeui::LabelImpl::draw ( const PixelDrawer drawPixel,
const Box< pxs > &  bounds,
LineInfo lineInfo 
)

◆ fontSize()

pxs teeui::LabelImpl::fontSize ( ) const
inline

◆ getCB()

optional< CallbackEvent > teeui::LabelImpl::getCB ( )
inline

◆ hit()

Error teeui::LabelImpl::hit ( const Event event,
const Box< pxs > &  bounds 
)

◆ setCB()

void teeui::LabelImpl::setCB ( CallbackEvent  cbEvent)
inline

◆ setText()

void teeui::LabelImpl::setText ( text_t  text)
inline

◆ setTextColor()

void teeui::LabelImpl::setTextColor ( Color  color)
inline

◆ text()

text_t teeui::LabelImpl::text ( ) const
inline

◆ textId()

uint64_t teeui::LabelImpl::textId ( ) const
inline

Member Data Documentation

◆ cbEvent_

optional<CallbackEvent> teeui::LabelImpl::cbEvent_
private

◆ font_

FontBuffer teeui::LabelImpl::font_
private

◆ fontSize_

pxs teeui::LabelImpl::fontSize_
private

◆ horizontalTextAlignment_

Alignment teeui::LabelImpl::horizontalTextAlignment_
private

◆ lineHeight_

pxs teeui::LabelImpl::lineHeight_
private

◆ text_

text_t teeui::LabelImpl::text_
private

◆ textColor_

Color teeui::LabelImpl::textColor_
private

◆ textId_

uint64_t teeui::LabelImpl::textId_
private

◆ verticalTextAlignment_

Alignment teeui::LabelImpl::verticalTextAlignment_
private

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