18#if LV_USE_BTNMATRIX != 0
25#define LV_BTNMATRIX_BTN_NONE 0xFFFF
26LV_EXPORT_CONST_INT(LV_BTNMATRIX_BTN_NONE);
35 _LV_BTNMATRIX_WIDTH = 0x0007,
36 LV_BTNMATRIX_CTRL_HIDDEN = 0x0008,
37 LV_BTNMATRIX_CTRL_NO_REPEAT = 0x0010,
38 LV_BTNMATRIX_CTRL_DISABLED = 0x0020,
39 LV_BTNMATRIX_CTRL_CHECKABLE = 0x0040,
40 LV_BTNMATRIX_CTRL_CHECKED = 0x0080,
41 LV_BTNMATRIX_CTRL_CLICK_TRIG = 0x0100,
42 LV_BTNMATRIX_CTRL_POPOVER = 0x0200,
43 LV_BTNMATRIX_CTRL_RECOLOR = 0x1000,
44 _LV_BTNMATRIX_CTRL_RESERVED = 0x2000,
45 LV_BTNMATRIX_CTRL_CUSTOM_1 = 0x4000,
46 LV_BTNMATRIX_CTRL_CUSTOM_2 = 0x8000,
49typedef uint16_t lv_btnmatrix_ctrl_t;
51typedef bool (*lv_btnmatrix_btn_draw_cb_t)(
lv_obj_t * btnm, uint32_t btn_id,
const lv_area_t * draw_area,
59 lv_btnmatrix_ctrl_t * ctrl_bits;
63 uint8_t one_check : 1;
73 LV_BTNMATRIX_DRAW_PART_BTN,
74} lv_btnmatrix_draw_part_type_t;
98void lv_btnmatrix_set_map(
lv_obj_t * obj,
const char * map[]);
112void lv_btnmatrix_set_ctrl_map(
lv_obj_t * obj,
const lv_btnmatrix_ctrl_t ctrl_map[]);
119void lv_btnmatrix_set_selected_btn(
lv_obj_t * obj, uint16_t btn_id);
127void lv_btnmatrix_set_btn_ctrl(
lv_obj_t * obj, uint16_t btn_id, lv_btnmatrix_ctrl_t ctrl);
135void lv_btnmatrix_clear_btn_ctrl(
lv_obj_t * obj, uint16_t btn_id, lv_btnmatrix_ctrl_t ctrl);
142void lv_btnmatrix_set_btn_ctrl_all(
lv_obj_t * obj, lv_btnmatrix_ctrl_t ctrl);
150void lv_btnmatrix_clear_btn_ctrl_all(
lv_obj_t * obj, lv_btnmatrix_ctrl_t ctrl);
161void lv_btnmatrix_set_btn_width(
lv_obj_t * obj, uint16_t btn_id, uint8_t width);
170void lv_btnmatrix_set_one_checked(
lv_obj_t * obj,
bool en);
181const char ** lv_btnmatrix_get_map(
const lv_obj_t * obj);
189uint16_t lv_btnmatrix_get_selected_btn(
const lv_obj_t * obj);
197const char * lv_btnmatrix_get_btn_text(
const lv_obj_t * obj, uint16_t btn_id);
206bool lv_btnmatrix_has_btn_ctrl(
lv_obj_t * obj, uint16_t btn_id, lv_btnmatrix_ctrl_t ctrl);
213bool lv_btnmatrix_get_one_checked(
const lv_obj_t * obj);
Definition lv_obj_class.h:49