Messages: add option to change size of message text

Include default size and localized setup.

TODO: localize for nederlands and slovak, current english only.


Origin commit data
------------------
Commit: 4988df1dd9
Author: Thilo Graf <dbt@novatux.de>
Date: 2016-11-20 (Sun, 20 Nov 2016)
This commit is contained in:
2016-11-20 01:08:14 +01:00
parent 5d258a58dd
commit ae117fae66
9 changed files with 32 additions and 4 deletions

View File

@@ -703,6 +703,7 @@ fontmenu.eventlist Event-Liste
fontmenu.head Schrift fontmenu.head Schrift
fontmenu.infobar Infobar fontmenu.infobar Infobar
fontmenu.menu Menü fontmenu.menu Menü
fontmenu.messages Meldungen
fontmenu.moviebrowser Moviebrowser fontmenu.moviebrowser Moviebrowser
fontmenu.other Andere fontmenu.other Andere
fontmenu.scaling Schriftgrößenfaktor fontmenu.scaling Schriftgrößenfaktor
@@ -736,6 +737,7 @@ fontsize.menu_foot Fußleiste (in allen Fenstern)
fontsize.menu_hint Menü-Hilfe fontsize.menu_hint Menü-Hilfe
fontsize.menu_info Menüinfo fontsize.menu_info Menüinfo
fontsize.menu_title Menütitel fontsize.menu_title Menütitel
fontsize.message_text Meldungstext
fontsize.moviebrowser_head Überschriften fontsize.moviebrowser_head Überschriften
fontsize.moviebrowser_info Info-Fenster fontsize.moviebrowser_info Info-Fenster
fontsize.moviebrowser_list Listen-Einträge fontsize.moviebrowser_list Listen-Einträge
@@ -1183,6 +1185,7 @@ menu.hint_menu_fonts Ändern Sie die Schriftgrößen im Menü
menu.hint_menu_hints Zeigt Ihnen Hinweise zu den Menüpunkten an. Sie erreichen das auch jederzeit mit der Taste 'Hilfe' menu.hint_menu_hints Zeigt Ihnen Hinweise zu den Menüpunkten an. Sie erreichen das auch jederzeit mit der Taste 'Hilfe'
menu.hint_menu_pos Legen Sie die Anzeigeposition der Menüs fest menu.hint_menu_pos Legen Sie die Anzeigeposition der Menüs fest
menu.hint_menus Wählen Sie die Anzeigeoptionen für die Menüs menu.hint_menus Wählen Sie die Anzeigeoptionen für die Menüs
menu.hint_message_fonts Anpassen der Schrift in Meldungsfenstern
menu.hint_misc_cec HDMI-CEC Optionen menu.hint_misc_cec HDMI-CEC Optionen
menu.hint_misc_channellist Erweiterte Einstellungen für die Kanallisten und Zapping-Einstellungen menu.hint_misc_channellist Erweiterte Einstellungen für die Kanallisten und Zapping-Einstellungen
menu.hint_misc_energy Energieverbrauchs- und Standby-Optionen, verzögertes Ausschalten, setzen bzw. ändern des Inaktivitätstimers menu.hint_misc_energy Energieverbrauchs- und Standby-Optionen, verzögertes Ausschalten, setzen bzw. ändern des Inaktivitätstimers

View File

