summaryrefslogtreecommitdiff
path: root/firmware/export
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2009-10-11 12:21:27 +0000
committerThomas Martitz <kugel@rockbox.org>2009-10-11 12:21:27 +0000
commita79dc877615c2af571bf0416dd2867c000701e7e (patch)
tree20be2176756c12d56d4e1947a05c2331fe1666ca /firmware/export
parente171294c1d50dc4e4ba30339940a854c2b82d1ea (diff)
downloadrockbox-a79dc877615c2af571bf0416dd2867c000701e7e.tar.gz
rockbox-a79dc877615c2af571bf0416dd2867c000701e7e.zip
Add a center flag, next to the rtl flag, for viewports. That results in any text being drawn centered. It overrides the RTL flag if set.
Simplify splashes and time menu by using it. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23105 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/export')
-rw-r--r--firmware/export/lcd.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/firmware/export/lcd.h b/firmware/export/lcd.h
index 2c66b5f8b3..463714ff03 100644
--- a/firmware/export/lcd.h
+++ b/firmware/export/lcd.h
@@ -26,9 +26,13 @@
26#include "cpu.h" 26#include "cpu.h"
27#include "config.h" 27#include "config.h"
28 28
29#define VP_FLAG_IS_RTL 0x01 29#define VP_FLAG_IS_RTL 0x01
30#define VP_FLAG_CENTER_ALIGN 0x02
30 31
31#define VP_IS_RTL(vp) (((vp)->flags & VP_FLAG_IS_RTL) != 0) 32#define VP_FLAG_ALIGNMENT_MASK \
33 (VP_FLAG_IS_RTL|VP_FLAG_CENTER_ALIGN)
34
35#define VP_IS_RTL(vp) (((vp)->flags & VP_FLAG_ALIGNMENT_MASK) == VP_FLAG_IS_RTL)
32 36
33struct viewport { 37struct viewport {
34 int x; 38 int x;