Comments (3)
Slint struct and other types can currently only contains fields of type known to Slint.
I don't know if we can support this usecase.
It can be worked around by using an integer id, and have mapping between id and the actual type in Rust.
from slint.
Slint struct and other types can currently only contains fields of type known to Slint. I don't know if we can support this usecase. It can be worked around by using an integer id, and have mapping between id and the actual type in Rust.
True, it's possible to do this with an id; but if you want to do anything more complicated inside the for loop, like calling a common function that affects each child individually, I think you would need the ability to pass more complicated types of variables as parameters in the function, like Widget types. This would be a huge bonus. This is one huge advantage of Flutter. It is similar to issue #4891.
It would be interesting to know how difficult this would be. I think this is a bottle-neck for a lot of functionality.
from slint.
We would need to support importing rust struct.
I think this would be a duplicate of #1726
So it would allow to import Rust struct from Slint code
Closing this issue as duplicate of #1726
from slint.
Related Issues (20)
- panic `NoSuchProperty` when changing `commands` in `Path` HOT 1
- Auto disable maximize button when window resize is disabled HOT 5
- Please add built-in scrolling support for ComboBox widget HOT 1
- Revert workaround for rgb breakage before release HOT 2
- Linux: TextEdit widget is always showing scrollbars even when empty
- use backend-linuxkms and renderer-software error HOT 6
- Double clicked of TouchArea in Flickable does not trigger
- Custom input validation for LineEdit/TextEdit HOT 2
- Integration with Rust 3D Graphics Libraries
- Generated C++ code issue with keyword "delete" HOT 1
- slint preview window not close-able on wayland HOT 2
- Feature Request: create an exclusive repository to the documentation HOT 3
- main thread panicked when pressing / moving a button added to a component HOT 4
- ComboBox: Popup height is not adjusting to items count HOT 2
- ComboBox: Popup position and width does not adjust to window resizes HOT 9
- VSCode language server panic in resolving.rs HOT 1
- VS Code extension: Disable Wayland use when running under WSL
- Mac: Showing a previously minimized/hidden window fails to resume animations and freezes
- live preview: Things arer added with x and y property in layouts
- Warning in Slint autogen code: variant `Destructive` is never constructed
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from slint.