summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Mair <amair.sob@googlemail.com>2007-07-02 12:12:06 +0200
committerAndreas Mair <amair.sob@googlemail.com>2007-07-02 12:12:06 +0200
commit40650ddcf7b4142790b786e50f315dade90e8678 (patch)
treea057261ca415fd1fdd40f1b3ea0e4fc3fa547131
parentfc61e314442d22bb7886dba77380497b776fcb62 (diff)
downloadvdr-plugin-skinenigmang-40650ddcf7b4142790b786e50f315dade90e8678.tar.gz
vdr-plugin-skinenigmang-40650ddcf7b4142790b786e50f315dade90e8678.tar.bz2
2007-07-02: Version 0.0.5v0.0.5
- Reworked font handling in menu OSD a little bit to (hopefully) fix crashes with plugins that patch fonts. - Updated Nederlands translation (Provided by dorpsgek @vdr-portal.de). - Don't make info area in mainmenu too small (Requested by vdrchuck @vdr-portal.de). - Save and restore TTF FixedFont (Reported by zulu @vdr-portal.de). - Updated Italian translation (Provided by Gringo). - Updated French translation (Provided by Pat @vdr-portal.de).
-rw-r--r--HISTORY8
-rw-r--r--README7
-rw-r--r--config.c8
-rw-r--r--config.h2
-rw-r--r--enigma.c108
-rw-r--r--i18n.c158
-rw-r--r--skinenigmang.c2
-rw-r--r--texteffects.c34
-rw-r--r--texteffects.h11
9 files changed, 188 insertions, 150 deletions
diff --git a/HISTORY b/HISTORY
index 75382a7..59f0174 100644
--- a/HISTORY
+++ b/HISTORY
@@ -1,6 +1,14 @@
VDR Skin 'EnigmaNG' Revision History
------------------------------------------
+2007-07-02: Version 0.0.5
+- Reworked font handling in menu OSD a little bit to (hopefully) fix crashes with plugins that patch fonts.
+- Updated Nederlands translation (Provided by dorpsgek @vdr-portal.de).
+- Don't make info area in mainmenu too small (Requested by vdrchuck @vdr-portal.de).
+- Save and restore TTF FixedFont (Reported by zulu @vdr-portal.de).
+- Updated Italian translation (Provided by Gringo).
+- Updated French translation (Provided by Pat @vdr-portal.de).
+
2007-06-25: Version 0.0.5rc3
- Updated Finnish translation (Submitted by Rolf Ahrenberg).
- Added quickepgsearch, sport and music plugins in main menu logos (Submitted by zulu @vdr-portal.de).
diff --git a/README b/README
index 62efd1e..eec17ff 100644
--- a/README
+++ b/README
@@ -32,6 +32,8 @@ There are some configuration items you need to set before running
SKINENIGMA_HAVE_EPGSEARCH = 1
If you are using the epgsearch plugin and want to see the number of
timer conflicts in the main menu's info area.
+NOTE: This requires the sources of the epgsearch Plugin beside the
+EnigmaNG sources!
SKINENIGMA_NO_MENULOGO = 1
This turns usage of logos in the main menu complete. This might also
@@ -203,6 +205,7 @@ Setup Options
requested flag file exists. Else language's abbreviation is drawn.
- Show mail icon (never/only if new mail present/always)
+ (NOTE: only visible if mailbox plugin support is compiled in and plugin is loaded!)
Enables mail icon in channel info.
- Show event/recording images
@@ -300,9 +303,11 @@ Setup Options
- Details: date
- Details: text
- Replay: times
+- Fixed Font
Set the font for the named area.
If you have set HAVE_FREETYPE you can set the TrueTypeFont to use by pressing
- the blue key.
+ the blue key. Then you can select one of the TrueTypeFonts found in EnigmaNG's
+ font directory (see above) and set it's size and width.
* EPGSearch
NOTE: only visible if epgsearch support is compiled in
diff --git a/config.c b/config.c
index 62b33cf..3d96fc3 100644
--- a/config.c
+++ b/config.c
@@ -48,7 +48,7 @@ FontConfig allFontConfig[FONT_NUMFONTS] =
{ FONT_DETAILSDATE, "FontDetailsDate", "FontDetailsDateName" },
{ FONT_DETAILSTEXT, "FontDetailsText", "FontDetailsTextName" },
{ FONT_REPLAYTIMES, "FontReplayTimes", "FontReplayTimesName" },
- { FONT_FIXED, "FontFixed", "FontFixed" }
+ { FONT_FIXED, "FontFixed", "FontFixedName" }
};
cEnigmaConfig::cEnigmaConfig() : showAuxInfo(1), showLogo(1), showVps(1), showSymbols(1),
@@ -130,11 +130,13 @@ void cEnigmaConfig::SetFontsDir(const char *dir)
}
#endif
-const cFont *cEnigmaConfig::GetFont(int id)
+const cFont *cEnigmaConfig::GetFont(int id, const cFont *pFontCur)
{
const cFont *res = NULL;
if (::Setup.UseSmallFont == 1) { // if "Use small font" == "skin dependent"
if (allFonts[id].VdrId == FONT_TRUETYPE) {
+ if (pFontCur) // TTFs can't get patched, so it's always save to return the previous pointer
+ return pFontCur;
if (!isempty(allFonts[id].Name)) {
#ifdef HAVE_FREETYPE
char *cachename;
@@ -170,7 +172,7 @@ void cEnigmaConfig::SetFont(int id, const char *font)
if (id >= 0 && id < FONT_NUMFONTS && font) {
char *tmp = strrchr(font, ':');
if (tmp) {
- strncpy(allFonts[id].Name, font, std::min((int)sizeof(allFonts[id].Name), tmp - font));
+ strncpy(allFonts[id].Name, font, std::min((int)sizeof(allFonts[id].Name), (int)(tmp - font)));
allFonts[id].Size = atoi(tmp + 1);
tmp = strchr(tmp + 1, ',');
if (tmp) {
diff --git a/config.h b/config.h
index e8aa2f4..9918cf4 100644
--- a/config.h
+++ b/config.h
@@ -102,7 +102,7 @@ public:
char *GetFontsDir(void) { return strFontsDir; }
#endif
const char *GetImageExtension(void);
- const cFont *GetFont(int id);
+ const cFont *GetFont(int id, const cFont *pFontCur = NULL);
void SetFont(int id, const char *font);
void SetFont(int id, int vdrId);
void GetOsdSize(struct EnigmaOsdSize *size);
diff --git a/enigma.c b/enigma.c
index 67dc61a..46a45ff 100644
--- a/enigma.c
+++ b/enigma.c
@@ -195,6 +195,7 @@ THEME_CLR(Theme, clrReplayProgressSelected, 0xFF4158BC);
THEME_CLR(Theme, clrReplayProgressMark, 0xFF4158BC);
THEME_CLR(Theme, clrReplayProgressCurrent, 0xFFFF0000);
+#define MIN_DATEWIDTH 144
#define TinyGap 1
#define SmallGap 2
#define Gap 4
@@ -437,7 +438,7 @@ void cSkinEnigmaDisplayChannel::DrawGroupInfo(const cChannel *Channel, int Numbe
#ifndef DISABLE_ANIMATED_TEXT
if (fScrollTitle) {
int xName = (fShowLogo && EnigmaConfig.fullTitleWidth ? xEventNowLeft : xTitleLeft + Roundness + pFontOsdTitle->Width("0000-") + Gap);
- idTitle = TE_TITLE(osd, idTitle, GetChannelName(Channel), pFontOsdTitle, xDateLeft - SmallGap - xName, this);
+ idTitle = TE_TITLE(osd, idTitle, GetChannelName(Channel), xDateLeft - SmallGap - xName, this);
} else
#endif
DrawTitle(GetChannelName(Channel));
@@ -488,7 +489,7 @@ void cSkinEnigmaDisplayChannel::DrawChannelInfo(const cChannel *Channel, int Num
#ifndef DISABLE_ANIMATED_TEXT
if (fScrollTitle) {
int xName = (fShowLogo && EnigmaConfig.fullTitleWidth ? xEventNowLeft : xTitleLeft + Roundness + pFontOsdTitle->Width("0000-") + Gap);
- idTitle = TE_TITLE(osd, idTitle, GetChannelName(Channel), pFontOsdTitle, xDateLeft - SmallGap - xName, this);
+ idTitle = TE_TITLE(osd, idTitle, GetChannelName(Channel), xDateLeft - SmallGap - xName, this);
} else
#endif
DrawTitle(GetChannelName(Channel));
@@ -680,7 +681,7 @@ void cSkinEnigmaDisplayChannel::SetChannel(const cChannel *Channel, int Number)
void cSkinEnigmaDisplayChannel::SetEvents(const cEvent *Present,
const cEvent *Following)
{
- debug("cSkinEnigmaDisplayChannel::SetEvents() %d %d", fScrollTitle, fLocked);
+ debug("cSkinEnigmaDisplayChannel::SetEvents()");
int xTimeLeft = xEventNowLeft + Gap;
int xTimeWidth = pFontTitle->Width("00:00");
@@ -886,19 +887,7 @@ class cSkinEnigmaDisplayMenu : public cSkinDisplayMenu, cSkinEnigmaOsd {
private:
cOsd *osd;
const cFont *pFontList;
- const cFont *pFontDate;
const cFont *pFontOsdTitle;
- const cFont *pFontDetailsTitle;
- const cFont *pFontDetailsSubtitle;
- const cFont *pFontDetailsDate;
- const cFont *pFontDetailsText;
- const cFont *pFontHelpKeys;
- const cFont *pFontInfoWarnHeadline;
- const cFont *pFontInfoWarnText;
- const cFont *pFontInfoTimerHeadline;
- const cFont *pFontInfoTimerText;
- const cFont *pFontMessage;
- const cFont *pFontFixed;
char *strTitle;
char *strLastDate;
@@ -943,7 +932,7 @@ private:
const char *GetPluginMainMenuName(const char *plugin);
int ReadSizeVdr(const char *strPath);
bool HasTabbedText(const char *s, int Tab);
- int getDateWidth(void);
+ int getDateWidth(const cFont *pFontDate);
public:
cSkinEnigmaDisplayMenu();
@@ -973,19 +962,12 @@ cSkinEnigmaDisplayMenu::cSkinEnigmaDisplayMenu(void)
setlocale(LC_TIME, tr("en_US"));
osd = NULL;
pFontList = EnigmaConfig.GetFont(FONT_LISTITEM);
- pFontDate = EnigmaConfig.GetFont(FONT_DATE);
pFontOsdTitle = EnigmaConfig.GetFont(FONT_OSDTITLE);
- pFontDetailsTitle = EnigmaConfig.GetFont(FONT_DETAILSTITLE);
- pFontDetailsSubtitle = EnigmaConfig.GetFont(FONT_DETAILSSUBTITLE);
- pFontDetailsDate = EnigmaConfig.GetFont(FONT_DETAILSDATE);
- pFontDetailsText = EnigmaConfig.GetFont(FONT_DETAILSTEXT);
- pFontHelpKeys = EnigmaConfig.GetFont(FONT_HELPKEYS);
- pFontInfoWarnHeadline = EnigmaConfig.GetFont(FONT_INFOWARNHEADLINE);
- pFontInfoWarnText = EnigmaConfig.GetFont(FONT_INFOWARNTEXT);
- pFontInfoTimerHeadline = EnigmaConfig.GetFont(FONT_INFOTIMERHEADLINE);
- pFontInfoTimerText = EnigmaConfig.GetFont(FONT_INFOTIMERTEXT);
- pFontMessage = EnigmaConfig.GetFont(FONT_MESSAGE);
- pFontFixed = EnigmaConfig.GetFont(FONT_FIXED);
+
+ const cFont *pFontDate = EnigmaConfig.GetFont(FONT_DATE);
+ const cFont *pFontDetailsTitle = EnigmaConfig.GetFont(FONT_DETAILSTITLE);
+ const cFont *pFontDetailsSubtitle = EnigmaConfig.GetFont(FONT_DETAILSSUBTITLE);
+ const cFont *pFontDetailsDate = EnigmaConfig.GetFont(FONT_DETAILSDATE);
strTitle = NULL;
strLastDate = NULL;
@@ -1019,14 +1001,16 @@ cSkinEnigmaDisplayMenu::cSkinEnigmaDisplayMenu(void)
int LogoWidth = EnigmaConfig.showImages ? std::max(IconWidth, EnigmaConfig.imageWidth) : IconWidth;
int RightColWidth = 0;
if (fShowLogoDefault) {
- int nMainDateWidth = getDateWidth() + SmallGap + LogoWidth;
+ int nMainDateWidth = getDateWidth(pFontDate) + SmallGap + LogoWidth;
cString date = DayDateTime();
int nSubDateWidth = pFontDate->Width(date);
RightColWidth = (SmallGap + Gap + std::max(nMainDateWidth, nSubDateWidth) + Gap) & ~0x07; // must be multiple of 8
} else {
cString date = DayDateTime();
- RightColWidth = (SmallGap + Gap + pFontDate->Width(date) + Gap) & ~0x07; // must be multiple of 8
+ RightColWidth = (SmallGap + Gap + std::max(MIN_DATEWIDTH + LogoWidth, pFontDate->Width(date)) + Gap) & ~0x07; // must be multiple of 8
}
+
+ const cFont *pFontMessage = EnigmaConfig.GetFont(FONT_MESSAGE);
int MessageHeight = 2 * SmallGap + pFontMessage->Height() + 2 * SmallGap;
// title bar
@@ -1039,7 +1023,7 @@ cSkinEnigmaDisplayMenu::cSkinEnigmaDisplayMenu(void)
// help buttons
xButtonsLeft = xTitleLeft;
xButtonsRight = OsdSize.w;
- yButtonsTop = OsdSize.h - pFontHelpKeys->Height();
+ yButtonsTop = OsdSize.h - EnigmaConfig.GetFont(FONT_HELPKEYS)->Height();
yButtonsBottom = OsdSize.h;
// content area with items
xBodyLeft = xTitleLeft;
@@ -1238,7 +1222,7 @@ void cSkinEnigmaDisplayMenu::SetupAreas(void)
#ifndef DISABLE_ANIMATED_TEXT
if (fScrollTitle) {
- idTitle = TE_TITLE(osd, idTitle, strTitle, pFontOsdTitle, xTitleRight - xTitleLeft - Roundness, this);
+ idTitle = TE_TITLE(osd, idTitle, strTitle, xTitleRight - xTitleLeft - Roundness, this);
} else
#endif
DrawTitle(strTitle);
@@ -1287,16 +1271,25 @@ void cSkinEnigmaDisplayMenu::SetupAreas(void)
p->Service("Epgsearch-lastconflictinfo-v1.0", serviceData);
if (serviceData->relevantConflicts > 0) {
+ const cFont *pFontInfoWarnHeadline = EnigmaConfig.GetFont(FONT_INFOWARNHEADLINE);
+ const cFont *pFontInfoWarnText = EnigmaConfig.GetFont(FONT_INFOWARNTEXT);
int yWarning = yMaxHeight -
pFontInfoWarnHeadline->Height() -
2 * pFontInfoWarnText->Height(); // Needed space for warning
yMaxHeight = yWarning;
osd->DrawRectangle(xInfoLeft, yWarning, xInfoRight - 1, yWarning + SmallGap + 1, Theme.Color(clrBackground));
yWarning += pFontInfoWarnText->Height() / 2;
+#ifndef DISABLE_ANIMATED_TEXT
TE_BLINK(osd, -1, xInfoLeft, yWarning, tr("WARNING"),
Theme.Color(clrMenuItemSelectableFg), Theme.Color(clrAltBackground),
+ FONT_INFOWARNHEADLINE,
+ w, pFontInfoWarnHeadline->Height(), taCenter);
+#else
+ osd->DrawText(xInfoLeft, yWarning, tr("WARNING"),
+ Theme.Color(clrMenuItemSelectableFg), Theme.Color(clrAltBackground),
pFontInfoWarnHeadline,
w, pFontInfoWarnHeadline->Height(), taCenter);
+#endif
yWarning += (int)(1.5 * pFontInfoWarnHeadline->Height());
char *info;
@@ -1314,6 +1307,8 @@ void cSkinEnigmaDisplayMenu::SetupAreas(void)
#endif //SKINENIGMA_HAVE_EPGSEARCH
if (Timers.GetNextActiveTimer()) {
+ const cFont *pFontInfoTimerHeadline = EnigmaConfig.GetFont(FONT_INFOTIMERHEADLINE);
+ const cFont *pFontInfoTimerText = EnigmaConfig.GetFont(FONT_INFOTIMERTEXT);
int h = pFontInfoTimerHeadline->Height();
// Show next active timers
y += h / 2;
@@ -1337,7 +1332,7 @@ void cSkinEnigmaDisplayMenu::SetupAreas(void)
TE_MARQUEE(osd, -1, x + (timer->isRecording ? (bmRecording.Width() + Gap) : 0),
y, timer->title.c_str(),
Theme.Color(clrMenuItemSelectableFg), Theme.Color(clrAltBackground),
- pFontInfoTimerText, w, h);
+ FONT_INFOTIMERTEXT, w, h);
else
#endif
osd->DrawText(x + (timer->isRecording ? (bmRecording.Width() + Gap) : 0),
@@ -1426,7 +1421,7 @@ void cSkinEnigmaDisplayMenu::Scroll(bool Up, bool Page)
int cSkinEnigmaDisplayMenu::MaxItems(void)
{
// max number of items
- return (yBodyBottom - yBodyTop) / pFontList->Height();
+ return (yBodyBottom - yBodyTop) / lineHeight;
}
void cSkinEnigmaDisplayMenu::Clear(void)
@@ -1435,6 +1430,7 @@ void cSkinEnigmaDisplayMenu::Clear(void)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
+ pFontList = EnigmaConfig.GetFont(FONT_LISTITEM, pFontList); //TODO? get current font which might have been patched meanwhile
nOldIndex = -1;
for (int i = MaxTabs - 1; i >= 0; i--) {
if (idListItem[i] >= 0) {
@@ -1492,7 +1488,7 @@ void cSkinEnigmaDisplayMenu::SetTitle(const char *Title)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
if (fScrollTitle) {
- idTitle = TE_TITLE(osd, idTitle, strTitle, pFontOsdTitle, xTitleRight - xTitleLeft - Roundness, this);
+ idTitle = TE_TITLE(osd, idTitle, strTitle, xTitleRight - xTitleLeft - Roundness, this);
} else
#endif
DrawTitle(Title);
@@ -1542,7 +1538,7 @@ void cSkinEnigmaDisplayMenu::SetTitle(const char *Title)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
if (fScrollTitle) {
- idTitle = TE_TITLE(osd, idTitle, strTitle, pFontOsdTitle, xTitleRight - xTitleLeft - Roundness, this);
+ idTitle = TE_TITLE(osd, idTitle, strTitle, xTitleRight - xTitleLeft - Roundness, this);
} else
#endif
DrawTitle(Title);
@@ -1569,6 +1565,7 @@ void cSkinEnigmaDisplayMenu::DrawTitle(const char *Title)
osd->DrawEllipse(xTitleLeft, yTitleTop, xTitleLeft + Roundness - 1, yTitleTop + Roundness - 1, clrTransparent, -2);
if (Title) {
+ pFontOsdTitle = EnigmaConfig.GetFont(FONT_OSDTITLE, pFontOsdTitle); //TODO? get current font which might have been patched meanwhile
int y = yTitleTop + (yTitleBottom - yTitleTop - pFontOsdTitle->Height()) / 2;
// draw title with shadow
osd->DrawText(xTitleLeft + Roundness + 3, y + 3, Title,
@@ -1591,6 +1588,7 @@ void cSkinEnigmaDisplayMenu::SetButtons(const char *Red, const char *Green, cons
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
#endif
+ const cFont *pFontHelpKeys = EnigmaConfig.GetFont(FONT_HELPKEYS);
int w = (xButtonsRight - xButtonsLeft) / 4;
int t3 = xButtonsLeft + xButtonsRight - xButtonsLeft - w;
int t2 = t3 - w;
@@ -1647,6 +1645,7 @@ void cSkinEnigmaDisplayMenu::SetMessage(eMessageType Type, const char *Text)
if (nMessagesShown == 0)
osd->SaveRegion(xMessageLeft, yMessageTop, xMessageRight - 1, yMessageBottom - 1);
+ const cFont *pFontMessage = EnigmaConfig.GetFont(FONT_MESSAGE);
// draw message
osd->DrawRectangle(xMessageLeft, yMessageTop, xMessageRight - 1,
yMessageBottom - 1, clrTransparent);
@@ -1715,6 +1714,7 @@ void cSkinEnigmaDisplayMenu::SetItem(const char *Text, int Index, bool Current,
}
}
+ pFontList = EnigmaConfig.GetFont(FONT_LISTITEM, pFontList); //TODO? get current font which might have been patched meanwhile
#ifndef DISABLE_ANIMATED_TEXT
if (!Current && Index == nOldIndex) {
for (int i = MaxTabs - 1; i >= 0; i--) {
@@ -1863,7 +1863,7 @@ void cSkinEnigmaDisplayMenu::SetItem(const char *Text, int Index, bool Current,
if (fScrollListItem) {
// if (i > 0)
//TODO? EnigmaTextEffects.UpdateTextWidth(idListItem[i - 1], Tab(i) - Tab(i - 1));
- idListItem[i] = TE_MARQUEE(osd, idListItem[i], xt, y, s, ColorFg, ColorBg, pFontList, w, nMessagesShown ? std::min(yMessageTop - y, lineHeight) : 0 );
+ idListItem[i] = TE_MARQUEE(osd, idListItem[i], xt, y, s, ColorFg, ColorBg, FONT_LISTITEM, w, nMessagesShown ? std::min(yMessageTop - y, lineHeight) : 0 );
} else
#endif
osd->DrawText(xt, y, s, ColorFg, ColorBg, pFontList, w, nMessagesShown ? std::min(yMessageTop - y, lineHeight) : 0 );
@@ -2058,6 +2058,11 @@ void cSkinEnigmaDisplayMenu::SetEvent(const cEvent *Event)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
#endif
+ const cFont *pFontDetailsTitle = EnigmaConfig.GetFont(FONT_DETAILSTITLE);
+ const cFont *pFontDetailsSubtitle = EnigmaConfig.GetFont(FONT_DETAILSSUBTITLE);
+ const cFont *pFontDetailsDate = EnigmaConfig.GetFont(FONT_DETAILSDATE);
+ const cFont *pFontDetailsText = EnigmaConfig.GetFont(FONT_DETAILSTEXT);
+
isMainMenu = false;
fShowInfo = false;
fShowLogo = fShowLogoDefault ? EnigmaConfig.showImages : false;
@@ -2148,7 +2153,7 @@ void cSkinEnigmaDisplayMenu::SetEvent(const cEvent *Event)
if (fScrollOther)
TE_MARQUEE(osd, -1, xBodyLeft + Gap, y, Event->Title(),
Theme.Color(clrMenuTxtFg), Theme.Color(clrAltBackground),
- pFontDetailsTitle, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsTitle->Height());
+ FONT_DETAILSTITLE, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsTitle->Height());
else
#endif
osd->DrawText(xBodyLeft + Gap, y, Event->Title(),
@@ -2178,7 +2183,7 @@ void cSkinEnigmaDisplayMenu::SetEvent(const cEvent *Event)
if (fScrollOther)
TE_MARQUEE(osd, -1, xBodyLeft + Gap, y, Event->ShortText(),
Theme.Color(clrMenuItemNotSelectableFg), Theme.Color(clrAltBackground),
- pFontDetailsSubtitle, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsSubtitle->Height());
+ FONT_DETAILSSUBTITLE, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsSubtitle->Height());
else
#endif
osd->DrawText(xBodyLeft + Gap, y, Event->ShortText(),
@@ -2315,6 +2320,11 @@ void cSkinEnigmaDisplayMenu::SetRecording(const cRecording *Recording)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
#endif
+ const cFont *pFontDetailsTitle = EnigmaConfig.GetFont(FONT_DETAILSTITLE);
+ const cFont *pFontDetailsSubtitle = EnigmaConfig.GetFont(FONT_DETAILSSUBTITLE);
+ const cFont *pFontDetailsDate = EnigmaConfig.GetFont(FONT_DETAILSDATE);
+ const cFont *pFontDetailsText = EnigmaConfig.GetFont(FONT_DETAILSTEXT);
+
isMainMenu = false;
fShowInfo = false;
fShowLogo = fShowLogoDefault ? EnigmaConfig.showImages : false;;
@@ -2381,7 +2391,7 @@ void cSkinEnigmaDisplayMenu::SetRecording(const cRecording *Recording)
if (fScrollOther)
TE_MARQUEE(osd, -1, xBodyLeft + Gap, y, Title,
Theme.Color(clrMenuTxtFg), Theme.Color(clrAltBackground),
- pFontDetailsTitle, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsTitle->Height());
+ FONT_DETAILSTITLE, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsTitle->Height());
else
#endif
osd->DrawText(xBodyLeft + Gap, y, Title,
@@ -2410,7 +2420,7 @@ void cSkinEnigmaDisplayMenu::SetRecording(const cRecording *Recording)
if (fScrollOther)
TE_MARQUEE(osd, -1, xBodyLeft + Gap, y, Info->ShortText(),
Theme.Color(clrMenuItemNotSelectableFg), Theme.Color(clrAltBackground),
- pFontDetailsSubtitle, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsSubtitle->Height());
+ FONT_DETAILSSUBTITLE, xHeadlineRight - xBodyLeft - Gap - 1, pFontDetailsSubtitle->Height());
else
#endif
osd->DrawText(xBodyLeft + Gap, y, Info->ShortText(),
@@ -2485,19 +2495,19 @@ int cSkinEnigmaDisplayMenu::GetTextAreaWidth(void) const
const cFont *cSkinEnigmaDisplayMenu::GetTextAreaFont(bool FixedFont) const
{
// text area font
- return FixedFont ? pFontFixed : pFontDetailsText;
+ return FixedFont ? EnigmaConfig.GetFont(FONT_FIXED) : EnigmaConfig.GetFont(FONT_DETAILSTEXT);
}
-int cSkinEnigmaDisplayMenu::getDateWidth(void)
-{
- int w = 144;
+int cSkinEnigmaDisplayMenu::getDateWidth(const cFont *pFontDate)
+{ // only called from constructor, so pFontDate should be OK
+ int w = MIN_DATEWIDTH;
struct tm tm_r;
time_t t = time(NULL);
tm *tm = localtime_r(&t, &tm_r);
int nWeekday = tm->tm_wday;
if (0 <= nWeekday && nWeekday < 7)
- w = pFontDate->Width(strWeekdays[nWeekday]);
+ w = std::max(w, pFontDate->Width(strWeekdays[nWeekday]));
char temp[32];
strftime(temp, sizeof(temp), "%d.%m.%Y", tm);
@@ -2523,6 +2533,7 @@ debug("cSkinEnigmaDisplayMenu::Flush()");
free(strLastDate);
strLastDate = strdup((const char*)time);
+ const cFont *pFontDate = EnigmaConfig.GetFont(FONT_DATE);
int x = xDateLeft + SmallGap;
int w = xLogoLeft - x;
int ys = yDateTop + (yDateBottom - SmallGap - yDateTop - 3 * pFontDate->Height()) / 2;
@@ -2560,6 +2571,7 @@ debug("cSkinEnigmaDisplayMenu::Flush()");
if ((strLastDate == NULL) || strcmp(strLastDate, (const char*)date) != 0) {
free(strLastDate);
strLastDate = strdup((const char*)date);
+ const cFont *pFontDate = EnigmaConfig.GetFont(FONT_DATE);
osd->DrawText(xDateLeft + SmallGap, yDateTop, date, Theme.Color(clrMenuTxtFg),
Theme.Color(clrLogoBg), pFontDate, xDateRight - xDateLeft - SmallGap,
yTitleDecoBottom - yDateTop, taCenter);
@@ -2752,7 +2764,7 @@ void cSkinEnigmaDisplayReplay::SetTitle(const char *Title)
#ifndef DISABLE_ANIMATED_TEXT
if (!fLocked) TE_LOCK;
if (fScrollTitle) {
- idTitle = TE_TITLE(osd, idTitle, Title, pFontOsdTitle, xTitleRight - Roundness - xTitleLeft - Roundness, this);
+ idTitle = TE_TITLE(osd, idTitle, Title, xTitleRight - Roundness - xTitleLeft - Roundness, this);
} else
#endif
DrawTitle(Title);
@@ -3573,7 +3585,7 @@ void cSkinEnigmaDisplayMessage::SetMessage(eMessageType Type, const char *Text)
idMessage = TE_MARQUEE(osd, idMessage, xMessageLeft, yMessageTop + 2 * SmallGap, Text,
Theme.Color(clrMessageStatusFg + 2 * Type),
Theme.Color(clrMessageStatusBg + 2 * Type),
- pFontMessage,
+ FONT_MESSAGE,
xMessageRight - xMessageLeft,
yMessageBottom - 2 * SmallGap - yMessageTop - 2 * SmallGap, taCenter);
else
diff --git a/i18n.c b/i18n.c
index 508d60a..087e661 100644
--- a/i18n.c
+++ b/i18n.c
@@ -8,14 +8,16 @@
* - English: Andreas Mair <andreas _@_ vdr-developer.org>
* - Deutsch: Andreas Mair <andreas _@_ vdr-developer.org>
* - Italiano: Gringo <vdr-italian _@_ tiscali.it>
- * - Nederlands: ???
+ * - Nederlands: dorpsgek @vdr-portal.de
* - Français: Patrice Staudt <pat @vdr-portal.de>
* - Finnish: Rolf Ahrenberg <rofafor @vdr-portal.de>
* - Polski: ???
* - Español: ???
* - Svenska: ???
- * - Russian: ???
+ * - Russian: SergArb @vdr-portal.de / neptunvasja @vdr-portal.de
* - Eesti: ???
+ * - Dansk: ???
+ * - Czech: ???
*
*/
@@ -381,7 +383,7 @@ const tI18nPhrase Phrases[] = {
"Mostra loghi canali", // Italiano
"Toon kanaallogo's", // Nederlands
"", // Português
- "Afficher logo des chaînes", // Français
+ "Afficher logos des chaînes", // Français
"", // Norsk
"Näytä kanavalogot", // suomi (Finnish)
"Pokazuj logo kana³u", // Polski
@@ -469,7 +471,7 @@ const tI18nPhrase Phrases[] = {
"Dimensione cache dei loghi",// Italiano
"Kanaallogo cache", // Nederlands
"", // Português
- "Taille du cache des logo", // Français
+ "Taille du cache des logos", // Français
"", // Norsk
"Välimuistin koko kanavalogoille", // suomi (Finnish)
"Rozmiar cache dla logo kana³u", // Polski
@@ -579,7 +581,7 @@ const tI18nPhrase Phrases[] = {
"Mostra informazione ausiliare", // Italiano
"Toon hulp informatie", // Nederlands
"", // Português
- "Afficher information auxiliaire", // Français
+ "Afficher informations auxiliaires", // Français
"", // Norsk
"Näytä lisätiedot", // suomi (Finnish)
"Pokazuj informacje pomocnicze", // Polski
@@ -667,7 +669,7 @@ const tI18nPhrase Phrases[] = {
"Mostra area info nel menu principale", // Italiano
"Info in hoofdmenu", // Nederlands
"", // Português
- "Surface d'infos dans le menu principale", // Français
+ "Surface d'infos dans le menu principal", // Français
"", // Norsk
"Näytä infoalue päävalikossa", // suomi (Finnish)
"", // Polski
@@ -887,7 +889,7 @@ const tI18nPhrase Phrases[] = {
"*** Canale non valido ***", // Italiano
"*** Ongeldig Kanaal ***", // Nederlands
"", // Português
- "*** Chaînes non valable ***", // Français
+ "*** Chaîne non valable ***", // Français
"", // Norsk
"*** Virheellinen kanava ***", // suomi (Finnish)
"", // Polski
@@ -995,9 +997,9 @@ const tI18nPhrase Phrases[] = {
"Einen 8bpp Bereich versuchen", // Deutsch
"", // Slovenski
"Prova area singola a 8bpp", // Italiano
- "", // Nederlands
+ "Op 8bpp bereik testen", // Nederlands
"", // Português
- "", // Français
+ "Essayer une surface à 8bpp",// Français
"", // Norsk
"Suosi yhtä 8bpp kuva-aluetta", // suomi (Finnish)
"", // Polski
@@ -1173,7 +1175,7 @@ const tI18nPhrase Phrases[] = {
"Usa sottotitolo per ripetizioni", // Italiano
"Gebr. ondertitlel voor herh.", // Nederlands
"", // Português
- "Utilise sous-titre pour les répétitions", // Français
+ "Utilise sous-titres pour les répétitions", // Français
"", // Norsk
"Käytä lyhyttä kuvausta uusinnoille", // suomi (Finnish)
"", // Polski
@@ -1305,7 +1307,7 @@ const tI18nPhrase Phrases[] = {
"Mostra dimensione delle registrazioni", // Italiano
"Opnamegrootte tonen", // Nederlands
"", // Português
- "Afficher la taille des l'enregistrements", // Français
+ "Afficher la taille des enregistrements", // Français
"", // Norsk
"Näytä tallenteen koko", // suomi (Finnish)
"", // Polski
@@ -1371,7 +1373,7 @@ const tI18nPhrase Phrases[] = {
"ingrandisci immagine", // Italiano
"zoomen", // Nederlands
"", // Português
- "Agrandit image", // Français
+ "Agrandir image", // Français
"", // Norsk
"zoomaus", // suomi (Finnish)
"", // Polski
@@ -1415,7 +1417,7 @@ const tI18nPhrase Phrases[] = {
" Ridimensiona immagini", // Italiano
" Aanpassen beeldgrootte", // Nederlands
"", // Português
- " Redimension les images", // Français
+ " Redimensionne les images", // Français
"", // Norsk
" Muokkaa kuvien kokoa", // suomi (Finnish)
"", // Polski
@@ -1503,7 +1505,7 @@ const tI18nPhrase Phrases[] = {
"Lunghezza titolo completo", // Italiano
"Volle titelbreedte", // Nederlands
"", // Português
- "Largeur total pour le titre", // Français
+ "Largeur totale pour le titre", // Français
"", // Norsk
"Levitä otsikkopalkki", // suomi (Finnish)
"", // Polski
@@ -1526,7 +1528,7 @@ const tI18nPhrase Phrases[] = {
"Mostra icona email", // Italiano
"Mail-ikoon tonen", // Nederlands
"", // Português
- "Affiche l'icone courriel", // Français
+ "Afficher l'icône courriel", // Français
"", // Norsk
"Näytä sähköpostikuvake", // suomi (Finnish)
"", // Polski
@@ -1570,7 +1572,7 @@ const tI18nPhrase Phrases[] = {
"Bewegter Text", // Deutsch
"", // Slovenski
"Testo animato", // Italiano
- "", // Nederlands
+ "Geanimeerde tekst", // Nederlands
"", // Português
"Texte défilant", // Français
"", // Norsk
@@ -1592,7 +1594,7 @@ const tI18nPhrase Phrases[] = {
"Verwenden", // Deutsch
"", // Slovenski
"Abilita", // Italiano
- "", // Nederlands
+ "Toelaten", // Nederlands
"", // Português
"Permettre", // Français
"", // Norsk
@@ -1614,7 +1616,7 @@ const tI18nPhrase Phrases[] = {
" Scroll-Verhalten", // Deutsch
"", // Slovenski
" Comportamento scorrimento",// Italiano
- "", // Nederlands
+ " Scroll gedrag", // Nederlands
"", // Português
" Comportement de défilement", // Français
"", // Norsk
@@ -1636,7 +1638,7 @@ const tI18nPhrase Phrases[] = {
"nach links", // Deutsch
"", // Slovenski
"verso la sinistra", // Italiano
- "", // Nederlands
+ "naar links", // Nederlands
"", // Português
"vers la gauche", // Français
"", // Norsk
@@ -1658,7 +1660,7 @@ const tI18nPhrase Phrases[] = {
"links und rechts", // Deutsch
"", // Slovenski
"sinistra e destra", // Italiano
- "", // Nederlands
+ "links en rechts", // Nederlands
"", // Português
"gauche et droite", // Français
"", // Norsk
@@ -1680,7 +1682,7 @@ const tI18nPhrase Phrases[] = {
" Scroll-Verzögerung (ms)", // Deutsch
"", // Slovenski
" Ritardo scorrimento (ms)",// Italiano
- "", // Nederlands
+ " Scrollvertraging (ms)", // Nederlands
"", // Português
" Délai de défilement (ms)",// Français
"", // Norsk
@@ -1702,7 +1704,7 @@ const tI18nPhrase Phrases[] = {
" Scroll-Pause (ms)", // Deutsch
"", // Slovenski
" Pausa scorrimento (ms)", // Italiano
- "", // Nederlands
+ " Scrollpause (ms)", // Nederlands
"", // Português
" Pause de défilement (ms)",// Français
"", // Norsk
@@ -1724,7 +1726,7 @@ const tI18nPhrase Phrases[] = {
" Blink-Pause (ms)", // Deutsch
"", // Slovenski
" Pausa lampeggiante (ms)", // Italiano
- "", // Nederlands
+ " Blinkpauze (ms)", // Nederlands
"", // Português
" Pause de clignotement (ms)",// Français
"", // Norsk
@@ -1746,9 +1748,9 @@ const tI18nPhrase Phrases[] = {
" OSD Titel scrollen", // Deutsch
"", // Slovenski
" Scorri titolo OSD", // Italiano
- "", // Nederlands
+ " OSD titel scrollen", // Nederlands
"", // Português
- " Défillement dans le titre du OSD", // Français
+ " Défilement dans le titre du OSD", // Français
"", // Norsk
" Vieritä valikon otsikkoa",// suomi (Finnish)
"", // Polski
@@ -1768,7 +1770,7 @@ const tI18nPhrase Phrases[] = {
" Infobereich scrollen", // Deutsch
"", // Slovenski
" Scorri informazioni area",// Italiano
- "", // Nederlands
+ " Infobereik scrollen", // Nederlands
"", // Português
" Barre de défilement dans la surface info", // Français
"", // Norsk
@@ -1790,7 +1792,7 @@ const tI18nPhrase Phrases[] = {
" Aktive Listenzeile scrollen", // Deutsch
"", // Slovenski
" Scorri valori lista attivi",// Italiano
- "", // Nederlands
+ " Lijst aktieve punten scrollen", // Nederlands
"", // Português
" Barre de défilement dans la liste active", // Français
"", // Norsk
@@ -1812,9 +1814,9 @@ const tI18nPhrase Phrases[] = {
" Andere Bereiche scrollen", // Deutsch
"", // Slovenski
" Scorri altri valori", // Italiano
- "", // Nederlands
+ " Ander bereik scrollen", // Nederlands
"", // Português
- " Barre de défilement dans d'autre partie", // Français
+ " Barre de défilement dans d'autres parties", // Français
"", // Norsk
" Vieritä muita alueita", // suomi (Finnish)
"", // Polski
@@ -1835,7 +1837,7 @@ const tI18nPhrase Phrases[] = {
" Symbole im Menü", // Deutsch
"", // Slovenski
" Mostra simboli nel menu", // Italiano
- "", // Nederlands
+ " Symbolen in menu", // Nederlands
"", // Português
" dans le menu", // Français
"", // Norsk
@@ -1857,7 +1859,7 @@ const tI18nPhrase Phrases[] = {
" Symbole bei der Wiedergabe", // Deutsch
"", // Slovenski
" Mostra simboli in esecuzione",// Italiano
- "", // Nederlands
+ " Symbolen bij weergave", // Nederlands
"", // Português
" dans lecture", // Français
"", // Norsk
@@ -1879,7 +1881,7 @@ const tI18nPhrase Phrases[] = {
" Symbole bei den Meldungen", // Deutsch
"", // Slovenski
" Mostra simboli nei messaggi",// Italiano
- "", // Nederlands
+ " Symbolen bij berichten", // Nederlands
"", // Português
" dans les messages", // Français
"", // Norsk
@@ -1901,7 +1903,7 @@ const tI18nPhrase Phrases[] = {
" Symbole bei Audio", // Deutsch
"", // Slovenski
" Mostra simboli in audio", // Italiano
- "", // Nederlands
+ " Symbolen bij audio", // Nederlands
"", // Português
" dans audio", // Français
"", // Norsk
@@ -1923,7 +1925,7 @@ const tI18nPhrase Phrases[] = {
"Fonts", // Deutsch
"", // Slovenski
"Caratteri", // Italiano
- "", // Nederlands
+ "Fonts", // Nederlands
"", // Português
"Les polices", // Français
"", // Norsk
@@ -1945,9 +1947,9 @@ const tI18nPhrase Phrases[] = {
"OSD Titel", // Deutsch
"", // Slovenski
"Titolo OSD", // Italiano
- "", // Nederlands
+ "OSD titel", // Nederlands
"", // Português
- "OSD Titre", // Français
+ "Titre OSD", // Français
"", // Norsk
"Valikon otsikko", // suomi (Finnish)
"", // Polski
@@ -1967,7 +1969,7 @@ const tI18nPhrase Phrases[] = {
"Datum", // Deutsch
"", // Slovenski
"Data", // Italiano
- "", // Nederlands
+ "Datum", // Nederlands
"", // Português
"Date", // Français
"", // Norsk
@@ -1989,7 +1991,7 @@ const tI18nPhrase Phrases[] = {
"Meldungen", // Deutsch
"", // Slovenski
"Messaggi", // Italiano
- "", // Nederlands
+ "Meldingen", // Nederlands
"", // Português
"Message", // Français
"", // Norsk
@@ -2011,7 +2013,7 @@ const tI18nPhrase Phrases[] = {
"Farb-Tasten", // Deutsch
"", // Slovenski
"Tasti d'aiuto", // Italiano
- "", // Nederlands
+ "Help toetsen", // Nederlands
"", // Português
"Touche couleur", // Français
"", // Norsk
@@ -2033,9 +2035,9 @@ const tI18nPhrase Phrases[] = {
"Kanalinfo: Titel", // Deutsch
"", // Slovenski
"Info canale: titolo", // Italiano
- "", // Nederlands
+ "Kanaalinfo: titel", // Nederlands
"", // Português
- "Channel info: titre ", // Français
+ "Chaîne info: titre ", // Français
"", // Norsk
"Kanavatieto: ohjelman nimi",// suomi (Finnish)
"", // Polski
@@ -2055,9 +2057,9 @@ const tI18nPhrase Phrases[] = {
"Kanalinfo: Untertitel", // Deutsch
"", // Slovenski
"Info canale: sottotitolo", // Italiano
- "", // Nederlands
+ "Kanaalinfo: ondertitel", // Nederlands
"", // Português
- "Channel info: sous-titre", // Français
+ "Chaîne info: sous-titres", // Français
"", // Norsk
"Kanavatieto: ohjelman kuvaus", // suomi (Finnish)
"", // Polski
@@ -2077,9 +2079,9 @@ const tI18nPhrase Phrases[] = {
"Kanalinfo: Sprache", // Deutsch
"", // Slovenski
"Info canale: lingua", // Italiano
- "", // Nederlands
+ "Kanaalinfo: taal", // Nederlands
"", // Português
- "Channel info: langue", // Français
+ "Chaîne info: langue", // Français
"", // Norsk
"Kanavatieto: kieli", // suomi (Finnish)
"", // Polski
@@ -2099,7 +2101,7 @@ const tI18nPhrase Phrases[] = {
"Listen", // Deutsch
"", // Slovenski
"Elenco", // Italiano
- "", // Nederlands
+ "Lijsten", // Nederlands
"", // Português
"Liste", // Français
"", // Norsk
@@ -2121,7 +2123,7 @@ const tI18nPhrase Phrases[] = {
"Infobereich: Timer Titel", // Deutsch
"", // Slovenski
"Info area: titoli timer", // Italiano
- "", // Nederlands
+ "Infobereik: Timertitel", // Nederlands
"", // Português
"Barre d'information: Titre Progammation", // Français
"", // Norsk
@@ -2143,7 +2145,7 @@ const tI18nPhrase Phrases[] = {
"Infobereich: Timer Text", // Deutsch
"", // Slovenski
"Info area: testo timer", // Italiano
- "", // Nederlands
+ "Infobereik: Timertekst", // Nederlands
"", // Português
"Barre d'information: Text programmation", // Français
"", // Norsk
@@ -2165,7 +2167,7 @@ const tI18nPhrase Phrases[] = {
"Infobereich: Warnung Titel", // Deutsch
"", // Slovenski
"Info area: titolo avviso", // Italiano
- "", // Nederlands
+ "Infobereik: waarschuwing titel", // Nederlands
"", // Português
"Barre d'information: avertissement titre", // Français
"", // Norsk
@@ -2187,7 +2189,7 @@ const tI18nPhrase Phrases[] = {
"Infobereich: Warnung Text", // Deutsch
"", // Slovenski
"Info area: testo avviso", // Italiano
- "", // Nederlands
+ "Infobereik: waarschuwing tekst", // Nederlands
"", // Português
"Barre d'information: texte d'avertissement", // Français
"", // Norsk
@@ -2209,7 +2211,7 @@ const tI18nPhrase Phrases[] = {
"Details: Titel", // Deutsch
"", // Slovenski
"Dettagli: titolo", // Italiano
- "", // Nederlands
+ "Details: titel", // Nederlands
"", // Português
"Détails: Titre", // Français
"", // Norsk
@@ -2231,7 +2233,7 @@ const tI18nPhrase Phrases[] = {
"Details: Untertitel", // Deutsch
"", // Slovenski
"Dettagli: sottotitolo", // Italiano
- "", // Nederlands
+ "Details: ondertitel", // Nederlands
"", // Português
"Détails: Sous-titre", // Français
"", // Norsk
@@ -2253,7 +2255,7 @@ const tI18nPhrase Phrases[] = {
"Details: Datumszeile", // Deutsch
"", // Slovenski
"Dettagli: data", // Italiano
- "", // Nederlands
+ "Details: datum", // Nederlands
"", // Português
"Détails: date", // Français
"", // Norsk
@@ -2275,9 +2277,9 @@ const tI18nPhrase Phrases[] = {
"Details: Text", // Deutsch
"", // Slovenski
"Dettagli: testo", // Italiano
- "", // Nederlands
+ "Details: tekst", // Nederlands
"", // Português
- "Détails: Text", // Français
+ "Détails: Texte", // Français
"", // Norsk
"Lisätiedot: leipäteksti", // suomi (Finnish)
"", // Polski
@@ -2297,7 +2299,7 @@ const tI18nPhrase Phrases[] = {
"Wiedergabe: Zeiten", // Deutsch
"", // Slovenski
"Esecuzione: volte", // Italiano
- "", // Nederlands
+ "Weergave: tijden", // Nederlands
"", // Português
"Rejouer : périodes", // Français
"", // Norsk
@@ -2319,9 +2321,9 @@ const tI18nPhrase Phrases[] = {
"Std. OSD Font", // Deutsch
"", // Slovenski
"Carattere OSD predefinito", // Italiano
- "", // Nederlands
+ "Standaard OSDfont", // Nederlands
"", // Português
- "OSD standart", // Français
+ "OSD standard", // Français
"", // Norsk
"oletuskirjasintyyppi", // suomi (Finnish)
"", // Polski
@@ -2341,9 +2343,9 @@ const tI18nPhrase Phrases[] = {
"Std. Schrift mit fester Breite", // Deutsch
"", // Slovenski
"Carattere dimensione fissa pred.",// Italiano
- "", // Nederlands
+ "Standaardwaarde font", // Nederlands
"", // Português
- "Largeur fixe standart", // Français
+ "Largeur fixe standard", // Français
"", // Norsk
"tasavälinen kirjasintyyppi", // suomi (Finnish)
"", // Polski
@@ -2363,9 +2365,9 @@ const tI18nPhrase Phrases[] = {
"Std. kleine Schrift", // Deutsch
"", // Slovenski
"Carattere piccolo pred.", // Italiano
- "", // Nederlands
+ "Standaard klein font", // Nederlands
"", // Português
- "Petite standart", // Français
+ "Petite police standard", // Français
"", // Norsk
"pieni kirjasintyyppi", // suomi (Finnish)
"", // Polski
@@ -2385,7 +2387,7 @@ const tI18nPhrase Phrases[] = {
"Kanal:", // Deutsch
"", // Slovenski
"Canale:", // Italiano
- "", // Nederlands
+ "Kanaal:", // Nederlands
"", // Português
"Chaîne:", // Français
"", // Norsk
@@ -2407,7 +2409,7 @@ const tI18nPhrase Phrases[] = {
"Suchmuster:", // Deutsch
"", // Slovenski
"Modello di ricerca:", // Italiano
- "", // Nederlands
+ "Zoekpatroon:", // Nederlands
"", // Português
"Modèle de recherche", // Français
"", // Norsk
@@ -2429,7 +2431,7 @@ const tI18nPhrase Phrases[] = {
"Ohne Überwachung", // Deutsch
"", // Slovenski
"Nessun timer verifica", // Italiano
- "", // Nederlands
+ "Geen controle", // Nederlands
"", // Português
"Sans surveillance", // Français
"", // Norsk
@@ -2451,7 +2453,7 @@ const tI18nPhrase Phrases[] = {
"Allgemein", // Deutsch
"", // Slovenski
"Generale", // Italiano
- "", // Nederlands
+ "Algemeen", // Nederlands
"", // Português
"Généralité", // Français
"", // Norsk
@@ -2473,7 +2475,7 @@ const tI18nPhrase Phrases[] = {
"Name", // Deutsch
"", // Slovenski
"Nome", // Italiano
- "", // Nederlands
+ "Naam", // Nederlands
"", // Português
"Nom", // Français
"", // Norsk
@@ -2495,7 +2497,7 @@ const tI18nPhrase Phrases[] = {
"Weite", // Deutsch
"", // Slovenski
"Larghezza", // Italiano
- "", // Nederlands
+ "Breedte", // Nederlands
"", // Português
"Largeur", // Français
"", // Norsk
@@ -2517,7 +2519,7 @@ const tI18nPhrase Phrases[] = {
"Ändern", // Deutsch
"", // Slovenski
"Imposta", // Italiano
- "", // Nederlands
+ "Veranderen", // Nederlands
"", // Português
"Changer", // Français
"", // Norsk
@@ -2539,7 +2541,7 @@ const tI18nPhrase Phrases[] = {
"TrueType Schrift", // Deutsch
"", // Slovenski
"Carattere TrueType", // Italiano
- "", // Nederlands
+ "TrueType Font", // Nederlands
"", // Português
"TrueType", // Français
"", // Norsk
@@ -2561,7 +2563,7 @@ const tI18nPhrase Phrases[] = {
"TTF nicht unterstützt!", // Deutsch
"", // Slovenski
"Nessun supporto TTF!", // Italiano
- "", // Nederlands
+ "TTF niet ondersteund!", // Nederlands
"", // Português
"Les polices TrueType ne sont pas supportées!", // Français
"", // Norsk
@@ -2583,9 +2585,9 @@ const tI18nPhrase Phrases[] = {
"Schrift mit fester Breite", // Deutsch
"", // Slovenski
"Carattere fisso", // Italiano
- "", // Nederlands
+ "Vaste waarde font", // Nederlands
"", // Português
- "", // Français
+ "Police avec une largeur fixe", // Français
"", // Norsk
"Tasavälinen kirjasintyyppi", // suomi (Finnish)
"", // Polski
@@ -2606,9 +2608,9 @@ const tI18nPhrase Phrases[] = {
"Dynamische OSD-Größe", // Deutsch
"", // Slovenski
"Dimensione OSD dinamica", // Italiano
- "", // Nederlands
+ "Dynamisch OSDgrootte", // Nederlands
"", // Português
- "", // Français
+ "Taille OSD dynamique", // Français
"", // Norsk
"Vaihtuva kuvaruutunäytön koko", // suomi (Finnish)
"", // Polski
@@ -2628,10 +2630,10 @@ const tI18nPhrase Phrases[] = {
{"No TrueType fonts installed!", // English
"Keine TrueType Schriften installiert!", // Deutsch
"", // Slovenski
- "", // Italiano
- "", // Nederlands
+ "Nessun carattere TrueType installato!", // Italiano
+ "Geen TrueType fonten geinstalleerd!", // Nederlands
"", // Português
- "", // Français
+ "Il n'y a pas de police TrueType d'installé!", // Français
"", // Norsk
"TrueType-kirjasintyyppejä ei löydy!", // suomi (Finnish)
"", // Polski
diff --git a/skinenigmang.c b/skinenigmang.c
index 8d4d86c..5e207ea 100644
--- a/skinenigmang.c
+++ b/skinenigmang.c
@@ -24,7 +24,7 @@
#warning "YOU NEED A PATCHED VDR 1.5.3 OR EnigmaNG WILL CRASH!"
#endif
-static const char VERSION[] = "0.0.5rc3";
+static const char VERSION[] = "0.0.5";
static const char DESCRIPTION[] = "EnigmaNG skin";
class cPluginSkinEnigma : public cPlugin {
diff --git a/texteffects.c b/texteffects.c
index 323a6c1..6f9e320 100644
--- a/texteffects.c
+++ b/texteffects.c
@@ -138,12 +138,13 @@ void cEnigmaTextEffects::DoEffect(tEffect *e, uint64_t nNow)
void cEnigmaTextEffects::DoScroll(tEffect *e, uint64_t nNow, bool fDrawItem)
{
// debug("cEnigmaTextEffects::DoScroll()");
- if (e->Font->Width(e->strText.c_str()) <= e->Width) {
+ const cFont *Font = EnigmaConfig.GetFont(e->FontId, e->Font);
+ if (Font->Width(e->strText.c_str()) <= e->Width) {
if (fDrawItem) {
if (e->Skin)
e->Skin->DrawTitle(e->strText.c_str());
else
- osd->DrawText(e->x, e->y, e->strText.c_str(), e->ColorFg, e->ColorBg, e->Font, e->Width, e->Height, e->Alignment);
+ osd->DrawText(e->x, e->y, e->strText.c_str(), e->ColorFg, e->ColorBg, Font, e->Width, e->Height, e->Alignment);
}
if (nNow)
@@ -156,7 +157,7 @@ void cEnigmaTextEffects::DoScroll(tEffect *e, uint64_t nNow, bool fDrawItem)
if (fDrawItem) {
switch (e->nDirection) {
case 0: // Scroll from left to right
- if (e->Font->Width(e->strText.c_str() + e->nOffset) <= e->Width) {
+ if (Font->Width(e->strText.c_str() + e->nOffset) <= e->Width) {
if (EnigmaConfig.scrollMode)
e->nDirection = 2;
else
@@ -186,26 +187,27 @@ void cEnigmaTextEffects::DoScroll(tEffect *e, uint64_t nNow, bool fDrawItem)
}
if (fDrawItem) {
-// printf("SCROLL: %d %d %d/%d (%s) %d %lu %lu\n", e->nOffset, e->nDirection, e->Font->Width(e->strText.c_str() + e->nOffset), e->Width, e->strText.c_str() + e->nOffset, e->strText.length(), nNow, e->nNextUpdate);
+// printf("SCROLL: %d %d %d/%d (%s) %d %lu %lu\n", e->nOffset, e->nDirection, Font->Width(e->strText.c_str() + e->nOffset), e->Width, e->strText.c_str() + e->nOffset, e->strText.length(), nNow, e->nNextUpdate);
if (e->Skin)
e->Skin->DrawTitle(e->strText.c_str() + e->nOffset);
else
- osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorFg, e->ColorBg, e->Font, e->Width, e->Height);
+ osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorFg, e->ColorBg, Font, e->Width, e->Height);
}
}
void cEnigmaTextEffects::DoBlink(tEffect *e, uint64_t nNow, bool fDrawItem)
{
// debug("cEnigmaTextEffects::DoBlink()");
+ const cFont *Font = EnigmaConfig.GetFont(e->FontId, e->Font);
if (fDrawItem) {
if (nNow) {
e->nDirection = (e->nDirection == 0 ? 1 : 0);
e->nNextUpdate = nNow + EnigmaConfig.blinkPause;
}
if (e->nDirection == 1)
- osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorFg, e->ColorBg, e->Font, e->Width, e->Height, e->Alignment);
+ osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorFg, e->ColorBg, Font, e->Width, e->Height, e->Alignment);
else
- osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorBg, e->ColorBg, e->Font, e->Width, e->Height, e->Alignment);
+ osd->DrawText(e->x, e->y, e->strText.c_str() + e->nOffset, e->ColorBg, e->ColorBg, Font, e->Width, e->Height, e->Alignment);
} else {
e->nNextUpdate = nNow + EnigmaConfig.blinkPause;
}
@@ -280,11 +282,13 @@ void cEnigmaTextEffects::ResetText(int i, tColor ColorFg, tColor ColorBg, bool f
tEffect *e = vecEffects[i];
if (e) {
- if (fDraw && osd)
+ if (fDraw && osd) {
+ const cFont *Font = EnigmaConfig.GetFont(e->FontId, e->Font);
osd->DrawText(e->x, e->y, e->strText.c_str(),
ColorFg ? ColorFg : e->ColorFg,
ColorBg ? ColorBg : e->ColorBg,
- e->Font, e->Width, e->Height);
+ Font, e->Width, e->Height);
+ }
delete(e);
vecEffects[i] = NULL;
}
@@ -307,11 +311,11 @@ void cEnigmaTextEffects::UpdateTextWidth(int i, int Width)
}
}
-int cEnigmaTextEffects::DrawAnimatedTitle(int o_id, int action, const char *s, const cFont *Font, int Width, cSkinEnigmaOsd *skin)
+int cEnigmaTextEffects::DrawAnimatedTitle(int o_id, int action, const char *s, int Width, cSkinEnigmaOsd *skin)
{
//Must be TE_LOCKed by caller
- if (Font == NULL || osd == NULL || skin == NULL)
+ if (osd == NULL || skin == NULL)
return -1;
debug("cEnigmaTextEffects::DrawAnimatedTitle(%d, %d, %s)", o_id, EnigmaConfig.useTextEffects, s);
@@ -334,6 +338,7 @@ int cEnigmaTextEffects::DrawAnimatedTitle(int o_id, int action, const char *s, c
}
} else {
skin->DrawTitle(s);
+ const cFont *Font = EnigmaConfig.GetFont(FONT_OSDTITLE);
if (EnigmaConfig.useTextEffects && ((Font->Width(s ? s : "") > Width) || (action > 0))) {
// New scrolling text
tEffect *effect = new tEffect;
@@ -344,6 +349,7 @@ int cEnigmaTextEffects::DrawAnimatedTitle(int o_id, int action, const char *s, c
effect->nAction = action;
effect->strText = std::string(s ? s : "");
effect->Width = Width;
+ effect->FontId = FONT_OSDTITLE;;
effect->Font = Font;
effect->Skin = skin;
vecEffects.push_back(effect);
@@ -354,11 +360,11 @@ int cEnigmaTextEffects::DrawAnimatedTitle(int o_id, int action, const char *s, c
}
}
-int cEnigmaTextEffects::DrawAnimatedText(int o_id, int action, int x, int y, const char *s, tColor ColorFg, tColor ColorBg, const cFont *Font, int Width, int Height, int Alignment)
+int cEnigmaTextEffects::DrawAnimatedText(int o_id, int action, int x, int y, const char *s, tColor ColorFg, tColor ColorBg, int FontId, int Width, int Height, int Alignment)
{
//Must be TE_LOCKed by caller
- if (Font == NULL || osd == NULL)
+ if (osd == NULL)
return -1;
debug("cEnigmaTextEffects::DrawAnimatedText(%d, %d, %s)", o_id, EnigmaConfig.useTextEffects, s);
@@ -380,6 +386,7 @@ int cEnigmaTextEffects::DrawAnimatedText(int o_id, int action, int x, int y, con
return -1;
}
} else {
+ const cFont *Font = EnigmaConfig.GetFont(FontId);
if (Height == 0)
Height = Font->Height(s);
osd->DrawText(x, y, s ? s : "", ColorFg, ColorBg, Font, Width, Height, Alignment);
@@ -397,6 +404,7 @@ int cEnigmaTextEffects::DrawAnimatedText(int o_id, int action, int x, int y, con
effect->Height = Height;
effect->ColorFg = ColorFg;
effect->ColorBg = ColorBg;
+ effect->FontId = FontId;
effect->Font = Font;
effect->Alignment = Alignment;
vecEffects.push_back(effect);
diff --git a/texteffects.h b/texteffects.h
index 5f1d61d..0eda97e 100644
--- a/texteffects.h
+++ b/texteffects.h
@@ -25,7 +25,7 @@
#define TE_WAKEUP ;
#define TE_MARQUEE(osd, id, x...) osd->DrawText(x)
#define TE_BLINK(osd, id, x...) osd->DrawText(x)
-#define TE_TITLE(osd, id, s, Font, Width, skin) osd->DrawTitle(s)
+#define TE_TITLE(osd, id, s, Width, skin) osd->DrawTitle(s)
#else // !DISABLE_ANIMATED_TEXT
#include <vdr/thread.h>
@@ -65,6 +65,7 @@ private:
std::string strText;
int x, y, Width, Height;
tColor ColorFg, ColorBg;
+ int FontId;
const cFont *Font;
int Alignment;
cSkinEnigmaOsd *Skin;
@@ -72,8 +73,8 @@ private:
public:
tEffect(void) : nAction(0), nOffset(0), nDirection(0),
nNextUpdate(0), x(0), y(0), Width(0), Height(0),
- ColorFg(0), ColorBg(0), Font(NULL), Alignment(taDefault),
- Skin(NULL)
+ ColorFg(0), ColorBg(0), FontId(fontOsd + 1), Font(NULL),
+ Alignment(taDefault), Skin(NULL)
{};
};
@@ -115,8 +116,8 @@ public:
void ResetText(int i, tColor ColorFg = 0, tColor ColorBg = 0, bool fDraw = true);
void PauseEffects(int y = 0);
void UpdateTextWidth(int i, int Width);
- int DrawAnimatedTitle(int o_id, int action, const char *s, const cFont *Font, int Width, cSkinEnigmaOsd *skin);
- int DrawAnimatedText(int o_id, int action, int x, int y, const char *s, tColor ColorFg, tColor ColorBg, const cFont *Font, int Width = 0, int Height = 0, int Alignment = taDefault);
+ int DrawAnimatedTitle(int o_id, int action, const char *s, int Width, cSkinEnigmaOsd *skin);
+ int DrawAnimatedText(int o_id, int action, int x, int y, const char *s, tColor ColorFg, tColor ColorBg, int FontId, int Width = 0, int Height = 0, int Alignment = taDefault);
void UpdateLock(void)
{