Views
Data Access Package API Reference Guide
Product Documentation:
Views Documentation Home
List of all members | Public Member Functions | Static Public Member Functions
IliTableGadget Class Reference

Field gadget class. More...

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

Inheritance diagram for IliTableGadget:
IlvGadget IliFieldItf IlvSimpleGraphic IlvStylable IlvGraphic IlvValueInterface IliInspectorGadget IliTableRepositoryGadget

Public Member Functions

 IliTableGadget (IlvDisplay *display, const IlvRect &rect, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 This constructor initializes a table gadget that is connected to a default table. More...
 
 IliTableGadget (IlvDisplay *display, IliTable *table, IlBoolean owner, const IlvRect &rect, IlUShort thickness=IlvDefaultGadgetThickness, IlvPalette *palette=0)
 This constructor initializes a table gadget that is connected to a table. More...
 
void addErrorMessage (const char *msg)
 Forwards an application error message to all the error sinks that have been added with the addErrorSink() member function. More...
 
void addErrorMessage (const IliErrorMessage &msg)
 Forwards an error message to all the error sinks that have been added with the addErrorSink() member function. More...
 
void addErrorSink (IliErrorSink *sink)
 All errors that occur on the table-gadget table or on the table-gadget data source (if it is bound to a data source) and all errors that are thrown by one of the addErrorMessage() member functions, will be forwarded to this error sink. More...
 
void allowColumnMove (IlBoolean flag)
 Allows or not the column moving by the end-user. More...
 
void allowColumnResize (IlBoolean flag)
 Enables/disables the column resizing by the end-user. More...
 
void allowRowMove (IlBoolean flag)
 Enables/disables the row moving by the end-user. More...
 
void allowRowResize (IlBoolean flag)
 Enables/disables the end-user to resize rows. More...
 
IlBoolean areToolTipsEnabled () const
 Returns IlTrue if tooltip display is enabled. More...
 
IliValue at (IlInt rowno, const char *colname) const
 Returns a value. More...
 
IliValue at (IlInt rowno, IlInt colno) const
 Returns a value. More...
 
void bindToDataSource (IlBoolean flag)
 Enables/Disables the bind data source option. More...
 
virtual void cancel ()
 Cancels any user input awaiting validation. More...
 
IlBoolean cellBBox (const IliTableSelection &sel, IlvRect &rect, const IlvTransformer *t=0) const
 Returns the bounding box of a selection, according to one (optional) transformer. More...
 
void copyToClipboard () const
 Copies the contents of the current selection to the clipboard.
 
void copyToClipboard (const IliTableSelection &sel) const
 Copies the contents of one selection to the clipboard. More...
 
void defaultDrawCell () const
 This member function may be called from the onDrawCell() virtual member function or from the corresponding callback.
 
void disableImmediateRefresh (IlBoolean disable)
 Disables the immediate refreshes of the gadget. More...
 
void dontDeleteRow ()
 Cancels the row deletion. More...
 
void dontValidateCell ()
 Called from the onValidateCell() virtual member function, or from its corresponding callback.
 
void dontValidateRow ()
 Cancels the row validation. More...
 
virtual void drawCell (IlvPort *dst, IlInt rowno, IlInt colno, const char *label, IlvAlignment align, IlBoolean selected, const IlvRect &bbox, IlvPalette *palette, const IlvRegion *clip) const
 Draws a cell. More...
 
virtual void drawCorner (IlvPort *dst, IlBoolean selected, const IlvRect &bbox, const IlvRegion *clip) const
 Draws the upper left corner of the table gadget. More...
 
virtual void drawHeader (IlvPort *dst, IlInt colno, const char *label, IlBoolean selected, const IlvRect &bbox, const IlvRegion *clip) const
 Draws a header. More...
 
virtual void drawHorzRule (IlvPort *dst, IlvPos x1, IlvPos x2, IlvPos y, IlInt rowno, IlInt colnoLeft, IlInt colnoRight, IlvPalette *palette, const IlvRegion *clip) const
 Draws a horizontal rule of the table gadget grid. More...
 
virtual void drawMarker (IlvPort *dst, IlInt rowno, IlBoolean selected, IlBoolean current, const IlvRect &bbox, const IlvRegion *clip) const
 Draws a marker. More...
 
virtual void drawVertRule (IlvPort *dst, IlvPos y1, IlvPos y2, IlvPos x, IlInt colno, IlInt rownoTop, IlInt rownoBot, IlvPalette *palette, const IlvRegion *clip) const
 Draws a vertical rule of the table gadget grid. More...
 
void enableKeyboardDeleteRow (IlBoolean flag)
 Enables/disables the user to delete the current row using the delete key. More...
 
void enableKeyboardRefresh (IlBoolean flag)
 Enables/disables the refresh key by the user. More...
 
void enableMultiSelection (IlBoolean flag)
 Enables/disables multi-selection mode. More...
 
void enableRowSelect (IlBoolean flag)
 Enables/disables row selection mode. More...
 
void enableSort (IlBoolean flag)
 Enables/disables the row sorting. More...
 
void enableToolTips (IlBoolean flag)
 Enables or disables the display of the tooltips. More...
 
void endOfBatch ()
 Used in conjunction with the startOfBatch() member function to terminate a series of modifications on the table gadget. Calls to startOfBatch() and endOfBatch() can be nested.
 
void ensureSelectionVisible ()
 Scrolls the table gadget so that its current selection becomes visible in the bounding box of the table gadget.
 
void ensureVisible (IliTableSelection sel)
 Scrolls the table gadget so that the selection becomes visible in the bounding box of the table gadget. 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 IlBoolean f_externalToInternal ()
 Updates the internal value of a field according to its current external representation. More...
 
virtual IliTablePropertyManagerf_getEffectiveTablePropertyManager ()
 Returns the effective table property manager. More...
 
virtual const IliTablePropertyManagerf_getEffectiveTablePropertyManager () const
 Returns the effective table property manager. 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_isAutoFitPullDown () const
 Returns IlTrue if the width of the pull-down menu is automatically computed so that its contents fit. More...
 
virtual IlBoolean f_isConsistent () const
 Returns IlTrue if the internal value of the field corresponds to its current external representation. More...
 
virtual IlBoolean f_isInputModified () const
 Returns IlTrue if the external representation has been edited by the end-user. More...
 
virtual IlBoolean f_isReadOnly () const
 Returns IlTrue if the field is read-only. More...
 
virtual void f_setAutoFitPullDown (IlBoolean)
 Enables/disables the automatic width computing of the pull-down menu. More...
 
virtual void f_setInputModified (IlBoolean)
 Sets the input-modified attribute of the field. More...
 
virtual void f_setReadOnly (IlBoolean)
 Sets the read-only property for the field. More...
 
virtual void f_setTablePropertyManagerName (const char *)
 Sets the name of the table property manager to use. More...
 
virtual IlBoolean f_setValue (const IliValue &, IlBoolean=IlFalse)
 Sets the value of the field. More...
 
virtual void f_useTableProperties (IlBoolean)
 Enables/Disables the use of the table properties. More...
 
IliTableFittingMode getAutoFittingMode () const
 Returns the auto-fitting mode. More...
 
IlInt getBatchCount () const
 Returns the current number of nested calls to startOfBatch(). More...
 
IlvColorgetCellBackground () const
 Returns the background color used to draw cells. More...
 
IlvFontgetCellFont () const
 Returns the font used to draw cells. More...
 
IlvColorgetCellForeground () const
 Returns the foreground color used to draw cells. More...
 
IliCellPaletteStructgetCellPaletteStruct () const
 Returns the description of the cell for which text and fill palettes are currently required, as well as the default values for these palettes. More...
 
IlInt getColumnDisplayWidth (IlInt colno) const
 Returns the column width, in pixels. More...
 
IliFieldItfgetColumnEditor (IlInt colno) const
 Returns the field that is used as an editor for a column. More...
 
IlInt getColumnsCount () const
 Returns the number of columns in the underlying table. More...
 
IlAny getCompareData () const
 Returns the user data that can be used to compare two rows. More...
 
IliCompareFunction getCompareFunction () const
 Returns the function that is used to compare two rows. More...
 
IlInt getCurrentColumn () const
 Returns current column. More...
 
IlInt getCurrentRow () const
 Returns current row. More...
 
virtual IliFieldItfgetCustomEditor (IlInt rowno, IlInt colno, IliFieldItf *fld) const
 Returns the field to use as an editor for a cell. More...
 
IlInt getDeletedRow () const
 Returns the deleted row position. More...
 
IliDrawCellStructgetDrawCellStruct () const
 Returns the description of the cell that is currently being drawn. More...
 
IliErrorReportergetErrorReporter () const
 Returns the error reporter that is used by the reportErrors() member functions. More...
 
IlInt getExtendedRowsCount () const
 Returns the number of rows in the underlying table (plus one if the insert row is currently shown). More...
 
IlInt getFetchedRow () const
 Returns the fetched row position. More...
 
IlInt getFirstColumn () const
 Returns the position of the first column shown (from left to right). More...
 
IlInt getFirstRow () const
 Returns the position in the underlying table of the first row shown (from top to bottom). More...
 
IlInt getFixedColumnsCount () const
 Returns the number of columns that do not scroll. These are the left-most columns. More...
 
IlvDim getHeaderHeight () const
 Returns header height, in pixels, of the column headers. More...
 
virtual IlvPalettegetHeaderTextPalette (IlInt colno) const
 Returns the header text palette. More...
 
IlvDim getMarkerWidth () const
 Returns the marker width, in pixels, of the row markers. More...
 
IlInt getRealIndex (IlInt colno) const
 Returns the position, in the underlying table, of the column in the table gadget. More...
 
virtual IlvPalettegetReliefPalette () const
 Returns the relief palette. More...
 
IlvDim getRowHeight () const
 Returns the height, in pixels, of the rows in the table gadget. More...
 
IlInt getRowsCount () const
 Returns the number of rows in the underlying table. More...
 
IlvScrollBargetScrollBar (IlvPosition which) const
 Returns a scroll bar. More...
 
IliShowMode getScrollBarShowMode (IlvPosition which) const
 Returns the show mode for a scroll bar. More...
 
void getSelection (IliTableSelection &sel) const
 Returns the current selection in the table gadget. More...
 
IliTablegetTable ()
 Returns the underlying table of the table gadget. More...
 
const IliTablegetTable () const
 Returns the underlying table of the table gadget. More...
 
IliTablePropertyManagergetTablePropertyManager ()
 Returns the table property manager used. More...
 
const IliTablePropertyManagergetTablePropertyManager () const
 Returns the table property manager used. More...
 
const char * getTablePropertyManagerName () const
 Returns the table property manager name. More...
 
virtual void getToolTipsText (const IlvPoint &pt, IliString &s)
 Returns the tooltip text that must be displayed. More...
 
const IliValuegetValue (IliName colname) const
 Returns the value at the column named colname in the row buffer of the table gadget. More...
 
const IliValuegetValue (IlInt colno) const
 Returns the value at column colno in the row buffer of the table gadget. More...
 
IlInt getVisibleRowsCount (IlBoolean &lastRowClipped) const
 Returns the maximum row count that are shown in the table gadget. More...
 
IlInt getVisualIndex (IlInt colno) const
 Returns the position, in the table gadget, of the column in the underlying table. More...
 
IlBoolean gotoInsertRow ()
 Attempts to move the current row to the insert row. More...
 
virtual IlBoolean gotoNextColumn ()
 Attempts to move the current column to the next shown column. More...
 
virtual IlBoolean gotoNextRow ()
 Attempts to move the current row to the next row. More...
 
virtual IlBoolean gotoPreviousColumn ()
 Attempts to move the current column to the previous shown column. More...
 
virtual IlBoolean gotoPreviousRow ()
 Attempts to move the current row to the previous row. More...
 
IlBoolean hasCustomCellPalettes () const
 Returns IlTrue if the table gadget calls the onGetCellPalette() virtual member function for each cell being drawn. More...
 
IlBoolean isBoundToDataSource () const
 Returns IlTrue if the table gadget is bound to its data source. More...
 
IlBoolean isCellEditorShown () const
 Returns IlTrue if the cell editor is shown in the selected cell when the cell is read-only. More...
 
IlBoolean isColumnGeometryLocal () const
 Returns IlTrue if the end-user is able to change the order of the columns. More...
 
IlBoolean isColumnMoveAllowed () const
 Returns IlTrue if the end-user is able to change the order of the columns. More...
 
IlBoolean isColumnResizeAllowed () const
 Returns IlTrue if the end-user is able to resize columns. More...
 
IlBoolean isColumnVisible (IlInt colno) const
 Returns the column visibility. More...
 
IlBoolean isConfirmOnDeleteRequired () const
 Returns IlTrue if the user is prompted for a confirmation before row deletion. More...
 
IlBoolean isImmediateRefreshDisabled () const
 Returns IlTrue if the immediate refreshes are disabled. More...
 
IlBoolean isInInsertMode () const
 Returns IlTrue if the current row is the insert row and if the current row buffer is modified. More...
 
IlBoolean isInsertRow (IlInt rowno) const
 Returns IlTrue if a row designates the insert row. More...
 
IlBoolean isInUpdateMode () const
 Returns IlTrue if the current row corresponds to an existing table row (that is, it is not the insert row), and if the current row buffer is modified. More...
 
IlBoolean isKeyboardDeleteRowEnabled () const
 Returns IlTrue if the user can use the delete key to delete the current row. More...
 
IlBoolean isKeyboardRefreshEnabled () const
 Returns IlTrue if the user can use the refresh key. More...
 
IlBoolean isMultiSelectionEnabled () const
 Returns IlTrue if the table gadget event handler allows the end-user to select more than one row or column. More...
 
IlBoolean isOnInsertRow () const
 Returns IlTrue if the current row is the insert row. More...
 
IlBoolean isReadOnly () const
 Returns IlTrue if the table gadget is read-only. More...
 
IlBoolean isRowMoveAllowed () const
 Returns IlTrue if the end-user is able to change the order of the rows. More...
 
IlBoolean isRowResizeAllowed () const
 Returns IlTrue if the end-user is able to resize rows. More...
 
IlBoolean isRowSelectEnabled () const
 Returns IlTrue if the row select mode is enabled. More...
 
IlBoolean isSelectionAlwaysShown () const
 Returns IlTrue if the selection of the table gadget is always highlighted. More...
 
IlBoolean isShowingGrid () const
 Returns IlTrue if the table gadget is drawn with a grid. More...
 
IlBoolean isShowingHeaders () const
 Returns IlTrue if the column headers are shown. More...
 
IlBoolean isShowingInsertRow () const
 Returns IlTrue if the insert row is shown. More...
 
IlBoolean isShowingMarkers () const
 Returns IlTrue if the row markers are shown. More...
 
IlBoolean isSortEnabled () const
 Returns IlTrue if the table gadget event handler will sort the rows according to the column header on which the user clicks. More...
 
IlBoolean isTableOwner () const
 Returns IlTrue if the table gadget owns its table. More...
 
IlBoolean isUsingRelief () const
 Returns IlTrue if the table gadget is drawn with a relief border. More...
 
IlBoolean isUsingTableProperties () const
 Returns IlTrue if the table gadget is sensitive to table properties. More...
 
IlBoolean moveColumn (IlInt from, IlInt to)
 Attempts to move the column from a position to another position. More...
 
virtual void onCancelEdits ()
 Called just after the edits in the current row have been canceled. More...
 
virtual void onDeleteRow ()
 Called just before a row in the underlying table is deleted. More...
 
virtual void onDoubleClick ()
 Called just after a double-click on the table gadget. More...
 
virtual void onDrawCell ()
 Called to draw a cell in the table gadget. More...
 
virtual void onEnterCell ()
 Called just after a new cell is entered. More...
 
virtual void onEnterInsertMode ()
 Called just after the current row buffer becomes modified, when the current row is the insert row. More...
 
virtual void onEnterRow ()
 Called just after a new row is entered. More...
 
virtual void onEnterUpdateMode ()
 Called just after the current row buffer becomes modified (when the current row is not the insert row). More...
 
virtual void onFetchRow ()
 Called just after a new row has been retrieved from a remote database and cached in the underlying table. More...
 
virtual void onGetCellPalette ()
 Called when the text and fill palettes of a cell are required (either to draw the cell or to configure the cell editor). More...
 
virtual void onPrepareDeleteRow ()
 Called when the user attempts to delete a row through this table gadget. More...
 
virtual void onPrepareInsert ()
 Called when an attempt is made to validate the current row, when the current row is the insert row. More...
 
virtual void onPrepareUpdate ()
 Called when an attempt is made to validate the current row (when the current row is not the insert row). More...
 
virtual void onQuitCell ()
 Called just before the selection moves out of a cell. More...
 
virtual void onQuitInsertMode ()
 Called just after the current row has been successfully validated, when the current row is the insert row. More...
 
virtual void onQuitRow ()
 Called just before the selection moves out of a row. More...
 
virtual void onQuitUpdateMode ()
 Called just after the current (non insert) row has been successfully validated. More...
 
virtual void onSelectionChange ()
 Called just after the selection has changed (whatever the change). More...
 
virtual void onValidateCell ()
 Called when an attempt is made to move the selection out of a cell. More...
 
virtual void onValidateRow ()
 Called when an attempt is made to validate the current row. More...
 
void pasteFromClipboard ()
 Pastes the contents of the clipboard into the current selection.
 
void pasteFromClipboard (const IliTableSelection &sel)
 Pastes the contents of the clipboard into the selection. More...
 
IlBoolean pointToSelection (const IlvPoint &pt, IliTableSelection &sel, const IlvTransformer *t=0) const
 Returns the selection pointed by a point. More...
 
void refreshAll ()
 Redraws the table gadget in its entirety.
 
void refreshCell (IlInt rowno, IlInt colno)
 Redraws a cell. More...
 
void refreshColumn (IlInt colno)
 Redraws a column. More...
 
void refreshRow (IlInt rowno)
 Redraws a row. More...
 
void removeErrorSink (IliErrorSink *sink)
 Removes an error sink from this table gadget. More...
 
void reportErrors (const IliErrorList &errorList) const
 Reports the errors that are contained in a error list. More...
 
void requireConfirmOnDelete (IlBoolean flag)
 Enables/disables confirmation before row deletion. More...
 
virtual void scrollTo (IlInt rowno, IlInt colno)
 Scrolls to a cell. More...
 
void scrollToColumn (IlInt colno)
 Scrolls to a column. More...
 
void scrollToRow (IlInt rowno)
 Scrolls to a row. More...
 
IlBoolean selectAll ()
 Attempts to select all rows and columns. More...
 
IlBoolean selectCell (IlInt rowno, IlInt colno)
 Attempts to select the cell at a row and a column. More...
 
IlBoolean selectColumn (IlInt colno)
 Attempts to select a column. More...
 
IlBoolean selectNone ()
 Attempts to deselect the current selection. More...
 
IlBoolean selectRow (IlInt rowno)
 Attempts to select a row. More...
 
void setAutoFittingMode (IliTableFittingMode mode)
 Sets the auto-fitting mode. More...
 
virtual void setCellBackground (IlvColor *color)
 Sets the background color used to draw cells. More...
 
virtual void setCellFont (IlvFont *font)
 Sets the font used to draw cells. More...
 
virtual void setCellForeground (IlvColor *color)
 Sets the foreground color used to draw cells. More...
 
void setColumnDisplayWidth (IlInt colno, IlInt width)
 Sets column width, in pixels. More...
 
IlBoolean setColumnEditor (IlInt colno, IliFieldItf *fld, IlBoolean owner=IlTrue)
 Sets the field that is used as an editor for column. More...
 
void setColumnGeometryLocal (IlBoolean flag)
 Enables/disables the column moving. More...
 
void setColumnVisible (IlInt colno, IlBoolean flag)
 Sets column visibility. More...
 
void setCompareFunction (IliCompareFunction fct, IlAny arg=0)
 Defines the function fct and user data that must be used to compare two rows. More...
 
void setCustomCellPalettes (IlBoolean flag)
 Enables/disables the use of specific palettes for a cell. More...
 
void setErrorReporter (IliErrorReporter *reporter)
 Sets the error reporter. More...
 
IlBoolean setFixedColumnsCount (IlInt count)
 Sets the number of columns that do not scroll. More...
 
void setHeaderHeight (IlvDim h)
 Sets header height. More...
 
void setMarkerWidth (IlvDim w)
 Sets the marker width. More...
 
IlBoolean setReadOnly (IlBoolean flag)
 Sets the table gadget as read-only or not. More...
 
void setReliefPalette (IlvPalette *pal)
 Sets the relief palette. More...
 
void setRowHeight (IlvDim h)
 Sets the height of the rows in a table gadget. More...
 
virtual IlBoolean setSelection (const IliTableSelection &sel)
 Attempts to set the table gadget selection. More...
 
virtual void setTable (IliTable *table, IlBoolean owner=IlTrue)
 Connects the table gadget to a table. More...
 
void setTablePropertyManager (IliTablePropertyManager *pMgr)
 Sets the table property manager. More...
 
void setTablePropertyManagerName (const char *name)
 Sets the table property manager name. More...
 
IlBoolean setValue (IliName colname, const IliValue &value)
 Sets the value at the column named colname, in the row buffer of the table gadget, to value. More...
 
IlBoolean setValue (IlInt colno, const IliValue &value)
 Sets the value at column colno, in the row buffer of the table gadget, to value. More...
 
void setVisibleRowsCount (IlInt count)
 Changes the height of the table gadget so that the maximum number of rows can be shown. More...
 
void showCellEditor (IlBoolean flag)
 Specifies that the cell editor is shown in read-only cells. More...
 
void showGrid (IlBoolean flag)
 Shows/Hides grid. More...
 
void showHeaders (IlBoolean flag)
 Shows/Hides the column headers. More...
 
IlBoolean showInsertRow (IlBoolean flag)
 Shows/Hides insert row. More...
 
void showMarkers (IlBoolean flag)
 Shows/Hides row markers. More...
 
void showScrollBar (IlvPosition which, IliShowMode mode)
 Sets the show mode for a scroll bar. More...
 
void showSelectionAlways (IlBoolean flag)
 Shows/hides the selection. More...
 
void sortColumn (IlInt colno)
 Sorts the rows according to ascending or descending order of column. More...
 
void startOfBatch ()
 Used to start a series of modifications to the table gadget. It allows the table gadget to significantly reduce the time needed to reformat itself.
 
void useRelief (IlBoolean flag)
 Shows/Hides relief border. More...
 
void useTableProperties (IlBoolean flag)
 Sets the table gadget sensitivity about table properties. More...
 
virtual IlBoolean validate (IlBoolean interactive=IlFalse)
 Validates the current row. 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 void f_enableCompletion (IlBoolean flag)
 Sets the completion property of the field. More...
 
virtual IlvAlignment f_getAlignment () const
 Returns the text alignment of the field. More...
 
IliDataSourcef_getDataSource ()
 Returns the data source. More...
 
const IliDataSourcef_getDataSource () const
 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...
 
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...
 
IliTablef_getForeignTable ()
 Returns the foreign table. More...
 
const IliTablef_getForeignTable () const
 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...
 
virtual const IliFormatf_getFormat () const
 Returns the format used to derive the external representation of the field from its internal value. More...
 
IlvGadgetf_getGadget ()
 Returns the gadget associated with this field through multiple inheritance. More...
 
const IlvGadgetf_getGadget () const
 Returns the constant gadget associated with this field through multiple inheritance. More...
 
IlvGraphicf_getGraphic ()
 Returns the graphic associated with this field through multiple inheritance. More...
 
const IlvGraphicf_getGraphic () const
 Returns the constant graphic associated with this field through multiple inheritance. More...
 
virtual const char * f_getLabel () const
 Returns the label displayed by the field gadget. 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...
 
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...
 
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_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_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 align)
 Sets the text alignment of the field. 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_setFormat (const IliFormat &fmt)
 Sets the format used to derive the external representation of the field from its internal value. More...
 
