snap_t lv_obj_get_scroll_snap_x(const_obj_t * obj) { if(obj->spec_attr) return obj->spec->scroll_snap_x; else return LV_SCROLL_SNAP_NONE; } lv_scroll_snap_t lv__scroll_snap_y(const lv_obj_t * obj) { if(obj->spec
voidmy_gui(void){lv_obj_t*parent = lv_obj_create(lv_scr_act());/* 创建父对象,默认大小 */lv_obj_set_size(parent,400,240);/* 设置父对象的大小 */lv_obj_t* child = lv_obj_create(parent);/* 在先前创建的父对象上创建一个子对象 */lv_obj_set_pos(child,50,10);/* 设置子对象的...
lv_obj_get_index(obj)returns the index of the object in its parent. It is equivalent to the number of younger children in the parent. You can bring an object to the foreground or send it to the background withlv_obj_move_foreground(obj)andlv_obj_move_background(obj). You can change...
While scrollbar mode and scroll directions are implemented, scroll snap is not configurable from EEZ Studio. Like scroll direction, two dropdowns could be added to select between lv_scroll_snap_t variants for each axis: A workaround is to manually call lv_obj_set_scroll_snap_x(obj, LV_...
滚动是可以冒泡的,如果一个控件已经滚动到底,再次对其尝试滚动将使滚动事件传播到父容器上。可以通过清除LV_OBJ_FLAG_SCROLL_CHAIN标志位去除这个性质。 可以通过lv_obj_set_scroll_dir()限制滚动的方向。例如: lv_obj_set_scroll_dir(obj, LV_DIR_RIGHT); ...
*/ lv_textarea_set_cursor_pos(obj, lv_text_get_cursor_pos(obj) + _lv_txt_get_encoded_lengthtxt)); lv_event_sendobj _EVENT_VALUE_CHANGED, NULL); } voidlv_textarea_del_char(lv_obj_t * obj) { LV_ASSERT_OBJ(obj, MY_CLASS); lv_textarea_t * ta = (lv_...
2.1.1791 Part 4 Section 6.4.2.62, UIObj (UI Object Toggle) 2.1.1792 Part 4 Section 6.4.2.63, Val (Scroll bar position) 2.1.1793 Part 4 Section 6.4.2.64, ValidIds (Valid ID) 2.1.1794 Part 4 Section 6.4.2.68, WidthMin (Minimum Width) 2.1.1795 Part 4 Section 6.4.3....
#define LV_USE_ASSERT_OBJ 0 /*Check the object's type and existence (e.g. not deleted). (Slow)*/ /*Add a custom handler when assert happens e.g. to restart the MCU*/ #define LV_ASSERT_HANDLER_INCLUDE <stdint.h> #define LV_ASSERT_HANDLER while(1); /*Halt by default*/ ...
{Object} opts 下载的一些选项 */ var downloadAndroidPkg = function (opts) { if (downLoadHandler) { clearTimeout(downLoadHandler); downLoadHandler = null; } var stTime = new Date().getTime(); downLoadHandler = setTimeout(function () { if (new Date().getTime() - stTime < 3000) { ...
{Object} opts 下载的一些选项 */ var downloadAndroidPkg = function (opts) { if (downLoadHandler) { clearTimeout(downLoadHandler); downLoadHandler = null; } var stTime = new Date().getTime(); downLoadHandler = setTimeout(function () { if (new Date().getTime() - stTime < 3000) { ...