What MCU/Processor/Board and compiler are you using?
Linux simulator base on SDL2
What LVGL version are you using?
LVGL v8.2.0
What do you want to achieve?
when scroll start, the screen does not change until scroll end, it’s look like switch immediately。 Can I use LVGL v8.2.0 API, and do not need to modify the source code ?
I’m not sure you can prevent it behaving like that when scrolling.
I know you can do that when using the buttons at the top/left but you seem to have made your content to be 100% height/width and this is probably making the buttons not show.
To stop the scroll animation when using the buttons at the top you can do something like this:
tv = lv_tabview_create(scr, LV_DIR_TOP, tvHeight);
lv_obj_add_event_cb(lv_tabview_get_content(tv), scroll_begin_event, LV_EVENT_SCROLL_BEGIN, NULL);
static void scroll_begin_event(lv_event_t * e)
{
/*Disable the scroll animations. Triggered when a tab button is clicked */
if(lv_event_get_code(e) == LV_EVENT_SCROLL_BEGIN) {
lv_anim_t * a = (lv_anim_t *)lv_event_get_param(e);
//lv_anim_t * a = lv_event_get_param(e);
if(a) a->time = 0;
}
}