virtual void f_setLabel (const char *label)
 Sets the label of the field gadget. More...
 
virtual void f_setMask (const IliInputMask &msk)
 Sets the input mask. More...
 
virtual void f_setMaxLength (IlShort vmax)
 Sets the maximum length allowed for the external representation of the field. 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...
 

Static Public Member Functions

static IlvSymbolCancelEditsSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolDeleteRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolDoubleClickSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolDrawCellSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolEnterCellSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolEnterInsertModeSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolEnterRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolEnterUpdateModeSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolFetchRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolGetCellPaletteSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static void GetRefreshShortCut (IlUShort &modifiers, IlUShort &key)
 Returns the definition of the shortcut key that refreshes all. More...
 
static IlvSymbolPrepareDeleteRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolPrepareInsertSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolPrepareUpdateSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolQuitCellSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolQuitInsertModeSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolQuitRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolQuitUpdateModeSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolSelectionChangeSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static void SetRefreshShortCut (IlUShort modifiers, IlUShort key)
 Sets the definition of the shortcut key that refreshes all. More...
 
static IlvSymbolValidateCellSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. More...
 
static IlvSymbolValidateRowSymbol ()
 Returns the name of the callback that will be called by the corresponding virtual member function. 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...
 

Additional Inherited Members

- 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 IliTableGadget class defines gadgets that can edit and display tables. It works in conjunction with the IliTable class.

