How to set a cursor to show where I touch the screen?

Hi, you can do show the system cursor like this

	lv_indev_drv_t indev_drv;
	lv_indev_drv_init(&indev_drv);
	indev_drv.type       = LV_INDEV_TYPE_POINTER;
	indev_drv.read_cb    = mouse_read;
	lv_indev_t *indev    = lv_indev_drv_register(&indev_drv);
	lv_obj_t *cursor_img = lv_img_create(lv_scr_act(), NULL);
	lv_img_set_src(cursor_img, LV_SYMBOL_OK);
	lv_indev_set_cursor(indev, cursor_img);
2 Likes