mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-28 07:03:00 +08:00
feat(Kconfig): add monitor position configuration (#2834)
* fix(Kconfig) remove duplicate LV_BUILD_EXAMPLES configuration * feat(Kconfig) add monitor position configuration Co-authored-by: pengyiqiang <pengyiqiang@xiaomi.com>
This commit is contained in:
parent
cd197a8e49
commit
9233918b93
54
Kconfig
54
Kconfig
@ -321,12 +321,62 @@ menu "LVGL configuration"
|
|||||||
|
|
||||||
menu "Others"
|
menu "Others"
|
||||||
config LV_USE_PERF_MONITOR
|
config LV_USE_PERF_MONITOR
|
||||||
bool "Show CPU usage and FPS count in the right bottom corner."
|
bool "Show CPU usage and FPS count."
|
||||||
|
|
||||||
|
choice
|
||||||
|
prompt "Performance monitor position."
|
||||||
|
depends on LV_USE_PERF_MONITOR
|
||||||
|
default LV_PERF_MONITOR_ALIGN_BOTTOM_RIGHT
|
||||||
|
|
||||||
|
config LV_PERF_MONITOR_ALIGN_TOP_LEFT
|
||||||
|
bool "Top left"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_TOP_MID
|
||||||
|
bool "Top middle"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_TOP_RIGHT
|
||||||
|
bool "Top right"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_BOTTOM_LEFT
|
||||||
|
bool "Bottom left"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_BOTTOM_MID
|
||||||
|
bool "Bottom middle"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_BOTTOM_RIGHT
|
||||||
|
bool "Bottom right"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_LEFT_MID
|
||||||
|
bool "Left middle"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_RIGHT_MID
|
||||||
|
bool "Right middle"
|
||||||
|
config LV_PERF_MONITOR_ALIGN_BOTTOM_CENTER
|
||||||
|
bool "Center"
|
||||||
|
endchoice
|
||||||
|
|
||||||
config LV_USE_MEM_MONITOR
|
config LV_USE_MEM_MONITOR
|
||||||
bool "Show the used memory and the memory fragmentation in the left bottom corner."
|
bool "Show the used memory and the memory fragmentation."
|
||||||
depends on !LV_MEM_CUSTOM
|
depends on !LV_MEM_CUSTOM
|
||||||
|
|
||||||
|
choice
|
||||||
|
prompt "Memory monitor position."
|
||||||
|
depends on LV_USE_MEM_MONITOR
|
||||||
|
default LV_MEM_MONITOR_ALIGN_BOTTOM_LEFT
|
||||||
|
|
||||||
|
config LV_MEM_MONITOR_ALIGN_TOP_LEFT
|
||||||
|
bool "Top left"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_TOP_MID
|
||||||
|
bool "Top middle"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_TOP_RIGHT
|
||||||
|
bool "Top right"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_BOTTOM_LEFT
|
||||||
|
bool "Bottom left"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_BOTTOM_MID
|
||||||
|
bool "Bottom middle"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_BOTTOM_RIGHT
|
||||||
|
bool "Bottom right"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_LEFT_MID
|
||||||
|
bool "Left middle"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_RIGHT_MID
|
||||||
|
bool "Right middle"
|
||||||
|
config LV_MEM_MONITOR_ALIGN_BOTTOM_CENTER
|
||||||
|
bool "Center"
|
||||||
|
endchoice
|
||||||
|
|
||||||
config LV_USE_REFR_DEBUG
|
config LV_USE_REFR_DEBUG
|
||||||
bool "Draw random colored rectangles over the redrawn areas."
|
bool "Draw random colored rectangles over the redrawn areas."
|
||||||
|
|
||||||
|
@ -131,6 +131,50 @@ extern "C" {
|
|||||||
# define CONFIG_LV_BIDI_BASE_DIR_DEF LV_BASE_DIR_AUTO
|
# define CONFIG_LV_BIDI_BASE_DIR_DEF LV_BASE_DIR_AUTO
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*------------------
|
||||||
|
* MONITOR POSITION
|
||||||
|
*-----------------*/
|
||||||
|
|
||||||
|
#ifdef CONFIG_LV_PERF_MONITOR_ALIGN_TOP_LEFT
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_TOP_LEFT
|
||||||
|
#elif defined(CONFIG_LV_USE_PERF_MONITOR_ALIGN_TOP_MID)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_TOP_MID
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_TOP_RIGHT)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_TOP_RIGHT
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_BOTTOM_LEFT)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_BOTTOM_LEFT
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_BOTTOM_MID)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_BOTTOM_MID
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_BOTTOM_RIGHT)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_BOTTOM_RIGHT
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_LEFT_MID)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_LEFT_MID
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_RIGHT_MID)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_RIGHT_MID
|
||||||
|
#elif defined(CONFIG_LV_PERF_MONITOR_ALIGN_CENTER)
|
||||||
|
# define CONFIG_LV_USE_PERF_MONITOR_POS LV_ALIGN_CENTER
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_LV_MEM_MONITOR_ALIGN_TOP_LEFT
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_TOP_LEFT
|
||||||
|
#elif defined(CONFIG_LV_USE_MEM_MONITOR_ALIGN_TOP_MID)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_TOP_MID
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_TOP_RIGHT)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_TOP_RIGHT
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_BOTTOM_LEFT)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_BOTTOM_LEFT
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_BOTTOM_MID)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_BOTTOM_MID
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_BOTTOM_RIGHT)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_BOTTOM_RIGHT
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_LEFT_MID)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_LEFT_MID
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_RIGHT_MID)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_RIGHT_MID
|
||||||
|
#elif defined(CONFIG_LV_MEM_MONITOR_ALIGN_CENTER)
|
||||||
|
# define CONFIG_LV_USE_MEM_MONITOR_POS LV_ALIGN_CENTER
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /*extern "C"*/
|
} /*extern "C"*/
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user