About clipboard

The table gadget can copy the contents of a given selection to the clipboard in the form of a character string. Each value in the selection is formatted according to the format and input mask of the column to which this column belongs. If the selection contains more than one column or more than one row, then each row is separated by a new line character and each column is separated by a tab character.

About Callbacks

Some virtual member functions described in this documentation are normally called by the table gadget itself when certain events occur. The behavior of the table gadget can be customized by defining a subclass of IliTableGadget and overriding these virtual member functions. Alternatively, it is possible to customize the behavior of a table gadget without subclassing. This can be done by setting callbacks (see the IlvGraphic::setCallback() member function).

The default implementation of these virtual member functions is to call the corresponding callback.

See also
IliDataSource, IliErrorMessage, IliErrorReporter, IliErrorSink, IliSchema, IliTable, IliCellPaletteStruct, IliDrawCellStruct, IliTableSelection, IliShowMode, IliTableFittingMode, IliTableSelectionType.

Accessors\nAccessors provide a scriptable and uniform way to inspect and modify an object by using its base class methods <tt>IlvValueInterface::queryValue()</tt>, <tt>IlvValueInterface::queryValues()</tt>, <tt>IlvValueInterface::changeValue()</tt>, <tt>IlvValueInterface::changeValues()</tt>.\n\n\nThis class inherits the accessors of its superclasses \c IlvGadget and \c IliFieldItf, and adds the following ones:

Data accessors

Name Type Equivalent methods
table Object getTable(), setTable()
currentRow Int getCurrentRow()
currentColumn Int getCurrentColumn()
columnsCount Int getColumnsCount()
allowColumnMove Boolean isColumnMoveAllowed(), allowColumnMove()
allowColumnResize Boolean isColumnResizeAllowed(), allowColumnResize()
allowRowMove Boolean isRowMoveAllowed(), allowRowMove()
allowRowResize Boolean isRowResizeAllowed(), allowRowResize()
alwaysShowSelection Boolean isSelectionAlwaysShown(), showSelectionAlways()
autoFit Int getAutoFittingMode(), setAutoFittingMode()
boundToDataSource Boolean isBoundToDataSource(), bindToDataSource(). See [boundToDataSource] below.
cellBackground Color getCellBackground(), setCellBackground()
cellFont Font getCellFont(), setCellFont()
cellForeground Color getCellForeground(), setCellForeground()
columnGeometryLocal Boolean isColumnGeometryLocal(), setColumnGeometryLocal(). See [columnGeometryLocal] below.
confirmDeletes Boolean isConfirmOnDeleteRequired(), requireConfirmOnDelete()
deleteKey Boolean isKeyboardDeleteRowEnabled(), enableKeyboardDeleteRow()
fixedColumns Int getFixedColumnsCount(), setFixedColumnsCount()
headerHeight Int getHeaderHeight(), setHeaderHeight()
horizontalScroll Int getScrollBarShowMode(IlvHorizontal), showScrollBar(IlvHorizontal, mode)
markerWidth Int getMarkerWidth(), setMarkerWidth()
refreshKey Boolean isKeyboardRefreshEnabled(), enableKeyboardRefresh()
rowHeight Int getRowHeight(), setRowHeight()
showCellEditor Boolean isCellEditorShown(), showCellEditor()
rowSelectEnabled Boolean isRowSelectEnabled(), enableRowSelect()
showGrid Boolean isShowingGrid(), showGrid()
showHeaders Boolean isShowingHeaders(), showHeaders()
showInsertRow Boolean isShowingInsertRow(), showInsertRow()
showMarkers Boolean isShowingMarkers(), showMarkers()
useRelief Boolean isUsingRelief(), useRelief()
verticalScroll Int getScrollBarShowMode(IlvVertical), showScrollBar(IlvVertical, mode)
selection Object getSelection(), setSelection()
firstRow Int getFirstRow(), scrollToRow()
firstColumn Int getFirstColumn(), scrollToColumn()
sortEnabled Boolean isSortEnabled(), enableSort()
multiSelectionEnabled Boolean isMultiSelectionEnabled(), enableMultiSelection()
deletedRow Int getDeletedRow()
fetchedRow Int getFetchedRow()
cellPaletteStruct Object IliCellPaletteStruct constructor
autoFittingPullDown Boolean f_isAutoFitPullDown(), f_setAutoFitPullDown()

[boundToDataSource] By default, a table gadget has the same current row as the data source to which it is connected. When you move to another row through the data source, the table gadget's current row changes accordingly and vice-versa. Also, if you start editing the current row through the data source, you see your changes in the table gadget even before the changes are validated, and vice-versa.
By setting the boundToDataSource property to false, you can have the table gadget manage its own notion of the current row, independently of its data source.

[columnGeometryLocal] By default, the table gadget shows the columns in the same order and with the same width as they are defined in the underlying table object. Consequently, if you connect two table gadgets to the same data source, each time the user resizes a column in one table gadget, the same column is resized in the other. This is not necessarily desirable, especially if auto fit mode is enabled.
By setting the columnGeometryLocal property to true, you can have the table gadget itself manage columns visibility, widths, and ordering. In this way, it is possible to have more than one table gadget showing different views (in terms of columns) of the same data source.
Here is an example in Rogue Wave Views Script:

var tgLeft = Application.MyPanel.LeftTG;
tgLeft.dataSourceName = "EMP";
tgLeft.columnGeometryLocal = true;
tgLeft.ID.visible = false;
var tgRight = Application.MyPanel.RightTG;
tgRight.dataSourceName = "EMP";
tgLeft.columnGeometryLocal = true;
tgLeft.ID.visible = true;
// now, the "ID" column is visible in one
// table-gadget but not in the other.

Method accessors

Name Return type Equivalent methods
selectCell(Int row, Int col) Boolean selectCell(row, col)
selectRow(Int row) Boolean selectRow(row)
selectColumn(Int col) Boolean selectColumn(col)
selectAll() Boolean selectAll()
selectNone() Boolean selectNone()
validate() Boolean validate(IlTrue)
validateSilently() Boolean validate(IlFalse)
cancel() Void cancel()
getColumn(String name) Object See [getColumn] below.
getColumnAt(Int col) Object See [getColumnAt] below.
useToggleAt(Int col) Void setColumnEditor(col, new IliSimpleToggle, IlTrue)
usePictureAt(Int col) Void setColumnEditor(col, new IliDbPicture, IlTrue)
isOnInsertRow() Boolean isOnInsertRow()
addError(String error) Void addErrorMessage(error)
addErrorMessage(Object errorMessage) Void addErrorMessage(errorMessage)
addErrorSink(Object sink) Void addErrorSink(sink). See [addErrorSink] below.
removeErrorSink(Object sink) Void removeErrorSink(sink)
reportErrors(Object errorList) Void reportErrors(errorList)
dontValidateRow() Void dontValidateRow()
dontValidateCell() Void dontValidateCell()
dontDeleteRow() Void dontDeleteRow()

[getColumn] This method returns the IliTableGadgetColumn object representing the column called name in the table.

Note that the columns become properties of the table gadget so that tg.getColumn("NAME") and tg.NAME.

[getColumnAt] This method returns the description of the column positioned at col.

[addErrorSink] The sink parameter can be one of the following:

Callbacks

There are many callbacks that you can use to customize a table gadget. Be aware that these callbacks are called in very specific contexts that are elaborated in the description for each callback.

Consequently, great care should be taken not to call directly or indirectly methods that would completely change the context in which the callback was called. For instance, you should not call the selectCell method from inside a FetchRow callback since this callback can be called asynchronously.

Many of these callbacks exist also on the IliDataSource class. If the table gadget is bound to its data source, it is the callbacks that are defined on the data source that are called and not those of the table gadget.

If, on the contrary, the table gadget is not bound to its data source, the callbacks that are defined on the table gadget will be called when the event originates from the table gadget and those defined on the data source will be called when the event originates from the data source.

The description for each callback below explains whether the callback depends in this way on the boundToDataSource property.

Name Notes
CancelEdits Only available if boundToDataSource is false. Called just after the edits in the current row have been cancelled.
DeleteRow Called just before a row in the underlying table is deleted. The index of the row that is to be deleted can be obtained by looking at the deletedRow property.
DoubleClick Called when the user double-clicks on the table gadget.
EnterCell Called just after a new cell is entered.
EnterInsertMode Only available if boundToDataSource is false. Called just after the current row buffer becomes modified when the current row is the insert row.
EnterRow Called just after a new row is entered.
EnterUpdateMode Only available if boundToDataSource is false. Called just after the current row buffer becomes modified when the current row is not the insert row.
FetchRow Called just after a new row has been retrieved from a remote database and cached in the underlying table. The index of the row that has just been fetched can be obtained by looking at the fetchedRow property. See [FetchRow] below.
GetCellPalette Called when the text and fill palettes of a cell are required, either to draw the cell or to configure the cell editor. The cell for which the palettes are required is described, along with other useful information, in the object obtained by looking at the cellPaletteStruct property.
PrepareDeleteRow This callback is only available if boundToDataSource is false. Called when the user attempts to delete a row through this table gadget. The index of the row that is to be deleted can be obtained by looking at the deletedRow property.
The row deletion can be prevented by calling the dontDeleteRow() method. In addition, the addErrorMessage() method may be called to describe the reason of the failure. See [PrepareDeleteRow] below.
PrepareInsert Only available if boundToDataSource is false. Called when an attempt is made to validate the current row when the current row is the insert row. This callback is called in addition to the ValidateRow callback. The row validation can be prevented by calling the dontValidateRow() method. In this case, the addErrorMessage() method should also be called to provide an error message to the user. Alternatively, it is possible to change some of the values in the current row before it is inserted in the underlying table.
PrepareUpdate Only available if boundToDataSource is false. Called when an attempt is made to validate the current row when the current row is not the insert row. This callback is called in addition to the ValidateRow callback. The row validation can be prevented by calling the dontValidateRow() method. In this case, the addErrorMessage() method should also be called to provide an error message to the user. Alternatively, it is possible to change some of the values in the current row before it is updated in the underlying table.
QuitCell Called just before the selection moves out of a cell.
QuitInsertMode This callback is only available if boundToDataSource is false. Called just after the current row has been successfully validated when the current row is the insert row.
QuitRow Called just before the selection moves out of a row.
QuitUpdateMode Only available if boundToDataSource is false. Called just after the current row has been successfully validated when the current is not the insert row.
SelectionChange Called just after the selection has changed (whatever the change).
ValidateCell Called when an attempt is made to move the selection out of a cell. The cell validation can be prevented by calling the dontValidateCell() method. In this case, the addErrorMessage() method should also be called to provide an error message to the user.
ValidateRow Only available if boundToDataSource is false. Called when an attempt is made to validate the current row. The row validation can be prevented by calling the dontValidateRow() method. In this case, the addErrorMessage() method should also be called to provide an error message to the user. Alternatively, it is possible to change some of the values in the current row before it is transmitted to the underlying table. This callback is called when an existing row is being updated or when a new row is being inserted. See [ValidateRow] below.

