3

I'm dynamically populating the options to a GTK3 ComboBox that has an Entry. Some the options can be quite long, and I'd like to be able to make the ComboBox wider if there are wide items in my model. Is there a way to do this?

(It would be especially nice if the combobox could be expanded automatically but with an upper limit that could be set.)

Dan
  • 3,665
  • 1
  • 31
  • 39
  • May I ask... how does it behave right now? – PALEN Aug 18 '12 at 15:44
  • @PALEN Certainly as of current GTK+, the ComboBox automatically resizes to fit the contents of the cells in its model. I would be surprised if this had ever not been true. – underscore_d Jul 09 '16 at 17:01
  • 2
    ...or rather, it automatically resizes _upwards_ to fit the largest of the options whose value it will display in the button. If you then change to a model with all shorter options... it doesn't shrink back down. – underscore_d Aug 07 '16 at 19:22

0 Answers0