CComponentsExtTextForm: add missed parameter font_text

Origin commit data
------------------
Commit: 80753c75d1
Author: Thilo Graf <dbt@novatux.de>
Date: 2016-10-03 (Mon, 03 Oct 2016)
This commit is contained in:
2016-10-03 00:44:27 +02:00
parent fc29cf8824
commit 93ca892022
3 changed files with 10 additions and 3 deletions

View File

@@ -174,7 +174,7 @@ void CBuildInfo::InitInfoItems()
//init info texts
for(size_t i=0; i<v_info.size(); i++){
CComponentsExtTextForm *info = new CComponentsExtTextForm(10, CC_APPEND, w_info, h_info, g_Locale->getText(v_info[i].caption), v_info[i].info_text, ccw_body);
CComponentsExtTextForm *info = new CComponentsExtTextForm(10, CC_APPEND, w_info, h_info, g_Locale->getText(v_info[i].caption), v_info[i].info_text, NULL, ccw_body);
info->setLabelAndTextFont(font);
info->setTextModes(CTextBox::TOP , CTextBox::AUTO_HIGH | CTextBox::TOP | CTextBox::AUTO_LINEBREAK_NO_BREAKCHARS);
info->doPaintBg(false);

View File

@@ -36,18 +36,20 @@ using namespace std;
CComponentsExtTextForm::CComponentsExtTextForm( const int& x_pos, const int& y_pos, const int& w, const int& h,
const std::string& label_text, const std::string& text,
Font* font_text,
CComponentsForm* parent,
int shadow_mode,
fb_pixel_t label_color,
fb_pixel_t text_color,
fb_pixel_t color_frame, fb_pixel_t color_body, fb_pixel_t color_shadow)
{
initVarExtTextForm(x_pos, y_pos, w, h, label_text, text, parent, shadow_mode, label_color, text_color, color_frame, color_body, color_shadow);
initVarExtTextForm(x_pos, y_pos, w, h, label_text, text, font_text, parent, shadow_mode, label_color, text_color, color_frame, color_body, color_shadow);
initCCTextItems();
}
CComponentsExtTextFormLocalized::CComponentsExtTextFormLocalized(const int& x_pos, const int& y_pos, const int& w, const int& h,
const neutrino_locale_t& locale_label_text, const neutrino_locale_t& locale_text,
Font* font_text,
CComponentsForm* parent,
int shadow_mode,
fb_pixel_t label_color,
@@ -55,12 +57,14 @@ CComponentsExtTextFormLocalized::CComponentsExtTextFormLocalized(const int& x_po
fb_pixel_t color_frame, fb_pixel_t color_body, fb_pixel_t color_shadow)
: CComponentsExtTextForm( x_pos, y_pos, w, h,
g_Locale->getText(locale_label_text), g_Locale->getText(locale_text),
font_text,
parent,
shadow_mode,
label_color, text_color, color_frame, color_body, color_shadow){};
void CComponentsExtTextForm::initVarExtTextForm(const int& x_pos, const int& y_pos, const int& w, const int& h,
const std::string& label_text, const std::string& text,
Font* font_text,
CComponentsForm* parent,
int shadow_mode,
fb_pixel_t label_color,
@@ -92,7 +96,7 @@ void CComponentsExtTextForm::initVarExtTextForm(const int& x_pos, const int& y_p
ccx_text_obj = NULL;
corner_type = 0;
int dx = 0, dy = DEF_HEIGHT;
ccx_font = *(CNeutrinoFonts::getInstance()->getDynFont(dx, dy));
ccx_font = font_text == NULL ? *(CNeutrinoFonts::getInstance()->getDynFont(dx, dy)) : g_Font[SNeutrinoSettings::FONT_TYPE_MENU_INFO];
ccx_label_align = ccx_text_align = CTextBox::NO_AUTO_LINEBREAK;
initParent(parent);

View File

@@ -68,6 +68,7 @@ class CComponentsExtTextForm : public CComponentsForm, public CCTextScreen
///initialize basic variables
void initVarExtTextForm(const int& x_pos, const int& y_pos, const int& w, const int& h,
const std::string& label_text, const std::string& text,
Font* font_text,
CComponentsForm* parent,
int shadow_mode,
fb_pixel_t label_color,
@@ -78,6 +79,7 @@ class CComponentsExtTextForm : public CComponentsForm, public CCTextScreen
///advanced constructor for CComponentsExtTextForm, provides parameters for the most required properties, and caption as string
CComponentsExtTextForm( const int& x_pos = 1, const int& y_pos = 1, const int& w = 300, const int& h = 48,
const std::string& label_text = "", const std::string& text = "",
Font* font_text = NULL,
CComponentsForm *parent = NULL,
int shadow_mode = CC_SHADOW_OFF,
fb_pixel_t label_color = COL_MENUCONTENTINACTIVE_TEXT,
@@ -141,6 +143,7 @@ class CComponentsExtTextFormLocalized : public CComponentsExtTextForm
///advanced constructor for CComponentsExtTextForm, provides parameters for the most required properties, and caption as locales
CComponentsExtTextFormLocalized(const int& x_pos = 1, const int& y_pos = 1, const int& w = 300, const int& h = 48,
const neutrino_locale_t& locale_label_text = NONEXISTANT_LOCALE, const neutrino_locale_t& locale_text = NONEXISTANT_LOCALE,
Font* font_text = NULL,
CComponentsForm *parent = NULL,
int shadow_mode = CC_SHADOW_OFF,
fb_pixel_t label_color = COL_MENUCONTENTINACTIVE_TEXT,