-
Notifications
You must be signed in to change notification settings - Fork 135
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[LVGL+Flow] Spinbox specific properties can be expressions/assignable #492
Comments
I noticed LVGL API is lacking:
So did some digging in lvgl sources. Would this be an option to use (to get min range value) as a temporary(?) workaround:
|
I've implemented part of it. Min/max range can be an expression now. Will work on the format count and position options in the same way before creating a merge request. Feel free to comment on the solution I used. |
I flew through the changes a bit and it looks pretty good to me. When you're done, I'll take a closer look. The next release should be by this Monday. If you can finish it by Friday then we can add it to this release. |
FYI In version 9.2 you can't access members of |
Thanks for the tip. I don't know if I will have the time to finish this before the end of the week. |
Never mind, take your time and we will release it when it is ready. |
I've added some updates to the branch (while following master branch). Current status is: In simulator:
|
Here is a test project to explore the different features. |
Also note the last commit I make Commented out unnecesairy callbacks: These are expressions not assignable? |
I'm not happy how currently adding new LVGL widget works. We have separate definitions for editing and running inside simulator (
and some more:
And, even worse, for I think, ideally, you should implement only one function that should work for both simulator and source code generator. And you shouldn't need to write wrapper code. I have some ideas how to do it, so for now I think you should stop working on this since it is possible that very soon I start to refactor all this |
Ok, I agree with you on your analysis. For adding/changing a single widgets parameters I had to touch code in a lot of different places (was not easy to figure it out). I also changed a few things in expression-property.tsx. Imho these functions will become unmaintainable if more LVGL versions and widgets are added. |
Is your feature request related to a problem? Please describe.
I can't dynamically change some of the properties of the spinbox.
Describe the solution you'd like
I would like to have the option to set the specific settings of the spinbox to an expression, not just literal.
These are the settings that the use of the spinbox doesn't change (expression not assignable).
In my case the spinbox properties need to change when I change to a different mode in my application. As an example I've filled in the expressions I need in the literal fields:

Describe alternatives you've considered
Additional context
This has a relation to #229 because spin boxes are mainly useful with encoders (imho).
The text was updated successfully, but these errors were encountered: