lv_conf_checker.py handle prerocessor indentations (e.g. # define ...)

This commit is contained in:
Gabor Kiss-Vamosi
2019-01-29 10:28:48 +01:00
parent 92be58d1d8
commit dd41f411e6
2 changed files with 31 additions and 30 deletions

View File

@@ -16,26 +16,26 @@
#define LV_MEM_CUSTOM 0 /*1: use custom malloc/free, 0: use the built-in lv_mem_alloc/lv_mem_free*/
#endif
#if LV_MEM_CUSTOM == 0
#ifndef define
#ifndef LV_MEM_SIZE
# define LV_MEM_SIZE (64U * 1024U) /*Size memory used by `lv_mem_alloc` in bytes (>= 2kB)*/
#endif
#ifndef define
#ifndef LV_MEM_ATTR
# define LV_MEM_ATTR /*Complier prefix for big array declaration*/
#endif
#ifndef define
#ifndef LV_MEM_ADR
# define LV_MEM_ADR 0 /*Set an address for memory pool instead of allocation it as an array. Can be in external SRAM too.*/
#endif
#ifndef define
#ifndef LV_MEM_AUTO_DEFRAG
# define LV_MEM_AUTO_DEFRAG 1 /*Automatically defrag on free*/
#endif
#else /*LV_MEM_CUSTOM*/
#ifndef define
#ifndef LV_MEM_CUSTOM_INCLUDE
# define LV_MEM_CUSTOM_INCLUDE <stdlib.h> /*Header for the dynamic memory function*/
#endif
#ifndef define
#ifndef LV_MEM_CUSTOM_ALLOC
# define LV_MEM_CUSTOM_ALLOC malloc /*Wrapper to malloc*/
#endif
#ifndef define
#ifndef LV_MEM_CUSTOM_FREE
# define LV_MEM_CUSTOM_FREE free /*Wrapper to free*/
#endif
#endif /*LV_MEM_CUSTOM*/
@@ -45,13 +45,13 @@
#define LV_ENABLE_GC 0
#endif
#if LV_ENABLE_GC != 0
#ifndef define
#ifndef LV_MEM_CUSTOM_REALLOC
# define LV_MEM_CUSTOM_REALLOC your_realloc /*Wrapper to realloc*/
#endif
#ifndef define
#ifndef LV_MEM_CUSTOM_GET_SIZE
# define LV_MEM_CUSTOM_GET_SIZE your_mem_get_size /*Wrapper to lv_mem_get_size*/
#endif
#ifndef define
#ifndef LV_GC_INCLUDE
# define LV_GC_INCLUDE "gc.h" /*Include Garbage Collector related things*/
#endif
#endif /* LV_ENABLE_GC */
@@ -256,12 +256,12 @@
* LV_LOG_LEVEL_WARN Log if something unwanted happened but didn't caused problem
* LV_LOG_LEVEL_ERROR Only critical issue, when the system may fail
*/
#ifndef define
#ifndef LV_LOG_LEVEL
# define LV_LOG_LEVEL LV_LOG_LEVEL_WARN
#endif
/* 1: Print the log with 'printf'; 0: user need to register a callback*/
#ifndef define
#ifndef LV_LOG_PRINTF
# define LV_LOG_PRINTF 1
#endif
#endif /*USE_LV_LOG*/
@@ -405,7 +405,7 @@
#define USE_LV_LABEL 1
#endif
#if USE_LV_LABEL != 0
#ifndef define
#ifndef LV_LABEL_SCROLL_SPEED
# define LV_LABEL_SCROLL_SPEED 25 /*Hor, or ver. scroll speed [px/sec] in 'LV_LABEL_LONG_SCROLL/ROLL' mode*/
#endif
#endif
@@ -415,10 +415,10 @@
#define USE_LV_IMG 1
#endif
#if USE_LV_IMG != 0
#ifndef define
#ifndef LV_IMG_CF_INDEXED
# define LV_IMG_CF_INDEXED 1 /*Enable indexed (palette) images*/
#endif
#ifndef define
#ifndef LV_IMG_CF_ALPHA
# define LV_IMG_CF_ALPHA 1 /*Enable alpha indexed images*/
#endif
#endif
@@ -457,7 +457,7 @@
#define USE_LV_TABVIEW 1
#endif
# if USE_LV_TABVIEW != 0
#ifndef define
#ifndef LV_TABVIEW_ANIM_TIME
# define LV_TABVIEW_ANIM_TIME 300 /*Time of slide animation [ms] (0: no animation)*/
#endif
#endif
@@ -467,7 +467,7 @@
#define USE_LV_TILEVIEW 1
#endif
#if USE_LV_TILEVIEW
#ifndef define
#ifndef LV_TILEVIEW_ANIM_TIME
# define LV_TILEVIEW_ANIM_TIME 300 /*Time of slide animation [ms] (0: no animation)*/
#endif
#endif
@@ -501,7 +501,7 @@
#define USE_LV_TABLE 1
#endif
#if USE_LV_TABLE
#ifndef define
#ifndef LV_TABLE_COL_MAX
# define LV_TABLE_COL_MAX 12
#endif
#endif
@@ -521,10 +521,10 @@
#define USE_LV_TA 1
#endif
#if USE_LV_TA != 0
#ifndef define
#ifndef LV_TA_CURSOR_BLINK_TIME
# define LV_TA_CURSOR_BLINK_TIME 400 /*ms*/
#endif
#ifndef define
#ifndef LV_TA_PWD_SHOW_TIME
# define LV_TA_PWD_SHOW_TIME 1500 /*ms*/
#endif
#endif
@@ -544,13 +544,13 @@
#define USE_LV_PRELOAD 1
#endif
#if USE_LV_PRELOAD != 0
#ifndef define
#ifndef LV_PRELOAD_DEF_ARC_LENGTH
# define LV_PRELOAD_DEF_ARC_LENGTH 60 /*[deg]*/
#endif
#ifndef define
#ifndef LV_PRELOAD_DEF_SPIN_TIME
# define LV_PRELOAD_DEF_SPIN_TIME 1000 /*[ms]*/
#endif
#ifndef define
#ifndef LV_PRELOAD_DEF_ANIM
# define LV_PRELOAD_DEF_ANIM LV_PRELOAD_TYPE_SPINNING_ARC
#endif
#endif
@@ -568,7 +568,7 @@
#define USE_LV_BTN 1
#endif
#if USE_LV_BTN != 0
#ifndef define
#ifndef LV_BTN_INK_EFFECT
# define LV_BTN_INK_EFFECT 1 /*Enable button-state animations - draw a circle on click (dependencies: USE_LV_ANIMATION)*/
#endif
#endif
@@ -578,7 +578,7 @@
#define USE_LV_IMGBTN 1
#endif
#if USE_LV_IMGBTN
#ifndef define
#ifndef LV_IMGBTN_TILED
# define LV_IMGBTN_TILED 0 /*1: The imgbtn requires left, mid and right parts and the width can be set freely*/
#endif
#endif
@@ -603,7 +603,7 @@
#define USE_LV_LIST 1
#endif
#if USE_LV_LIST != 0
#ifndef define
#ifndef LV_LIST_FOCUS_TIME
# define LV_LIST_FOCUS_TIME 100 /*Default animation time of focusing to a list element [ms] (0: no animation) */
#endif
#endif
@@ -613,7 +613,7 @@
#define USE_LV_DDLIST 1
#endif
#if USE_LV_DDLIST != 0
#ifndef define
#ifndef LV_DDLIST_ANIM_TIME
# define LV_DDLIST_ANIM_TIME 200 /*Open and close default animation time [ms] (0: no animation)*/
#endif
#endif
@@ -623,7 +623,7 @@
#define USE_LV_ROLLER 1
#endif
#if USE_LV_ROLLER != 0
#ifndef define
#ifndef LV_ROLLER_ANIM_TIME
# define LV_ROLLER_ANIM_TIME 200 /*Focus animation time [ms] (0: no animation)*/
#endif
#endif
@@ -642,7 +642,7 @@
* Non-user section
*************************/
#if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_WARNINGS) /* Disable warnings for Visual Studio*/
#ifndef define
#ifndef _CRT_SECURE_NO_WARNINGS
# define _CRT_SECURE_NO_WARNINGS
#endif
#endif