summaryrefslogtreecommitdiff
path: root/dvbapi.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2000-11-05 13:04:23 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2000-11-05 13:04:23 +0100
commitea0bd668c8326a90cc4727004780abe14bab1edc (patch)
tree668685e52e23210bdfb6c977eb6ed3b3794209c7 /dvbapi.c
parent88253cfba73ed92f85af7be47b5d05f88226859b (diff)
downloadvdr-ea0bd668c8326a90cc4727004780abe14bab1edc.tar.gz
vdr-ea0bd668c8326a90cc4727004780abe14bab1edc.tar.bz2
Date and time in the title of an event info page are now always right adjusted
Diffstat (limited to 'dvbapi.c')
-rw-r--r--dvbapi.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/dvbapi.c b/dvbapi.c
index cc246d2f..a2fa9dcb 100644
--- a/dvbapi.c
+++ b/dvbapi.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbapi.c 1.34 2000/11/01 09:19:27 kls Exp $
+ * $Id: dvbapi.c 1.35 2000/11/05 13:04:23 kls Exp $
*/
#include "dvbapi.h"
@@ -1616,6 +1616,15 @@ int cDvbApi::Width(unsigned char c)
#endif
}
+int cDvbApi::WidthInCells(const char *s)
+{
+#ifdef DEBUG_OSD
+ return strlen(s);
+#else
+ return (osd->Width(s) + charWidth - 1) / charWidth;
+#endif
+}
+
void cDvbApi::Text(int x, int y, const char *s, eDvbColor colorFg, eDvbColor colorBg)
{
if (x < 0) x = cols + x;