summaryrefslogtreecommitdiff
path: root/skinclassic.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-02-05 15:09:51 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2006-02-05 15:09:51 +0100
commitc5a5f098453635e142f936de0b2d3378517d3fc2 (patch)
treebd9cc5df1e73d6efb6da82887d60884fa2378982 /skinclassic.c
parent36b720b1cfc3e21acafc543bed68bb67197b9b33 (diff)
downloadvdr-c5a5f098453635e142f936de0b2d3378517d3fc2.tar.gz
vdr-c5a5f098453635e142f936de0b2d3378517d3fc2.tar.bz2
Added cSkin::GetTextAreaWidth() and cSkin::GetTextAreaFont()1.3.42
Diffstat (limited to 'skinclassic.c')
-rw-r--r--skinclassic.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/skinclassic.c b/skinclassic.c
index 18851a8e..f471b303 100644
--- a/skinclassic.c
+++ b/skinclassic.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: skinclassic.c 1.13 2006/01/01 14:37:58 kls Exp $
+ * $Id: skinclassic.c 1.14 2006/02/05 14:51:39 kls Exp $
*/
#include "skinclassic.h"
@@ -169,6 +169,8 @@ public:
virtual void SetEvent(const cEvent *Event);
virtual void SetRecording(const cRecording *Recording);
virtual void SetText(const char *Text, bool FixedFont);
+ virtual int GetTextAreaWidth(void) const;
+ virtual const cFont *GetTextAreaFont(bool FixedFont) const;
virtual void Flush(void);
};
@@ -357,11 +359,20 @@ void cSkinClassicDisplayMenu::SetRecording(const cRecording *Recording)
void cSkinClassicDisplayMenu::SetText(const char *Text, bool FixedFont)
{
- const cFont *font = cFont::GetFont(FixedFont ? fontFix : fontOsd);
- textScroller.Set(osd, x0, y2, x1 - x0 - 2 * ScrollWidth, y3 - y2, Text, font, Theme.Color(clrMenuText), Theme.Color(clrBackground));
+ textScroller.Set(osd, x0, y2, GetTextAreaWidth(), y3 - y2, Text, GetTextAreaFont(FixedFont), Theme.Color(clrMenuText), Theme.Color(clrBackground));
SetScrollbar();
}
+int cSkinClassicDisplayMenu::GetTextAreaWidth(void) const
+{
+ return x1 - x0 - 2 * ScrollWidth;
+}
+
+const cFont *cSkinClassicDisplayMenu::GetTextAreaFont(bool FixedFont) const
+{
+ return cFont::GetFont(FixedFont ? fontFix : fontOsd);
+}
+
void cSkinClassicDisplayMenu::Flush(void)
{
cString date = DayDateTime();