feat(label): added animation style property to apply it to circular scrolling animation of label widget (#3128)
* feat(label): added animation style property to apply it to circular scrolling animation of label widget Added an animation style property to be used as animation template for different use cases in different widgets. This commit implements using this property to set the start and repeat delay of the circular scrolling animation of the label widget. Closes #3097 * fix(label): changed animation style property's var_type to `const lv_anim_t *` * example(label): added example showing how to customize circular scrolling animation * chore(label): ran code-format.py and added missing function prototype to lv_example_widgets.h
This commit is contained in:
@@ -680,6 +680,14 @@ void lv_style_set_color_filter_opa(lv_style_t * style, lv_opa_t value)
|
||||
lv_style_set_prop(style, LV_STYLE_COLOR_FILTER_OPA, v);
|
||||
}
|
||||
|
||||
void lv_style_set_anim(lv_style_t * style, const lv_anim_t * value)
|
||||
{
|
||||
lv_style_value_t v = {
|
||||
.ptr = value
|
||||
};
|
||||
lv_style_set_prop(style, LV_STYLE_ANIM, v);
|
||||
}
|
||||
|
||||
void lv_style_set_anim_time(lv_style_t * style, uint32_t value)
|
||||
{
|
||||
lv_style_value_t v = {
|
||||
|
||||
Reference in New Issue
Block a user