Merge branch 'master' of https://github.com/littlevgl/lvgl
This commit is contained in:
@@ -121,7 +121,7 @@ For more examples see the [lv_examples](https://github.com/lvgl/lv_examples) rep
|
|||||||
|
|
||||||
### Button with label
|
### Button with label
|
||||||
```c
|
```c
|
||||||
lv_obj_t * btn = lv_btn_create(lv_scr_act(), NULL); /*Add a button the current screen*/
|
lv_obj_t * btn = lv_btn_create(lv_scr_act(), NULL); /*Add a button to the current screen*/
|
||||||
lv_obj_set_pos(btn, 10, 10); /*Set its position*/
|
lv_obj_set_pos(btn, 10, 10); /*Set its position*/
|
||||||
lv_obj_set_size(btn, 100, 50); /*Set its size*/
|
lv_obj_set_size(btn, 100, 50); /*Set its size*/
|
||||||
lv_obj_set_event_cb(btn, btn_event_cb); /*Assign a callback to the button*/
|
lv_obj_set_event_cb(btn, btn_event_cb); /*Assign a callback to the button*/
|
||||||
|
|||||||
Reference in New Issue
Block a user