[FetchRow] Here is an example of a FetchRow callback:

var counter = 0;
function OnFetchRow(tg) {
var column = tg.COUNTER.tableColumn;
column.setInCache(tg.fetchedRow, ++counter);
}

Note how it uses the setInCache() method of IliTableColumn to store a value in the local row cache of the table object.

[PrepareDeleteRow] Here is an example of a PrepareDeleteRow callback:

function OnPrepareDeleteRow(tg) {
if (tg.deletedRow == 0) {
tg.dontDeleteRow();
tg.addError("Leaf node cannot be deleted.");
}
}

[ValidateRow] Here is an example of a ValidateRow callback:

function OnValidateRow(tg) {
var capacity = tg.CAPACITY.value;
var volume = tg.VOLUME.value;
if (volume > capacity) {
tg.dontValidateRow();
tg.addError("Volume must be less than Capacity");
}
else {
tg.LASTMODIF.value = new Date();
}
}

Constructor & Destructor Documentation

◆ IliTableGadget() [1/2]

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

This constructor initializes a table gadget that is connected to a default table.

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

◆ IliTableGadget() [2/2]

IliTableGadget::IliTableGadget ( IlvDisplay display,
IliTable table,
IlBoolean  owner,
const IlvRect rect,
IlUShort  thickness = IlvDefaultGadgetThickness,
IlvPalette palette = 0 
)

This constructor initializes a table gadget that is connected to a table.

Parameters
displayThe display.
tableThe table.
ownerThe table owner, if IlTrue, the table gadget becomes the table owner.
rectThe location.
thicknessThe border thickness.
paletteThe palette.

Member Function Documentation

◆ addErrorMessage() [1/2]

void IliTableGadget::addErrorMessage ( const char *  msg)

Forwards an application error message to all the error sinks that have been added with the addErrorSink() member function.

This member function may be called by one of the onValidateCell(), onValidateRow(), onPrepareInsert(), or onPrepareInsert() virtual member functions, or by the corresponding callbacks.

Parameters
msgThe error message.

◆ addErrorMessage() [2/2]

void IliTableGadget::addErrorMessage ( const IliErrorMessage msg)

Forwards an error message to all the error sinks that have been added with the addErrorSink() member function.

This member function may be called by one of the onValidateCell(), onValidateRow(), onPrepareInsert(), or onPrepareInsert() virtual member functions, or by the corresponding callbacks.

Parameters
msgThe error message.

◆ addErrorSink()

void IliTableGadget::addErrorSink ( IliErrorSink sink)

All errors that occur on the table-gadget table or on the table-gadget data source (if it is bound to a data source) and all errors that are thrown by one of the addErrorMessage() member functions, will be forwarded to this error sink.

Note that the table gadget will not delete the error sink at destruction time, so the same error sink may be safely shared by many table gadgets.

Parameters
sinkThe error sink.

◆ allowColumnMove()

void IliTableGadget::allowColumnMove ( IlBoolean  flag)

Allows or not the column moving by the end-user.

Parameters
flagIf IlTrue, allows the end-user to move columns around. Otherwise, this feature is disabled.

◆ allowColumnResize()

void IliTableGadget::allowColumnResize ( IlBoolean  flag)

Enables/disables the column resizing by the end-user.

Parameters
flagIf IlTrue, allows the end-user to resize columns. Otherwise, this feature is disabled.

◆ allowRowMove()

void IliTableGadget::allowRowMove ( IlBoolean  flag)

Enables/disables the row moving by the end-user.

Parameters
flagIf IlTrue, allows the end-user to move rows around. Otherwise, this feature is disabled.

◆ allowRowResize()

void IliTableGadget::allowRowResize ( IlBoolean  flag)

Enables/disables the end-user to resize rows.

Parameters
flagIf IlTrue, allows the end-user to resize rows. Otherwise, this feature is disabled.

◆ areToolTipsEnabled()

IlBoolean IliTableGadget::areToolTipsEnabled ( ) const

Returns IlTrue if tooltip display is enabled.

Returns
The tooltip displaying permission.

◆ at() [1/2]

IliValue IliTableGadget::at ( IlInt  rowno,
const char *  colname 
) const

Returns a value.

Parameters
rownoThe row position, if it designates the current row, the value comes from the underlying table. If not, the value comes from the row buffer of the table gadget.
colnameThe column name.
Returns
The value.

◆ at() [2/2]

IliValue IliTableGadget::at ( IlInt  rowno,
IlInt  colno 
) const

Returns a value.

Parameters
rownoThe row position, if it designates the current row, the value comes from the underlying table. If not, the value comes from the row buffer of the table gadget.
colnoThe column position as it appears in the table gadget (see the getVisualColno() member function description).
Returns
The value.

◆ bindToDataSource()

void IliTableGadget::bindToDataSource ( IlBoolean  flag)

Enables/Disables the bind data source option.

Parameters
flagIf IlTrue, binds the table gadget to its data source and unbinds it otherwise.

◆ cancel()

virtual void IliTableGadget::cancel ( )
virtual

Cancels any user input awaiting validation.

The row buffer of the table gadget becomes unmodified. This member function calls the onCancelEdits() virtual member function.

Note that if the table gadget is bound to a data source, then the onCancelEdits() is called on the data source instead of on the table gadget.

◆ CancelEditsSymbol()

static IlvSymbol* IliTableGadget::CancelEditsSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ cellBBox()

IlBoolean IliTableGadget::cellBBox ( const IliTableSelection sel,
IlvRect rect,
const IlvTransformer t = 0 
) const

Returns the bounding box of a selection, according to one (optional) transformer.

Parameters
selThe selection.
rectThe computed bounding box.
tThe transformer.
Returns
IlTrue if the bounding box of the selection intersects the bounding box of the table gadget.

◆ copyToClipboard()

void IliTableGadget::copyToClipboard ( const IliTableSelection sel) const

Copies the contents of one selection to the clipboard.

Parameters
selThe selection.

◆ DeleteRowSymbol()

static IlvSymbol* IliTableGadget::DeleteRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ disableImmediateRefresh()

void IliTableGadget::disableImmediateRefresh ( IlBoolean  disable)

Disables the immediate refreshes of the gadget.

This function is used to disable the immediate refreshes. The immedite refreshes are replaced by refreshes which are executed after the last call to the reDrawView() function of the container.

Parameters
disableIf IlTrue the immediate refreshes are disabled.

◆ dontDeleteRow()

void IliTableGadget::dontDeleteRow ( )

Cancels the row deletion.

Call this member function from the onPrepareDeleteRow() virtual member function or from its corresponding callback to cancel the row deletion.

◆ dontValidateRow()

void IliTableGadget::dontValidateRow ( )

Cancels the row validation.

Called from one of the onValidateRow(), onPrepareInsert(), or onPrepareUpdate() virtual member functions, or from one of their corresponding callbacks. Note that if the table gadget is bound to its data source, this member function has no application.

◆ DoubleClickSymbol()

static IlvSymbol* IliTableGadget::DoubleClickSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ drawCell()

virtual void IliTableGadget::drawCell ( IlvPort dst,
IlInt  rowno,
IlInt  colno,
const char *  label,
IlvAlignment  align,
IlBoolean  selected,
const IlvRect bbox,
IlvPalette palette,
const IlvRegion clip 
) const
virtual

Draws a cell.

Parameters
dstThe port.
rownoThe row position.
colnoThe column position.
labelThe label.
alignThe alignment.
selectedIf IlTrue, it is selected.
bboxThe bounding box.
paletteThe palette.
clipThe region of clipping.

◆ DrawCellSymbol()

static IlvSymbol* IliTableGadget::DrawCellSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ drawCorner()

virtual void IliTableGadget::drawCorner ( IlvPort dst,
IlBoolean  selected,
const IlvRect bbox,
const IlvRegion clip 
) const
virtual

Draws the upper left corner of the table gadget.

Parameters
dstThe port.
selectedIf IlTrue, it is selected.
bboxThe bounding box.
clipThe region of clipping.

◆ drawHeader()

virtual void IliTableGadget::drawHeader ( IlvPort dst,
IlInt  colno,
const char *  label,
IlBoolean  selected,
const IlvRect bbox,
const IlvRegion clip 
) const
virtual

Draws a header.

Parameters
dstThe port.
colnoThe column position.
labelThe label.
selectedIf IlTrue, it is selected.
bboxThe bounding box.
clipThe region of clipping.

◆ drawHorzRule()

virtual void IliTableGadget::drawHorzRule ( IlvPort dst,
IlvPos  x1,
IlvPos  x2,
IlvPos  y,
IlInt  rowno,
IlInt  colnoLeft,
IlInt  colnoRight,
IlvPalette palette,
const IlvRegion clip 
) const
virtual

Draws a horizontal rule of the table gadget grid.

Draws a horizontal rule of the table gadget grid in the dst port.

Parameters
dstThe port.
x1The x start position.
x2The x last position.
yThe y position.
rownoThe row position.
colnoLeftThe first column position.
colnoRightThe last column position.
paletteThe palette.
clipThe region of clipping.

Reimplemented in IliInspectorGadget.

◆ drawMarker()

virtual void IliTableGadget::drawMarker ( IlvPort dst,
IlInt  rowno,
IlBoolean  selected,
IlBoolean  current,
const IlvRect bbox,
const IlvRegion clip 
) const
virtual

Draws a marker.

Parameters
dstThe port.
rownoThe row position.
selectedIf IlTrue, it is selected.
currentIf IlTrue, it is the marker of the current row.
bboxThe bounding box.
clipThe region of clipping.

Reimplemented in IliInspectorGadget.

◆ drawVertRule()

virtual void IliTableGadget::drawVertRule ( IlvPort dst,
IlvPos  y1,
IlvPos  y2,
IlvPos  x,
IlInt  colno,
IlInt  rownoTop,
IlInt  rownoBot,
IlvPalette palette,
const IlvRegion clip 
) const
virtual

Draws a vertical rule of the table gadget grid.

Parameters
dstThe port.
y1The y start position.
y2The y last position.
xThe x position.
colnoThe column position.
rownoTopThe first row position.
rownoBotThe last row position.
paletteThe palette.
clipThe region of clipping.

Reimplemented in IliInspectorGadget.

◆ enableKeyboardDeleteRow()

void IliTableGadget::enableKeyboardDeleteRow ( IlBoolean  flag)

Enables/disables the user to delete the current row using the delete key.

Parameters
flagIf IlTrue, enables the user to delete the current row using the delete key. Otherwise, this feature is disabled.

◆ enableKeyboardRefresh()

void IliTableGadget::enableKeyboardRefresh ( IlBoolean  flag)

Enables/disables the refresh key by the user.

Enables the user to call the IliTable::select() member function, on the underlying table with the refresh key, if flag is IlTrue (by default the F9 function key, but see the SetRefreshShortCut() member function description). Otherwise, this feature will be disabled.

◆ enableMultiSelection()

void IliTableGadget::enableMultiSelection ( IlBoolean  flag)

Enables/disables multi-selection mode.

Note that this mode only affects the behavior of the event-handler.

Parameters
flagIf IlTrue, enables multi-selection mode. Otherwise, multi-selection mode is disabled.

◆ enableRowSelect()

void IliTableGadget::enableRowSelect ( IlBoolean  flag)

Enables/disables row selection mode.

