mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-27 23:42:58 +02:00
CComponentsText: expand setTextColor() methode
apply color value direct in text box object
This commit is contained in:
@@ -187,7 +187,7 @@ void CComponentsText::setText(const std::string& stext, const int mode, Font* fo
|
||||
ct_text_mode = mode;
|
||||
ct_font = font_text;
|
||||
if (color_text != 0)
|
||||
ct_col_text = color_text;
|
||||
setTextColor(color_text);
|
||||
|
||||
dprintf(DEBUG_DEBUG, "[CComponentsText] [%s - %d] ct_text: %s \n", __func__, __LINE__, ct_text.c_str());
|
||||
}
|
||||
@@ -298,3 +298,10 @@ int CComponentsText::getTextLinesAutoHeight(const int& textMaxHeight, const int&
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
void CComponentsText::setTextColor(const fb_pixel_t& color_text)
|
||||
{
|
||||
ct_col_text = color_text;
|
||||
if (ct_textbox)
|
||||
ct_textbox->setTextColor(ct_col_text);
|
||||
}
|
||||
|
Reference in New Issue
Block a user