mirror of
https://github.com/esphome/esphome.git
synced 2026-02-18 15:35:59 -07:00
[lvgl] Layout improvements (#10149)
Co-authored-by: clydeps <U5yx99dok9> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -113,9 +113,10 @@ lvgl:
|
||||
title: Messagebox
|
||||
bg_color: 0xffff
|
||||
widgets:
|
||||
- label:
|
||||
text: Hello Msgbox
|
||||
id: msgbox_label
|
||||
# Test single widget without list
|
||||
label:
|
||||
text: Hello Msgbox
|
||||
id: msgbox_label
|
||||
body:
|
||||
text: This is a sample messagebox
|
||||
bg_color: 0x808080
|
||||
@@ -281,7 +282,7 @@ lvgl:
|
||||
#endif
|
||||
return std::string(buf);
|
||||
align: top_left
|
||||
- obj:
|
||||
- container:
|
||||
align: center
|
||||
arc_opa: COVER
|
||||
arc_color: 0xFF0000
|
||||
@@ -414,6 +415,7 @@ lvgl:
|
||||
- buttons:
|
||||
- id: button_e
|
||||
- button:
|
||||
layout: 2x1
|
||||
id: button_button
|
||||
width: 20%
|
||||
height: 10%
|
||||
@@ -430,8 +432,13 @@ lvgl:
|
||||
checked:
|
||||
bg_color: 0x000000
|
||||
widgets:
|
||||
- label:
|
||||
text: Button
|
||||
# Test parse a dict instead of list
|
||||
label:
|
||||
text: Button
|
||||
align: bottom_right
|
||||
image:
|
||||
src: cat_image
|
||||
align: top_left
|
||||
on_click:
|
||||
- lvgl.widget.focus: spin_up
|
||||
- lvgl.widget.focus: next
|
||||
@@ -539,6 +546,7 @@ lvgl:
|
||||
- logger.log: "tile 1 is now showing"
|
||||
tiles:
|
||||
- id: tile_1
|
||||
layout: vertical
|
||||
row: 0
|
||||
column: 0
|
||||
dir: ALL
|
||||
@@ -554,6 +562,7 @@ lvgl:
|
||||
bg_color: 0x000000
|
||||
|
||||
- id: page2
|
||||
layout: vertical
|
||||
widgets:
|
||||
- canvas:
|
||||
id: canvas_id
|
||||
@@ -1005,6 +1014,7 @@ lvgl:
|
||||
r_mod: -20
|
||||
opa: 0%
|
||||
- id: page3
|
||||
layout: horizontal
|
||||
widgets:
|
||||
- keyboard:
|
||||
id: lv_keyboard
|
||||
|
||||
Reference in New Issue
Block a user