ESP32 port config

Using menuconfig/kconfig makes it almost never necessary to change stuff on the lvgl.h config, but still some stuff that is needed, like enabling themes and fonts.

What would be an accepted way to change those settings without having to alter the lvgl or add all the possible options to menuconfig?

1 Like


We were starting to think about adding more options to the menuconfig of the “official” port of lvgl to esp32.

You can edit the lv_conf.h file available in the components/lvgl directory directly.

What options (besides the themes and fonts) do you think are still missing in the menuconfig menu?


Yeah that was what I did (edit the lv_conf.h) but that makes the git submodule to have local changes.

I think the biggest ones that I hit were theme and font support, really, the rest is usually ok witht he default.

I might be wrong but editing the lv_conf file should do changes on the lvgl submodule as the lvgl submodule is the lvgl directory inside components/lvgl/lvgl

[submodule “lvgl”]
path = components/lvgl/lvgl
url =

We can start by adding an option to the menuconfig to choose the theme and another option to choose the font from the available options, and then try to add a custom font/theme. I can try that this weekend.

Hi @coredump,

Just started working on this, I’m working on a branch named lvgl_kconfig on the lv_port_esp32 repository. So far I’ve added a new LVGL configuration menu, this one is to configure the LVGL lib:

If you enter it you can find what i have so far, as today saturday february 29, enable built-in fonts:


There is a lot to be done, but I would like you to let me know what do you think and if i should follow this way with other configuration options, maybe you were meaning something else when asking about esp32 port config.


Nope, that was exactly what I had in mind!

Nice, I don’t have as much free time as I would like, but I will try to keep adding more configuration options or maybe you or someone else can see what I did and contribute.


Added a couple more menues:

Setting the default built-in font, if you set as default a font that havent been enable this menu enable the font automagically!

Enabling themes:

All of this is being done on the lvgl_kconfig branch as i said before, it will take a will until i finish, keep in mind that lv_port_esp32 is using an old version of lvgl and v7 will have even more options.

Is it ok to send PR and introduce to Kconfig some other option as well?

For example, in my project I’m using USER_DATA and a different LV_THEME_DEFAULT_FONT_SMALL, as well as set dark theme flag. It required lv_conf.h changes and then shows submodule changes. It is also not very convenient to keep such changes between repo copies. I would prefer to have them in the main project repo.

Sure, you can send a PR for LVGL configuration. The theme configuration is (I think) the most difficult to do, because it would enable the user to choose between a lot of possible configurations.

If you want to get started I would suggest to add enable/disable options for LVGL widgets.

@heathen Can you test this branch

I’ve added some theme configuration options on the menuconfig interface. If it is working we can then try to add the USER_DATA option.

1 Like

I’m really sorry, been very busy and just noticed this message.

Don’t worry, it’s on master now :slight_smile:

Where to get those awesome themes you have there?

These are themes from LVGL 6.1. In v7 the style system was rewritten, and for simplicity, most of the themes were not carried over to the new version. It’s easier to override themes in v7 and v8 so there wasn’t really a need to have multiple themes.

1 Like