CComponents: add sub class CComponentsText

Origin commit data
------------------
Branch: ni/coolstream
Commit: d8447b9110
Author: Thilo Graf <dbt@novatux.de>
Date: 2012-09-24 (Mon, 24 Sep 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
2012-09-24 20:21:11 +02:00
parent dd48917b6d
commit 20b0197244
2 changed files with 113 additions and 0 deletions

View File

@@ -410,4 +410,30 @@ class CComponentsForm : public CComponentsContainer
void setIcon(const std::string& icon_name){tb_icon = icon_name;};
};
class CComponentsText : public CComponentsContainer
{
private:
Font* ct_font;
CBox * ct_box;
CTextBox * ct_textbox;
const char* ct_text;
int ct_text_mode; //see textbox.h for possible modes
fb_pixel_t ct_col_text;
bool ct_text_sended;
void initVarText();
void initText();
public:
CComponentsText();
~CComponentsText();
inline void setText(const char* text, const int text_mode=CTextBox::AUTO_WIDTH, Font* font_text=NULL){ct_text = text; ct_text_mode = text_mode, ct_font = font_text;};
void hide(bool no_restore = false);
void paint(bool do_save_bg = CC_SAVE_SCREEN_YES);
void setTextFont(Font* font_text){ct_font = font_text;};
};
#endif