mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-27 23:42:51 +02:00
CHintBox/CMsgBox: rework text handling and dynamic size behavior
Origin commit data
------------------
Commit: e3f51f2c91
Author: Thilo Graf <dbt@novatux.de>
Date: 2016-11-03 (Thu, 03 Nov 2016)
This commit is contained in:
@@ -128,16 +128,14 @@ CHintBox::CHintBox( const char * const Caption,
|
||||
|
||||
void CHintBox::init(const std::string& Text, const int& Width, const std::string& Picon, const int& header_buttons, const int& text_mode, const int& indent)
|
||||
{
|
||||
lines = 0;
|
||||
timeout = HINTBOX_DEFAULT_TIMEOUT;
|
||||
w_indentation = indent;
|
||||
hb_text_mode = text_mode;
|
||||
|
||||
hb_font = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_INFO];
|
||||
|
||||
//set required window width and basic height
|
||||
width = max(HINTBOX_MIN_WIDTH, max(Width, min(hb_font->getRenderWidth(Text), (int)frameBuffer->getScreenWidth())));
|
||||
height = max(HINTBOX_MIN_HEIGHT, height);
|
||||
width = getMaxWidth(Text, hb_font, Width);
|
||||
height = max(HINTBOX_MIN_HEIGHT, min(HINTBOX_MAX_HEIGHT, height));
|
||||
|
||||
ccw_buttons = header_buttons;
|
||||
|
||||
@@ -151,19 +149,14 @@ void CHintBox::init(const std::string& Text, const int& Width, const std::string
|
||||
//disable footer for default
|
||||
showFooter(false);
|
||||
|
||||
//add the content container, contains the hint objects
|
||||
obj_content = new CComponentsFrmChain(CC_CENTERED, CC_CENTERED, ccw_body->getWidth(), ccw_body->getHeight(), NULL, CC_DIR_X, ccw_body);
|
||||
obj_content->doPaintBg(false);
|
||||
|
||||
y_hint_obj = 0;
|
||||
h_hint_obj = obj_content->getHeight();
|
||||
y_hint_obj = CC_CENTERED;
|
||||
|
||||
//initialize timeout bar and its timer
|
||||
timeout_pb = NULL;
|
||||
timeout_pb_timer= NULL;
|
||||
|
||||
if (!Text.empty())
|
||||
addHintItem(Text, hb_text_mode, Picon);
|
||||
addHintItem(Text, text_mode, Picon, COL_MENUCONTENT_TEXT, hb_font);
|
||||
}
|
||||
|
||||
CHintBox::~CHintBox()
|
||||
@@ -253,135 +246,73 @@ int CHintBox::exec()
|
||||
return res;
|
||||
}
|
||||
|
||||
void CHintBox::addHintItem(const std::string& Text, const int& text_mode, const std::string& Picon, const u_int8_t& at_page_number, const fb_pixel_t& color_text, Font* font_text)
|
||||
void CHintBox::addHintItem(const std::string& Text, const int& text_mode, const std::string& Picon, const fb_pixel_t& color_text, Font* font_text)
|
||||
{
|
||||
dprintf(DEBUG_INFO, "[CHintBox] [%s - %d] add new hint '%s' %s\n", __func__, __LINE__, Text.c_str(), Picon.c_str());
|
||||
/* set required font and line height */
|
||||
Font* item_font = !font_text ? hb_font : font_text;
|
||||
|
||||
//set required font and line size
|
||||
hb_font = !font_text ? hb_font : font_text;
|
||||
width = getMaxWidth(Text, width);
|
||||
int h_line = hb_font->getHeight();
|
||||
/* pre define required info height depends of lines and minimal needed height*/
|
||||
int line_breaks = CTextBox::getLines(Text);
|
||||
int h_font = item_font->getHeight();
|
||||
int h_lines = h_font * line_breaks;
|
||||
|
||||
//init side picon object
|
||||
CComponentsPicture *obj_picon = new CComponentsPicture(0, timeout > 0 ? TIMEOUT_BAR_HEIGHT : 0, Picon);
|
||||
obj_picon->doPaintBg(false);
|
||||
obj_picon->SetTransparent(CFrameBuffer::TM_BLACK);
|
||||
int w_picon = obj_picon->getWidth();
|
||||
/* get required height depends of possible lines and max height */
|
||||
h_hint_obj = min(HINTBOX_MAX_HEIGHT - (ccw_head ? ccw_head->getHeight() : 0), h_lines + 2*w_indentation);
|
||||
|
||||
//init text item object
|
||||
int x_text_obj = (w_picon > 0) ? (w_picon + w_indentation) : 0;
|
||||
int w_text_obj = obj_content->getWidth() - w_picon - w_indentation;
|
||||
int h_text_obj = max(h_line, obj_picon->getHeight());
|
||||
CComponentsText *obj_text = new CComponentsText(x_text_obj,
|
||||
timeout > 0 ? TIMEOUT_BAR_HEIGHT : 0,
|
||||
w_text_obj,
|
||||
h_text_obj,
|
||||
Text,
|
||||
text_mode,
|
||||
hb_font);
|
||||
|
||||
//provide the internal textbox object
|
||||
CTextBox *textbox = obj_text->getCTextBoxObject();
|
||||
int lines_count = textbox->getLines();
|
||||
|
||||
//get required height of text object related to height of current text object, header and footer
|
||||
int fh_h = (ccw_head ? ccw_head->getHeight() : 0) + (ccw_footer ? ccw_footer->getHeight() : 0) + obj_text->getHeight();
|
||||
int h_required = min( max(height,fh_h), (int)frameBuffer->getScreenHeight()) ;//lines_count * h_line + (ccw_head ? ccw_head->getHeight() : 0) + (ccw_footer ? ccw_footer->getHeight() : 0);
|
||||
|
||||
//set minimal required height
|
||||
height = max(height, min(HINTBOX_MAX_HEIGHT, max(HINTBOX_MIN_HEIGHT, h_required)));
|
||||
|
||||
//if have no pre defined text mode:
|
||||
//more than 1 line or a picon is defined, then do not center text and allow scroll if > 1 lines
|
||||
if (text_mode == 0){
|
||||
if (lines_count == 1)
|
||||
obj_text->setTextMode(CTextBox::AUTO_WIDTH | CTextBox::AUTO_HIGH | CTextBox::CENTER);
|
||||
if (w_picon > 1)
|
||||
obj_text->setTextMode(CTextBox::AUTO_WIDTH | CTextBox::AUTO_HIGH);
|
||||
if (lines_count > 1)
|
||||
obj_text->setTextMode(CTextBox::AUTO_WIDTH | CTextBox::AUTO_HIGH | (h_required > HINTBOX_MAX_HEIGHT ? CTextBox::SCROLL : CTextBox::AUTO_HIGH));
|
||||
if (lines_count > 1 && w_picon == 0)
|
||||
obj_text->setTextMode(CTextBox::AUTO_WIDTH | CTextBox::AUTO_HIGH | CTextBox::CENTER | (h_required > HINTBOX_MAX_HEIGHT ? CTextBox::SCROLL : CTextBox::AUTO_HIGH));
|
||||
}
|
||||
else
|
||||
obj_text->setTextMode(text_mode);
|
||||
|
||||
//text item object: don't paint background
|
||||
obj_text->doPaintBg(false);
|
||||
obj_text->setCorner(corner_rad, corner_type);
|
||||
|
||||
//set text color
|
||||
obj_text->setTextColor(color_text);
|
||||
|
||||
//calculate height of hint object
|
||||
if (obj_content->size() == 0){
|
||||
if (lines_count == 1){
|
||||
h_hint_obj = max(h_hint_obj, h_text_obj);
|
||||
obj_text->setYPos(CC_CENTERED);
|
||||
}
|
||||
else
|
||||
h_hint_obj = max(h_hint_obj, h_line*lines_count);
|
||||
}
|
||||
else{
|
||||
if (lines_count == 1){
|
||||
h_hint_obj = h_text_obj;
|
||||
obj_text->setYPos(CC_CENTERED);
|
||||
}
|
||||
else
|
||||
h_hint_obj = h_line*lines_count;
|
||||
/* add scroll mode if needed */
|
||||
int txt_mode = text_mode;
|
||||
if (h_lines > h_hint_obj){
|
||||
txt_mode = text_mode | CTextBox::SCROLL;
|
||||
ccw_buttons = ccw_buttons | CComponentsHeader::CC_BTN_TOP | CComponentsHeader::CC_BTN_DOWN;
|
||||
}
|
||||
|
||||
//init hint container object
|
||||
if (isPageChanged())
|
||||
y_hint_obj = 0;
|
||||
CComponentsFrmChain *obj_hint = new CComponentsFrmChain( 0+w_indentation,
|
||||
/* define y start position of infobox inside body */
|
||||
if(!ccw_body->empty()){
|
||||
ccw_body->front()->setYPos(w_indentation);
|
||||
y_hint_obj += ccw_body->back()->getYPos()+ ccw_body->back()->getHeight();
|
||||
}
|
||||
|
||||
/* calcoulation of maximal hintbox height include possible header*/
|
||||
height = min(HINTBOX_MAX_HEIGHT, (ccw_head ? ccw_head->getHeight() : 0)+ h_hint_obj);
|
||||
height = max(height, HINTBOX_MIN_HEIGHT);
|
||||
|
||||
/* get current maximal width and refresh window items TODO: required maximal width*/
|
||||
width = getMaxWidth(Text, item_font, width);
|
||||
|
||||
/* initialize infobox as container for text and possible picon*/
|
||||
CComponentsInfoBox *info_box = new CComponentsInfoBox( 0,
|
||||
y_hint_obj,
|
||||
obj_content->getWidth()-2*w_indentation,
|
||||
width, // FIXME: not critical here but ccw_body->getWidth() != width, this should be the same value!
|
||||
h_hint_obj,
|
||||
NULL,
|
||||
CC_DIR_X,
|
||||
obj_content);
|
||||
Text,
|
||||
txt_mode,
|
||||
item_font,
|
||||
ccw_body,
|
||||
CC_SHADOW_OFF,
|
||||
color_text);
|
||||
|
||||
//don't paint background for hint container
|
||||
obj_hint->doPaintBg(false);
|
||||
obj_hint->setCorner(corner_rad, corner_type);
|
||||
obj_hint->setPageNumber(at_page_number);
|
||||
/* define picon and disable bg */
|
||||
info_box->setPicture(Picon);
|
||||
info_box->doPaintBg(false);
|
||||
|
||||
//add the created items to obj_hint
|
||||
obj_hint->addCCItem(obj_picon);
|
||||
obj_hint->addCCItem(obj_text);
|
||||
|
||||
//text object obtains the full height of its parent object
|
||||
obj_text->setHeightP(100);
|
||||
|
||||
//if we have only one line and a defined picon, then do centering picon to text on the left site
|
||||
if (lines_count == 1)
|
||||
obj_picon->setYPos(CC_CENTERED);
|
||||
|
||||
//set next y pos for the next hint object
|
||||
y_hint_obj += h_hint_obj;
|
||||
|
||||
|
||||
//recalculate new hintbox height
|
||||
/* recalculate new hintbox height */
|
||||
ReSize();
|
||||
|
||||
//set hint box position general to center and refresh window
|
||||
/* set hint box position general to center and refresh window */
|
||||
setCenterPos();
|
||||
Refresh();
|
||||
|
||||
lines += lines_count;
|
||||
Refresh();
|
||||
}
|
||||
|
||||
void CHintBox::setMsgText(const std::string& Text, const uint& hint_id, const int& mode, Font* font_text, const fb_pixel_t& color_text, const int& style)
|
||||
{
|
||||
uint id = hint_id;
|
||||
if (hint_id+1 > obj_content->size()){
|
||||
if (hint_id+1 > ccw_body->size()){
|
||||
id = 0;
|
||||
dprintf(DEBUG_NORMAL, "[CHintBox] [%s - %d] mismatching hint_id [%u]...\n", __func__, __LINE__, id);
|
||||
}
|
||||
|
||||
CComponentsFrmChain *obj_hint = static_cast<CComponentsFrmChain*>(obj_content->getCCItem(id));
|
||||
CComponentsText *obj_text = static_cast<CComponentsText*>(obj_hint->getCCItem(1));
|
||||
CComponentsInfoBox *obj_text = static_cast<CComponentsInfoBox*>(ccw_body->getCCItem(id));
|
||||
|
||||
//set required font and line size
|
||||
Font* font = font_text == NULL ? g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_INFO] : font_text;
|
||||
@@ -391,33 +322,29 @@ void CHintBox::setMsgText(const std::string& Text, const uint& hint_id, const in
|
||||
|
||||
void CHintBox::ReSize()
|
||||
{
|
||||
int h_content_old = obj_content->getHeight();
|
||||
int h_content_new = 0;
|
||||
for (size_t i= 0; i< obj_content->size(); i++){
|
||||
CComponentsItem *item = obj_content->getCCItem(i);
|
||||
h_content_new += item->getHeight();
|
||||
int h = (ccw_head ? ccw_head->getHeight() : 0);
|
||||
for (size_t i= 0; i< ccw_body->size(); i++){
|
||||
CComponentsItem *item = ccw_body->getCCItem(i);
|
||||
h += item->getHeight();
|
||||
}
|
||||
int h_content_diff = h_content_new - h_content_old;
|
||||
|
||||
obj_content->setHeight(h_content_new);
|
||||
setHeight(height+h_content_diff);
|
||||
height = min(HINTBOX_MAX_HEIGHT, max(HINTBOX_MIN_HEIGHT, max(height,h)));
|
||||
Refresh();
|
||||
}
|
||||
|
||||
|
||||
void CHintBox::Scroll(bool down, const uint& hint_id)
|
||||
{
|
||||
uint id = hint_id;
|
||||
if (hint_id+1 > obj_content->size()){
|
||||
if (hint_id+1 > ccw_body->size()){
|
||||
id = 0;
|
||||
dprintf(DEBUG_NORMAL, "[CHintBox] [%s - %d] mismatching hint_id [%u]...\n", __func__, __LINE__, id);
|
||||
}
|
||||
|
||||
CComponentsFrmChain *obj_hint = static_cast<CComponentsFrmChain*>(obj_content->getCCItem(id));
|
||||
CComponentsText *obj_text = static_cast<CComponentsText*>(obj_hint->getCCItem(1));
|
||||
CComponentsInfoBox *obj_text = static_cast<CComponentsInfoBox*>(ccw_body->getCCItem(id));
|
||||
|
||||
if (obj_text) {
|
||||
dprintf(DEBUG_INFO, "[CHintBox] [%s - %d] try to scroll %s hint_id [%u]...Text= %s\n", __func__, __LINE__, down ? "down" : "up", id, obj_text->getText().c_str());
|
||||
CTextBox* textbox = obj_text->getCTextBoxObject();
|
||||
dprintf(DEBUG_DEBUG, "[CHintBox] [%s - %d] try to scroll %s hint_id [%u]...Text= %s\n", __func__, __LINE__, down ? "down" : "up", id, obj_text->getText().c_str());
|
||||
CTextBox* textbox = obj_text->cctext->getCTextBoxObject();
|
||||
if (textbox) {
|
||||
textbox->enableBackgroundPaint(true);
|
||||
if (down)
|
||||
@@ -439,9 +366,9 @@ void CHintBox::scroll_down(const uint& hint_id)
|
||||
Scroll(true, hint_id);
|
||||
}
|
||||
|
||||
int CHintBox::getMaxWidth(const string& Text, const int& minWidth)
|
||||
int CHintBox::getMaxWidth(const string& Text, Font *font, const int& minWidth)
|
||||
{
|
||||
return max(HINTBOX_MIN_WIDTH, max(minWidth, min(hb_font->getRenderWidth(Text), (int)frameBuffer->getScreenWidth())));
|
||||
return max(HINTBOX_MIN_WIDTH, max(minWidth+w_indentation, min(font->getRenderWidth(Text)+w_indentation, (int)frameBuffer->getScreenWidth())));
|
||||
}
|
||||
|
||||
int ShowHint(const char * const Caption, const char * const Text, const int Width, int timeout, const char * const Icon, const char * const Picon, const int& header_buttons)
|
||||
|
@@ -32,7 +32,7 @@
|
||||
|
||||
#include <gui/components/cc.h>
|
||||
|
||||
#define HINTBOX_MIN_WIDTH 400
|
||||
#define HINTBOX_MIN_WIDTH 420
|
||||
#define HINTBOX_MIN_HEIGHT 125
|
||||
#define HINTBOX_MAX_HEIGHT 420
|
||||
#define HINTBOX_DEFAULT_TIMEOUT 5
|
||||
@@ -42,6 +42,8 @@
|
||||
#define HINTBOX_DEFAULT_FRAME_COLOR COL_FRAME
|
||||
#define TIMEOUT_BAR_HEIGHT OFFSET_SHADOW/2
|
||||
|
||||
#define DEFAULT_HINTBOX_TEXT_MODE (CTextBox::NO_AUTO_LINEBREAK)
|
||||
|
||||
//! Sub class of CComponentsWindow. Shows a window as a hintbox with text and optional icon beside of text.
|
||||
/*!
|
||||
CHintBox provides a small window with header and a text item,
|
||||
@@ -55,19 +57,12 @@ class CHintBox : public CComponentsWindow
|
||||
int y_hint_obj;
|
||||
int h_hint_obj;
|
||||
int w_indentation;
|
||||
int hb_text_mode;
|
||||
|
||||
Font* hb_font;
|
||||
|
||||
///global count of lines
|
||||
uint lines;
|
||||
|
||||
///timeout value, see also setTimeOut()
|
||||
int timeout;
|
||||
|
||||
///content container object, contains the hint objects, it's a child of body object
|
||||
CComponentsFrmChain *obj_content;
|
||||
|
||||
///timeout bar
|
||||
CProgressBar *timeout_pb;
|
||||
CComponentsTimer *timeout_pb_timer;
|
||||
@@ -85,7 +80,7 @@ class CHintBox : public CComponentsWindow
|
||||
|
||||
virtual void ReSize();
|
||||
void showTimeOutBar(){enableTimeOutBar();}
|
||||
int getMaxWidth(const std::string& Text, const int& minWidth);
|
||||
int getMaxWidth(const std::string& Text, Font *font, const int& minWidth);
|
||||
|
||||
public:
|
||||
/**CHintBox Constructor
|
||||
@@ -125,7 +120,7 @@ class CHintBox : public CComponentsWindow
|
||||
const char * const Icon = NULL,
|
||||
const char * const Picon = NULL,
|
||||
const int& header_buttons = 0,
|
||||
const int& text_mode = 0,
|
||||
const int& text_mode = DEFAULT_HINTBOX_TEXT_MODE,
|
||||
const int& indent = W_FRAME);
|
||||
|
||||
/**CHintBox Constructor
|
||||
@@ -139,7 +134,7 @@ class CHintBox : public CComponentsWindow
|
||||
const char * const Icon = NULL,
|
||||
const char * const Picon = NULL,
|
||||
const int& header_buttons = 0,
|
||||
const int& text_mode = 0,
|
||||
const int& text_mode = DEFAULT_HINTBOX_TEXT_MODE,
|
||||
const int& indent = W_FRAME);
|
||||
|
||||
/**CHintBox Constructor
|
||||
@@ -155,7 +150,7 @@ class CHintBox : public CComponentsWindow
|
||||
const char * const Icon = NULL,
|
||||
const char * const Picon = NULL,
|
||||
const int& header_buttons = 0,
|
||||
const int& text_mode = 0,
|
||||
const int& text_mode = DEFAULT_HINTBOX_TEXT_MODE,
|
||||
const int& indent = W_FRAME);
|
||||
|
||||
/**CHintBox Constructor
|
||||
@@ -171,7 +166,7 @@ class CHintBox : public CComponentsWindow
|
||||
const char * const Icon = NULL,
|
||||
const char * const Picon = NULL,
|
||||
const int& header_buttons = 0,
|
||||
const int& text_mode = 0,
|
||||
const int& text_mode = DEFAULT_HINTBOX_TEXT_MODE,
|
||||
const int& indent = W_FRAME);
|
||||
|
||||
virtual ~CHintBox();
|
||||
@@ -236,17 +231,14 @@ class CHintBox : public CComponentsWindow
|
||||
* AUTO_LINEBREAK_NO_BREAKCHARS
|
||||
* @param[in] Picon
|
||||
* @li optional: exepts type std::string, defines the picon name on the left side of message text, default = NULL (non Icon)
|
||||
* @param[in] at_page_number
|
||||
* @li optional: exepts type int, defines the page number on that this hint will be, default = 0 (first page)
|
||||
* @param[in] color_text
|
||||
* @li optional: exepts type fb_pixel_t, defines the text color, default = COL_MENUCONTENT_TEXT
|
||||
* * @param[in] font_text
|
||||
* @li optional: exepts type Font*, defines the text font type, default = NULL for system preset for message contents
|
||||
*/
|
||||
void addHintItem( const std::string& Text,
|
||||
const int& text_mode = 0,
|
||||
const int& text_mode = DEFAULT_HINTBOX_TEXT_MODE,
|
||||
const std::string& Picon = std::string(),
|
||||
const u_int8_t& at_page_number = 0,
|
||||
const fb_pixel_t& color_text = COL_MENUCONTENT_TEXT,
|
||||
Font* font_text = NULL);
|
||||
|
||||
@@ -257,7 +249,7 @@ class CHintBox : public CComponentsWindow
|
||||
*
|
||||
* @see /gui/components/cc_types.h
|
||||
*/
|
||||
void addHintItem(CComponentsItem* cc_Item){obj_content->addCCItem(cc_Item);}
|
||||
void addHintItem(CComponentsItem* cc_Item){ccw_body->addCCItem(cc_Item);}
|
||||
|
||||
/**
|
||||
* Sets a text to a hint item.
|
||||
|
@@ -38,7 +38,7 @@
|
||||
#define MSGBOX_MIN_WIDTH HINTBOX_MIN_WIDTH
|
||||
#define MSGBOX_MIN_HEIGHT HINTBOX_MIN_HEIGHT + 75
|
||||
|
||||
#define DEFAULT_TEXT_MODE (CMsgBox::CENTER | CMsgBox::AUTO_WIDTH | CMsgBox::AUTO_HIGH | CMsgBox::SCROLL)
|
||||
#define DEFAULT_MSGBOX_TEXT_MODE (CMsgBox::CENTER | CMsgBox::AUTO_WIDTH | CMsgBox::AUTO_HIGH)
|
||||
|
||||
//! Sub class of CHintBox. Shows a window as a messagebox
|
||||
/*!
|
||||
@@ -159,7 +159,7 @@ class CMsgBox : public CHintBox
|
||||
* BOTTOM
|
||||
* NO_AUTO_LINEBREAK
|
||||
* AUTO_LINEBREAK_NO_BREAKCHARS
|
||||
* NOTE: default parameter to find in macro DEFAULT_TEXT_MODE
|
||||
* NOTE: default parameter to find in macro DEFAULT_MSGBOX_TEXT_MODE
|
||||
*
|
||||
* @see class CHintBox()
|
||||
*/
|
||||
@@ -171,7 +171,7 @@ class CMsgBox : public CHintBox
|
||||
const int& Height = MSGBOX_MIN_HEIGHT,
|
||||
const int& ShowButtons = mbCancel,
|
||||
const msg_result_t& Default_result = mbrCancel,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE);
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE);
|
||||
|
||||
/**CMsgBox Constructor
|
||||
* @param[in] Text
|
||||
@@ -213,7 +213,7 @@ class CMsgBox : public CHintBox
|
||||
* BOTTOM
|
||||
* NO_AUTO_LINEBREAK
|
||||
* AUTO_LINEBREAK_NO_BREAKCHARS
|
||||
* NOTE: default parameter to find in macro DEFAULT_TEXT_MODE
|
||||
* NOTE: default parameter to find in macro DEFAULT_MSGBOX_TEXT_MODE
|
||||
*
|
||||
* @see class CHintBox()
|
||||
*/
|
||||
@@ -225,7 +225,7 @@ class CMsgBox : public CHintBox
|
||||
const int& Height = MSGBOX_MIN_HEIGHT,
|
||||
const int& ShowButtons = mbCancel,
|
||||
const msg_result_t& Default_result = mbrCancel,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE);
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE);
|
||||
|
||||
// ~CMsgBox(); //inherited
|
||||
/**
|
||||
@@ -323,7 +323,7 @@ int ShowMsg2UTF( const neutrino_locale_t Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg2UTF( const char * const Title,
|
||||
@@ -334,7 +334,7 @@ int ShowMsg2UTF( const char * const Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg( const neutrino_locale_t Title,
|
||||
@@ -345,7 +345,7 @@ int ShowMsg( const neutrino_locale_t Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg( const char * const Title,
|
||||
@@ -356,7 +356,7 @@ int ShowMsg( const char * const Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg( const neutrino_locale_t Title,
|
||||
@@ -367,7 +367,7 @@ int ShowMsg( const neutrino_locale_t Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg( const neutrino_locale_t Title,
|
||||
@@ -378,7 +378,7 @@ int ShowMsg( const neutrino_locale_t Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
int ShowMsg( const std::string & Title,
|
||||
@@ -389,13 +389,13 @@ int ShowMsg( const std::string & Title,
|
||||
const int Width = MSGBOX_MIN_WIDTH,
|
||||
const int Timeout = -1,
|
||||
bool returnDefaultOnTimeout = false,
|
||||
const int& Text_mode = DEFAULT_TEXT_MODE,
|
||||
const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE,
|
||||
fb_pixel_t color_frame = HINTBOX_DEFAULT_FRAME_COLOR); // UTF-8
|
||||
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const int& Text_mode = DEFAULT_TEXT_MODE); // UTF-8
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const neutrino_locale_t& caption, const int& Text_mode = DEFAULT_TEXT_MODE); // UTF-8
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const std::string& caption, const int& Text_mode = DEFAULT_TEXT_MODE); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const int& Text_mode = DEFAULT_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const neutrino_locale_t& caption, const int& Text_mode = DEFAULT_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const std::string& caption, const int& Text_mode = DEFAULT_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE); // UTF-8
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const neutrino_locale_t& caption, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE); // UTF-8
|
||||
void DisplayErrorMessage(const char * const ErrorMsg, const std::string& caption, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const neutrino_locale_t& caption, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
void DisplayInfoMessage(const char * const InfoMsg, const std::string& caption, const int& Text_mode = DEFAULT_MSGBOX_TEXT_MODE, fb_pixel_t color_frame = COL_DARK_GRAY); // UTF-8
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user