ListBox widget added.
I've created simple ListBox widget basing on ComboBox and CustomWidgetExample. Selection works same as in windows explorer. Check out the example.
I'm not familiar with the styles engine, so I'd be grateful if someone made selection color customizable(currently hardcoded sf::Color::Blue).
Looks like the whole BREW stuff is missing.
I'm not familiar with the styles engine, so I'd be grateful if someone made selection color customizable(currently hardcoded sf::Color::Blue).
It's quite simple. Just have a look at the existing BREW elements.
Looks like the whole BREW stuff is missing.
The whole BREW rendering seems to be integrated inside the widget itself (in ListBox::invalidateImpl()). I can change @Zax37 code to put the rendering code in the BREW renderer and make another PR if you still wants this widget (I'm interested by this particular one for a project of mine).
Sure, go for it.
Its ListBox implementation doesn't support scrollbars (it keeps growing when items are added). Should I add support for scrollbars (vertical at least) or keep it simple while the user can still have scrollbars by combining it with a ScrolledWindow ?
It would be nice if the user didn't have to do so much work themselves for something they almost always expect. Add the scrollbars... :wink:
Ok, will do it :)
I know how to add and manage the vertical scrollbar (scroll item by item) but I don't know how I can manage a horizontal scrollbar. Putting "..." at the end of the item's text if it is too large could be a better (and easier ^^) idea.
Made the implementation in my feature/listbox branch : https://github.com/victorlevasseur/SFGUI/tree/feature/listbox
What do you think of it ? (some features are still missing)

I'm also waiting for this one :)