The combobox is there but shows empty. You don’t see it immediately because the content is not shown.
When you click the combobox the first time (just behind the text), you have to click it a second time to see it’s a dropdown and a third time to actually see the dropdown list, which still shows empty:
What am I doing wrong?
PS: it’s a pity the documentation about Eto is so fragmented and in different languages. As I am not aquainted with C++ or C#, I can’t understand the code or translate it to Python …
Thanks for the inquiry and apologies for the late response. What you need to do is set the DataStore of the ComboBoxCell instead of using a ComboBox as the value for each cell. Something like this should work:
About the documentation, I will try to compile a list of items I had problems with to understand. Maybe you can use that to add to the documentation.
At the moment I’m not busy with Rhino Python, but when I do again, I will dedicate some time to it.
I am having the same issues in RhinoPyhton. I found that using the mouse scroll-wheel does change the ComboBoxCell content during editing, but using a mouse click I get the same behavior as @mingo1214 (unable to expand the ComboBoxCell dropdown)
Hi @curtisw, your example does not seem to work over here using Win7 and Rhino 6 SR25. I see the combobox once clicked in the gridview but it does not show the values in a dropdown.
It is a good start but would be even more helpful if these examples are complete and ready to run for new users from the built in python editor. It seems that someone just tried out various Eto controls and made screenshots from a dialog with the same title but never saved the complete results.
Rather than using gridview, I ended up using table layout for these sorts of layout.
Unfortunately you lose the abilities to add, delete and move rows, but if you have a specified set of data going in, you at least get consistent results.
@curtisw , Reviving this topic as it is still a problem in v7.4. The problem as described by @mingo1214 persists. I’ve spent quite a bit of time digging into this and it seems to stem from the combobox not getting proper focus. The first time you try and use the combobox via drop down it doesn’t work, but if you try it again without clicking on something else it will work. Similarly, if you select the combobox without activating the drop down first and then click the drop down it will function as expected. As mentioned by @etiennekasteel , selecting the combobox and using the scroll wheel or arrow keys to select other options also works. Happy to start a new thread but thought it would be good to continue it here.
Thank you for the update. I may add that the same problem holds for the “checkbox” field in a gridview.
Depending on the focus the checkbox may or may not correctly trigger the callback. A workaround here is to select the correct cell and then use the “space-bar” to change the checkbox status and confirm with “Enter-key”. I have found this always triggers the callback correctly.