@@ -106,10 +106,10 @@ static void fontgroup_drawwchar(font_group_t *group, const font_t *fnt_default,
106
106
static void fontgroup_drawstring (font_group_t *group, const font_t *fnt_default, const char *utf8_msg, read_byte_cb_t cb_read_byte, void * userdata, fontgroup_cb_draw_t cb_draw_ram) {
107
107
const uint8_t *p = (uint8_t *)utf8_msg;
108
108
for (;;) {
109
- lchar_t ch ;
110
- p = get_utf8_value_cb (p, cb_read_byte, ch );
111
- if (!ch ) break ;
112
- fontgroup_drawwchar (group, fnt_default, ch , userdata, cb_draw_ram);
109
+ lchar_t wc ;
110
+ p = get_utf8_value_cb (p, cb_read_byte, wc );
111
+ if (!wc ) break ;
112
+ fontgroup_drawwchar (group, fnt_default, wc , userdata, cb_draw_ram);
113
113
}
114
114
}
115
115
@@ -154,14 +154,14 @@ static int fontgroup_cb_draw_u8g(void *userdata, const font_t *fnt_current, cons
154
154
* @param pu8g : U8G pointer
155
155
* @param x : position x axis
156
156
* @param y : position y axis
157
- * @param ch : the lchar_t
157
+ * @param wc : the lchar_t
158
158
* @param max_width : the pixel width of the string allowed
159
159
*
160
160
* @return number of pixels advanced
161
161
*
162
162
* Draw a UTF-8 string at the specified position
163
163
*/
164
- unsigned int uxg_DrawWchar (u8g_t *pu8g, unsigned int x, unsigned int y, const lchar_t &ch , pixel_len_t max_width) {
164
+ unsigned int uxg_DrawWchar (u8g_t *pu8g, unsigned int x, unsigned int y, const lchar_t &wc , pixel_len_t max_width) {
165
165
struct _uxg_drawu8_data_t data;
166
166
font_group_t *group = &g_fontgroup_root;
167
167
const font_t *fnt_default = uxg_GetFont (pu8g);
@@ -176,7 +176,7 @@ unsigned int uxg_DrawWchar(u8g_t *pu8g, unsigned int x, unsigned int y, const lc
176
176
data.adv = 0 ;
177
177
data.max_width = max_width;
178
178
data.fnt_prev = nullptr ;
179
- fontgroup_drawwchar (group, fnt_default, ch , (void *)&data, fontgroup_cb_draw_u8g);
179
+ fontgroup_drawwchar (group, fnt_default, wc , (void *)&data, fontgroup_cb_draw_u8g);
180
180
u8g_SetFont (pu8g, (const u8g_fntpgm_uint8_t *)fnt_default);
181
181
182
182
return data.adv ;
0 commit comments