Rogue Wave Views 5.6 |
Rogue Wave Views |
Rogue Wave Views Documentation Home |
Gadget class. More...
#include <ilviews/gadgets/scombo.h>
Public Member Functions | |
IlvScrolledComboBox (IlvDisplay *display, const IlvRect &rect, const char *label, const char *const *labels=0, IlUShort count=0, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0) | |
Constructor. | |
IlvScrolledComboBox (IlvDisplay *display, const IlvPoint &point, const char *label, const char *const *labels=0, IlUShort count=0, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0) | |
Constructor. | |
void | disableLargeList () |
Disables the large list mode. | |
void | enableLargeList (IlvPosition pos=IlvLeft) |
Enables the large list mode. | |
IlvStringList * | getStringList () const |
Returns a pointer to the string list encapsulated by the scrolled combo box. | |
IlUShort | getVisibleItems () const |
Returns the number of visible items in the string list. | |
IlvPosition | hasLargeList () const |
Indicates whether the large list mode is used. | |
virtual void | hideList () |
Hides the string list. | |
virtual IlBoolean | isListVisible () const |
Indicates whether the list of items of the combo box is visible. | |
void | setVisibleItems (IlUShort count) |
Sets the number of visible items in the string list. | |
virtual void | showList (IlBoolean grab=IlTrue) |
Displays the string list. | |
Friends | |
class | IlvDefaultScrolledComboBoxLFHandler |
Gadget class.
Library: ilvadvgdt
This class is a subclass of IlvComboBox
that combines a text field (IlvTextField
class) with a scrollable string list. The user can enter a character string in the combo box text field, or click on the arrow that appears on the right side of the field to display a string list of the class IlvStringList
providing a set of predefined choices.
IlvScrolledComboBox
is an advanced scrollable string list rather than an IlvPopupMenu
as in the superclass, the inherited IlvComboBox::getSubMenu
member function must not be called for the IlvScrolledComboBox
class. It returns 0
. IlvScrolledComboBox::IlvScrolledComboBox | ( | IlvDisplay * | display, | |
const IlvPoint & | point, | |||
const char * | label, | |||
const char *const * | labels = 0 , |
|||
IlUShort | count = 0 , |
|||
IlUShort | thickness = IlvDefaultGadgetThickness , |
|||
IlvPalette * | palette = 0 | |||
) |
Constructor.
Initializes a new instance of the class IlvScrolledComboBox
. The size of the combo box is computed from the label parameter. If you want to give the combo box a specific size, use the other constructor.
display | The connection to the display. | |
point | The position of the combo box. | |
label | The label of the combo box. | |
labels | An array containing the predefined labels of the combo box. | |
count | The number of elements in the labels array. | |
thickness | The thickness of the combo box. | |
palette | The palette used by the combo box. |
IlvScrolledComboBox::IlvScrolledComboBox | ( | IlvDisplay * | display, | |
const IlvRect & | rect, | |||
const char * | label, | |||
const char *const * | labels = 0 , |
|||
IlUShort | count = 0 , |
|||
IlUShort | thickness = IlvDefaultGadgetThickness , |
|||
IlvPalette * | palette = 0 | |||
) |
Constructor.
Initializes a new instance of the IlvScrolledComboBox
.
display | The connection to the display. | |
rect | The size and position of the combo box. | |
label | The label of the combo box. | |
labels | An array containing the predefined labels of the combo box. | |
count | The number of elements in the labels array. | |
thickness | The thickness of the combo box. | |
palette | The palette used by the combo box. |
void IlvScrolledComboBox::disableLargeList | ( | ) |
Disables the large list mode.
void IlvScrolledComboBox::enableLargeList | ( | IlvPosition | pos = IlvLeft |
) |
Enables the large list mode.
By default, the string list of the scrolled combo box has the same width as the text field. If the string list contains items that are wider than the text field, these may be hidden partially. When the large list mode is enabled, the string list is resized to accommodate the widest item.
alignment | The alignment of the string list. Valid values are: IlvLeft and IlvRight . |
IlvStringList* IlvScrolledComboBox::getStringList | ( | ) | const |
Returns a pointer to the string list encapsulated by the scrolled combo box.
IlUShort IlvScrolledComboBox::getVisibleItems | ( | ) | const |
Returns the number of visible items in the string list.
IlvPosition IlvScrolledComboBox::hasLargeList | ( | ) | const |
Indicates whether the large list mode is used.
IlvBadPosition
if the combo box does not use the large list mode. virtual void IlvScrolledComboBox::hideList | ( | ) | [virtual] |
Hides the string list.
virtual IlBoolean IlvScrolledComboBox::isListVisible | ( | ) | const [virtual] |
Indicates whether the list of items of the combo box is visible.
IlTrue
if the list of items of the combo box is visible and IlFalse
if it is not. Reimplemented from IlvComboBox.
void IlvScrolledComboBox::setVisibleItems | ( | IlUShort | count | ) |
Sets the number of visible items in the string list.
count | The new number of visible items in the string list. |
© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.