879 changed files with 304372 additions and 1 deletions
@ -0,0 +1,8 @@ |
|||
codecov: |
|||
notify: |
|||
require_ci_to_pass: true |
|||
comment: off |
|||
coverage: |
|||
status: |
|||
patch: off |
|||
project: off |
@ -0,0 +1,6 @@ |
|||
[*.{c,h,ino}] |
|||
indent_style = space |
|||
indent_size = 4 |
|||
end_of_line = lf |
|||
insert_final_newline = true |
|||
trim_trailing_whitespace = true |
@ -0,0 +1,94 @@ |
|||
if(ESP_PLATFORM) |
|||
|
|||
file(GLOB_RECURSE SOURCES src/*.c) |
|||
|
|||
idf_build_get_property(LV_MICROPYTHON LV_MICROPYTHON) |
|||
|
|||
if (LV_MICROPYTHON) |
|||
idf_component_register(SRCS ${SOURCES} |
|||
INCLUDE_DIRS . src ../ |
|||
REQUIRES main) |
|||
else() |
|||
idf_component_register(SRCS ${SOURCES} |
|||
INCLUDE_DIRS . src ../) |
|||
endif() |
|||
|
|||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_CONF_INCLUDE_SIMPLE") |
|||
|
|||
if (CONFIG_LV_ATTRIBUTE_FAST_MEM_USE_IRAM) |
|||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_ATTRIBUTE_FAST_MEM=IRAM_ATTR") |
|||
endif() |
|||
|
|||
elseif(ZEPHYR_BASE) |
|||
|
|||
if(CONFIG_LVGL) |
|||
|
|||
zephyr_include_directories(${ZEPHYR_BASE}/lib/gui/lvgl) |
|||
|
|||
target_include_directories(lvgl INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) |
|||
|
|||
zephyr_compile_definitions(LV_CONF_KCONFIG_EXTERNAL_INCLUDE=<autoconf.h>) |
|||
|
|||
zephyr_library() |
|||
|
|||
file(GLOB_RECURSE SOURCES src/*.c) |
|||
zephyr_library_sources(${SOURCES}) |
|||
|
|||
endif(CONFIG_LVGL) |
|||
|
|||
else() |
|||
|
|||
file(GLOB_RECURSE SOURCES ${CMAKE_CURRENT_LIST_DIR}/src/*.c) |
|||
file(GLOB_RECURSE EXAMPLE_SOURCES ${CMAKE_CURRENT_LIST_DIR}/examples/*.c) |
|||
|
|||
if(MICROPY_DIR) |
|||
# with micropython, build lvgl as interface library |
|||
# link chain is: lvgl_interface [lvgl] โ usermod_lvgl_bindings [lv_bindings] โ usermod [micropython] โ firmware [micropython] |
|||
add_library(lvgl_interface INTERFACE) |
|||
# ${SOURCES} must NOT be given to add_library directly for some reason (won't be built) |
|||
target_sources(lvgl_interface INTERFACE ${SOURCES}) |
|||
# Micropython builds with -Werror; we need to suppress some warnings, such as: |
|||
# |
|||
# /home/test/build/lv_micropython/ports/rp2/build-PICO/lv_mp.c:29316:16: error: 'lv_style_transition_dsc_t_path_xcb_callback' defined but not used [-Werror=unused-function] |
|||
# 29316 | STATIC int32_t lv_style_transition_dsc_t_path_xcb_callback(const struct _lv_anim_t * arg0) |
|||
# | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|||
target_compile_options(lvgl_interface INTERFACE -Wno-unused-function) |
|||
else(MICROPY_DIR) |
|||
# without micropython, build lvgl and examples libs normally |
|||
# default linux build uses this scope |
|||
add_library(lvgl STATIC ${SOURCES}) |
|||
add_library(lvgl_examples STATIC ${EXAMPLE_SOURCES}) |
|||
|
|||
include_directories(${CMAKE_SOURCE_DIR}) |
|||
|
|||
# Lbrary and headers can be installed to system using make install |
|||
file(GLOB LVGL_PUBLIC_HEADERS |
|||
"${CMAKE_SOURCE_DIR}/lv_conf.h" |
|||
"${CMAKE_SOURCE_DIR}/lvgl.h") |
|||
|
|||
if("${LIB_INSTALL_DIR}" STREQUAL "") |
|||
set(LIB_INSTALL_DIR "lib") |
|||
endif() |
|||
if("${INC_INSTALL_DIR}" STREQUAL "") |
|||
set(INC_INSTALL_DIR "include/lvgl") |
|||
endif() |
|||
|
|||
install(DIRECTORY "${CMAKE_SOURCE_DIR}/src" |
|||
DESTINATION "${CMAKE_INSTALL_PREFIX}/${INC_INSTALL_DIR}/" |
|||
FILES_MATCHING |
|||
PATTERN "*.h") |
|||
|
|||
set_target_properties(lvgl PROPERTIES |
|||
OUTPUT_NAME lvgl |
|||
ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib" |
|||
PUBLIC_HEADER "${LVGL_PUBLIC_HEADERS}") |
|||
|
|||
install(TARGETS lvgl |
|||
ARCHIVE DESTINATION "${LIB_INSTALL_DIR}" |
|||
PUBLIC_HEADER DESTINATION "${INC_INSTALL_DIR}") |
|||
|
|||
endif(MICROPY_DIR) |
|||
|
|||
endif() |
|||
|
|||
|
@ -0,0 +1,860 @@ |
|||
# Kconfig file for LVGL v8.0 |
|||
menuconfig LIB_LV |
|||
bool "Enable LittleVGL " |
|||
default n |
|||
|
|||
if 0 |
|||
menu "LVGL configuration" |
|||
|
|||
# Define CONFIG_LV_CONF_SKIP so we can use LVGL |
|||
# without lv_conf.h file, the lv_conf_internal.h and |
|||
# lv_conf_kconfig.h files are used instead. |
|||
config LV_CONF_SKIP |
|||
bool |
|||
default n |
|||
|
|||
config LV_CONF_MINIMAL |
|||
bool "LVGL minimal configuration." |
|||
|
|||
menu "Color settings" |
|||
choice |
|||
prompt "Color depth." |
|||
default LV_COLOR_DEPTH_16 |
|||
help |
|||
Color depth to be used. |
|||
|
|||
config LV_COLOR_DEPTH_32 |
|||
bool "32: ARGB8888" |
|||
config LV_COLOR_DEPTH_16 |
|||
bool "16: RGB565" |
|||
config LV_COLOR_DEPTH_8 |
|||
bool "8: RGB232" |
|||
config LV_COLOR_DEPTH_1 |
|||
bool "1: 1 byte per pixel" |
|||
endchoice |
|||
|
|||
config LV_COLOR_DEPTH |
|||
int |
|||
default 1 if LV_COLOR_DEPTH_1 |
|||
default 8 if LV_COLOR_DEPTH_8 |
|||
default 16 if LV_COLOR_DEPTH_16 |
|||
default 32 if LV_COLOR_DEPTH_32 |
|||
|
|||
config LV_COLOR_16_SWAP |
|||
bool "Swap the 2 bytes of RGB565 color. Useful if the display has an 8-bit interface (e.g. SPI)." |
|||
depends on LV_COLOR_DEPTH_16 |
|||
|
|||
config LV_COLOR_SCREEN_TRANSP |
|||
bool "Enable more complex drawing routines to manage screens transparency." |
|||
depends on LV_COLOR_DEPTH_32 |
|||
help |
|||
Can be used if the UI is above another layer, e.g. an OSD menu or video player. |
|||
Requires `LV_COLOR_DEPTH = 32` colors and the screen's `bg_opa` should be set to |
|||
non LV_OPA_COVER value |
|||
|
|||
config LV_COLOR_MIX_ROUND_OFS |
|||
int "Adjust color mix functions rounding" |
|||
default 128 if !LV_COLOR_DEPTH_32 |
|||
default 0 if LV_COLOR_DEPTH_32 |
|||
range 0 254 |
|||
help |
|||
0: no adjustment, get the integer part of the result (round down) |
|||
64: round up from x.75 |
|||
128: round up from half |
|||
192: round up from x.25 |
|||
254: round up |
|||
|
|||
config LV_COLOR_CHROMA_KEY_HEX |
|||
hex "Images pixels with this color will not be drawn (if they are chroma keyed)." |
|||
range 0x000000 0xFFFFFF |
|||
default 0x00FF00 |
|||
help |
|||
See misc/lv_color.h for some color values examples. |
|||
endmenu |
|||
|
|||
menu "Memory settings" |
|||
config LV_MEM_CUSTOM |
|||
bool "If true use custom malloc/free, otherwise use the built-in `lv_mem_alloc()` and `lv_mem_free()`" |
|||
|
|||
config LV_MEM_SIZE_KILOBYTES |
|||
int "Size of the memory used by `lv_mem_alloc` in kilobytes (>= 2kB)" |
|||
range 2 128 |
|||
default 32 |
|||
depends on !LV_MEM_CUSTOM |
|||
|
|||
config LV_MEM_ADDR |
|||
hex "Address for the memory pool instead of allocating it as a normal array" |
|||
default 0x0 |
|||
depends on !LV_MEM_CUSTOM |
|||
|
|||
config LV_MEM_CUSTOM_INCLUDE |
|||
string "Header to include for the custom memory function" |
|||
default "stdlib.h" |
|||
depends on LV_MEM_CUSTOM |
|||
|
|||
config LV_MEM_BUF_MAX_NUM |
|||
int "Number of the memory buffer" |
|||
default 16 |
|||
help |
|||
Number of the intermediate memory buffer used during rendering and other |
|||
internal processing mechanisms. You will see an error log message if |
|||
there wasn't enough buffers. |
|||
|
|||
config LV_MEMCPY_MEMSET_STD |
|||
bool "Use the standard memcpy and memset instead of LVGL's own functions" |
|||
endmenu |
|||
|
|||
menu "HAL Settings" |
|||
config LV_DISP_DEF_REFR_PERIOD |
|||
int "Default display refresh period (ms)." |
|||
default 30 |
|||
help |
|||
Can be changed in the display driver (`lv_disp_drv_t`). |
|||
|
|||
config LV_INDEV_DEF_READ_PERIOD |
|||
int "Input device read period [ms]." |
|||
default 30 |
|||
|
|||
config LV_TICK_CUSTOM |
|||
bool "Use a custom tick source" |
|||
|
|||
config LV_TICK_CUSTOM_INCLUDE |
|||
string "Header for the system time function" |
|||
default "Arduino.h" |
|||
depends on LV_TICK_CUSTOM |
|||
|
|||
config LV_DPI_DEF |
|||
int "Default Dots Per Inch (in px)." |
|||
default 130 |
|||
help |
|||
Used to initialize default sizes such as widgets sized, style paddings. |
|||
(Not so important, you can adjust it to modify default sizes and spaces) |
|||
endmenu |
|||
|
|||
menu "Feature configuration" |
|||
|
|||
menu "Drawing" |
|||
config LV_DRAW_COMPLEX |
|||
bool "Enable complex draw engine" |
|||
default y |
|||
help |
|||
Required to draw shadow, gradient, rounded corners, circles, arc, skew lines, |
|||
image transformations or any masks. |
|||
|
|||
config LV_SHADOW_CACHE_SIZE |
|||
int "Allow buffering some shadow calculation" |
|||
depends on LV_DRAW_COMPLEX |
|||
default 0 |
|||
help |
|||
LV_SHADOW_CACHE_SIZE is the max shadow size to buffer, where |
|||
shadow size is `shadow_width + radius`. |
|||
Caching has LV_SHADOW_CACHE_SIZE^2 RAM cost. |
|||
|
|||
config LV_CIRCLE_CACHE_SIZE |
|||
int "Set number of maximally cached circle data" |
|||
depends on LV_DRAW_COMPLEX |
|||
default 4 |
|||
help |
|||
The circumference of 1/4 circle are saved for anti-aliasing |
|||
radius * 4 bytes are used per circle (the most often used |
|||
radiuses are saved). |
|||
Set to 0 to disable caching. |
|||
|
|||
config LV_IMG_CACHE_DEF_SIZE |
|||
int "Default image cache size. 0 to disable caching." |
|||
default 0 |
|||
help |
|||
If only the built-in image formats are used there is no real advantage of caching. |
|||
(I.e. no new image decoder is added). |
|||
|
|||
With complex image decoders (e.g. PNG or JPG) caching can |
|||
save the continuous open/decode of images. |
|||
However the opened images might consume additional RAM. |
|||
|
|||
config LV_DISP_ROT_MAX_BUF |
|||
int "Maximum buffer size to allocate for rotation" |
|||
default 10240 |
|||
help |
|||
Only used if software rotation is enabled in the display driver. |
|||
endmenu |
|||
|
|||
menu "GPU" |
|||
config LV_USE_EXTERNAL_RENDERER |
|||
bool |
|||
|
|||
config LV_USE_GPU_STM32_DMA2D |
|||
bool "Enable STM32 DMA2D (aka Chrom Art) GPU." |
|||
config LV_GPU_DMA2D_CMSIS_INCLUDE |
|||
string "include path of CMSIS header of target processor" |
|||
depends on LV_USE_GPU_STM32_DMA2D |
|||
default "" |
|||
help |
|||
Must be defined to include path of CMSIS header of target processor |
|||
e.g. "stm32f769xx.h" or "stm32f429xx.h" |
|||
|
|||
config LV_USE_GPU_NXP_PXP |
|||
bool "Use NXP's PXP GPU iMX RTxxx platforms." |
|||
config LV_USE_GPU_NXP_PXP_AUTO_INIT |
|||
bool "Call lv_gpu_nxp_pxp_init() automatically or manually." |
|||
depends on LV_USE_GPU_NXP_PXP |
|||
help |
|||
1: Add default bare metal and FreeRTOS interrupt handling |
|||
routines for PXP (lv_gpu_nxp_pxp_osa.c) and call |
|||
lv_gpu_nxp_pxp_init() automatically during lv_init(). |
|||
Note that symbol SDK_OS_FREE_RTOS has to be defined in order |
|||
to use FreeRTOS OSA, otherwise bare-metal implementation is |
|||
selected. |
|||
0: lv_gpu_nxp_pxp_init() has to be called manually before |
|||
lv_init(). |
|||
|
|||
config LV_USE_GPU_NXP_VG_LITE |
|||
bool "Use NXP's VG-Lite GPU iMX RTxxx platforms." |
|||
|
|||
config LV_USE_GPU_SDL |
|||
bool "Use SDL renderer API" |
|||
select LV_USE_EXTERNAL_RENDERER |
|||
default n |
|||
config LV_GPU_SDL_INCLUDE_PATH |
|||
string "include path of SDL header" |
|||
depends on LV_USE_GPU_SDL |
|||
default "SDL2/SDL.h" |
|||
endmenu |
|||
|
|||
menu "Logging" |
|||
config LV_USE_LOG |
|||
bool "Enable the log module" |
|||
|
|||
choice |
|||
bool "Default log verbosity" if LV_USE_LOG |
|||
default LV_LOG_LEVEL_WARN |
|||
help |
|||
Specify how important log should be added. |
|||
|
|||
config LV_LOG_LEVEL_TRACE |
|||
bool "A lot of logs to give detailed information" |
|||
config LV_LOG_LEVEL_INFO |
|||
bool "Log important events" |
|||
config LV_LOG_LEVEL_WARN |
|||
bool "Log if something unwanted happened but didn't cause a problem" |
|||
config LV_LOG_LEVEL_ERROR |
|||
bool "Only critical issues, when the system may fail" |
|||
config LV_LOG_LEVEL_USER |
|||
bool "Only logs added by the user" |
|||
config LV_LOG_LEVEL_NONE |
|||
bool "Do not log anything" |
|||
endchoice |
|||
|
|||
config LV_LOG_LEVEL |
|||
int |
|||
default 0 if LV_LOG_LEVEL_TRACE |
|||
default 1 if LV_LOG_LEVEL_INFO |
|||
default 2 if LV_LOG_LEVEL_WARN |
|||
default 3 if LV_LOG_LEVEL_ERROR |
|||
default 4 if LV_LOG_LEVEL_USER |
|||
default 5 if LV_LOG_LEVEL_NONE |
|||
|
|||
config LV_LOG_PRINTF |
|||
bool "Print the log with 'printf'" if LV_USE_LOG |
|||
help |
|||
Use printf for log output. |
|||
If not set the user needs to register a callback with `lv_log_register_print_cb`. |
|||
|
|||
config LV_LOG_TRACE_MEM |
|||
bool "Enable/Disable LV_LOG_TRACE in mem module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_TIMER |
|||
bool "Enable/Disable LV_LOG_TRACE in timer module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_INDEV |
|||
bool "Enable/Disable LV_LOG_TRACE in indev module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_DISP_REFR |
|||
bool "Enable/Disable LV_LOG_TRACE in disp refr module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_EVENT |
|||
bool "Enable/Disable LV_LOG_TRACE in event module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_OBJ_CREATE |
|||
bool "Enable/Disable LV_LOG_TRACE in obj create module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_LAYOUT |
|||
bool "Enable/Disable LV_LOG_TRACE in layout module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
|
|||
config LV_LOG_TRACE_ANIM |
|||
bool "Enable/Disable LV_LOG_TRACE in anim module" |
|||
default y |
|||
depends on LV_USE_LOG |
|||
endmenu |
|||
|
|||
menu "Asserts" |
|||
config LV_USE_ASSERT_NULL |
|||
bool "Check if the parameter is NULL. (Very fast, recommended)" |
|||
default y if !LV_CONF_MINIMAL |
|||
|
|||
config LV_USE_ASSERT_MALLOC |
|||
bool "Checks if the memory is successfully allocated or no. (Very fast, recommended)" |
|||
default y if !LV_CONF_MINIMAL |
|||
|
|||
config LV_USE_ASSERT_STYLE |
|||
bool "Check if the styles are properly initialized. (Very fast, recommended)" |
|||
|
|||
config LV_USE_ASSERT_MEM_INTEGRITY |
|||
bool "Check the integrity of `lv_mem` after critical operations. (Slow)" |
|||
|
|||
config LV_USE_ASSERT_OBJ |
|||
bool "Check NULL, the object's type and existence (e.g. not deleted). (Slow)." |
|||
|
|||
config LV_ASSERT_HANDLER_INCLUDE |
|||
string "Header to include for the custom assert function" |
|||
default "assert.h" |
|||
endmenu |
|||
|
|||
menu "Others" |
|||
config LV_USE_PERF_MONITOR |
|||
bool "Show CPU usage and FPS count in the right bottom corner." |
|||
|
|||
config LV_USE_MEM_MONITOR |
|||
bool "Show the used memory and the memory fragmentation in the left bottom corner." |
|||
depends on !LV_MEM_CUSTOM |
|||
|
|||
config LV_USE_REFR_DEBUG |
|||
bool "Draw random colored rectangles over the redrawn areas." |
|||
|
|||
config LV_SPRINTF_CUSTOM |
|||
bool "Change the built-in (v)snprintf functions" |
|||
|
|||
config LV_SPRINTF_INCLUDE |
|||
string "Header to include for the custom sprintf function" |
|||
depends on LV_SPRINTF_CUSTOM |
|||
default "stdio.h" |
|||
|
|||
config LV_SPRINTF_USE_FLOAT |
|||
bool "Enable float in built-in (v)snprintf functions" |
|||
depends on !LV_SPRINTF_CUSTOM |
|||
|
|||
config LV_USE_USER_DATA |
|||
bool "Add a 'user_data' to drivers and objects." |
|||
default y |
|||
|
|||
config LV_ENABLE_GC |
|||
bool "Enable garbage collector" |
|||
|
|||
config LV_GC_INCLUDE |
|||
string "Header to include for the garbage collector related things" |
|||
depends on LV_ENABLE_GC |
|||
default "gc.h" |
|||
endmenu |
|||
|
|||
menu "Compiler settings" |
|||
config LV_BIG_ENDIAN_SYSTEM |
|||
bool "For big endian systems set to 1" |
|||
|
|||
config LV_ATTRIBUTE_MEM_ALIGN_SIZE |
|||
int "Required alignment size for buffers" |
|||
default 1 |
|||
|
|||
config LV_ATTRIBUTE_FAST_MEM_USE_IRAM |
|||
bool "Set IRAM as LV_ATTRIBUTE_FAST_MEM" |
|||
help |
|||
Set this option to configure IRAM as LV_ATTRIBUTE_FAST_MEM |
|||
|
|||
config LV_USE_LARGE_COORD |
|||
bool "Extend the default -32k..32k coordinate range to -4M..4M by using int32_t for coordinates instead of int16_t" |
|||
endmenu |
|||
endmenu |
|||
|
|||
menu "Font usage" |
|||
menu "Enable built-in fonts" |
|||
config LV_FONT_MONTSERRAT_8 |
|||
bool "Enable Montserrat 8" |
|||
config LV_FONT_MONTSERRAT_10 |
|||
bool "Enable Montserrat 10" |
|||
config LV_FONT_MONTSERRAT_12 |
|||
bool "Enable Montserrat 12" |
|||
config LV_FONT_MONTSERRAT_14 |
|||
bool "Enable Montserrat 14" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_FONT_MONTSERRAT_16 |
|||
bool "Enable Montserrat 16" |
|||
config LV_FONT_MONTSERRAT_18 |
|||
bool "Enable Montserrat 18" |
|||
config LV_FONT_MONTSERRAT_20 |
|||
bool "Enable Montserrat 20" |
|||
config LV_FONT_MONTSERRAT_22 |
|||
bool "Enable Montserrat 22" |
|||
config LV_FONT_MONTSERRAT_24 |
|||
bool "Enable Montserrat 24" |
|||
config LV_FONT_MONTSERRAT_26 |
|||
bool "Enable Montserrat 26" |
|||
config LV_FONT_MONTSERRAT_28 |
|||
bool "Enable Montserrat 28" |
|||
config LV_FONT_MONTSERRAT_30 |
|||
bool "Enable Montserrat 30" |
|||
config LV_FONT_MONTSERRAT_32 |
|||
bool "Enable Montserrat 32" |
|||
config LV_FONT_MONTSERRAT_34 |
|||
bool "Enable Montserrat 34" |
|||
config LV_FONT_MONTSERRAT_36 |
|||
bool "Enable Montserrat 36" |
|||
config LV_FONT_MONTSERRAT_38 |
|||
bool "Enable Montserrat 38" |
|||
config LV_FONT_MONTSERRAT_40 |
|||
bool "Enable Montserrat 40" |
|||
config LV_FONT_MONTSERRAT_42 |
|||
bool "Enable Montserrat 42" |
|||
config LV_FONT_MONTSERRAT_44 |
|||
bool "Enable Montserrat 44" |
|||
config LV_FONT_MONTSERRAT_46 |
|||
bool "Enable Montserrat 46" |
|||
config LV_FONT_MONTSERRAT_48 |
|||
bool "Enable Montserrat 48" |
|||
|
|||
config LV_FONT_MONTSERRAT_12_SUBPX |
|||
bool "Enable Montserrat 12 sub-pixel" |
|||
config LV_FONT_MONTSERRAT_28_COMPRESSED |
|||
bool "Enable Montserrat 28 compressed" |
|||
config LV_FONT_DEJAVU_16_PERSIAN_HEBREW |
|||
bool "Enable Dejavu 16 Persian, Hebrew, Arabic letters" |
|||
config LV_FONT_SIMSUN_16_CJK |
|||
bool "Enable Simsun 16 CJK" |
|||
|
|||
config LV_FONT_UNSCII_8 |
|||
bool "Enable UNSCII 8 (Perfect monospace font)" |
|||
default y if LV_CONF_MINIMAL |
|||
config LV_FONT_UNSCII_16 |
|||
bool "Enable UNSCII 16 (Perfect monospace font)" |
|||
|
|||
config LV_FONT_CUSTOM |
|||
bool "Enable the custom font" |
|||
config LV_FONT_CUSTOM_DECLARE |
|||
string "Header to include for the custom font" |
|||
depends on LV_FONT_CUSTOM |
|||
endmenu |
|||
|
|||
choice LV_FONT_DEFAULT |
|||
prompt "Select theme default title font" |
|||
default LV_FONT_DEFAULT_MONTSERRAT_14 if !LV_CONF_MINIMAL |
|||
default LV_FONT_DEFAULT_UNSCII_8 if LV_CONF_MINIMAL |
|||
help |
|||
Select theme default title font |
|||
|
|||
config LV_FONT_DEFAULT_MONTSERRAT_8 |
|||
bool "Montserrat 8" |
|||
select LV_FONT_MONTSERRAT_8 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_12 |
|||
bool "Montserrat 12" |
|||
select LV_FONT_MONTSERRAT_12 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_14 |
|||
bool "Montserrat 14" |
|||
select LV_FONT_MONTSERRAT_14 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_16 |
|||
bool "Montserrat 16" |
|||
select LV_FONT_MONTSERRAT_16 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_18 |
|||
bool "Montserrat 18" |
|||
select LV_FONT_MONTSERRAT_18 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_20 |
|||
bool "Montserrat 20" |
|||
select LV_FONT_MONTSERRAT_20 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_22 |
|||
bool "Montserrat 22" |
|||
select LV_FONT_MONTSERRAT_22 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_24 |
|||
bool "Montserrat 24" |
|||
select LV_FONT_MONTSERRAT_24 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_26 |
|||
bool "Montserrat 26" |
|||
select LV_FONT_MONTSERRAT_26 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_28 |
|||
bool "Montserrat 28" |
|||
select LV_FONT_MONTSERRAT_28 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_30 |
|||
bool "Montserrat 30" |
|||
select LV_FONT_MONTSERRAT_30 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_32 |
|||
bool "Montserrat 32" |
|||
select LV_FONT_MONTSERRAT_32 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_34 |
|||
bool "Montserrat 34" |
|||
select LV_FONT_MONTSERRAT_34 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_36 |
|||
bool "Montserrat 36" |
|||
select LV_FONT_MONTSERRAT_36 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_38 |
|||
bool "Montserrat 38" |
|||
select LV_FONT_MONTSERRAT_38 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_40 |
|||
bool "Montserrat 40" |
|||
select LV_FONT_MONTSERRAT_40 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_42 |
|||
bool "Montserrat 42" |
|||
select LV_FONT_MONTSERRAT_42 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_44 |
|||
bool "Montserrat 44" |
|||
select LV_FONT_MONTSERRAT_44 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_46 |
|||
bool "Montserrat 46" |
|||
select LV_FONT_MONTSERRAT_46 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_48 |
|||
bool "Montserrat 48" |
|||
select LV_FONT_MONTSERRAT_48 |
|||
config LV_FONT_DEFAULT_MONTSERRAT_12_SUBPX |
|||
bool "Montserrat 12 sub-pixel" |
|||
select LV_FONT_MONTSERRAT_12_SUBPX |
|||
config LV_FONT_DEFAULT_MONTSERRAT_28_COMPRESSED |
|||
bool "Montserrat 28 compressed" |
|||
select LV_FONT_MONTSERRAT_28_COMPRESSED |
|||
config LV_FONT_DEFAULT_DEJAVU_16_PERSIAN_HEBREW |
|||
bool "Dejavu 16 Persian, Hebrew, Arabic letters" |
|||
select LV_FONT_DEJAVU_16_PERSIAN_HEBREW |
|||
config LV_FONT_DEFAULT_SIMSUN_16_CJK |
|||
bool "Simsun 16 CJK" |
|||
select LV_FONT_SIMSUN_16_CJK |
|||
config LV_FONT_DEFAULT_UNSCII_8 |
|||
bool "UNSCII 8 (Perfect monospace font)" |
|||
select LV_FONT_UNSCII_8 |
|||
config LV_FONT_DEFAULT_UNSCII_16 |
|||
bool "UNSCII 16 (Perfect monospace font)" |
|||
select LV_FONT_UNSCII_16 |
|||
endchoice |
|||
|
|||
config LV_FONT_FMT_TXT_LARGE |
|||
bool "Enable it if you have fonts with a lot of characters." |
|||
help |
|||
The limit depends on the font size, font face and bpp |
|||
but with > 10,000 characters if you see issues probably you |
|||
need to enable it. |
|||
|
|||
config LV_USE_FONT_COMPRESSED |
|||
bool "Sets support for compressed fonts." |
|||
|
|||
config LV_USE_FONT_SUBPX |
|||
bool "Enable subpixel rendering." |
|||
|
|||
config LV_FONT_SUBPX_BGR |
|||
bool "Use BGR instead RGB for sub-pixel rendering." |
|||
depends on LV_USE_FONT_SUBPX |
|||
help |
|||
Set the pixel order of the display. |
|||
Important only if "subpx fonts" are used. |
|||
With "normal" font it doesn't matter. |
|||
endmenu |
|||
|
|||
menu "Text Settings" |
|||
choice LV_TXT_ENC |
|||
prompt "Select a character encoding for strings" |
|||
help |
|||
Select a character encoding for strings. Your IDE or editor should have the same character encoding. |
|||
default LV_TXT_ENC_UTF8 if !LV_CONF_MINIMAL |
|||
default LV_TXT_ENC_ASCII if LV_CONF_MINIMAL |
|||
|
|||
config LV_TXT_ENC_UTF8 |
|||
bool "UTF8" |
|||
config LV_TXT_ENC_ASCII |
|||
bool "ASCII" |
|||
endchoice |
|||
|
|||
config LV_TXT_BREAK_CHARS |
|||
string "Can break (wrap) texts on these chars" |
|||
default " ,.;:-_" |
|||
|
|||
config LV_TXT_LINE_BREAK_LONG_LEN |
|||
int "Line break long length" |
|||
default 0 |
|||
help |
|||
If a word is at least this long, will break wherever 'prettiest'. |
|||
To disable, set to a value <= 0. |
|||
|
|||
config LV_TXT_LINE_BREAK_LONG_PRE_MIN_LEN |
|||
int "Min num chars before break" |
|||
default 3 |
|||
depends on LV_TXT_LINE_BREAK_LONG_LEN > 0 |
|||
help |
|||
Minimum number of characters in a long word to put on a line before a break. |
|||
|
|||
config LV_TXT_LINE_BREAK_LONG_POST_MIN_LEN |
|||
int "Min num chars after break" |
|||
default 3 |
|||
depends on LV_TXT_LINE_BREAK_LONG_LEN > 0 |
|||
help |
|||
Minimum number of characters in a long word to put on a line after a break. |
|||
|
|||
config LV_TXT_COLOR_CMD |
|||
string "The control character to use for signalling text recoloring" |
|||
default "#" |
|||
|
|||
config LV_USE_BIDI |
|||
bool "Support bidirectional texts" |
|||
help |
|||
Allows mixing Left-to-Right and Right-to-Left texts. |
|||
The direction will be processed according to the Unicode Bidirectional Algorithm: |
|||
https://www.w3.org/International/articles/inline-bidi-markup/uba-basics |
|||
|
|||
choice |
|||
prompt "Set the default BIDI direction" |
|||
default LV_BIDI_DIR_AUTO |
|||
depends on LV_USE_BIDI |
|||
|
|||
config LV_BIDI_DIR_LTR |
|||
bool "Left-to-Right" |
|||
config LV_BIDI_DIR_RTL |
|||
bool "Right-to-Left" |
|||
config LV_BIDI_DIR_AUTO |
|||
bool "Detect texts base direction" |
|||
endchoice |
|||
|
|||
config LV_USE_ARABIC_PERSIAN_CHARS |
|||
bool "Enable Arabic/Persian processing" |
|||
help |
|||
In these languages characters should be replaced with |
|||
an other form based on their position in the text. |
|||
endmenu |
|||
|
|||
menu "Widget usage" |
|||
config LV_USE_ARC |
|||
bool "Arc." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_BAR |
|||
bool "Bar." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_BTN |
|||
bool "Button." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_BTNMATRIX |
|||
bool "Button matrix." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_CANVAS |
|||
bool "Canvas. Dependencies: lv_img." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_CHECKBOX |
|||
bool "Check Box" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_DROPDOWN |
|||
bool "Drop down list. Requires: lv_label." |
|||
select LV_USE_LABEL |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_IMG |
|||
bool "Image. Requires: lv_label." |
|||
select LV_USE_LABEL |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_LABEL |
|||
bool "Label." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_LABEL_TEXT_SELECTION |
|||
bool "Enable selecting text of the label." |
|||
depends on LV_USE_LABEL |
|||
default y |
|||
config LV_LABEL_LONG_TXT_HINT |
|||
bool "Store extra some info in labels (12 bytes) to speed up drawing of very long texts." |
|||
depends on LV_USE_LABEL |
|||
default y |
|||
config LV_USE_LINE |
|||
bool "Line." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_ROLLER |
|||
bool "Roller. Requires: lv_label." |
|||
select LV_USE_LABEL |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_ROLLER_INF_PAGES |
|||
int "Number of extra 'pages' when the controller is infinite." |
|||
default 7 |
|||
depends on LV_USE_ROLLER |
|||
config LV_USE_SLIDER |
|||
bool "Slider. Requires: lv_bar." |
|||
select LV_USE_BAR |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_SWITCH |
|||
bool "Switch." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_TEXTAREA |
|||
bool "Text area. Requires: lv_label." |
|||
select LV_USE_LABEL |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_TEXTAREA_DEF_PWD_SHOW_TIME |
|||
int "Text area def. pwd show time [ms]." |
|||
default 1500 |
|||
depends on LV_USE_TEXTAREA |
|||
config LV_USE_TABLE |
|||
bool "Table." |
|||
default y if !LV_CONF_MINIMAL |
|||
endmenu |
|||
|
|||
menu "Extra Widgets" |
|||
config LV_USE_ANIMIMG |
|||
bool "Anim image." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_CALENDAR |
|||
bool "Calendar." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_CALENDAR_WEEK_STARTS_MONDAY |
|||
bool "Calendar week starts monday." |
|||
depends on LV_USE_CALENDAR |
|||
config LV_USE_CALENDAR_HEADER_ARROW |
|||
bool "Use calendar header arrow" |
|||
depends on LV_USE_CALENDAR |
|||
default y |
|||
config LV_USE_CALENDAR_HEADER_DROPDOWN |
|||
bool "Use calendar header dropdown" |
|||
depends on LV_USE_CALENDAR |
|||
default y |
|||
config LV_USE_CHART |
|||
bool "Chart." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_COLORWHEEL |
|||
bool "Colorwheel." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_IMGBTN |
|||
bool "Imgbtn." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_KEYBOARD |
|||
bool "Keyboard." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_LED |
|||
bool "LED." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_LIST |
|||
bool "List." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_METER |
|||
bool "Meter." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_MSGBOX |
|||
bool "Msgbox." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_SPINBOX |
|||
bool "Spinbox." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_SPINNER |
|||
bool "Spinner." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_TABVIEW |
|||
bool "Tabview." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_TILEVIEW |
|||
bool "Tileview" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_WIN |
|||
bool "Win" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_SPAN |
|||
bool "span" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_SPAN_SNIPPET_STACK_SIZE |
|||
int "Maximum number of span descriptor" |
|||
default 64 |
|||
depends on LV_USE_SPAN |
|||
endmenu |
|||
|
|||
menu "Themes" |
|||
config LV_USE_THEME_DEFAULT |
|||
bool "A simple, impressive and very complete theme" |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_THEME_DEFAULT_DARK |
|||
bool "Yes to set dark mode, No to set light mode" |
|||
depends on LV_USE_THEME_DEFAULT |
|||
config LV_THEME_DEFAULT_GROW |
|||
bool "Enable grow on press" |
|||
default y |
|||
depends on LV_USE_THEME_DEFAULT |
|||
config LV_THEME_DEFAULT_TRANSITION_TIME |
|||
int "Default transition time in [ms]" |
|||
default 80 |
|||
depends on LV_USE_THEME_DEFAULT |
|||
config LV_USE_THEME_BASIC |
|||
bool "A very simple theme that is a good starting point for a custom theme" |
|||
default y if !LV_CONF_MINIMAL |
|||
endmenu |
|||
|
|||
menu "Layouts" |
|||
config LV_USE_FLEX |
|||
bool "A layout similar to Flexbox in CSS." |
|||
default y if !LV_CONF_MINIMAL |
|||
config LV_USE_GRID |
|||
bool "A layout similar to Grid in CSS." |
|||
default y if !LV_CONF_MINIMAL |
|||
endmenu |
|||
|
|||
menu "3rd Party Libraries" |
|||
config LV_USE_FS_STDIO |
|||
int "File system on top of stdio API" |
|||
default 0 |
|||
config LV_FS_STDIO_PATH |
|||
string "Set the working directory" |
|||
depends on LV_USE_FS_STDIO |
|||
|
|||
config LV_USE_FS_POSIX |
|||
int "File system on top of posix API" |
|||
default 0 |
|||
config LV_FS_POSIX_PATH |
|||
string "Set the working directory" |
|||
depends on LV_USE_FS_POSIX |
|||
|
|||
config LV_USE_FS_WIN32 |
|||
int "File system on top of Win32 API" |
|||
default 0 |
|||
config LV_FS_WIN32_PATH |
|||
string "Set the working directory" |
|||
depends on LV_USE_FS_WIN32 |
|||
|
|||
config LV_USE_FS_FATFS |
|||
int "File system on top of FatFS" |
|||
default 0 |
|||
|
|||
config LV_USE_PNG |
|||
bool "PNG decoder library" |
|||
|
|||
config LV_USE_BMP |
|||
bool "BMP decoder library" |
|||
|
|||
config LV_USE_SJPG |
|||
bool "JPG + split JPG decoder library" |
|||
|
|||
config LV_USE_GIF |
|||
bool "GIF decoder library" |
|||
|
|||
config LV_USE_QRCODE |
|||
bool "QR code library" |
|||
|
|||
config LV_USE_FREETYPE |
|||
bool "FreeType library" |
|||
config LV_FREETYPE_CACHE_SIZE |
|||
int "Memory used by FreeType to cache characters [bytes] (-1: no caching)" |
|||
depends on LV_USE_FREETYPE |
|||
default 16384 |
|||
|
|||
config LV_USE_RLOTTIE |
|||
bool "Lottie library" |
|||
endmenu |
|||
|
|||
menu "Others" |
|||
config LV_USE_SNAPSHOT |
|||
bool "Enable API to take snapshot" |
|||
default y if !LV_CONF_MINIMAL |
|||
endmenu |
|||
|
|||
menu "Examples" |
|||
config LV_BUILD_EXAMPLES |
|||
bool "Enable the examples to be built" |
|||
default y if !LV_CONF_MINIMAL |
|||
endmenu |
|||
|
|||
config LV_BUILD_EXAMPLES |
|||
bool "Enable the examples to be built with the library." |
|||
default y |
|||
|
|||
endmenu |
|||
endif |
@ -0,0 +1,8 @@ |
|||
MIT licence |
|||
Copyright (c) 2021 LVGL Kft |
|||
|
|||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the โSoftwareโ), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: |
|||
|
|||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. |
|||
|
|||
THE SOFTWARE IS PROVIDED โAS ISโ, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
@ -0,0 +1,5 @@ |
|||
LVGL_DIR := .. |
|||
LVGL_DIR_NAME = lvgl |
|||
SRC_FILES += $(VPATH) |
|||
include lvgl.mk |
|||
include $(KERNEL_ROOT)/compiler.mk |
@ -0,0 +1,181 @@ |
|||
<h1 align="center"> LVGL - Light and Versatile Graphics Library</h1> |
|||
|
|||
<p align="center"> |
|||
<img src="https://lvgl.io/assets/images/lvgl_widgets_demo.gif"> |
|||
</p> |
|||
|
|||
<p align="center"> |
|||
LVGL provides everything you need to create an embedded GUI with easy-to-use graphical elements, beautiful visual effects and a low memory footprint. |
|||
</p> |
|||
|
|||
<h4 align="center"> |
|||
<a href="https://lvgl.io">Website </a> · |
|||
<a href="https://docs.lvgl.io/">Docs</a> · |
|||
<a href="https://forum.lvgl.io">Forum</a> · |
|||
<a href="https://lvgl.io/services">Services</a> · |
|||
<a href="https://docs.lvgl.io/master/examples.html">Interactive examples</a> |
|||
</h4> |
|||
|
|||
--- |
|||
|
|||
#### Table of content |
|||
- [Overview](#overview) |
|||
- [Get started](#get-started) |
|||
- [Examples](#examples) |
|||
- [Services](#services) |
|||
- [Contributing](#contributing) |
|||
|
|||
|
|||
## Overview |
|||
### Features |
|||
* Powerful [building blocks](https://docs.lvgl.io/master/widgets/index.html): buttons, charts, lists, sliders, images, etc. |
|||
* Advanced graphics engine: animations, anti-aliasing, opacity, smooth scrolling, blending modes, etc |
|||
* Supports [various input devices](https://docs.lvgl.io/master/overview/indev.html): touchscreen, mouse, keyboard, encoder, buttons, etc. |
|||
* Supports [multiple displays](https://docs.lvgl.io/master/overview/display.html) |
|||
* Hardware independent, can be use with any microcontroller and display |
|||
* Scalable to operate with little memory (64 kB Flash, 16 kB RAM) |
|||
* Multi-language support with UTF-8 handling, CJK, Bidirectional and Arabic script support |
|||
* Fully customizable graphical elements via [CSS-like styles](https://docs.lvgl.io/master/overview/style.html) |
|||
* Powerful layouts inspired by CSS: [Flexbox](https://docs.lvgl.io/master/layouts/flex.html) and [Grid](https://docs.lvgl.io/master/layouts/grid.html) |
|||
* OS, External memory and GPU are supported but not required. (built in support for STM32 DMA2D, and NXP PXP and VGLite) |
|||
* Smooth rendering even with a [single frame buffer](https://docs.lvgl.io/master/porting/display.html) |
|||
* Written in C and compatibile with C++ |
|||
* Micropython Binding exposes [LVGL API in Micropython](https://blog.lvgl.io/2019-02-20/micropython-bindings) |
|||
* [Simulator](https://docs.lvgl.io/master/get-started/pc-simulator.html) to develop on PC without embedded hardware |
|||
* 100+ simple [Examples](https://github.com/lvgl/lvgl/tree/master/examples) |
|||
* [Documentation](http://docs.lvgl.io/) and API references online and in PDF |
|||
|
|||
### Requirements |
|||
Basically, every modern controller (which is able to drive a display) is suitable to run LVGL. The minimal requirements are: |
|||
<table> |
|||
<tr> |
|||
<td> <strong>Name</strong> </td> |
|||
<td><strong>Minimal</strong></td> |
|||
<td><strong>Recommended</strong></td> |
|||
</tr> |
|||
<tr> |
|||
<td><strong>Architecture</strong></td> |
|||
<td colspan="2">16, 32 or 64 bit microcontroller or processor</td> |
|||
</tr> |
|||
<tr> |
|||
<td> <strong>Clock</strong></td> |
|||
<td> > 16 MHz </td> |
|||
<td> > 48 MHz</td> |
|||
</tr> |
|||
|
|||
<tr> |
|||
<td> <strong>Flash/ROM</strong></td> |
|||
<td> > 64 kB </td> |
|||
<td> > 180 kB</td> |
|||
</tr> |
|||
|
|||
<tr> |
|||
<td> <strong>Static RAM</strong></td> |
|||
<td> > 16 kB </td> |
|||
<td> > 48 kB</td> |
|||
</tr> |
|||
|
|||
<tr> |
|||
<td> <strong>Draw buffer</strong></td> |
|||
<td> > 1 × <em>hor. res.</em> pixels </td> |
|||
<td> > 1/10 screen size </td> |
|||
</tr> |
|||
|
|||
<tr> |
|||
<td> <strong>Compiler</strong></td> |
|||
<td colspan="2"> C99 or newer </td> |
|||
</tr> |
|||
</table> |
|||
|
|||
*Note that the memory usage might vary depending on the architecture, compiler and build options.* |
|||
|
|||
### Supported platforms |
|||
LVGL is completely platform independent and can be used with any MCU that fulfills the requirements. |
|||
Just to mention some platforms: |
|||
- NXP: Kinetis, LPC, iMX, iMX RT |
|||
- STM32F1, STM32F3, STM32F4, STM32F7, STM32L4, STM32L5, STM32H7 |
|||
- Microchip dsPIC33, PIC24, PIC32MX, PIC32MZ |
|||
- [Linux frame buffer](https://blog.lvgl.io/2018-01-03/linux_fb) (/dev/fb) |
|||
- [Raspberry Pi](http://www.vk3erw.com/index.php/16-software/63-raspberry-pi-official-7-touchscreen-and-littlevgl) |
|||
- [Espressif ESP32](https://github.com/lvgl/lv_port_esp32) |
|||
- [Infineon Aurix](https://github.com/lvgl/lv_port_aurix) |
|||
- Nordic NRF52 Bluetooth modules |
|||
- Quectel modems |
|||
|
|||
LVGL is also avaiable as: |
|||
- [Arduino library](https://docs.lvgl.io/master/get-started/arduino.html) |
|||
- [PlatformIO package](https://platformio.org/lib/show/12440/lvgl) |
|||
- [Zephyr library](https://docs.zephyrproject.org/latest/reference/kconfig/CONFIG_LVGL.html) |
|||
- [ESP32 component](https://docs.lvgl.io/master/get-started/espressif.html) |
|||
- [NXP MCUXpresso component](https://www.nxp.com/design/software/embedded-software/lvgl-open-source-graphics-library:LITTLEVGL-OPEN-SOURCE-GRAPHICS-LIBRARY) |
|||
- [NuttX library](https://docs.lvgl.io/master/get-started/nuttx.html) |
|||
|
|||
|
|||
## Get started |
|||
This list shows the recommended way of learning the library: |
|||
1. Check the [Online demos](https://lvgl.io/demos) to see LVGL in action (3 minutes) |
|||
2. Read the [Introduction](https://docs.lvgl.io/master/intro/index.html) page of the documentation (5 minutes) |
|||
3. Get familiar with the basics on the [Quick overview](https://docs.lvgl.io/master/get-started/quick-overview.html) page (15 minutes) |
|||
4. Set up a [Simulator](https://docs.lvgl.io/master/get-started/pc-simulator.html) (10 minutes) |
|||
5. Try out some [Examples](https://github.com/lvgl/lvgl/tree/master/examples) |
|||
6. Port LVGL to a board. See the [Porting](https://docs.lvgl.io/master/porting/index.html) guide or check the ready to use [Projects](https://github.com/lvgl?q=lv_port_) |
|||
7. Read the [Overview](https://docs.lvgl.io/master/overview/index.html) page to get a better understanding of the library (2-3 hours) |
|||
8. Check the documentation of the [Widgets](https://docs.lvgl.io/master/widgets/index.html) to see their features and usage |
|||
9. If you have questions go to the [Forum](http://forum.lvgl.io/) |
|||
10. Read the [Contributing](https://docs.lvgl.io/master/CONTRIBUTING.html) guide to see how you can help to improve LVGL (15 minutes) |
|||
|
|||
## Examples |
|||
|
|||
For more examples see the [examples](https://github.com/lvgl/lvgl/tree/master/examples) folder. |
|||
|
|||
 |
|||
|
|||
### C |
|||
```c |
|||
lv_obj_t * btn = lv_btn_create(lv_scr_act()); /*Add a button to the current screen*/ |
|||
lv_obj_set_pos(btn, 10, 10); /*Set its position*/ |
|||
lv_obj_set_size(btn, 100, 50); /*Set its size*/ |
|||
lv_obj_add_event_cb(btn, btn_event_cb, LV_EVENT_CLICKED, NULL); /*Assign a callback to the button*/ |
|||
|
|||
lv_obj_t * label = lv_label_create(btn); /*Add a label to the button*/ |
|||
lv_label_set_text(label, "Button"); /*Set the labels text*/ |
|||
lv_obj_center(label); /*Align the label to the center*/ |
|||
... |
|||
|
|||
void btn_event_cb(lv_event_t * e) |
|||
{ |
|||
printf("Clicked\n"); |
|||
} |
|||
``` |
|||
### Micropython |
|||
Learn more about [Micropython](https://docs.lvgl.io/master/get-started/micropython.html). |
|||
```python |
|||
def btn_event_cb(e): |
|||
print("Clicked") |
|||
|
|||
# Create a Button and a Label |
|||
btn = lv.btn(lv.scr_act()) |
|||
btn.set_pos(10, 10) |
|||
btn.set_size(100, 50) |
|||
btn.add_event_cb(btn_event_cb, lv.EVENT.CLICKED, None) |
|||
|
|||
label = lv.label(btn) |
|||
label.set_text("Button") |
|||
label.center() |
|||
``` |
|||
|
|||
## Services |
|||
LVGL Kft was established to provide a solid background for LVGL library. We offer several type of services to help you in UI development: |
|||
- Graphics design |
|||
- UI implementation |
|||
- Consulting/Support |
|||
|
|||
For more information see https://lvgl.io/services |
|||
Feel free to contact us if you have any questions. |
|||
|
|||
|
|||
## Contributing |
|||
LVGL is an open project and contribution is very welcome. There are many ways to contribute from simply speaking about your project, through writing examples, improving the documentation, fixing bugs to hosting your own project under the LVGL organization. |
|||
|
|||
For a detailed description of contribution opportunities visit the [Contributing](https://docs.lvgl.io/master/CONTRIBUTING.html) section of the documentation. |
|||
|
@ -0,0 +1,11 @@ |
|||
# RT-Thread building script for bridge |
|||
|
|||
import os |
|||
from building import * |
|||
|
|||
objs = [] |
|||
cwd = GetCurrentDir() |
|||
|
|||
objs = objs + SConscript(cwd + '/rt-thread/SConscript') |
|||
|
|||
Return('objs') |
@ -0,0 +1,34 @@ |
|||
# ESP-IDF component file for make based commands
|
|||
|
|||
COMPONENT_SRCDIRS := . \
|
|||
src \
|
|||
src/core \
|
|||
src/draw \
|
|||
src/extra \
|
|||
src/font \
|
|||
src/gpu \
|
|||
src/hal \
|
|||
src/misc \
|
|||
src/widgets \
|
|||
src/extra/layouts \
|
|||
src/extra/layouts/flex \
|
|||
src/extra/layouts/grid \
|
|||
src/extra/themes \
|
|||
src/extra/themes/basic \
|
|||
src/extra/themes/default \
|
|||
src/extra/widgets/calendar \
|
|||
src/extra/widgets/colorwheel \
|
|||
src/extra/widgets \
|
|||
src/extra/widgets/imgbtn \
|
|||
src/extra/widgets/keyboard \
|
|||
src/extra/widgets/led \
|
|||
src/extra/widgets/list \
|
|||
src/extra/widgets/msgbox \
|
|||
src/extra/widgets/spinbox \
|
|||
src/extra/widgets/spinner \
|
|||
src/extra/widgets/tabview \
|
|||
src/extra/widgets/tileview \
|
|||
src/extra/widgets/win |
|||
|
|||
|
|||
COMPONENT_ADD_INCLUDEDIRS := $(COMPONENT_SRCDIRS) . |
File diff suppressed because it is too large
@ -0,0 +1,46 @@ |
|||
# Contributor Covenant Code of Conduct |
|||
|
|||
## Our Pledge |
|||
|
|||
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation. |
|||
|
|||
## Our Standards |
|||
|
|||
Examples of behavior that contributes to creating a positive environment include: |
|||
|
|||
* Using welcoming and inclusive language |
|||
* Being respectful of differing viewpoints and experiences |
|||
* Gracefully accepting constructive criticism |
|||
* Focusing on what is best for the community |
|||
* Showing empathy towards other community members |
|||
|
|||
Examples of unacceptable behavior by participants include: |
|||
|
|||
* The use of sexualized language or imagery and unwelcome sexual attention or advances |
|||
* Trolling, insulting/derogatory comments, and personal or political attacks |
|||
* Public or private harassment |
|||
* Publishing others' private information, such as a physical or electronic address, without explicit permission |
|||
* Other conduct which could reasonably be considered inappropriate in a professional setting |
|||
|
|||
## Our Responsibilities |
|||
|
|||
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior. |
|||
|
|||
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. |
|||
|
|||
## Scope |
|||
|
|||
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers. |
|||
|
|||
## Enforcement |
|||
|
|||
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team using the [contact form](https://lvgl.io/about). All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately. |
|||
|
|||
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership. |
|||
|
|||
## Attribution |
|||
|
|||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version] |
|||
|
|||
[homepage]: http://contributor-covenant.org |
|||
[version]: http://contributor-covenant.org/version/1/4/ |
@ -0,0 +1,89 @@ |
|||
# Coding style |
|||
|
|||
## File format |
|||
Use [misc/lv_templ.c](https://github.com/lvgl/lvgl/blob/master/src/misc/lv_templ.c) and [misc/lv_templ.h](https://github.com/lvgl/lvgl/blob/master/src/misc/lv_templ.h) |
|||
|
|||
## Naming conventions |
|||
* Words are separated by '_' |
|||
* In variable and function names use only lower case letters (e.g. *height_tmp*) |
|||
* In enums and defines use only upper case letters (e.g. *e.g. MAX_LINE_NUM*) |
|||
* Global names (API): |
|||
* start with *lv* |
|||
* followed by module name: *btn*, *label*, *style* etc. |
|||
* followed by the action (for functions): *set*, *get*, *refr* etc. |
|||
* closed with the subject: *name*, *size*, *state* etc. |
|||
* Typedefs |
|||
* prefer `typedef struct` and `typedef enum` instead of `struct name` and `enum name` |
|||
* always end `typedef struct` and `typedef enum` type names with `_t` |
|||
* Abbreviations: |
|||
* Only words longer or equal than 6 characters can be abbreviated. |
|||
* Abbreviate only if it makes the word at least half as long |
|||
* Use only very straightforward and well-known abbreviations (e.g. pos: position, def: default, btn: button) |
|||
|
|||
## Coding guide |
|||
* Functions: |
|||
* Try to write function shorter than is 50 lines |
|||
* Always shorter than 200 lines (except very straightforwards) |
|||
* Variables: |
|||
* One line, one declaration (BAD: char x, y;) |
|||
* Use `<stdint.h>` (*uint8_t*, *int32_t* etc) |
|||
* Declare variables where needed (not all at function start) |
|||
* Use the smallest required scope |
|||
* Variables in a file (outside functions) are always *static* |
|||
* Do not use global variables (use functions to set/get static variables) |
|||
|
|||
## Comments |
|||
Before every function have a comment like this: |
|||
|
|||
```c |
|||
/** |
|||
* Return with the screen of an object |
|||
* @param obj pointer to an object |
|||
* @return pointer to a screen |
|||
*/ |
|||
lv_obj_t * lv_obj_get_scr(lv_obj_t * obj); |
|||
``` |
|||
|
|||
Always use `/*Something*/` format and NOT `//Something` |
|||
|
|||
Write readable code to avoid descriptive comments like: |
|||
`x++; /*Add 1 to x*/`. |
|||
The code should show clearly what you are doing. |
|||
|
|||
You should write **why** have you done this: |
|||
`x++; /*Because of closing '\0' of the string*/` |
|||
|
|||
Short "code summaries" of a few lines are accepted. E.g. `/*Calculate the new coordinates*/` |
|||
|
|||
In comments use \` \` when referring to a variable. E.g. ``/*Update the value of `x_act`*/`` |
|||
|
|||
### Formatting |
|||
Here is example to show bracket placing and using of white spaces: |
|||
```c |
|||
/** |
|||
* Set a new text for a label. Memory will be allocated to store the text by the label. |
|||
* @param label pointer to a label object |
|||
* @param text '\0' terminated character string. NULL to refresh with the current text. |
|||
*/ |
|||
void lv_label_set_text(lv_obj_t * label, const char * text) |
|||
{ /*Main brackets of functions in new line*/ |
|||
|
|||
if(label == NULL) return; /*No bracket only if the command is inline with the if statement*/ |
|||
|
|||
lv_obj_inv(label); |
|||
|
|||
lv_label_ext_t * ext = lv_obj_get_ext(label); |
|||
|
|||
/*Comment before a section*/ |
|||
if(text == ext->txt || text == NULL) { /*Bracket of statements start inline*/ |
|||
lv_label_refr_text(label); |
|||
return; |
|||
} |
|||
|
|||
... |
|||
} |
|||
``` |
|||
|
|||
Use 4 spaces indentation instead of tab. |
|||
|
|||
You can use **astyle** to format the code. Run `code-formatter.sh` from the `scrips` folder. |
@ -0,0 +1,266 @@ |
|||
```eval_rst |
|||
.. include:: /header.rst |
|||
:github_url: |github_link_base|/CONTRIBUTING.md |
|||
``` |
|||
|
|||
# Contributing |
|||
|
|||
## Introduction |
|||
|
|||
Join LVGL's community and leave your footprint in the library! |
|||
|
|||
There are a lot of ways to contribute to LVGL even if you are new to the library or even new to programming. |
|||
|
|||
It might be scary to make the first step but you have nothing to be afraid of. |
|||
A friendly and helpful community is waiting for you. Get to know like-minded people and make something great together. |
|||
|
|||
So let's find which contribution option fits you the best and help you join the development of LVGL! |
|||
|
|||
Before getting started here are some guidelines to make contribution smoother: |
|||
- Be kind and friendly. |
|||
- Be sure to read the relevant part of the documentation before posting a question. |
|||
- Ask questions in the [Forum](https://forum.lvgl.io/) and use [GitHub](https://github.com/lvgl/) for development-related discussions. |
|||
- Always fill out the post or issue templates in the Forum or GitHub (or at least provide equivalent information). It makes understanding your contribution or issue easier and you will get a useful response faster. |
|||
- If possible send an absolute minimal but buildable code example in order to reproduce the issue. Be sure it contains all the required variable declarations, constants, and assets (images, fonts). |
|||
- Use [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet) to format your posts. You can learn it in 10 minutes. |
|||
- Speak about one thing in one issue or topic. It makes your post easier to find later for someone with the same question. |
|||
- Give feedback and close the issue or mark the topic as solved if your question is answered. |
|||
- For non-trivial fixes and features, it's better to open an issue first to discuss the details instead of sending a pull request directly. |
|||
- Please read and follow the <a href="https://github.com/lvgl/lvgl/blob/master/docs/CODING_STYLE.md">Coding style</a> guide. |
|||
|
|||
## Pull request |
|||
|
|||
Merging new code into the lvgl, documentation, blog, examples, and other repositories happen via *Pull requests* (PR for short). |
|||
A PR is a notification like "Hey, I made some updates to your project. Here are the changes, you can add them if you want." |
|||
To do this you need a copy (called fork) of the original project under your account, make some changes there, and notify the original repository about your updates. |
|||
You can see what it looks like on GitHub for LVGL here: [https://github.com/lvgl/lvgl/pulls](https://github.com/lvgl/lvgl/pulls). |
|||
|
|||
To add your changes you can edit files online on GitHub and send a new Pull request from there (recommended for small changes) or |
|||
add the updates in your favorite editor/IDE and use git to publish the changes (recommended for more complex updates). |
|||
|
|||
### From GitHub |
|||
1. Navigate to the file you want to edit. |
|||
2. Click the Edit button in the top right-hand corner. |
|||
3. Add your changes to the file. |
|||
4. Add a commit message on the bottom of the page. |
|||
5. Click the *Propose changes* button. |
|||
|
|||
### From command line |
|||
|
|||
The instructions describe the main `lvgl` repository but it works the same way for the other repositories. |
|||
1. Fork the [lvgl repository](https://github.com/lvgl/lvgl). To do this click the "Fork" button in the top right corner. |
|||
It will "copy" the `lvgl` repository to your GitHub account (`https://github.com/<YOUR_NAME>?tab=repositories`) |
|||
2. Clone your forked repository. |
|||
3. Add your changes. You can create a *feature branch* from *master* for the updates: `git checkout -b the-new-feature` |
|||
4. Commit and push your changes to the forked `lvgl` repository. |
|||
5. Create a PR on GitHub from the page of your `lvgl` repository (`https://github.com/<YOUR_NAME>/lvgl`) by clicking the *"New pull request"* button. Don't forget to select the branch where you added your changes. |
|||
7. Set the base branch. It means where you want to merge your update. In the `lvgl` repo fixes go to `master`, new features to `dev` branch. |
|||
8. Describe what is in the update. An example code is welcome if applicable. |
|||
9. If you need to make more changes, just update your forked `lvgl` repo with new commits. They will automatically appear in the PR. |
|||
|
|||
### Commit message format |
|||
In commit messages please follow the [Angular Commit Format](https://gist.github.com/brianclements/841ea7bffdb01346392c). |
|||
|
|||
Some examples: |
|||
``` |
|||
fix(img) update size if a new source is set |
|||
``` |
|||
|
|||
``` |
|||
fix(bar) fix memory leak |
|||
|
|||
The animations weren't deleted in the destructor. |
|||
|
|||
Fixes: #1234 |
|||
``` |
|||
|
|||
``` |
|||
feat add span widget |
|||
|
|||
The span widget allows mixing different font sizes, colors and styles. |
|||
It's similar to HTML <span> |
|||
``` |
|||
|
|||
``` |
|||
docs(porting) fix typo |
|||
``` |
|||
|
|||
## Developer Certification of Origin (DCO) |
|||
|
|||
### Overview |
|||
|
|||
To ensure all licensing criteria are met for every repository of the LVGL project, we apply a process called DCO (Developer's Certificate of Origin). |
|||
|
|||
The text of DCO can be read here: [https://developercertificate.org/](https://developercertificate.org/). |
|||
|
|||
By contributing to any repositories of the LVGL project you agree that your contribution complies with the DCO. |
|||
|
|||
If your contribution fulfills the requirements of the DCO no further action is needed. If you are unsure feel free to ask us in a comment. |
|||
|
|||
### Accepted licenses and copyright notices |
|||
|
|||
To make the DCO easier to digest, here are some practical guides about specific cases: |
|||
|
|||
#### Your own work |
|||
|
|||
The simplest case is when the contribution is solely your own work. |
|||
In this case you can just send a Pull Request without worrying about any licensing issues. |
|||
|
|||
#### Use code from online source |
|||
|
|||
If the code you would like to add is based on an article, post or comment on a website (e.g. StackOverflow) the license and/or rules of that site should be followed. |
|||
|
|||
For example in case of StackOwerflow a notice like this can be used: |
|||
``` |
|||
/* The original version of this code-snippet was published on StackOverflow. |
|||
* Post: http://stackoverflow.com/questions/12345 |
|||
* Author: http://stackoverflow.com/users/12345/username |
|||
* The following parts of the snippet were changed: |
|||
* - Check this or that |
|||
* - Optimize performance here and there |
|||
*/ |
|||
... code snippet here ... |
|||
``` |
|||
|
|||
#### Use MIT licensed code |
|||
As LVGL is MIT licensed, other MIT licensed code can be integrated without issues. |
|||
The MIT license requires a copyright notice be added to the derived work. Any derivative work based on MIT licensed code must copy the original work's license file or text. |
|||
|
|||
#### Use GPL licensed code |
|||
The GPL license is not compatible with the MIT license. Therefore, LVGL can not accept GPL licensed code. |
|||
|
|||
## Ways to contribute |
|||
|
|||
Even if you're just getting started with LVGL there are plenty of ways to get your feet wet. |
|||
Most of these options don't even require knowing a single line of LVGL code. |
|||
|
|||
Below we have collected some opportunities about the ways you can contribute to LVGL. |
|||
|
|||
### Give LVGL a Star |
|||
|
|||
Show that you like LVGL by giving it star on GitHub! |
|||
<!-- Place this tag in your head or just before your close body tag. --> |
|||
<script async defer src="https://buttons.github.io/buttons.js"></script> |
|||
<!-- Place this tag where you want the button to render. --> |
|||
<a class="github-button" href="https://github.com/lvgl/lvgl" data-icon="octicon-star" data-size="large" data-show-count="true" aria-label="Star lvgl/lvgl on GitHub">Star</a> |
|||
|
|||
This simple click makes LVGL more visible on GitHub and makes it more attractive to other people. |
|||
So with this, you already helped a lot! |
|||
|
|||
### Tell what you have achieved |
|||
|
|||
Have you already started using LVGL in a [Simulator](/get-started/pc-simulator), a development board, or on your custom hardware? |
|||
Was it easy or were there some obstacles? Are you happy with the result? |
|||
Showing your project to others is a win-win situation because it increases your and LVGL's reputation at the same time. |
|||
|
|||
You can post about your project on Twitter, Facebook, LinkedIn, create a YouTube video, and so on. |
|||
Only one thing: On social media don't forget to add a link to `https://lvgl.io` or `https://github.com/lvgl` and use the hashtag `#lvgl`. Thank you! :) |
|||
|
|||
You can also open a new topic in the [My projects](https://forum.lvgl.io/c/my-projects/10) category of the Forum. |
|||
|
|||
The [LVGL Blog](https://blog.lvgl.io) welcomes posts from anyone. |
|||
It's a good place to talk about a project you created with LVGL, write a tutorial, or share some nice tricks. |
|||
The latest blog posts are shown on the [homepage of LVGL](https://lvgl.io) to make your work more visible. |
|||
|
|||
The blog is hosted on GitHub. If you add a post GitHub automatically turns it into a website. |
|||
See the [README](https://github.com/lvgl/blog) of the blog repo to see how to add your post. |
|||
|
|||
Any of these help to spread the word and familiarize new developers with LVGL. |
|||
|
|||
If you don't want to speak about your project publicly, feel free to use [Contact form](https://lvgl.io/#contact) on lvgl.io to private message to us. |
|||
|
|||
### Write examples |
|||
As you learn LVGL you will probably play with the features of widgets. Why not publish your experiments? |
|||
|
|||
Each widgets' documentation contains examples. For instance, here are the examples of the [Drop-down list](/widgets/core/dropdown#examples) widget. |
|||
The examples are directly loaded from the [lvgl/examples](https://github.com/lvgl/lvgl/tree/master/examples) folder. |
|||
|
|||
So all you need to do is send a [Pull request](#pull-request) to the [lvgl](https://github.com/lvgl/lvgl) repository and follow some conventions: |
|||
- Name the examples like `lv_example_<widget_name>_<index>`. |
|||
- Make the example as short and simple as possible. |
|||
- Add comments to explain what the example does. |
|||
- Use 320x240 resolution. |
|||
- Update `index.rst` in the example's folder with your new example. To see how other examples are added, look in the [lvgl/examples/widgets](https://github.com/lvgl/lvgl/tree/master/examples/widgets) folder. |
|||
|
|||
### Improve the docs |
|||
|
|||
As you read the documentation you might see some typos or unclear sentences. All the documentation is located in the [lvgl/docs](https://github.com/lvgl/lvgl/tree/master/docs) folder. |
|||
For typos and straightforward fixes, you can simply edit the file on GitHub. |
|||
|
|||
Note that the documentation is also formatted in [Markdown](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet). |
|||
|
|||
### Report bugs |
|||
As you use LVGL you might find bugs. Before reporting them be sure to check the relevant parts of the documentation. |
|||
|
|||
If it really seems like a bug feel free to open an [issue on GitHub](https://github.com/lvgl/lvgl/issues). |
|||
|
|||
When filing the issue be sure to fill out the template. It helps find the root of the problem while avoiding extensive questions and exchanges with other developers. |
|||
|
|||
### Send fixes |
|||
The beauty of open-source software is you can easily dig in to it to understand how it works. You can also fix or adjust it as you wish. |
|||
|
|||
If you found and fixed a bug don't hesitate to send a [Pull request](#pull-request) with the fix. |
|||
|
|||
In your Pull request please also add a line to [`CHANGELOG.md`](https://github.com/lvgl/lvgl/blob/master/CHANGELOG.md). |
|||
|
|||
### Join the conversations in the Forum |
|||
It feels great to know you are not alone if something is not working. It's even better to help others when they struggle with something. |
|||
|
|||
While you were learning LVGL you might have had questions and used the Forum to get answers. As a result, you probably have more knowledge about how LVGL works. |
|||
|
|||
One of the best ways to give back is to use the Forum and answer the questions of newcomers - like you were once. |
|||
|
|||
Just read the titles and if you are familiar with the topic don't hesitate to share your thoughts and suggestions. |
|||
|
|||
Participating in the discussions is one of the best ways to become part of the project and get to know like-minded people! |
|||
|
|||
### Add features |
|||
If you have created a cool widget, or added useful feature to LVGL feel free to open a new PR for it. |
|||
We collect the optional features (a.k.a. plugins) in [lvgl/src/extra](https://github.com/lvgl/lvgl/tree/master/src/extra) folder so if you are interested in adding a new features please use this folder. |
|||
The [README](https://github.com/lvgl/lvgl/blob/master/src/extra/README.md) file describes the basics rules of contribution and also lists some ideas. |
|||
|
|||
For further ideas take a look at the [Roadmap](/ROADMAP) page. If you are interested in any of them feel free to share your opinion and/or participate in the implementation. |
|||
|
|||
Other features which are (still) not on the road map are listed in the [Feature request](https://forum.lvgl.io/c/feature-request/9) category of the Forum. |
|||
|
|||
When adding a new features the followings also needs to be updated: |
|||
- Update [lv_conf_template.h](https://github.com/lvgl/lvgl/blob/master/lv_conf_template.h) |
|||
- Add description in the [docs](https://github.com/lvgl/lvgl/tree/master/docs) |
|||
- Add [examples](https://github.com/lvgl/lvgl/tree/master/examples) |
|||
- Update the [changelog](https://github.com/lvgl/lvgl/tree/master/docs/CHANGELOG.md) |
|||
|
|||
### Become a maintainer |
|||
|
|||
If you want to become part of the core development team, you can become a maintainer of a repository. |
|||
|
|||
By becoming a maintainer: |
|||
- You get write access to that repo: |
|||
- Add code directly without sending a pull request |
|||
- Accept pull requests |
|||
- Close/reopen/edit issues |
|||
- Your input has higher impact when we are making decisions |
|||
|
|||
You can become a maintainer by invitation, however the following conditions need to met |
|||
1. Have > 50 replies in the Forum. You can look at your stats [here](https://forum.lvgl.io/u?period=all) |
|||
2. Send > 5 non-trivial pull requests to the repo where you would like to be a maintainer |
|||
|
|||
|
|||
If you are interested, just send a message (e.g. from the Forum) to the current maintainers of the repository. They will check if the prerequisites are met. |
|||
Note that meeting the prerequisites is not a guarantee of acceptance, i.e. if the conditions are met you won't automatically become a maintainer. |
|||
It's up to the current maintainers to make the decision. |
|||
|
|||
### Move your project repository under LVGL organization |
|||
Besides the core `lvgl` repository there are other repos for ports to development boards, IDEs or other environment. |
|||
If you ported LVGL to a new platform we can host it under the LVGL organization among the other repos. |
|||
|
|||
This way your project will become part of the whole LVGL project and can get more visibility. |
|||
If you are interested in this opportunity just open an [issue in lvgl repo](https://github.com/lvgl/lvgl/issues) and tell what you have! |
|||
|
|||
If we agree that your port fit well into the LVGL organization, we will open a repository for your project where you will have admin rights. |
|||
|
|||
To make this concept sustainable there a few rules to follow: |
|||
- You need to add a README to your repo. |
|||
- We expect to maintain the repo to some extent: |
|||
- Follow at least the major versions of LVGL |
|||
- Respond to the issues (in a reasonable time) |
|||
- If there is no activity in a repo for 1 year it will be archived |
@ -0,0 +1,82 @@ |
|||
# Roadmap |
|||
|
|||
This is a summary for planned new features and a collection of ideas. |
|||
This list indicates only the current intention and it can be changed. |
|||
|
|||
## v8.1 |
|||
### Features |
|||
- [x] Unit testing (gtest?). See #1658 |
|||
- [ ] Benchmarking (gem5 or qemu?). See #1660 |
|||
- [ ] lv_snapshot: buffer a widget and all of its children into an image. The source widget can be on a different screen too. The resulting image can be transformed. |
|||
- [ ] High level GPU support. See #2058 |
|||
|
|||
#### New features |
|||
- [x] merge MicroPython examples |
|||
- [x] add a "Try out yourself" button to the Micropython examples |
|||
|
|||
### Discuss |
|||
- [ ] CPP binding |
|||
- [ ] Plugins. In v8 core and extra widgets are separated. With the new flexible events, the behavior of the widgets can be modified in a modular way. E.g. a plugin to add faded area to a line chart (as in the widgets demo) |
|||
|
|||
### Docs |
|||
- [x] Display the Micropytohn examples too. |
|||
- [x] Add a link to the example C and py files |
|||
- [x] List of all examples on a page. All in iframes grouped by category (e.g. flex, style, button) |
|||
|
|||
### Others |
|||
- [ ] Add automatic rebuild to get binary directly. Similarly to [STM32F746 project](https://github.com/lvgl/lv_port_stm32f746_disco#try-it-with-just-a-few-clicks). |
|||
- [ ] Implement release scripts. I've added a basic specification [here](https://github.com/lvgl/lvgl/tree/master/scripts/release), but we should discuss it. |
|||
- [ ] Unit test for the core widgets |
|||
|
|||
## v8.2 |
|||
- [ ] Optimize line and circle drawing and masking |
|||
- [ ] Handle stride. See [#1858](https://github.com/lvgl/lvgl/issues/1858) |
|||
- [ ] Support LV_STATE_HOVERED |
|||
|
|||
## Ideas |
|||
- Reconsider color format management for run time color format setting, and custom color format usage. (Also [RGB888](https://github.com/lvgl/lvgl/issues/1722)) |
|||
- Make gradients more versatile |
|||
- Make image transformations more versatile |
|||
- Switch to RGBA colors in styles |
|||
- Consider direct binary font format support |
|||
- Simplify `group`s. Discussion is [here](https://forum.lvgl.io/t/lv-group-tabindex/2927/3). |
|||
- Use [generate-changelog](https://github.com/lob/generate-changelog) to automatically generate changelog |
|||
- lv_mem_alloc_aligned(size, align) |
|||
- Text node. See [#1701](https://github.com/lvgl/lvgl/issues/1701#issuecomment-699479408) |
|||
- CPP binding. See [Forum](https://forum.lvgl.io/t/is-it-possible-to-officially-support-optional-cpp-api/2736) |
|||
- Optimize font decompression |
|||
- Need coverage report for tests |
|||
- Need static analyze (via coverity.io or somehing else) |
|||
- Support dot_begin and dot_middle long modes for labels |
|||
- Add new label alignment modes. [#1656](https://github.com/lvgl/lvgl/issues/1656) |
|||
- Support larger images: [#1892](https://github.com/lvgl/lvgl/issues/1892) |
|||
|
|||
--- |
|||
|
|||
## v8 |
|||
- Create an `extra` folder for complex widgets |
|||
- It makes the core LVGL leaner |
|||
- In `extra` we can have a lot and specific widgets |
|||
- Good place for contributions |
|||
- New scrolling: |
|||
- See [feat/new-scroll](https://github.com/lvgl/lvgl/tree/feat/new-scroll) branch and [#1614](https://github.com/lvgl/lvgl/issues/1614)) issue. |
|||
- Remove `lv_page` and support scrolling on `lv_obj` |
|||
- Support "elastic" scrolling when scrolled in |
|||
- Support scroll chaining among any objects types (not only `lv_pages`s) |
|||
- Remove `lv_drag`. Similar effect can be achieved by setting the position in `LV_EVENT_PRESSING` |
|||
- Add snapping |
|||
- Add snap stop to scroll max 1 snap point |
|||
- Already working |
|||
- New layouts: |
|||
- See [#1615](https://github.com/lvgl/lvgl/issues/1615) issue |
|||
- [CSS Grid](https://css-tricks.com/snippets/css/a-guide-to-grid/)-like layout support |
|||
- [CSS Flexbox](https://css-tricks.com/snippets/css/a-guide-to-flexbox/)-like layout support |
|||
- Remove `lv_cont` and support layouts on `lv_obj` |
|||
- Simplified File system interface ([feat/new_fs_api](https://github.com/lvgl/lvgl/tree/feat/new-fs-api) branch) to make porting easier |
|||
- Work in progress |
|||
- Remove the align parameter from `lv_canvas_draw_text` |
|||
- Remove the copy parameter from create functions |
|||
- Optimize and simplify styles [#1832](https://github.com/lvgl/lvgl/issues/1832) |
|||
- Use a more generic inheritance [#1919](https://github.com/lvgl/lvgl/issues/1919) |
|||
- Allow adding multiple events to an object |
|||
|
@ -0,0 +1,98 @@ |
|||
import os |
|||
|
|||
from docutils import nodes |
|||
from docutils.parsers.rst import Directive, directives |
|||
from docutils.parsers.rst.directives.images import Image |
|||
from sphinx.directives.code import LiteralInclude |
|||
|
|||
|
|||
def excluded_list(argument): |
|||
return argument.split(',') |
|||
|
|||
|
|||
|
|||