summaryrefslogtreecommitdiff
path: root/apps/gui/viewport.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/gui/viewport.h')
-rw-r--r--apps/gui/viewport.h44
1 files changed, 25 insertions, 19 deletions
diff --git a/apps/gui/viewport.h b/apps/gui/viewport.h
index d431766ab5..9cabc00468 100644
--- a/apps/gui/viewport.h
+++ b/apps/gui/viewport.h
@@ -66,6 +66,7 @@ void viewport_set_defaults(struct viewport *vp, enum screen_type screen);
66#define VP_SB_IGNORE_SETTING(screen) BIT_N(4+screen) 66#define VP_SB_IGNORE_SETTING(screen) BIT_N(4+screen)
67#define VP_SB_ALLSCREENS (VP_SB_ONSCREEN(0)|VP_SB_ONSCREEN(1)) 67#define VP_SB_ALLSCREENS (VP_SB_ONSCREEN(0)|VP_SB_ONSCREEN(1))
68 68
69#ifndef __PCTOOL__
69/* 70/*
70 * Initialize the viewportmanager, which in turns initializes the UI vp and 71 * Initialize the viewportmanager, which in turns initializes the UI vp and
71 * statusbar stuff 72 * statusbar stuff
@@ -86,25 +87,6 @@ void viewport_set_fullscreen(struct viewport *vp, enum screen_type screen);
86#ifdef HAVE_LCD_BITMAP 87#ifdef HAVE_LCD_BITMAP
87 88
88/* 89/*
89 * Parse a viewport definition (vp_def), which looks like:
90 *
91 * Screens with depth > 1:
92 * X|Y|width|height|font|foregorund color|background color
93 * Screens with depth = 1:
94 * X|Y|width|height|font
95 *
96 * | is a separator and can be specified via the parameter
97 *
98 * Returns the pointer to the char after the last character parsed
99 * if everything went OK or NULL if an error happened (some values
100 * not specified in the definition)
101 */
102const char* viewport_parse_viewport(struct viewport *vp,
103 enum screen_type screen,
104 const char *vp_def,
105 const char separator);
106
107/*
108 * Returns a pointer to the current viewport 90 * Returns a pointer to the current viewport
109 * - That could be the UI vp, or a viewport passed to do_menu() or the like 91 * - That could be the UI vp, or a viewport passed to do_menu() or the like
110 */ 92 */
@@ -129,4 +111,28 @@ bool viewport_point_within_vp(const struct viewport *vp, int x, int y);
129#define viewport_set_current_vp(a) 111#define viewport_set_current_vp(a)
130#define viewport_get_current_vp() NULL 112#define viewport_get_current_vp() NULL
131#endif 113#endif
114
115#endif /* __PCTOOL__ */
116
117#ifdef HAVE_LCD_BITMAP
118
119/*
120 * Parse a viewport definition (vp_def), which looks like:
121 *
122 * Screens with depth > 1:
123 * X|Y|width|height|font|foregorund color|background color
124 * Screens with depth = 1:
125 * X|Y|width|height|font
126 *
127 * | is a separator and can be specified via the parameter
128 *
129 * Returns the pointer to the char after the last character parsed
130 * if everything went OK or NULL if an error happened (some values
131 * not specified in the definition)
132 */
133const char* viewport_parse_viewport(struct viewport *vp,
134 enum screen_type screen,
135 const char *vp_def,
136 const char separator);
137#endif /* HAVE_LCD_BITMAP */
132#endif /* __VIEWPORT_H__ */ 138#endif /* __VIEWPORT_H__ */