fix color bleeding on border drawing
Fixes https://forum.lvgl.io/t/border-dont-cover-calendar/3029/4
This commit is contained in:
@@ -3801,7 +3801,7 @@ static lv_design_res_t lv_obj_design(lv_obj_t * obj, const lv_area_t * clip_area
|
||||
lv_draw_rect_dsc_init(&draw_dsc);
|
||||
/*If the border is drawn later disable loading its properties*/
|
||||
if(lv_obj_get_style_border_post(obj, LV_OBJ_PART_MAIN)) {
|
||||
draw_dsc.border_opa = LV_OPA_TRANSP;
|
||||
draw_dsc.border_post = 1;
|
||||
}
|
||||
|
||||
lv_obj_init_draw_rect_dsc(obj, LV_OBJ_PART_MAIN, &draw_dsc);
|
||||
|
||||
@@ -391,6 +391,7 @@ LV_ATTRIBUTE_FAST_MEM static void draw_border(const lv_area_t * coords, const lv
|
||||
if(dsc->border_opa <= LV_OPA_MIN) return;
|
||||
if(dsc->border_width == 0) return;
|
||||
if(dsc->border_side == LV_BORDER_SIDE_NONE) return;
|
||||
if(dsc->border_post) return;
|
||||
|
||||
int32_t coords_w = lv_area_get_width(coords);
|
||||
int32_t coords_h = lv_area_get_height(coords);
|
||||
|
||||
@@ -41,6 +41,7 @@ typedef struct {
|
||||
lv_style_int_t border_side;
|
||||
lv_opa_t border_opa;
|
||||
lv_blend_mode_t border_blend_mode;
|
||||
uint8_t border_post :1; /*There is a border it will be drawn later. */
|
||||
|
||||
/*Outline*/
|
||||
lv_color_t outline_color;
|
||||
|
||||
Reference in New Issue
Block a user