eez-open / studio

Cross-platform low-code GUI and automation
https://www.envox.eu/studio/studio-introduction/
GNU General Public License v3.0
530 stars 91 forks source link

[LVGL] Allow enabling default dark theme in editor and generated files #456

Closed tylercamp closed 2 months ago

tylercamp commented 2 months ago

Is your feature request related to a problem? Please describe. LVGL offers a default dark theme which I'd like to use.

Describe the solution you'd like I'd like a checkbox in the project settings page for whether to use light or dark theme for the project. It would modify screens.c code generation and apply to widgets shown within EEZ Studio editor

Describe alternatives you've considered I'm currently applying a new theme with dark mode after the init call to EEZ Studio's generated code, but I'd like to manage the setting and see a preview of those changes directly in EEZ Studio.


The code-gen update would be easy but I'm not sure about updating widget styling within EEZ Studio's preview. I see a reference to a wasm wrapper util, so I assume there's some sort of LVGL web binding being used, but I can't tell how the lvglruntime* files are being generated

(If it's using a proper LVGL API binding then updating EEZ UI for dark mode would probably be easy too, but I can't tell whether that's the case)

mvladic commented 2 months ago

Implemented.

image

gwiethaus commented 1 month ago

First, please excuse my English

In the new version EEZ Studio 0.16.0 I enabled the "dark theme" and it only changed the development screen. The editor continues with the default white theme.

mvladic commented 1 month ago

For the EEZ Studio you can select dark theme here:

image

gwiethaus commented 1 month ago

For the EEZ Studio you can select dark theme here:

image

Thanks for the tip. I created a new database. However, I discovered that I can't access the bottom of the screen. I think the scroll bar to reach the rest of the features is missing. I marked it in red as far as I can see on the screen. Remember that I'm using a laptop.

Screen Setting

mvladic commented 1 month ago

Hm, this is bug. Fortunately, you can also select dark theme from the main menu:

image

gwiethaus commented 1 month ago

Hm, this is bug. Fortunately, you can also select dark theme from the main menu:

image

Damn... how stupid I am!

Thank you very much for this help. I am recently discovering how to use this wonderful tool. I am exploring it. I have a big hobby project for my project to create a controller with a display for my "CNC Router" which I have already completed. With this tool EEZ Studio will make my projects much easier.