@@ -703,6 +703,7 @@ fontmenu.eventlist Eventlist
fontmenu.head Font settings fontmenu.head Font settings
fontmenu.infobar Infobar fontmenu.infobar Infobar
fontmenu.menu Menu fontmenu.menu Menu
fontmenu.messages Messages
fontmenu.moviebrowser Moviebrowser fontmenu.moviebrowser Moviebrowser
fontmenu.other Other fontmenu.other Other
fontmenu.scaling Global Font Zoom Factor fontmenu.scaling Global Font Zoom Factor
@@ -736,6 +737,7 @@ fontsize.menu_foot Footer (in all GUI elements)
fontsize.menu_hint Menu hints fontsize.menu_hint Menu hints
fontsize.menu_info Menu Info fontsize.menu_info Menu Info
fontsize.menu_title Menu Title fontsize.menu_title Menu Title
fontsize.message_text Message Text
fontsize.moviebrowser_head Headers fontsize.moviebrowser_head Headers
fontsize.moviebrowser_info Info window fontsize.moviebrowser_info Info window
fontsize.moviebrowser_list List items fontsize.moviebrowser_list List items
@@ -1183,6 +1185,7 @@ menu.hint_menu_fonts Change menu font sizes
menu.hint_menu_hints Show this hints. Also you can switch\nit any time using 'help' button menu.hint_menu_hints Show this hints. Also you can switch\nit any time using 'help' button
menu.hint_menu_pos Select menu position menu.hint_menu_pos Select menu position
menu.hint_menus Configure menu options menu.hint_menus Configure menu options
menu.hint_message_fonts Change message text font sizes
menu.hint_misc_cec HDMI-CEC Options menu.hint_misc_cec HDMI-CEC Options
menu.hint_misc_channellist HD/New/Removed channel lists\nZap cycle menu.hint_misc_channellist HD/New/Removed channel lists\nZap cycle
menu.hint_misc_energy Enable soft-standby, delayed shutdown\ninactivity timers menu.hint_misc_energy Enable soft-standby, delayed shutdown\ninactivity timers

View File

@@ -657,6 +657,7 @@ fontmenu.eventlist Programmalijst
fontmenu.head Lettertype instellingen fontmenu.head Lettertype instellingen
fontmenu.infobar Informatiebalk fontmenu.infobar Informatiebalk
fontmenu.menu Menu fontmenu.menu Menu
fontmenu.messages Messages
fontmenu.other Andere fontmenu.other Andere
fontmenu.scaling Globale lettertype Zoom Factor fontmenu.scaling Globale lettertype Zoom Factor
fontmenu.scaling_x Horizontaal (in %) fontmenu.scaling_x Horizontaal (in %)
@@ -685,6 +686,7 @@ fontsize.infobar_info Info
fontsize.infobar_number Nummer fontsize.infobar_number Nummer
fontsize.infobar_small Klein fontsize.infobar_small Klein
fontsize.menu Menu tekst fontsize.menu Menu tekst
fontsize.message_text Messag Text
fontsize.menu_hint Menu hints fontsize.menu_hint Menu hints
fontsize.menu_info Menu Info fontsize.menu_info Menu Info
fontsize.menu_title Menu Titel fontsize.menu_title Menu Titel
@@ -1095,6 +1097,7 @@ menu.hint_menu_fonts Lettertype grote van menu's aanpassen
menu.hint_menu_hints Hints weergeven Show this hints. U kunt tevens gebruik maken van de 'help' toets. menu.hint_menu_hints Hints weergeven Show this hints. U kunt tevens gebruik maken van de 'help' toets.
menu.hint_menu_pos Selecteer menu positie menu.hint_menu_pos Selecteer menu positie
menu.hint_menus Configureer menu opties menu.hint_menus Configureer menu opties
menu.hint_message_fonts Change message text font sizes
menu.hint_misc_cec HDMI-CEC Opties menu.hint_misc_cec HDMI-CEC Opties
menu.hint_misc_channellist HD/Nieuw/Verwijderde kanalen lijst \nZap cyclus menu.hint_misc_channellist HD/Nieuw/Verwijderde kanalen lijst \nZap cyclus
menu.hint_misc_energy Softstandby, uitgesteld uitschakelen en inactiviteit timers inschakelen menu.hint_misc_energy Softstandby, uitgesteld uitschakelen en inactiviteit timers inschakelen

View File

