summaryrefslogtreecommitdiff
path: root/apps/plugins/lib/display_text.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins/lib/display_text.c')
-rw-r--r--apps/plugins/lib/display_text.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/apps/plugins/lib/display_text.c b/apps/plugins/lib/display_text.c
index 90712a649f..5f37b736df 100644
--- a/apps/plugins/lib/display_text.c
+++ b/apps/plugins/lib/display_text.c
@@ -39,9 +39,7 @@ static bool wait_key_press(void)
39bool display_text(unsigned short words, char** text, struct style_text* style, 39bool display_text(unsigned short words, char** text, struct style_text* style,
40 struct viewport* vp_text, bool wait_key) 40 struct viewport* vp_text, bool wait_key)
41{ 41{
42#ifdef HAVE_LCD_BITMAP
43 int prev_drawmode; 42 int prev_drawmode;
44#endif
45#ifdef HAVE_LCD_COLOR 43#ifdef HAVE_LCD_COLOR
46 int standard_fgcolor; 44 int standard_fgcolor;
47#endif 45#endif
@@ -55,10 +53,8 @@ bool display_text(unsigned short words, char** text, struct style_text* style,
55 vp_height = vp_text->height; 53 vp_height = vp_text->height;
56 } 54 }
57 rb->screens[SCREEN_MAIN]->set_viewport(vp_text); 55 rb->screens[SCREEN_MAIN]->set_viewport(vp_text);
58#ifdef HAVE_LCD_BITMAP
59 prev_drawmode = rb->lcd_get_drawmode(); 56 prev_drawmode = rb->lcd_get_drawmode();
60 rb->lcd_set_drawmode(DRMODE_SOLID); 57 rb->lcd_set_drawmode(DRMODE_SOLID);
61#endif
62#ifdef HAVE_LCD_COLOR 58#ifdef HAVE_LCD_COLOR
63 standard_fgcolor = rb->lcd_get_foreground(); 59 standard_fgcolor = rb->lcd_get_foreground();
64#endif 60#endif
@@ -121,11 +117,9 @@ bool display_text(unsigned short words, char** text, struct style_text* style,
121#endif 117#endif
122 rb->lcd_putsxy(x, y, text[i]); 118 rb->lcd_putsxy(x, y, text[i]);
123 /* underline the word */ 119 /* underline the word */
124#ifdef HAVE_LCD_BITMAP
125 if (style[style_index].flags&TEXT_UNDERLINE) { 120 if (style[style_index].flags&TEXT_UNDERLINE) {
126 rb->lcd_hline(x, x+width, y+height-1); 121 rb->lcd_hline(x, x+width, y+height-1);
127 } 122 }
128#endif
129#ifdef HAVE_LCD_COLOR 123#ifdef HAVE_LCD_COLOR
130 rb->lcd_set_foreground(standard_fgcolor); 124 rb->lcd_set_foreground(standard_fgcolor);
131#endif 125#endif
@@ -134,9 +128,7 @@ bool display_text(unsigned short words, char** text, struct style_text* style,
134 x += width + space_w; 128 x += width + space_w;
135 } 129 }
136 rb->screens[SCREEN_MAIN]->update_viewport(); 130 rb->screens[SCREEN_MAIN]->update_viewport();
137#ifdef HAVE_LCD_BITMAP
138 rb->lcd_set_drawmode(prev_drawmode); 131 rb->lcd_set_drawmode(prev_drawmode);
139#endif
140 if (wait_key) 132 if (wait_key)
141 { 133 {
142 if (wait_key_press()) 134 if (wait_key_press())