Hi,
I'm trying to add a padding to the selection brush in a Combobox. I have created a subclass of ListboxTextItem for creating my custom items. In the constructor of this subclass I am appending the string "[padding='l:5 t:3 r:0 b:3']" to create the required padding, but then, when an item is selected, the combobox selection is showing the formatting tag (it looks perfect in the drop down list) as text.
I have tried to increase the size of 'targetRect' in the ListboxTextItem::draw method but it's adding the padding outside the selection brush, and not looking ok.
How can I accomplish what I want?
CEGUI vesion: 0.7.5
Thanks for your help.
ListboxItemText selection brush padding.
Moderators: CEGUI MVP, CEGUI Team
Re: ListboxItemText selection brush padding.
Cegui 0.7? Gosh, I wasn't even born then.. Let me c what I can do.
Re: ListboxItemText selection brush padding.
@frigopie: In "FalagardEditbox::renderTextNoBidi" search for "hlarea" - it defines the area of the highlight. Try to play with it as u wish. If it works, we'll perhaps add a property that controls its padding.
Who is online
Users browsing this forum: No registered users and 8 guests