Parameters
flagIf IlTrue, enables row select mode. Otherwise row select mode is disabled.

◆ enableSort()

void IliTableGadget::enableSort ( IlBoolean  flag)

Enables/disables the row sorting.

Parameters
flagIf IlTrue, enables the sort mode. Otherwise, the sort mode is disabled. Note that this mode only affects the behavior of the event-handler.

◆ enableToolTips()

void IliTableGadget::enableToolTips ( IlBoolean  flag)

Enables or disables the display of the tooltips.

Parameters
flagThe tooltip show flag.

◆ ensureVisible()

void IliTableGadget::ensureVisible ( IliTableSelection  sel)

Scrolls the table gadget so that the selection becomes visible in the bounding box of the table gadget.

Parameters
selThe selection.

◆ EnterCellSymbol()

static IlvSymbol* IliTableGadget::EnterCellSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ EnterInsertModeSymbol()

static IlvSymbol* IliTableGadget::EnterInsertModeSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ EnterRowSymbol()

static IlvSymbol* IliTableGadget::EnterRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ EnterUpdateModeSymbol()

static IlvSymbol* IliTableGadget::EnterUpdateModeSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ f_complete()

virtual IlBoolean IliTableGadget::f_complete ( )
virtual

Updates the internal value of the field, according to its current external representation and its foreign table, provided completion is enabled for the field.

For more information on completion, see the f_iscompletionEnabled() member function.

Returns
IlTrue if successful.

Reimplemented from IliFieldItf.

◆ f_externalToInternal()

virtual IlBoolean IliTableGadget::f_externalToInternal ( )
virtual

Updates the internal value of a field according to its current external representation.

Returns
IlTrue if successful and IlFalse otherwise. Note that this may fail due to the fact that not all external representations can be converted to a value object. For example, this is especially true for text fields that are used to edit numeric or date values.

Reimplemented from IliFieldItf.

◆ f_getEffectiveTablePropertyManager() [1/2]

virtual IliTablePropertyManager* IliTableGadget::f_getEffectiveTablePropertyManager ( )
virtual

Returns the effective table property manager.

Returns
The effective table property manager that is obtained as follows:
  • If the useTableProperties property is IlFalse or if the data source to which the field is connected has its useTableProperties property set to IlFalse, this member function returns 0.
  • Otherwise, if the tablePropertyManagerName property is not empty, the table property manager with that name is returned.
  • Otherwise, if the data source to which the field is connected has a tablePropertyManagerName property that is not empty, the table property manager with that name is returned.
  • Otherwise, the table default property manager is returned.

Reimplemented from IliFieldItf.

◆ f_getEffectiveTablePropertyManager() [2/2]

virtual const IliTablePropertyManager* IliTableGadget::f_getEffectiveTablePropertyManager ( ) const
virtual

Returns the effective table property manager.

Returns
The effective table property manager that is obtained as follows:
  • If the useTableProperties property is IlFalse or if the data source to which the field is connected has its useTableProperties property set to IlFalse, this member function returns 0.
  • Otherwise, if the tablePropertyManagerName property is not empty, the table property manager with that name is returned.
  • Otherwise, if the data source to which the field is connected has a tablePropertyManagerName property that is not empty, the table property manager with that name is returned.
  • Otherwise, the table default property manager is returned.

Reimplemented from IliFieldItf.

◆ f_getValue()

virtual const IliValue& IliTableGadget::f_getValue ( IlBoolean  internal = IlFalse) const
virtual

Returns the value of the field.

Parameters
internalIf IlTrue, the returned value does not necessarily reflect the state of the field as the user sees it.
Returns
The value.

Reimplemented from IliFieldItf.

◆ f_isAutoFitPullDown()

virtual IlBoolean IliTableGadget::f_isAutoFitPullDown ( ) const
virtual

Returns IlTrue if the width of the pull-down menu is automatically computed so that its contents fit.

Returns
IlTrue if the width of the pull-down menu is automatically computed so that its contents fit. The value returned by this virtual member function is currently meaningful only when the field gadget is one of the following: For a table gadget, this property applies to all table combo boxes contained in the table gadget.

Reimplemented from IliFieldItf.

◆ f_isConsistent()

virtual IlBoolean IliTableGadget::f_isConsistent ( ) const
virtual

Returns IlTrue if the internal value of the field corresponds to its current external representation.

A return value of IlFalse means that the external representation of the field has been edited by the end-user since the last time one of the member functions, f_setValue(), f_externalToInternal(), f_internalToExternal() or f_complete() was successfully called.

Returns
IlTrue if the internal value of the field corresponds to its current external representation.

Reimplemented from IliFieldItf.

◆ f_isInputModified()

virtual IlBoolean IliTableGadget::f_isInputModified ( ) const
virtual

Returns IlTrue if the external representation has been edited by the end-user.

Returns
IlTrue if the external representation has been edited by the end-user since the last time one of the member functions, f_setValue(), f_externalToInternal(), f_internalToExternal(), or f_complete() was successfully called.

Reimplemented from IliFieldItf.

◆ f_isReadOnly()

virtual IlBoolean IliTableGadget::f_isReadOnly ( ) const
virtual

Returns IlTrue if the field is read-only.

Returns
IlTrue if the field is read-only.

Reimplemented from IliFieldItf.

◆ f_setAutoFitPullDown()

virtual void IliTableGadget::f_setAutoFitPullDown ( IlBoolean  flag)
virtual

Enables/disables the automatic width computing of the pull-down menu.

Parameters
flagIf IlTrue, the width of the pull-down menu is automatically computed so that its contents fit. See the description of f_isAutoFitPullDown() for more information on this property.

Reimplemented from IliFieldItf.

◆ f_setInputModified()

virtual void IliTableGadget::f_setInputModified ( IlBoolean  flag)
virtual

Sets the input-modified attribute of the field.

This member function is presented here for completeness. However, it should be used with care since it may cause the field, and other related components, to be in error with regard to the current state of the field.

Parameters
flagThe input-modified attribute.

Reimplemented from IliFieldItf.

◆ f_setReadOnly()

virtual void IliTableGadget::f_setReadOnly ( IlBoolean  flag)
virtual

Sets the read-only property for the field.

Parameters
flagThe read-only flag.

Reimplemented from IliFieldItf.

◆ f_setTablePropertyManagerName()

virtual void IliTableGadget::f_setTablePropertyManagerName ( const char *  name)
virtual

Sets the name of the table property manager to use.

Parameters
nameThe table property manager. If name is 0 or an empty string, the default table property manager is be used.

Reimplemented from IliFieldItf.

◆ f_setValue()

virtual IlBoolean IliTableGadget::f_setValue ( const IliValue val,
IlBoolean  internal = IlFalse 
)
virtual

Sets the value of the field.

Parameters
valThe value.
internalIf IlFalse, then the external representation and the display of the field are automatically updated.
Returns
IlTrue if successful, and IlFalse otherwise.

Reimplemented from IliFieldItf.

◆ f_useTableProperties()

virtual void IliTableGadget::f_useTableProperties ( IlBoolean  flag)
virtual

Enables/Disables the use of the table properties.

Parameters
flagIf IlTrue, the field will use table properties.

Reimplemented from IliFieldItf.

◆ FetchRowSymbol()

static IlvSymbol* IliTableGadget::FetchRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ getAutoFittingMode()

IliTableFittingMode IliTableGadget::getAutoFittingMode ( ) const

Returns the auto-fitting mode.

This mode determines how the table gadget recalculates its column widths when the table gadget itself is resized. The return value may be any of the following:

  • IliFitNone
  • IliFitProportional
  • IliFitLast

Initially, this property is set to IliFitNone.

Returns
The auto-fitting mode.

◆ getBatchCount()

IlInt IliTableGadget::getBatchCount ( ) const

Returns the current number of nested calls to startOfBatch().

Returns
The call count.

◆ getCellBackground()

IlvColor* IliTableGadget::getCellBackground ( ) const

Returns the background color used to draw cells.

Initially, this property is set to the background color of the table gadget palette.

Returns
The color.

◆ getCellFont()

IlvFont* IliTableGadget::getCellFont ( ) const

Returns the font used to draw cells.

Initially, this property is set to the font of the table gadget palette.

Returns
The font.

◆ getCellForeground()

IlvColor* IliTableGadget::getCellForeground ( ) const

Returns the foreground color used to draw cells.

Initially, this property is set to the foreground color of the table gadget palette.

Returns
The color.

◆ getCellPaletteStruct()

IliCellPaletteStruct* IliTableGadget::getCellPaletteStruct ( ) const

Returns the description of the cell for which text and fill palettes are currently required, as well as the default values for these palettes.

This member function may be called from the onGetCellPalette() virtual member function, or from the corresponding callback.

Returns
The cell palette description.

◆ GetCellPaletteSymbol()

static IlvSymbol* IliTableGadget::GetCellPaletteSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ getColumnDisplayWidth()

IlInt IliTableGadget::getColumnDisplayWidth ( IlInt  colno) const

Returns the column width, in pixels.

Parameters
colnoThe column position.
Returns
The width.

◆ getColumnEditor()

IliFieldItf* IliTableGadget::getColumnEditor ( IlInt  colno) const

Returns the field that is used as an editor for a column.

Parameters
colnoThe column position.
Returns
The field or 0 if the column does not have an editor.

◆ getColumnsCount()

IlInt IliTableGadget::getColumnsCount ( ) const

Returns the number of columns in the underlying table.

Returns
The column count.

◆ getCompareData()

IlAny IliTableGadget::getCompareData ( ) const

Returns the user data that can be used to compare two rows.

Returns
The user data.

◆ getCompareFunction()

IliCompareFunction IliTableGadget::getCompareFunction ( ) const

Returns the function that is used to compare two rows.

Returns
The function.

◆ getCurrentColumn()

IlInt IliTableGadget::getCurrentColumn ( ) const

Returns current column.

Returns
The current column or -1 if there is no current column.

◆ getCurrentRow()

IlInt IliTableGadget::getCurrentRow ( ) const

Returns current row.

Returns
The current row or -1 if there is no current row.

◆ getCustomEditor()

virtual IliFieldItf* IliTableGadget::getCustomEditor ( IlInt  rowno,
IlInt  colno,
IliFieldItf fld 
) const
virtual

Returns the field to use as an editor for a cell.

This virtual member function is called, with the fld parameter set to the column editor, each time a new cell is entered. The default implementation returns the fld parameter. However, it is possible to return any other editor in a subclass of IliTableGadget.

Parameters
rownoThe row position.
colnoThe column position.
fldThe default editor.
Returns
The field.

Reimplemented in IliInspectorGadget.

◆ getDeletedRow()

IlInt IliTableGadget::getDeletedRow ( ) const

Returns the deleted row position.

Returns
The position of the row that is currently being deleted if called from the onDeleteRow() member function, or returns the position of the row that is to be deleted if called from the onPrepareDeleteRow() member function (or from the corresponding callback).

◆ getDrawCellStruct()

IliDrawCellStruct* IliTableGadget::getDrawCellStruct ( ) const

Returns the description of the cell that is currently being drawn.

This member function may be called from the onDrawCell() virtual member function or from the corresponding callback.

Returns
The draw cell description.

◆ getErrorReporter()

IliErrorReporter* IliTableGadget::getErrorReporter ( ) const

Returns the error reporter that is used by the reportErrors() member functions.

When this property is 0 a default error reporter is used. Initially this property is 0.

Returns
The error reporter.

◆ getExtendedRowsCount()

IlInt IliTableGadget::getExtendedRowsCount ( ) const

Returns the number of rows in the underlying table (plus one if the insert row is currently shown).

Returns
The row count.

◆ getFetchedRow()

IlInt IliTableGadget::getFetchedRow ( ) const

Returns the fetched row position.

Returns
The position of the row that is currently being fetched. This member function may be called from the onFetchRow() member function or from the corresponding callback.

◆ getFirstColumn()

IlInt IliTableGadget::getFirstColumn ( ) const

Returns the position of the first column shown (from left to right).