@@ -703,6 +703,7 @@ fontmenu.eventlist Programový sprievodca
fontmenu.head Nastavenie písma fontmenu.head Nastavenie písma
fontmenu.infobar Informačná lišta fontmenu.infobar Informačná lišta
fontmenu.menu Menu fontmenu.menu Menu
fontmenu.messages Messages
fontmenu.moviebrowser Prehliadač filmov fontmenu.moviebrowser Prehliadač filmov
fontmenu.other Iné fontmenu.other Iné
fontmenu.scaling Faktor zoomu globálneho fontu fontmenu.scaling Faktor zoomu globálneho fontu
@@ -732,6 +733,7 @@ fontsize.infobar_info Informácia na informačnej lište
fontsize.infobar_ng_ecminfo ECM Informácia fontsize.infobar_ng_ecminfo ECM Informácia
fontsize.infobar_number Kanál na informačnej lište fontsize.infobar_number Kanál na informačnej lište
fontsize.menu Text menu fontsize.menu Text menu
fontsize.message_text Messagwe Text
fontsize.menu_foot Päta (vo všetkých grafických elementoch) fontsize.menu_foot Päta (vo všetkých grafických elementoch)
fontsize.menu_hint Popis menu fontsize.menu_hint Popis menu
fontsize.menu_info Informačné menu fontsize.menu_info Informačné menu
@@ -1183,6 +1185,7 @@ menu.hint_menu_fonts Zmena veľkosti písma menu
menu.hint_menu_hints Zobrazí túto nápovedu. Taktiež môžno kedykoľvek zmeniť použitím tlačidla ´HELP´. menu.hint_menu_hints Zobrazí túto nápovedu. Taktiež môžno kedykoľvek zmeniť použitím tlačidla ´HELP´.
menu.hint_menu_pos Výber umiestnenia menu menu.hint_menu_pos Výber umiestnenia menu
menu.hint_menus Konfigurácia volieb ponuky menu.hint_menus Konfigurácia volieb ponuky
menu.hint_message_fonts Change message text font sizes
menu.hint_misc_cec HDMI-CEC voľby menu.hint_misc_cec HDMI-CEC voľby
menu.hint_misc_channellist HD/Nové/Odstránené zoznamy kanálov, cyklické prepnutie menu.hint_misc_channellist HD/Nové/Odstránené zoznamy kanálov, cyklické prepnutie
menu.hint_misc_energy Použitie pohotovostného režimu, oneskorené vypnutie\nčasovače neaktivity menu.hint_misc_energy Použitie pohotovostného režimu, oneskorené vypnutie\nčasovače neaktivity

View File

@@ -164,6 +164,13 @@ const SNeutrinoSettings::FONT_TYPES other_font_sizes[] =
}; };
size_t other_font_items = sizeof(other_font_sizes)/sizeof(other_font_sizes[0]); size_t other_font_items = sizeof(other_font_sizes)/sizeof(other_font_sizes[0]);
const SNeutrinoSettings::FONT_TYPES msgtext_font_sizes[] =
{
SNeutrinoSettings::FONT_TYPE_MESSAGE_TEXT
};
size_t msgtext_font_items = sizeof(msgtext_font_sizes)/sizeof(msgtext_font_sizes[0]);
font_sizes_groups font_sizes_groups[] = font_sizes_groups font_sizes_groups[] =
{ {
{LOCALE_FONTMENU_MENU , menu_font_items , menu_font_sizes , "fontsize.dmen", LOCALE_MENU_HINT_MENU_FONTS }, {LOCALE_FONTMENU_MENU , menu_font_items , menu_font_sizes , "fontsize.dmen", LOCALE_MENU_HINT_MENU_FONTS },
@@ -172,6 +179,7 @@ font_sizes_groups font_sizes_groups[] =
{LOCALE_FONTMENU_EPG , epg_font_items , epg_font_sizes , "fontsize.depg", LOCALE_MENU_HINT_EPG_FONTS }, {LOCALE_FONTMENU_EPG , epg_font_items , epg_font_sizes , "fontsize.depg", LOCALE_MENU_HINT_EPG_FONTS },
{LOCALE_FONTMENU_INFOBAR , infobar_font_items , infobar_font_sizes , "fontsize.dinf", LOCALE_MENU_HINT_INFOBAR_FONTS }, {LOCALE_FONTMENU_INFOBAR , infobar_font_items , infobar_font_sizes , "fontsize.dinf", LOCALE_MENU_HINT_INFOBAR_FONTS },
{LOCALE_FONTMENU_MOVIEBROWSER,moviebrowser_font_items,moviebrowser_font_sizes,"fontsize.dmbr", LOCALE_MENU_HINT_MOVIEBROWSER_FONTS }, {LOCALE_FONTMENU_MOVIEBROWSER,moviebrowser_font_items,moviebrowser_font_sizes,"fontsize.dmbr", LOCALE_MENU_HINT_MOVIEBROWSER_FONTS },
{LOCALE_FONTMENU_MESSAGES , msgtext_font_items , msgtext_font_sizes , "fontsize.msg", LOCALE_MENU_HINT_MESSAGE_FONTS },
{LOCALE_FONTMENU_OTHER , other_font_items , other_font_sizes , "fontsize.doth", LOCALE_MENU_HINT_OTHER_FONTS } {LOCALE_FONTMENU_OTHER , other_font_items , other_font_sizes , "fontsize.doth", LOCALE_MENU_HINT_OTHER_FONTS }
}; };
#define FONT_GROUP_COUNT (sizeof(font_sizes_groups)/sizeof(font_sizes_groups[0])) #define FONT_GROUP_COUNT (sizeof(font_sizes_groups)/sizeof(font_sizes_groups[0]))
@@ -205,7 +213,8 @@ font_sizes_struct neutrino_font[SNeutrinoSettings::FONT_TYPE_COUNT] =
{LOCALE_FONTSIZE_MOVIEBROWSER_HEAD , 15, CNeutrinoFonts::FONT_STYLE_REGULAR, 2}, {LOCALE_FONTSIZE_MOVIEBROWSER_HEAD , 15, CNeutrinoFonts::FONT_STYLE_REGULAR, 2},
{LOCALE_FONTSIZE_MOVIEBROWSER_LIST , 17, CNeutrinoFonts::FONT_STYLE_REGULAR, 0}, {LOCALE_FONTSIZE_MOVIEBROWSER_LIST , 17, CNeutrinoFonts::FONT_STYLE_REGULAR, 0},
{LOCALE_FONTSIZE_MOVIEBROWSER_INFO , 17, CNeutrinoFonts::FONT_STYLE_REGULAR, 0}, {LOCALE_FONTSIZE_MOVIEBROWSER_INFO , 17, CNeutrinoFonts::FONT_STYLE_REGULAR, 0},
{LOCALE_FONTSIZE_SUBTITLES , 25, CNeutrinoFonts::FONT_STYLE_BOLD , 0} {LOCALE_FONTSIZE_SUBTITLES , 25, CNeutrinoFonts::FONT_STYLE_BOLD , 0},
{LOCALE_FONTSIZE_MESSAGE_TEXT , 20, CNeutrinoFonts::FONT_STYLE_REGULAR, 1}
}; };
int COsdSetup::exec(CMenuTarget* parent, const std::string &actionKey) int COsdSetup::exec(CMenuTarget* parent, const std::string &actionKey)

