summaryrefslogtreecommitdiff
path: root/apps/plugins/text_viewer/tv_display.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins/text_viewer/tv_display.h')
-rw-r--r--apps/plugins/text_viewer/tv_display.h57
1 files changed, 27 insertions, 30 deletions
diff --git a/apps/plugins/text_viewer/tv_display.h b/apps/plugins/text_viewer/tv_display.h
index aa30436c4c..67709f825d 100644
--- a/apps/plugins/text_viewer/tv_display.h
+++ b/apps/plugins/text_viewer/tv_display.h
@@ -24,7 +24,29 @@
24#include "plugin.h" 24#include "plugin.h"
25#include "tv_screen_pos.h" 25#include "tv_screen_pos.h"
26 26
27/* text viewer layout parts functions */ 27/* stuff for the screen access */
28
29/*
30 * initialize the display module
31 *
32 * [In/Out] buf
33 * the start pointer of the buffer
34 *
35 * [In/Out] size
36 * buffer size
37 *
38 * return
39 * true initialize success
40 * false initialize failure
41 */
42bool tv_init_display(unsigned char **buf, size_t *size);
43
44/* finalize the display module */
45void tv_finalize_display(void);
46
47
48/* layout parts accessing functions */
49
28#ifdef HAVE_LCD_BITMAP 50#ifdef HAVE_LCD_BITMAP
29 51
30/* show headaer */ 52/* show headaer */
@@ -66,7 +88,6 @@ void tv_init_scrollbar(off_t total, bool show_scrollbar);
66 * the size of text in displayed. 88 * the size of text in displayed.
67 */ 89 */
68void tv_show_scrollbar(int window, int col, off_t cur_pos, int size); 90void tv_show_scrollbar(int window, int col, off_t cur_pos, int size);
69#endif
70 91
71/* 92/*
72 * show bookmark 93 * show bookmark
@@ -79,10 +100,9 @@ void tv_show_scrollbar(int window, int col, off_t cur_pos, int size);
79 */ 100 */
80void tv_show_bookmarks(const int *rows, int count); 101void tv_show_bookmarks(const int *rows, int count);
81 102
82/* common display functons */ 103#endif
83 104
84/* initialized display functions */ 105/* common display functons */
85void tv_init_display(void);
86 106
87/* start the display processing */ 107/* start the display processing */
88void tv_start_display(void); 108void tv_start_display(void);
@@ -107,32 +127,17 @@ void tv_update_display(void);
107 */ 127 */
108void tv_draw_text(int row, const unsigned char *text, int offset); 128void tv_draw_text(int row, const unsigned char *text, int offset);
109 129
130
110/* layout functions */ 131/* layout functions */
111#ifdef HAVE_LCD_BITMAP
112 132
113/* 133/*
114 * set the layout 134 * set the layout
115 * 135 *
116 * [In] col_w
117 * width per column
118 *
119 * [In] show_scrollbar 136 * [In] show_scrollbar
120 * true: show the vertical scrollbar 137 * true: show the vertical scrollbar
121 * false: does not show the vertical scrollbar 138 * false: does not show the vertical scrollbar
122 */ 139 */
123void tv_set_layout(int col_w, bool show_scrollbar); 140void tv_set_layout(bool show_scrollbar);
124
125#else
126
127/*
128 * set the layout
129 *
130 * [In] col_w
131 * width per column
132 */
133void tv_set_layout(int col_w);
134
135#endif
136 141
137/* 142/*
138 * get the draw area info 143 * get the draw area info
@@ -148,12 +153,4 @@ void tv_set_layout(int col_w);
148 */ 153 */
149void tv_get_drawarea_info(int *width, int *cols, int *rows); 154void tv_get_drawarea_info(int *width, int *cols, int *rows);
150 155
151/* viewport functions */
152
153/* change the viewport */
154void tv_change_viewport(void);
155
156/* undo the viewport */
157void tv_undo_viewport(void);
158
159#endif 156#endif