-
I have a ComboBox widget in my application that is intended to allow the user to pick from sections in a file they choose. Setting the I've tried the following to no avail:
If anyone has any ideas for this they would be much appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You may need to create a callback that sets the text value manually when you change the model. |
Beta Was this translation helpful? Give feedback.
-
Sorry for getting back to this so late. Using a binding to |
Beta Was this translation helpful? Give feedback.
You may need to create a callback that sets the text value manually when you change the model.
So something like this: https://slint-ui.com/releases/1.0.2/editor/?snippet=import+%7B+ComboBox%2C+CheckBox+%7D+from+%22std-widgets.slint%22%3B%0Aexport+component+Example+inherits+Window+%7B%0A++++width%3A+200px%3B%0A++++height%3A+130px%3B%0A++++cb+%3A%3D+ComboBox+%7B%0A++++++++y%3A+0px%3B%0A++++++++width%3A+self.preferred-width%3B%0A++++++++height%3A+self.preferred-height%3B%0A++++++++model%3A+check.checked+%3F+%5B%22other%22%2C+%22other+2%22%5D+%3A+%5B%22first%22%2C+%22second%22%2C+%22third%22%5D%3B%0A++++%7D%0A++++check+%3A%3D+CheckBox+%7B%0A++++++++text%3A+%22Use+second+set%22%3B%0A++++++++t…