combo box weirdness
Moderators: CEGUI MVP, CEGUI Team
combo box weirdness
I've found that the combobox doesn't expand beyond the parent window size - perhaps this is the reason the drop down list is less than expected. Iis the 30% in comparison to the standard API combobox, or a previous CEGUI version?
combo box weirdness
If its the child list box being clipped (most probable) then there are a few solutions. The easiest fix I found so far is the following code snippet:
What the code does is get the child listbox, which was created by the combobox, and then sets the flag to indicate that the listbox window is not to be clipped by any parent windows. You only need to do this once when the combobox is created.
Code: Select all
CEGUI::Window* droplist = mComboboxWidget->getChild(mComboboxWidget->getName() + "__auto_droplist__");
droplist->setClippedByParent(false);
What the code does is get the child listbox, which was created by the combobox, and then sets the flag to indicate that the listbox window is not to be clipped by any parent windows. You only need to do this once when the combobox is created.
combo box weirdness
Forgot to mention that the vertical size of the Combobox effects the vertical size of the droplist too which is probably your problem and not clipping (yet).
The vertical size of the combobox effects both the vertical size of the editbox and the combobox. Think of the vertical size of the combobox as the sum of the editbox height and the droplist vertical size that you want. The vertical size of the editbox will be 1.5 times the font height (for TL widgets). So combobox height - editbox height will be the droplist height. If combobox height is less than the editbox height then you will only see a portion of the editbox and nothing of the drop list.
The vertical size of the combobox effects both the vertical size of the editbox and the combobox. Think of the vertical size of the combobox as the sum of the editbox height and the droplist vertical size that you want. The vertical size of the editbox will be 1.5 times the font height (for TL widgets). So combobox height - editbox height will be the droplist height. If combobox height is less than the editbox height then you will only see a portion of the editbox and nothing of the drop list.
- CrazyEddie
- CEGUI Project Lead
- Posts: 6760
- Joined: Wed Jan 12, 2005 12:06
- Location: England
- Contact:
combo box weirdness
@Lettique:
Everything posted so far is correct, if this is not the issue you're having, then please provide code or XML layout snippets, and if at all possible a screenshot to indicate the exact problem.
Thanks,
CE.
Everything posted so far is correct, if this is not the issue you're having, then please provide code or XML layout snippets, and if at all possible a screenshot to indicate the exact problem.
Thanks,
CE.
Return to “Modifications / Integrations / Customisations”
Who is online
Users browsing this forum: No registered users and 5 guests