mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-14 06:42:58 +08:00
fix drawing images with 1 px height or width
This commit is contained in:
parent
5566935a5d
commit
d99ea10213
@ -13,6 +13,7 @@
|
||||
- Add rounding to btnmatrix line height calculation
|
||||
- Add `decmopr_buf` to GC roots
|
||||
- Fix divisioin by zero in draw_pattern (lv_draw_rect.c) if the image or letter is not found
|
||||
- Fix drawing images with 1 px height or width
|
||||
|
||||
## v7.4.0 (01.09.2020)
|
||||
|
||||
|
@ -706,10 +706,10 @@ static lv_design_res_t lv_img_design(lv_obj_t * img, const lv_area_t * clip_area
|
||||
coords_tmp.y1 = zommed_coords.y1;
|
||||
coords_tmp.y2 = zommed_coords.y1 + ext->h - 1;
|
||||
|
||||
for(; coords_tmp.y1 < zommed_coords.y2; coords_tmp.y1 += zoomed_src_h, coords_tmp.y2 += zoomed_src_h) {
|
||||
for(; coords_tmp.y1 <= zommed_coords.y2; coords_tmp.y1 += zoomed_src_h, coords_tmp.y2 += zoomed_src_h) {
|
||||
coords_tmp.x1 = zommed_coords.x1;
|
||||
coords_tmp.x2 = zommed_coords.x1 + ext->w - 1;
|
||||
for(; coords_tmp.x1 < zommed_coords.x2; coords_tmp.x1 += zoomed_src_w, coords_tmp.x2 += zoomed_src_w) {
|
||||
for(; coords_tmp.x1 <= zommed_coords.x2; coords_tmp.x1 += zoomed_src_w, coords_tmp.x2 += zoomed_src_w) {
|
||||
lv_draw_img(&coords_tmp, &clip_real, ext->src, &img_dsc);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user