Returns
The column position.

◆ getFirstRow()

IlInt IliTableGadget::getFirstRow ( ) const

Returns the position in the underlying table of the first row shown (from top to bottom).

Returns
The row position.

◆ getFixedColumnsCount()

IlInt IliTableGadget::getFixedColumnsCount ( ) const

Returns the number of columns that do not scroll. These are the left-most columns.

Initially, this property is set to 0.

Returns
The fixed column count.

◆ getHeaderHeight()

IlvDim IliTableGadget::getHeaderHeight ( ) const

Returns header height, in pixels, of the column headers.

Initially, the header height is set according to the font height used to draw them.

Returns
The height.

◆ getHeaderTextPalette()

virtual IlvPalette* IliTableGadget::getHeaderTextPalette ( IlInt  colno) const
virtual

Returns the header text palette.

Parameters
colnoThe column position.
Returns
The header text palette for a column. If the column position is invalid, this function returns 0.

◆ getMarkerWidth()

IlvDim IliTableGadget::getMarkerWidth ( ) const

Returns the marker width, in pixels, of the row markers.

Returns
The width.

◆ getRealIndex()

IlInt IliTableGadget::getRealIndex ( IlInt  colno) const

Returns the position, in the underlying table, of the column in the table gadget.

Parameters
colnoThe column position.
Returns
The real position. If the column geometry is not local, the return value equals colno.

◆ GetRefreshShortCut()

static void IliTableGadget::GetRefreshShortCut ( IlUShort modifiers,
IlUShort key 
)
static

Returns the definition of the shortcut key that refreshes all.

The definition of the shortcut key that will trigger a call to the IliTable::select() member function for all table gadgets. The default for this property is the unmodified F9 key.

Parameters
modifiersThe modifiers.
keyThe key.
Returns
The refresh key.

◆ getReliefPalette()

virtual IlvPalette* IliTableGadget::getReliefPalette ( ) const
virtual

Returns the relief palette.

The relief palette is used to draw the relief border, the markers and the headers.

Returns
The relief palette.

◆ getRowHeight()

IlvDim IliTableGadget::getRowHeight ( ) const

Returns the height, in pixels, of the rows in the table gadget.

Note that all rows have the same height. Initially the row height is set according to the font height used to draw cells.

Returns
The row height.

◆ getRowsCount()

IlInt IliTableGadget::getRowsCount ( ) const

Returns the number of rows in the underlying table.

Returns
The row count.

◆ getScrollBar()

IlvScrollBar* IliTableGadget::getScrollBar ( IlvPosition  which) const

Returns a scroll bar.

Parameters
whichThe scroll bar position.
Returns
The horizontal scroll bar, if which is set to IlvHorizontal and the vertical scroll bar if which is set to IlvVertical. This member function returns 0 if the designated scroll bar is not shown.

◆ getScrollBarShowMode()

IliShowMode IliTableGadget::getScrollBarShowMode ( IlvPosition  which) const

Returns the show mode for a scroll bar.

Parameters
whichThe scroll bar position.
Returns
The show mode.

◆ getSelection()

void IliTableGadget::getSelection ( IliTableSelection sel) const

Returns the current selection in the table gadget.

Parameters
selThe current selection.
Returns
The current selection.

◆ getTable() [1/2]

IliTable* IliTableGadget::getTable ( )

Returns the underlying table of the table gadget.

If the table gadget is connected to a data source, the underlying table can also be obtained by calling:

Returns
The table.

◆ getTable() [2/2]

const IliTable* IliTableGadget::getTable ( ) const

Returns the underlying table of the table gadget.

If the table gadget is connected to a data source, the underlying table can also be obtained by calling:

Returns
The table.

◆ getTablePropertyManager() [1/2]

IliTablePropertyManager* IliTableGadget::getTablePropertyManager ( )

Returns the table property manager used.

Returns
The table property manager.

◆ getTablePropertyManager() [2/2]

const IliTablePropertyManager* IliTableGadget::getTablePropertyManager ( ) const

Returns the table property manager used.

Returns
The table property manager.

◆ getTablePropertyManagerName()

const char* IliTableGadget::getTablePropertyManagerName ( ) const

Returns the table property manager name.

Note, the name of the default property manager is 0.

Returns
The name of the table property manager.

◆ getToolTipsText()

virtual void IliTableGadget::getToolTipsText ( const IlvPoint pt,
IliString s 
)
virtual

Returns the tooltip text that must be displayed.

By default, this function returns the title of the column header when the mouse is positioned over a header. Otherwise, this function returns an empty string of characters, which means "no display".

Parameters
ptThe mouse position.
sThe tooltip text.
Returns
The tooltip text.

◆ getValue() [1/2]

const IliValue& IliTableGadget::getValue ( IliName  colname) const

Returns the value at the column named colname in the row buffer of the table gadget.

Parameters
colnameThe column name.
Returns
The value.

◆ getValue() [2/2]

const IliValue& IliTableGadget::getValue ( IlInt  colno) const

Returns the value at column colno in the row buffer of the table gadget.

Parameters
colnoThe column position.
Returns
The value.

◆ getVisibleRowsCount()

IlInt IliTableGadget::getVisibleRowsCount ( IlBoolean lastRowClipped) const

Returns the maximum row count that are shown in the table gadget.

Parameters
lastRowClippedIf IlTrue, the last of these rows cannot be shown in its entirety. The actual number of rows in the underlying table is not taken into account.
Returns
The maximum number of rows.

◆ getVisualIndex()

IlInt IliTableGadget::getVisualIndex ( IlInt  colno) const

Returns the position, in the table gadget, of the column in the underlying table.

Parameters
colnoThe column position.
Returns
The position. If the column geometry is not local, the return value equals colno.

◆ gotoInsertRow()

IlBoolean IliTableGadget::gotoInsertRow ( )

Attempts to move the current row to the insert row.

Returns
IlTrue if successful.

◆ gotoNextColumn()

virtual IlBoolean IliTableGadget::gotoNextColumn ( )
virtual

Attempts to move the current column to the next shown column.

Returns
IlTrue if successful.

◆ gotoNextRow()

virtual IlBoolean IliTableGadget::gotoNextRow ( )
virtual

Attempts to move the current row to the next row.

Returns
IlTrue if successful.

◆ gotoPreviousColumn()

virtual IlBoolean IliTableGadget::gotoPreviousColumn ( )
virtual

Attempts to move the current column to the previous shown column.

Returns
IlTrue if successful.

◆ gotoPreviousRow()

virtual IlBoolean IliTableGadget::gotoPreviousRow ( )
virtual

Attempts to move the current row to the previous row.

Returns
IlTrue if successful.

◆ hasCustomCellPalettes()

IlBoolean IliTableGadget::hasCustomCellPalettes ( ) const

Returns IlTrue if the table gadget calls the onGetCellPalette() virtual member function for each cell being drawn.

Initially this property is set to IlFalse.

Returns
The custom cell palette using flag.

◆ isBoundToDataSource()

IlBoolean IliTableGadget::isBoundToDataSource ( ) const

Returns IlTrue if the table gadget is bound to its data source.

When the table gadget is bound to its data source, the current row of the table gadget is synchronized with the current row of the data source.

Returns
The bound data source flag.

◆ isCellEditorShown()

IlBoolean IliTableGadget::isCellEditorShown ( ) const

Returns IlTrue if the cell editor is shown in the selected cell when the cell is read-only.

The default for this property is IlTrue.

Returns
IlTrue if the cell editor is shown in the selected cell when the cell is read-only. This member function returns IlFalse if the cell editor is only shown when the selected cell is read-write.

◆ isColumnGeometryLocal()

IlBoolean IliTableGadget::isColumnGeometryLocal ( ) const

Returns IlTrue if the end-user is able to change the order of the columns.

Note that this member function does consider whether the underlying table has this capability. Initially, this property is set IlTrue.

Returns
The column geometry local flag.

◆ isColumnMoveAllowed()

IlBoolean IliTableGadget::isColumnMoveAllowed ( ) const

Returns IlTrue if the end-user is able to change the order of the columns.

Note that this member function does consider whether the underlying table has this capability. Initially, this property is set IlTrue.

Returns
The column moving permission.

◆ isColumnResizeAllowed()

IlBoolean IliTableGadget::isColumnResizeAllowed ( ) const

Returns IlTrue if the end-user is able to resize columns.

Initially, this property is set IlTrue.

Returns
The column resizing permission.

◆ isColumnVisible()

IlBoolean IliTableGadget::isColumnVisible ( IlInt  colno) const

Returns the column visibility.

Note that for the end-user to see the column it must be shown, its size must be greater than zero, and it must lie within the bounds of the table gadget.

Parameters
colnoThe column position.
Returns
The column visibility.

◆ isConfirmOnDeleteRequired()

IlBoolean IliTableGadget::isConfirmOnDeleteRequired ( ) const

Returns IlTrue if the user is prompted for a confirmation before row deletion.

Initially, this property is set to IlTrue.

Returns
The confirmation required flag.

◆ isImmediateRefreshDisabled()

IlBoolean IliTableGadget::isImmediateRefreshDisabled ( ) const

Returns IlTrue if the immediate refreshes are disabled.

Returns IlTrue if the immediate refreshes are disabled.

Returns
IlTrue if the immediate refreshes are disabled, the default value is IlFalse.

◆ isInInsertMode()

IlBoolean IliTableGadget::isInInsertMode ( ) const

Returns IlTrue if the current row is the insert row and if the current row buffer is modified.

Returns
The insert mode flag.

◆ isInsertRow()

IlBoolean IliTableGadget::isInsertRow ( IlInt  rowno) const

Returns IlTrue if a row designates the insert row.

Parameters
rownoThe row position.
Returns
The insert row flag.

◆ isInUpdateMode()

IlBoolean IliTableGadget::isInUpdateMode ( ) const

Returns IlTrue if the current row corresponds to an existing table row (that is, it is not the insert row), and if the current row buffer is modified.

Returns
The update mode flag.

◆ isKeyboardDeleteRowEnabled()

IlBoolean IliTableGadget::isKeyboardDeleteRowEnabled ( ) const

Returns IlTrue if the user can use the delete key to delete the current row.

Initially, this property is set to IlTrue.

Returns
The delete key using flag.

◆ isKeyboardRefreshEnabled()

IlBoolean IliTableGadget::isKeyboardRefreshEnabled ( ) const

Returns IlTrue if the user can use the refresh key.

When the user uses the refresh key, the IliTable::select() member function on the underlying table is called. By default the refresh key is the F9 function key. The refresh key can be changed with the SetRefreshShortCut() member function. Initially, this property is set to IlTrue.

Returns
The refresh key status.

◆ isMultiSelectionEnabled()

IlBoolean IliTableGadget::isMultiSelectionEnabled ( ) const

Returns IlTrue if the table gadget event handler allows the end-user to select more than one row or column.

Initially, this property is set to IlTrue.

Returns
The multi-selection permission.

◆ isOnInsertRow()

IlBoolean IliTableGadget::isOnInsertRow ( ) const

Returns IlTrue if the current row is the insert row.

Returns
The insert row flag.

◆ isReadOnly()

IlBoolean IliTableGadget::isReadOnly ( ) const

Returns IlTrue if the table gadget is read-only.

Initially, this property is set to IlFalse.

Returns
The read-only flag.

◆ isRowMoveAllowed()

IlBoolean IliTableGadget::isRowMoveAllowed ( ) const

Returns IlTrue if the end-user is able to change the order of the rows.

Note that this member function does not consider whether the underlying table has this capability or not. Initially, this property is set to IlTrue.

Returns
The row moving permission.

◆ isRowResizeAllowed()

IlBoolean IliTableGadget::isRowResizeAllowed ( ) const

Returns IlTrue if the end-user is able to resize rows.

Initially, this property is set to IlTrue.

Returns
The row resizing permission.

◆ isRowSelectEnabled()

IlBoolean IliTableGadget::isRowSelectEnabled ( ) const

Returns IlTrue if the row select mode is enabled.

