App:Library:LVGL:docs:Overview:Objects

提供: robot-jp wiki
2022年6月22日 (水) 23:00時点におけるTakashi (トーク | 投稿記録)による版
ナビゲーションに移動検索に移動

https://docs.lvgl.io/8.2/overview/object.html

英文 自動翻訳

Objects

In LVGL the basic building blocks of a user interface are the objects, also called Widgets. For example a Button, Label, Image, List, Chart or Text area.

You can see all the Object types here.

All objects are referenced using an lv_obj_t pointer as a handle. This pointer can later be used to set or get the attributes of the object.

Attributes

Basic attributes

All object types share some basic attributes:

  • Position
  • Size
  • Parent
  • Styles
  • Event handlers
  • Etc

You can set/get these attributes with lv_obj_set_... and lv_obj_get_... functions. For example:

/*Set basic object attributes*/
lv_obj_set_size(btn1, 100, 50);	  /*Set a button's size*/
lv_obj_set_pos(btn1, 20,30);      /*Set a button's position*/ 

To see all the available functions visit the Base object's documentation.




戻る : Previous