1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-28 07:03:00 +08:00

Merge pull request #1111 from gsar-rez/dev-6.0

lv_draw_basic: use uint16_t for letter width
This commit is contained in:
Gabor Kiss-Vamosi 2019-06-21 23:16:30 +02:00 committed by GitHub
commit 65d9dc503d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -286,7 +286,7 @@ void lv_draw_letter(const lv_point_t * pos_p, const lv_area_t * mask_p, const lv
uint8_t width_byte_scr = g.box_w >> 3; /*Width in bytes (on the screen finally) (e.g. w = 11 -> 2 bytes wide)*/
if(g.box_w & 0x7) width_byte_scr++;
uint8_t width_bit = g.box_w * g.bpp; /*Letter width in bits*/
uint16_t width_bit = g.box_w * g.bpp; /*Letter width in bits*/
/* Calculate the col/row start/end on the map*/
lv_coord_t col_start = pos_x >= mask_p->x1 ? 0 : mask_p->x1 - pos_x;