Rogue Wave Views
Data Access Package API Reference Guide
Product Documentation:

Rogue Wave Views
Documentation Home
List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions
IliAbstractComboBox Class Reference

Field gadget class. More...

#include <ilviews/dataccess/gadgets/abscombo.h>

Inheritance diagram for IliAbstractComboBox:
IliEntryField IlvTextField IliFieldItf IlvGadget IlvSimpleGraphic IlvStylable IlvGraphic IlvValueInterface IliDialogComboBox IliTableComboBox

Public Member Functions

void allowEdit (IlBoolean enable)
 Specifies whether editing is allowed for the abstract combo box. More...
 
virtual void close ()
 Hides the pull-down menu or dialog box. More...
 
virtual IlBoolean f_isReadOnly () const
 Returns IlTrue if the field is read-only. More...
 
virtual void f_setReadOnly (IlBoolean)
 Sets the read-only property for the field. More...
 
IlBoolean isArrowShown () const
 Returns IlTrue if the button is shown. More...
 
IlBoolean isEditAllowed () const
 Returns IlTrue if editing is allowed for the abstract combo box. More...
 
virtual IlBoolean isOpen () const
 Returns IlTrue if the pull-down menu or the dialog box is currently displayed. More...
 
virtual void onClose ()
 Called just after the pull-down menu or the dialog box is dismissed. More...
 
virtual void onOpen ()
 Called just before the pull-down menu or the dialog box is displayed. More...
 
virtual void open (IlBoolean grab)
 Causes a pull-down menu or dialog box to be displayed. More...
 
void showArrow (IlBoolean show)
 Shows or hides the arrow button. More...
 