When the row select mode is enabled, whenever the user attempts to select a cell, the row containing this cell is selected instead. The default for this property is IlFalse.

Returns
The row select mode status.

◆ isSelectionAlwaysShown()

IlBoolean IliTableGadget::isSelectionAlwaysShown ( ) const

Returns IlTrue if the selection of the table gadget is always highlighted.

Returns
The selection show status.

◆ isShowingGrid()

IlBoolean IliTableGadget::isShowingGrid ( ) const

Returns IlTrue if the table gadget is drawn with a grid.

Initially, this property is set to IlTrue.

Returns
The grid flag.

◆ isShowingHeaders()

IlBoolean IliTableGadget::isShowingHeaders ( ) const

Returns IlTrue if the column headers are shown.

Initially, headers are shown.

Returns
The show flag.

◆ isShowingInsertRow()

IlBoolean IliTableGadget::isShowingInsertRow ( ) const

Returns IlTrue if the insert row is shown.

Returns
The show flag.

◆ isShowingMarkers()

IlBoolean IliTableGadget::isShowingMarkers ( ) const

Returns IlTrue if the row markers are shown.

Returns
The show flag.

◆ isSortEnabled()

IlBoolean IliTableGadget::isSortEnabled ( ) const

Returns IlTrue if the table gadget event handler will sort the rows according to the column header on which the user clicks.

Initially, this property is set to IlFalse.

Returns
The sort flag.

◆ isTableOwner()

IlBoolean IliTableGadget::isTableOwner ( ) const

Returns IlTrue if the table gadget owns its table.

Returns
The owner flag.

◆ isUsingRelief()

IlBoolean IliTableGadget::isUsingRelief ( ) const

Returns IlTrue if the table gadget is drawn with a relief border.

Initially, this property is set to IlTrue.

Returns
The relief flag.

◆ isUsingTableProperties()

IlBoolean IliTableGadget::isUsingTableProperties ( ) const

Returns IlTrue if the table gadget is sensitive to table properties.

Note that contrary to other subclasses of IliFieldItf, the table gadget is not sensitive to the useTableProperties() and tablePropertyManagerName properties of its data source.

Returns
The sensitivity about the table properties.

◆ moveColumn()

IlBoolean IliTableGadget::moveColumn ( IlInt  from,
IlInt  to 
)

Attempts to move the column from a position to another position.

Parameters
fromThe origin position.
toThe destination position.
Returns
IlTrue if successful.

◆ onCancelEdits()

virtual void IliTableGadget::onCancelEdits ( )
virtual

Called just after the edits in the current row have been canceled.

The default implementation of this virtual member function calls the CancelEdits callback. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onDeleteRow()

virtual void IliTableGadget::onDeleteRow ( )
virtual

Called just before a row in the underlying table is deleted.

The index of the deleted row can be retrieved with the getDeletedRow() member function. The default implementation of this virtual member function calls the DeleteRow callback.

◆ onDoubleClick()

virtual void IliTableGadget::onDoubleClick ( )
virtual

Called just after a double-click on the table gadget.

The default implementation of this virtual member function calls the DoubleClick callback.

◆ onDrawCell()

virtual void IliTableGadget::onDrawCell ( )
virtual

Called to draw a cell in the table gadget.

The cell to be drawn is described, along with other useful information, in the object returned by the getDrawCellStruct() member function. The default implementation is as follows: a DrawCell callback is called, if it has been defined, otherwise the defaultDrawCell() member function is called. Do not override this virtual member function in subclasses of IliTableGadget. If necessary, the drawCell() virtual member function can be redefined in subclasses.

◆ onEnterCell()

virtual void IliTableGadget::onEnterCell ( )
virtual

Called just after a new cell is entered.

The default implementation of this virtual member function calls the EnterCell callback.

◆ onEnterInsertMode()

virtual void IliTableGadget::onEnterInsertMode ( )
virtual

Called just after the current row buffer becomes modified, when the current row is the insert row.

The default implementation of this virtual member function calls the EnterInsertMode callback. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onEnterRow()

virtual void IliTableGadget::onEnterRow ( )
virtual

Called just after a new row is entered.

The default implementation of this virtual member function calls the EnterCell callback.

◆ onEnterUpdateMode()

virtual void IliTableGadget::onEnterUpdateMode ( )
virtual

Called just after the current row buffer becomes modified (when the current row is not the insert row).

The default implementation of this virtual member function calls the EnterUpdateMode callback. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onFetchRow()

virtual void IliTableGadget::onFetchRow ( )
virtual

Called just after a new row has been retrieved from a remote database and cached in the underlying table.

The index of the fetched row can be retrieved with the getFetchedRow() member function. The default implementation of this virtual member function calls the FetchRow callback.

◆ onGetCellPalette()

virtual void IliTableGadget::onGetCellPalette ( )
virtual

Called when the text and fill palettes of a cell are required (either to draw the cell or to configure the cell editor).

The cell for which the palettes are required is described in the object returned by the getCellPaletteStruct() member function. This object also contains the default text and fill palettes. If the application requires the use of palettes other than the default, for a given cell, it must change the value for these palettes in the object returned by getCellPaletteStruct(). The default implementation calls the GetCellPalette callback. Note that this virtual member function will not be called by the table gadget unless a GetCellPalette callback has been set or the setCustomCellPalettes() member function has been called with an IlTrue argument.

◆ onPrepareDeleteRow()

virtual void IliTableGadget::onPrepareDeleteRow ( )
virtual

Called when the user attempts to delete a row through this table gadget.

The index of the row to be deleted can be obtained by calling the getDeletedRow() member function. This virtual member function can be overridden to do the following:

  • Check any application-defined constraints. If the constraints are not satisfied, the dontDeleteRow() should be called. In this case, the row will not be deleted.
  • In addition, the addErrorMessage() member function can be called to describe the reason for the failure.

The default implementation of this virtual member function calls the PrepareDeleteRow callback. Note that if the table gadget is bound to a data-source, this virtual member function is not called.

◆ onPrepareInsert()

virtual void IliTableGadget::onPrepareInsert ( )
virtual

Called when an attempt is made to validate the current row, when the current row is the insert row.

The default implementation of this virtual member function calls the PrepareInsert callback. When you override this virtual member function or if you define a PrepareInsert callback, you can call the dontValidateRow() member function to cancel the validation. In this case, you can also call the addErrorMessage () member function to provide the user with an error message.

Alternatively, you can change some of the values in the current row before it is inserted into the underlying table. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onPrepareUpdate()

virtual void IliTableGadget::onPrepareUpdate ( )
virtual

Called when an attempt is made to validate the current row (when the current row is not the insert row).

The default implementation of this virtual member function calls the PrepareUpdate callback. When you override this virtual member function or if you define a PrepareUpdate callback, you can call the dontValidateRow() member function to cancel the validation. In this case, you can also call the addErrorMessage() member function to provide the user with an error message.

Alternatively, you can change some of the values in the current row before the underlying table is updated. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onQuitCell()

virtual void IliTableGadget::onQuitCell ( )
virtual

Called just before the selection moves out of a cell.

The default implementation of this virtual member function calls the QuitCell callback.

◆ onQuitInsertMode()

virtual void IliTableGadget::onQuitInsertMode ( )
virtual

Called just after the current row has been successfully validated, when the current row is the insert row.

The default implementation of this virtual member function calls the QuitInsertMode callback. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onQuitRow()

virtual void IliTableGadget::onQuitRow ( )
virtual

Called just before the selection moves out of a row.

The default implementation of this virtual member function calls the QuitRow callback.

◆ onQuitUpdateMode()

virtual void IliTableGadget::onQuitUpdateMode ( )
virtual

Called just after the current (non insert) row has been successfully validated.

The default implementation of this virtual member function calls the QuitUpdateMode callback. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ onSelectionChange()

virtual void IliTableGadget::onSelectionChange ( )
virtual

Called just after the selection has changed (whatever the change).

The default implementation of this virtual member function calls the SelectionChange callback.

◆ onValidateCell()

virtual void IliTableGadget::onValidateCell ( )
virtual

Called when an attempt is made to move the selection out of a cell.

The default implementation of this virtual member function calls the ValidateCell callback. When you override this virtual member function, or if you define a ValidateCell callback, you can call the dontValidateCell() member function to inhibit the selection change. In this case, you can also call the addErrorMessage() member function to generate an error message for the user.

◆ onValidateRow()

virtual void IliTableGadget::onValidateRow ( )
virtual

Called when an attempt is made to validate the current row.

The default implementation of this virtual member function calls the ValidateRow callback. When you override this virtual member function, or if you define a ValidateRow callback, you can call the dontValidateRow() member function to cancel the validation. In this case, you can also call the addErrorMessage() member function to generate an error message for the user. Alternatively, you can change some of the values in the current row before the underlying table is updated. Note that if the table gadget is bound to its data source, this virtual member function is not called.

◆ pasteFromClipboard()

void IliTableGadget::pasteFromClipboard ( const IliTableSelection sel)

Pastes the contents of the clipboard into the selection.

Parameters
selThe selection.

◆ pointToSelection()

IlBoolean IliTableGadget::pointToSelection ( const IlvPoint pt,
IliTableSelection sel,
const IlvTransformer t = 0 
) const

Returns the selection pointed by a point.

Parameters
ptThe point.
selThe computed selection.
tThe transformer.
Returns
IlTrue if this selection is not empty.

◆ PrepareDeleteRowSymbol()

static IlvSymbol* IliTableGadget::PrepareDeleteRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ PrepareInsertSymbol()

static IlvSymbol* IliTableGadget::PrepareInsertSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ PrepareUpdateSymbol()

static IlvSymbol* IliTableGadget::PrepareUpdateSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ QuitCellSymbol()

static IlvSymbol* IliTableGadget::QuitCellSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ QuitInsertModeSymbol()

static IlvSymbol* IliTableGadget::QuitInsertModeSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ QuitRowSymbol()

static IlvSymbol* IliTableGadget::QuitRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ QuitUpdateModeSymbol()

static IlvSymbol* IliTableGadget::QuitUpdateModeSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ refreshCell()

void IliTableGadget::refreshCell ( IlInt  rowno,
IlInt  colno 
)

Redraws a cell.

Parameters
rownoThe row position.
colnoThe column position as it appears in the underlying table (see the getRealColno() member function).

◆ refreshColumn()

void IliTableGadget::refreshColumn ( IlInt  colno)

Redraws a column.

Parameters
colnoThe column position as it appears in the underlying table (see the getRealColno() member function).

◆ refreshRow()

void IliTableGadget::refreshRow ( IlInt  rowno)

Redraws a row.

Redraws the row at position rowno.

Parameters
rownoThe row position.

◆ removeErrorSink()

void IliTableGadget::removeErrorSink ( IliErrorSink sink)

Removes an error sink from this table gadget.

Parameters
sinkThe error sink.

◆ reportErrors()

void IliTableGadget::reportErrors ( const IliErrorList errorList) const

Reports the errors that are contained in a error list.

This member function makes use of the error reporter returned by getErrorReporter() if any. Otherwise it uses a default error reporter.

Parameters
errorListThe error list.

◆ requireConfirmOnDelete()

void IliTableGadget::requireConfirmOnDelete ( IlBoolean  flag)

Enables/disables confirmation before row deletion.

Parameters
flagIf IlTrue, the user is prompted for confirmation before deleting a row. Otherwise, any row deletion requests will proceed without confirmation.

◆ scrollTo()

virtual void IliTableGadget::scrollTo ( IlInt  rowno,
IlInt  colno 
)
virtual

Scrolls to a cell.

Parameters
rownoThe row position.
colnoThe column position.

◆ scrollToColumn()

void IliTableGadget::scrollToColumn ( IlInt  colno)

Scrolls to a column.

Parameters
colnoThe column position.

◆ scrollToRow()

void IliTableGadget::scrollToRow ( IlInt  rowno)

Scrolls to a row.

Parameters
rownoThe row position.

◆ selectAll()

