Toggle navigation
ivorium
iv_components
Example project
GitHub
Main Page
Modules
Classes
Files
File List
File Members
ivorium_UI
LumaText.cpp
Go to the documentation of this file.
1
#include "
LumaText.hpp
"
2
3
namespace
iv
4
{
5
6
LumaText::LumaText
(
Instance
* inst,
LumaStyleId
style_id,
bool
monospace ) :
7
Text
( inst ),
8
LumaListener
( inst, style_id ),
9
cm( inst, this,
"LumaText"
),
10
monospace( monospace )
11
{
12
this->
cm
.
inherits
( this->
Text::cm
, this->
LumaListener::cm
);
13
this->
LumaStyleChanged
( this->
style
() );
14
}
15
16
void
LumaText::LumaStyleChanged
(
LumaStyle
const
& style )
17
{
18
this->
color
( style.
on_surface
);
19
20
if
( this->monospace )
21
this->
font
( style.
font_monospace
);
22
else
23
this->
font
( style.
font_normal
);
24
}
25
26
}