View File

@@ -36,7 +36,7 @@
#include "hintbox.h" #include "hintbox.h"
#include <system/debug.h> #include <system/debug.h>
#define MSG_FONT g_Font[SNeutrinoSettings::FONT_TYPE_MESSAGE_TEXT]
/** /**
x width ccw_head [relevant for CHintBox, CMsgBox. not enabled in CHint class] x width ccw_head [relevant for CHintBox, CMsgBox. not enabled in CHint class]
@@ -132,7 +132,7 @@ void CHintBox::init(const std::string& Text, const int& Width, const std::string
timeout = HINTBOX_DEFAULT_TIMEOUT; timeout = HINTBOX_DEFAULT_TIMEOUT;
w_indentation = indent; w_indentation = indent;
hb_font = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_INFO]; hb_font = MSG_FONT;
//enable shadow //enable shadow
shadow = true; shadow = true;
@@ -321,7 +321,7 @@ void CHintBox::setMsgText(const std::string& Text, const uint& hint_id, const in
CComponentsInfoBox *obj_text = static_cast<CComponentsInfoBox*>(ccw_body->getCCItem(id)); CComponentsInfoBox *obj_text = static_cast<CComponentsInfoBox*>(ccw_body->getCCItem(id));
//set required font and line size //set required font and line size
Font* font = font_text == NULL ? g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_INFO] : font_text; Font* font = font_text == NULL ? MSG_FONT : font_text;
if (obj_text) if (obj_text)
obj_text->setText(Text, mode, font, color_text, style); obj_text->setText(Text, mode, font, color_text, style);
} }

View File

@@ -730,6 +730,7 @@ typedef enum
LOCALE_FONTMENU_HEAD, LOCALE_FONTMENU_HEAD,
LOCALE_FONTMENU_INFOBAR, LOCALE_FONTMENU_INFOBAR,
LOCALE_FONTMENU_MENU, LOCALE_FONTMENU_MENU,
LOCALE_FONTMENU_MESSAGES,
LOCALE_FONTMENU_MOVIEBROWSER, LOCALE_FONTMENU_MOVIEBROWSER,
LOCALE_FONTMENU_OTHER, LOCALE_FONTMENU_OTHER,
LOCALE_FONTMENU_SCALING, LOCALE_FONTMENU_SCALING,
@@ -763,6 +764,7 @@ typedef enum
LOCALE_FONTSIZE_MENU_HINT, LOCALE_FONTSIZE_MENU_HINT,
LOCALE_FONTSIZE_MENU_INFO, LOCALE_FONTSIZE_MENU_INFO,
LOCALE_FONTSIZE_MENU_TITLE, LOCALE_FONTSIZE_MENU_TITLE,
LOCALE_FONTSIZE_MESSAGE_TEXT,
LOCALE_FONTSIZE_MOVIEBROWSER_HEAD, LOCALE_FONTSIZE_MOVIEBROWSER_HEAD,
LOCALE_FONTSIZE_MOVIEBROWSER_INFO, LOCALE_FONTSIZE_MOVIEBROWSER_INFO,
LOCALE_FONTSIZE_MOVIEBROWSER_LIST, LOCALE_FONTSIZE_MOVIEBROWSER_LIST,
@@ -1210,6 +1212,7 @@ typedef enum
LOCALE_MENU_HINT_MENU_HINTS, LOCALE_MENU_HINT_MENU_HINTS,
LOCALE_MENU_HINT_MENU_POS, LOCALE_MENU_HINT_MENU_POS,
LOCALE_MENU_HINT_MENUS, LOCALE_MENU_HINT_MENUS,
LOCALE_MENU_HINT_MESSAGE_FONTS,
LOCALE_MENU_HINT_MISC_CEC, LOCALE_MENU_HINT_MISC_CEC,
LOCALE_MENU_HINT_MISC_CHANNELLIST, LOCALE_MENU_HINT_MISC_CHANNELLIST,
LOCALE_MENU_HINT_MISC_ENERGY, LOCALE_MENU_HINT_MISC_ENERGY,

View File

@@ -730,6 +730,7 @@ const char * locale_real_names[] =
"fontmenu.head", "fontmenu.head",
"fontmenu.infobar", "fontmenu.infobar",
"fontmenu.menu", "fontmenu.menu",
"fontmenu.messages",
"fontmenu.moviebrowser", "fontmenu.moviebrowser",
"fontmenu.other", "fontmenu.other",
"fontmenu.scaling", "fontmenu.scaling",
@@ -763,6 +764,7 @@ const char * locale_real_names[] =
"fontsize.menu_hint", "fontsize.menu_hint",
"fontsize.menu_info", "fontsize.menu_info",
"fontsize.menu_title", "fontsize.menu_title",
"fontsize.message_text",
"fontsize.moviebrowser_head", "fontsize.moviebrowser_head",
"fontsize.moviebrowser_info", "fontsize.moviebrowser_info",
"fontsize.moviebrowser_list", "fontsize.moviebrowser_list",
@@ -1210,6 +1212,7 @@ const char * locale_real_names[] =
"menu.hint_menu_hints", "menu.hint_menu_hints",
"menu.hint_menu_pos", "menu.hint_menu_pos",
"menu.hint_menus", "menu.hint_menus",
"menu.hint_message_fonts",
"menu.hint_misc_cec", "menu.hint_misc_cec",
"menu.hint_misc_channellist", "menu.hint_misc_channellist",
"menu.hint_misc_energy", "menu.hint_misc_energy",

View File

@@ -683,6 +683,7 @@ struct SNeutrinoSettings
FONT_TYPE_MOVIEBROWSER_LIST, FONT_TYPE_MOVIEBROWSER_LIST,
FONT_TYPE_MOVIEBROWSER_INFO, FONT_TYPE_MOVIEBROWSER_INFO,
FONT_TYPE_SUBTITLES, FONT_TYPE_SUBTITLES,
FONT_TYPE_MESSAGE_TEXT,
FONT_TYPE_COUNT FONT_TYPE_COUNT
}; };