IlBoolean IliTableGadget::selectAll ( )

Attempts to select all rows and columns.

Returns
IlTrue if successful.

◆ selectCell()

IlBoolean IliTableGadget::selectCell ( IlInt  rowno,
IlInt  colno 
)

Attempts to select the cell at a row and a column.

Parameters
rownoThe cell row.
colnoThe cell column.
Returns
IlTrue if successful.

◆ selectColumn()

IlBoolean IliTableGadget::selectColumn ( IlInt  colno)

Attempts to select a column.

Parameters
colnoThe column position.
Returns
IlTrue if successful.

◆ SelectionChangeSymbol()

static IlvSymbol* IliTableGadget::SelectionChangeSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ selectNone()

IlBoolean IliTableGadget::selectNone ( )

Attempts to deselect the current selection.

Returns
IlTrue if successful.

◆ selectRow()

IlBoolean IliTableGadget::selectRow ( IlInt  rowno)

Attempts to select a row.

Parameters
rownoThe row position.
Returns
-1 if successful.

◆ setAutoFittingMode()

void IliTableGadget::setAutoFittingMode ( IliTableFittingMode  mode)

Sets the auto-fitting mode.

Parameters
modeThe auto-fitting mode.

◆ setCellBackground()

virtual void IliTableGadget::setCellBackground ( IlvColor color)
virtual

Sets the background color used to draw cells.

Parameters
colorThe new color.

◆ setCellFont()

virtual void IliTableGadget::setCellFont ( IlvFont font)
virtual

Sets the font used to draw cells.

Parameters
fontThe new font.

◆ setCellForeground()

virtual void IliTableGadget::setCellForeground ( IlvColor color)
virtual

Sets the foreground color used to draw cells.

Parameters
colorThe new color.

◆ setColumnDisplayWidth()

void IliTableGadget::setColumnDisplayWidth ( IlInt  colno,
IlInt  width 
)

Sets column width, in pixels.

Parameters
colnoThe column position.
widthThe column width.

◆ setColumnEditor()

IlBoolean IliTableGadget::setColumnEditor ( IlInt  colno,
IliFieldItf fld,
IlBoolean  owner = IlTrue 
)

Sets the field that is used as an editor for column.

Parameters
colnoThe column position.
fldThe editor.
ownerIf IlTrue, the table gadget becomes the owner of the field.

◆ setColumnGeometryLocal()

void IliTableGadget::setColumnGeometryLocal ( IlBoolean  flag)

Enables/disables the column moving.

Parameters
flagIf IlTrue, enables the column moving.

◆ setColumnVisible()

void IliTableGadget::setColumnVisible ( IlInt  colno,
IlBoolean  flag 
)

Sets column visibility.

Parameters
colnoThe column position.
flagIf IlTrue, shows the column and hides it otherwise.

◆ setCompareFunction()

void IliTableGadget::setCompareFunction ( IliCompareFunction  fct,
IlAny  arg = 0 
)

Defines the function fct and user data that must be used to compare two rows.

Parameters
fctThe function to compare.
argThe user data.

◆ setCustomCellPalettes()

void IliTableGadget::setCustomCellPalettes ( IlBoolean  flag)

Enables/disables the use of specific palettes for a cell.

This member function must be called with a value of IlTrue for the flag parameter by any subclass of the table gadget that overrides the onGetCellPalette() virtual member function.

Parameters
flagThe use of specific palette flag

◆ setErrorReporter()

void IliTableGadget::setErrorReporter ( IliErrorReporter reporter)

Sets the error reporter.

Note that the table gadget will not delete the error reporter at destruction time, so the same error reporter may be safely shared by many table gadgets.

Parameters
reporterThe new error reporter.

◆ setFixedColumnsCount()

IlBoolean IliTableGadget::setFixedColumnsCount ( IlInt  count)

Sets the number of columns that do not scroll.

Parameters
countThe column count.
Returns
IlTrue if successful, and IlFalse if count is greater that the current number of columns.

◆ setHeaderHeight()

void IliTableGadget::setHeaderHeight ( IlvDim  h)

Sets header height.

Parameters
hThe header height.

◆ setMarkerWidth()

void IliTableGadget::setMarkerWidth ( IlvDim  w)

Sets the marker width.

Parameters
wThe marker width.

◆ setReadOnly()

IlBoolean IliTableGadget::setReadOnly ( IlBoolean  flag)

Sets the table gadget as read-only or not.

Parameters
flagIf IlTrue, sets the table gadget as read-only. The table gadget is set to read-write otherwise.

◆ SetRefreshShortCut()

static void IliTableGadget::SetRefreshShortCut ( IlUShort  modifiers,
IlUShort  key 
)
static

Sets the definition of the shortcut key that refreshes all.

Parameters
modifiersThe modifiers.
keyThe key, if key has a value 0 then no shortcut key is defined.

◆ setReliefPalette()

void IliTableGadget::setReliefPalette ( IlvPalette pal)

Sets the relief palette.

The relief palette is used to draw the relief border, the markers and the headers.

Parameters
palThe relief palette.

◆ setRowHeight()

void IliTableGadget::setRowHeight ( IlvDim  h)

Sets the height of the rows in a table gadget.

Parameters
hThe row height.

◆ setSelection()

virtual IlBoolean IliTableGadget::setSelection ( const IliTableSelection sel)
virtual

Attempts to set the table gadget selection.

Parameters
selThe new selection.
Returns
IlTrue if successful.

Reimplemented in IliInspectorGadget.

◆ setTable()

virtual void IliTableGadget::setTable ( IliTable table,
IlBoolean  owner = IlTrue 
)
virtual

Connects the table gadget to a table.

You do not need to use this method if you connect the table gadget to a data source using the IliFieldItf::f_setDataSource() or IliFieldItf::f_setDataSourceName() member functions.

Parameters
tableThe table.
ownerThe table owner, if IlTrue, the table gadget becomes the owner.

◆ setTablePropertyManager()

void IliTableGadget::setTablePropertyManager ( IliTablePropertyManager pMgr)

Sets the table property manager.

Parameters
pMgrThe table property manager.

◆ setTablePropertyManagerName()

void IliTableGadget::setTablePropertyManagerName ( const char *  name)

Sets the table property manager name.

Parameters
nameThe table property manager name. If the name is 0 or an empty string, the default table property manager is used.

◆ setValue() [1/2]

IlBoolean IliTableGadget::setValue ( IliName  colname,
const IliValue value 
)

Sets the value at the column named colname, in the row buffer of the table gadget, to value.

Parameters
colnameThe column name.
valueThe value.

◆ setValue() [2/2]

IlBoolean IliTableGadget::setValue ( IlInt  colno,
const IliValue value 
)

Sets the value at column colno, in the row buffer of the table gadget, to value.

Parameters
colnoThe column position.
valueThe value.

◆ setVisibleRowsCount()

void IliTableGadget::setVisibleRowsCount ( IlInt  count)

Changes the height of the table gadget so that the maximum number of rows can be shown.

Parameters
countThe maximum number of rows that can be shown.

◆ showCellEditor()

void IliTableGadget::showCellEditor ( IlBoolean  flag)

Specifies that the cell editor is shown in read-only cells.

Parameters
flagIf IlTrue, specifies that the cell editor is shown in read-only cells. Otherwise, the cell editor is only shown in read-write cells.

◆ showGrid()

void IliTableGadget::showGrid ( IlBoolean  flag)

Shows/Hides grid.

Parameters
flagIf IlTrue, draws the table gadget with a grid. Otherwise, a grid is not drawn.

◆ showHeaders()

void IliTableGadget::showHeaders ( IlBoolean  flag)

Shows/Hides the column headers.

Parameters
flagIf IlTrue, shows the column headers. Otherwise hides the column headers.

◆ showInsertRow()

IlBoolean IliTableGadget::showInsertRow ( IlBoolean  flag)

Shows/Hides insert row.

Parameters
flagIf IlTrue, shows the insert row. Otherwise hides the insert row.

◆ showMarkers()

void IliTableGadget::showMarkers ( IlBoolean  flag)

Shows/Hides row markers.

Parameters
flagIf IlTrue, shows the row markers. Otherwise hides the row markers.

◆ showScrollBar()

void IliTableGadget::showScrollBar ( IlvPosition  which,
IliShowMode  mode 
)

Sets the show mode for a scroll bar.

Changes the show mode of the scroll bar, designated by the which parameter, to mode. The parameter mode may take any of the following values:

  • IliShowNever
  • IliShowAsNeeded
  • IliShowAlways
Parameters
whichThe scroll bar position.
modeThe show mode.

◆ showSelectionAlways()

void IliTableGadget::showSelectionAlways ( IlBoolean  flag)

Shows/hides the selection.

Parameters
flagIf IlTrue, the selection of the table gadget will always be highlighted. Otherwise, it will be only be highlighted when the table gadget has the focus.

◆ sortColumn()

void IliTableGadget::sortColumn ( IlInt  colno)

Sorts the rows according to ascending or descending order of column.

The global functions IliAscOrder and IliDescOrder are used to indicate the type of sort. Example:

//Sorts column 2 in ascending order
tg->sortColumn(IliAscOrder(2));
//Sorts column 3 in descending order
tg->sortColumn(IliDescOrder(3));
Parameters
colnoThe column position.

◆ useRelief()

void IliTableGadget::useRelief ( IlBoolean  flag)

Shows/Hides relief border.

Parameters
flagIf IlTrue, draws the table gadget with a relief border. Otherwise, it will be drawn without a relief border.

◆ useTableProperties()

void IliTableGadget::useTableProperties ( IlBoolean  flag)

Sets the table gadget sensitivity about table properties.

Parameters
flagIf IlTrue, the table gadget becomes sensitive to table properties. It becomes insensitive if flag is IlFalse.

◆ validate()

virtual IlBoolean IliTableGadget::validate ( IlBoolean  interactive = IlFalse)
virtual

Validates the current row.

Validation proceeds in the following manner:

  • If the row buffer of the table gadget is unmodified, validation succeeds immediately.
  • Otherwise, some system defined constraints are checked on the current row buffer. If these constraints are not satisfied, validation fails.
  • The onValidateRow() virtual method is then called, which checks any application defined constraints. If these are not satisfied, it calls the dontValidateRow() member function, and validation fails.
  • One of the onPrepareInsert() or onPrepareUpdate() virtual member functions is then called (depending on whether the current row is an inserted row).
  • A new row is then inserted into the underlying table, or an existing row is updated in the underlying table (depending on whether the current row is an inserted row). If successful, one of the onQuitInsertMode() or onQuitUpdateMode() is called and IlTrue is returned.

If successful, the row buffer of the table gadget becomes unmodified.

If the interactive parameter is IlTrue, any errors that may occur are automatically reported to the user by calling the reportErrors() member function. If the interactive parameter is IlFalse, errors are not reported.

Note that if the table gadget is bound to a data source, the onValidateRow(), onPrepareInsert(), onPrepareUpdate(), onQuitInsertMode(), and onQuitUpdateMode() virtual member functions are called on the data source, instead of on the table gadget.

Parameters
interactiveThe interactive flag.
Returns
IlTrue if successful.

◆ ValidateCellSymbol()

static IlvSymbol* IliTableGadget::ValidateCellSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.

◆ ValidateRowSymbol()

static IlvSymbol* IliTableGadget::ValidateRowSymbol ( )
static

Returns the name of the callback that will be called by the corresponding virtual member function.

Returns
The callback name.
IliDataSource::getTable
const IliTable * getTable() const
Returns the table of the data source.
IliDescOrder
IlInt IliDescOrder(IlInt colno)
Table columns can be sorted by ascending or descending order. The IliDescOrder() function takes a col...
IliFieldItf::f_getDataSource
const IliDataSource * f_getDataSource() const
Returns the data source.
IliErrorList
Error Class.
Definition: error.h:407
IliAscOrder
IlInt IliAscOrder(IlInt colno)
Table columns can be sorted by ascending or descending order. The IliAscOrder() function takes a colu...