- Public Member Functions inherited from IliEntryField
 IliEntryField (IlvDisplay *display, const IlvRect &rect, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 Initializes a new IliEntryField instance. More...
 
 IliEntryField (IlvDisplay *display, const char *label, const IlvRect &rect, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 Initializes a new IliEntryField instance. More...
 
 IliEntryField (IlvDisplay *display, const IlvPoint &at, const char *label, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 Initializes a new IliEntryField instance. More...
 
virtual IlBoolean f_externalToInternal ()
 Updates the internal value of a field according to its current external representation. More...
 
virtual IlvAlignment f_getAlignment () const
 Returns the text alignment of the field. More...
 
virtual const IliFormatf_getFormat () const
 Returns the format used to derive the external representation of the field from its internal value. More...
 
virtual const IliInputMaskf_getMask () const
 Returns the input mask used to edit values in the field. More...
 
virtual IlShort f_getMaxLength () const
 Returns the maximum length allowed for the external representation of the field. More...
 
virtual const IliValuef_getValue (IlBoolean=IlFalse) const
 Returns the value of the field. More...
 
virtual void f_internalToExternal ()
 Updates the external representation of the field and its display according to its current internal value.
 
virtual IlBoolean f_isConsistent () const
 Returns IlTrue if the internal value of the field corresponds to its current external representation. More...
 
virtual void f_selectTextForAppend ()
 Deselects all the text and positions the editing caret at the end of the text, provided the field gadget supports text selection.
 
virtual void f_selectTextForOverwrite ()
 Selects all the text, provided the field gadget supports text selection.
 
virtual void f_setAlignment (IlvAlignment)
 Sets the text alignment of the field. More...
 
virtual void f_setFormat (const IliFormat &)
 Sets the format used to derive the external representation of the field from its internal value. More...
 
virtual void f_setInputModified (IlBoolean)
 Sets the input-modified attribute of the field. More...
 
virtual void f_setMask (const IliInputMask &)
 Sets the input mask. More...
 
virtual void f_setMaxLength (IlShort)
 Sets the maximum length allowed for the external representation of the field. More...
 
virtual IlBoolean f_setValue (const IliValue &, IlBoolean=IlFalse)
 Sets the value of the field. More...
 
- Public Member Functions inherited from IliFieldItf
void f_applyReferences (IlvApplyObject f, IlAny a)
 Should be called when the applyReferences() member function, of the gadget class, is called. More...
 
virtual IlBoolean f_complete ()
 Updates the internal value of the field, according to its current external representation and its foreign table, provided completion is enabled for the field. More...
 
virtual void f_enableCompletion (IlBoolean flag)
 Sets the completion property of the field. More...
 
const IliDataSourcef_getDataSource () const
 Returns the data source. More...
 
IliDataSourcef_getDataSource ()
 Returns the data source. More...
 
const char * f_getDataSourceColumnName () const
 Returns the name of the column. More...
 
const char * f_getDataSourceName () const
 Returns the name of the data source, which this field is (or must be) connected to. More...
 
virtual const IliTablePropertyManagerf_getEffectiveTablePropertyManager () const
 Returns the effective table property manager. More...
 
virtual IliTablePropertyManagerf_getEffectiveTablePropertyManager ()
 Returns the effective table property manager. More...
 
const char * f_getForeignDataSourceName () const
 Returns the name of the foreign data source. More...
 
const char * f_getForeignDisplayColumnName () const
 Returns the name of the column of the foreign table that will serve as a result. More...
 
const IliTablef_getForeignTable () const
 Returns the foreign table. More...
 
IliTablef_getForeignTable ()
 Returns the foreign table. More...
 
const char * f_getForeignValueColumnName () const
 Returns the name of the column of the foreign table that will serve as a key. More...
 
const IlvGadgetf_getGadget () const
 Returns the constant gadget associated with this field through multiple inheritance. More...
 
IlvGadgetf_getGadget ()
 Returns the gadget associated with this field through multiple inheritance. More...
 
const IlvGraphicf_getGraphic () const
 Returns the constant graphic associated with this field through multiple inheritance. More...
 
IlvGraphicf_getGraphic ()
 Returns the graphic associated with this field through multiple inheritance. More...
 
virtual const char * f_getLabel () const
 Returns the label displayed by the field gadget. More...
 
const char * f_getTablePropertyManagerName () const
 Returns the name of the table property manager used by this field. More...
 
IlInt f_getVisibleRowsCount () const
 Returns the number of rows that will be displayed when the foreign table is displayed. More...
 
virtual IlBoolean f_hasLabel () const
 Returns IlTrue if the field gadget can display a label. More...
 
virtual void f_ignoreModifiedState (IlBoolean ignore)
 Sets the ignore modified state attribute of the field. More...
 
virtual IlBoolean f_isAutoFitPullDown () const
 Returns IlTrue if the width of the pull-down menu is automatically computed so that its contents fit. More...
 
IlBoolean f_isCompletionEnabled () const
 Returns IlTrue if completion is enabled. More...
 
IlBoolean f_isConnectedToDataSource () const
 Returns IlTrue if the field is currently connected to a column of a data source. More...
 
IlBoolean f_isConstrained () const
 Returns IlTrue if the foreign table limits the set of possible internal values for this field. More...
 
IlBoolean f_isDataSourceOwner () const
 Returns IlTrue if the field owns the data source. More...
 
IlBoolean f_isForeignTableOwner () const
 Returns IlTrue if the field owns its foreign table. More...
 
virtual IlBoolean f_isInputModified () const
 Returns IlTrue if the external representation has been edited by the end-user. More...
 
virtual IlBoolean f_isModifiedStateIgnored () const
 Returns IlTrue if the modified states are ignored when the f_setValue() function is called. More...
 
IlBoolean f_isUsingTableProperties () const
 Returns IlTrue if the field uses table properties. More...
 
void f_killFocus ()
 Should be called when the gadget loses the focus.
 
virtual void f_setAutoFitPullDown (IlBoolean flag)
 Enables/disables the automatic width computing of the pull-down menu. More...
 
virtual void f_setConstrained (IlBoolean flag)
 Sets the constrained property of the field. More...
 
virtual void f_setDataSourceColumnName (const char *name)
 Sets the name of the column. More...
 
virtual void f_setDataSourceName (const char *name)
 Sets the name of the data source. More...
 
void f_setFocus ()
 Should be called when the gadget receives the focus.
 
virtual void f_setForeignDataSourceName (const char *name)
 Sets the name of the foreign data source. More...
 
virtual void f_setForeignDisplayColumnName (const char *name)
 Sets the name of the column of the foreign table that will serve as a result, when the table is used as a map to convert internal values into external representations. More...
 
virtual void f_setForeignTable (IliTable *tbl, IlBoolean owner=IlFalse)
 Sets the foreign table of the field. More...
 
virtual void f_setForeignValueColumnName (const char *name)
 Sets the name of the column of the foreign table that will serve as a key, when the table is used as a map to convert internal values into external representations. More...
 
virtual void f_setLabel (const char *label)
 Sets the label of the field gadget. More...
 
virtual void f_setTablePropertyManagerName (const char *name)
 Sets the name of the table property manager to use. More...
 
virtual void f_setVisibleRowsCount (IlInt count)
 Sets the number of rows to be displayed when the foreign table is displayed. More...
 
virtual IlBoolean f_supportsTableProperties () const
 Returns IlTrue if this gadget supports table properties. More...
 
virtual void f_useTableProperties (IlBoolean flag)
 Enables/Disables the use of the table properties. More...
 

Static Public Member Functions

static IlvSymbolCloseSymbol ()
 Returns the symbol name of the Close callback. More...
 
static void GetOpenShortCut (IlUShort &modifiers, IlUShort &key)
 Returns the definition of the shortcut key that causes the pull-down menu or dialog box to be displayed. More...
 
static IlvSymbolOpenSymbol ()
 Returns the symbol name of the Open callback. More...
 
static void SetOpenShortCut (IlUShort modifiers, IlUShort key)
 Defines the shortcut key that causes the pull-down menu or dialog box to be displayed. More...
 
- Static Public Member Functions inherited from IliFieldItf
static IlvSymbolInputModifiedSymbol ()
 Returns the name of the callback that the field gadget will invoke every time the field input-modified property changes from IlFalse to IlTrue. More...
 

Protected Member Functions

 IliAbstractComboBox (IlvDisplay *display, const IlvRect &rect, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 Initializes a new abstract combo box. More...
 
- Protected Member Functions inherited from IliEntryField
const char * formatValue (IliString &dest, const IliValue &val)
 Returns a character string which contains the formatted value. More...
 
void setLabelSilently (const char *label)
 Sets a new label and launches the drawing of the new label. More...
 
virtual void valueToLabel (const IliValue &value)
 Sets the value to the label of the entry field. More...
 
- Protected Member Functions inherited from IliFieldItf
void f_read (IlvInputFile &input)
 Should be called by the stream-based constructor of the gadget. More...
 
void f_set (IlvGraphic *g, const IliFieldItf &other)
 Should be called by the copy constructor of the graphic class that is passed. More...
 
void f_setGraphic (IlvGraphic *g)
 Should be called by all constructors of the graphic class (except the copy constructor). More...
 
void f_subscribe ()
 Should be called after the setHolder() member function of the gadget class.
 
void f_unsubscribe ()
 Should be called before the setHolder() member function of the gadget class. More...
 
void f_write (IlvOutputFile &output) const
 Should be called by the write() member function of the gadget class. More...
 

Detailed Description

Field gadget class.

Library: dbgadget

The IliAbstractComboBox abstract class is intended to serve as a base class for combo box fields such as IliTableComboBox. An IliAbstractComboBox consists of a text field with a button immediately to its right. If editing is allowed, you can edit the value directly in the text field. Alternatively, the button may be used to access either a pull-down menu of multiple choices, or a dialog box to edit the value in a more structured way. A shortcut key also allows you to rapidly activate the button (by default F4).

Note that this class does not define what happens when the user clicks on the button. It is assumed that each subclass of IliAbstractComboBox will behave in a specific manner. For instance, when you click on the button in the IliTableComboBox class, a pull-down menu, containing the foreign table of the field, is opened.

See also
liDialogComboBox, IliTableComboBox.

Accessors

Accessors provide a scriptable and uniform way to inspect and modify an object by using its base class methods IlvValueInterface::queryValue(), IlvValueInterface::queryValues(), IlvValueInterface::changeValue(), IlvValueInterface::changeValues(). This class inherits the accessors of its superclass IliEntryField.

Constructor & Destructor Documentation

§ IliAbstractComboBox()

IliAbstractComboBox::IliAbstractComboBox ( IlvDisplay display,
const IlvRect rect,
IlUShort  thickness = IlvDefaultGadgetThickness,
IlvPalette palette = 0 
)
protected

Initializes a new abstract combo box.

Parameters
displayThe display.
rectThe location.
thicknessThe border thickness.
paletteThe palette.

Member Function Documentation

§ allowEdit()

void IliAbstractComboBox::allowEdit ( IlBoolean  enable)

Specifies whether editing is allowed for the abstract combo box.

Parameters
enableThe editing state: enable (IlTrue)/disable (IlFalse).

§ close()

virtual void IliAbstractComboBox::close ( )
virtual

Hides the pull-down menu or dialog box.

The type of object that is hidden depends on the subclass of IliAbstractComboBox being used.

Reimplemented in IliTableComboBox, and IliDialogComboBox.

§ CloseSymbol()

static IlvSymbol* IliAbstractComboBox::CloseSymbol ( )
static

Returns the symbol name of the Close callback.

Returns
The symbol.

§ f_isReadOnly()

virtual IlBoolean IliAbstractComboBox::f_isReadOnly ( ) const
virtual

Returns IlTrue if the field is read-only.

Returns
IlTrue if the field is read-only.

Reimplemented from IliEntryField.

§ f_setReadOnly()

virtual void IliAbstractComboBox::f_setReadOnly ( IlBoolean  flag)
virtual

Sets the read-only property for the field.

Parameters
flagThe read-only flag.

Reimplemented from IliEntryField.

§ GetOpenShortCut()

static void IliAbstractComboBox::GetOpenShortCut ( IlUShort modifiers,
IlUShort key 
)
static

Returns the definition of the shortcut key that causes the pull-down menu or dialog box to be displayed.

The default for this property is the F4 key.

Parameters
modifiersThe modifiers.
keyThe key
Returns
The shortcut key.

§ isArrowShown()

IlBoolean IliAbstractComboBox::isArrowShown ( ) const

Returns IlTrue if the button is shown.

Initially, this property is IlTrue. When the button is not shown, the gadget looks like a text field.

Returns
The visibility.

§ isEditAllowed()

IlBoolean IliAbstractComboBox::isEditAllowed ( ) const

Returns IlTrue if editing is allowed for the abstract combo box.

This property should not be confused with the read-only property obtained with the f_isReadOnly() member function. An abstract combo box may inhibit editing without being read-only. This is because editing, in this situation, only refers to the text field part of the abstract combo box. Therefore, though editing may be inhibited, you are still able to change the value for the gadget using the pull-down menu or dialog box.

Returns
The editing rights flag.

§ isOpen()

virtual IlBoolean IliAbstractComboBox::isOpen ( ) const
virtual

Returns IlTrue if the pull-down menu or the dialog box is currently displayed.

Returns
The pull-down menu (or dialog box) visibility.

Reimplemented in IliTableComboBox, and IliDialogComboBox.

§ onClose()

virtual void IliAbstractComboBox::onClose ( )
virtual

Called just after the pull-down menu or the dialog box is dismissed.

By default, the Close callback is called.

§ onOpen()

virtual void IliAbstractComboBox::onOpen ( )
virtual

Called just before the pull-down menu or the dialog box is displayed.

By default, the Open callback is called.

§ open()

virtual void IliAbstractComboBox::open ( IlBoolean  grab)
virtual

Causes a pull-down menu or dialog box to be displayed.

Whether the object displayed is a pull-down menu or a dialog box depends on the subclass of IliAbstractComboBox being used.

Parameters
grabReserved for future use and its value must always be IlFalse.

Reimplemented in IliDialogComboBox.

§ OpenSymbol()

static IlvSymbol* IliAbstractComboBox::OpenSymbol ( )
static

Returns the symbol name of the Open callback.

Returns
The symbol.

§ SetOpenShortCut()

static void IliAbstractComboBox::SetOpenShortCut ( IlUShort  modifiers,
IlUShort  key 
)
static

Defines the shortcut key that causes the pull-down menu or dialog box to be displayed.

If key has a value of 0, no shortcut key is defined.

Parameters
modifiersThe modifiers.
keyThe key.

§ showArrow()

void IliAbstractComboBox::showArrow ( IlBoolean  show)

Shows or hides the arrow button.

Parameters
showIf IlTrue, the button is visible otherwise (IlFalse) the button is not visible.

© Copyright 2018, 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.