The GridWidget object represents the user interface control that shows a GridData object inside a Property Page.
It exposes information that is transitive and directly related to the state of the control itself rather than the underlying GridData. For example, this object exposes information about which cells the user has clicked on.
Unlike the actual GridData content, the selection state is lost when the Property Page is closed and then reopened.
#include <xsi_gridwidget.h>
Public Member Functions | |
GridWidget () | |
~GridWidget () | |
GridWidget (const CRef &in_ref) | |
GridWidget (const GridWidget &in_obj) | |
bool | IsA (siClassID in_ClassID) const |
siClassID | GetClassID () const |
GridWidget & | operator= (const GridWidget &in_obj) |
GridWidget & | operator= (const CRef &in_ref) |
bool | IsCellSelected (LONG in_Column, LONG in_Row) const |
bool | IsRowSelected (LONG in_Row) const |
bool | IsColumnSelected (LONG in_Column) const |
CStatus | AddToSelection (LONG in_Column, LONG in_Row) |
CStatus | ClearSelection () |
CStatus | SortColumn (LONG in_Column, bool in_bAscending) |
CStatus | GetSelection (CLongArray &out_rArraySelection) const |
GridWidget | ( | ) |
Default constructor.
~GridWidget | ( | ) |
Default destructor.
GridWidget | ( | const CRef & | in_ref | ) |
Constructor.
in_ref | constant reference object. |
GridWidget | ( | const GridWidget & | in_obj | ) |
Copy constructor.
in_obj | constant class object. |
bool IsA | ( | siClassID | in_ClassID | ) | const [virtual] |
Returns true if a given class type is compatible with this API class.
in_ClassID | class type. |
Reimplemented from CBase.
siClassID GetClassID | ( | ) | const [virtual] |
GridWidget& operator= | ( | const GridWidget & | in_obj | ) |
Creates an object from another object.
in_obj | constant class object. |
GridWidget& operator= | ( | const CRef & | in_ref | ) |
Creates an object from a reference object. The newly created object is set to empty if the input reference object is not compatible.
in_ref | constant class object. |
bool IsCellSelected | ( | LONG | in_Column, |
LONG | in_Row | ||
) | const |
Tests whether a cell has been selected. If the Grid is in header selection mode then use GridWidget::IsRowSelected or GridWidget::IsColumnSelected instead. (For further information about configuring the selection mode see ::siUIGridSelectionMode in the ::siPPGItemAttribute enum documentation).
in_Column | Index of the column where the cell is located. |
in_Row | Index of the row where the cell is located. |
bool IsRowSelected | ( | LONG | in_Row | ) | const |
Tests whether an entire row has been selected
in_Row | Index of the row to test. |
bool IsColumnSelected | ( | LONG | in_Column | ) | const |
Tests whether an entire column has been selected
in_Column | Index of the column to test. |
CStatus AddToSelection | ( | LONG | in_Column, |
LONG | in_Row | ||
) |
Adds a cell to the selection. In header selection mode, specify -1 as the row to select an entire column, or specify -1 as the column to select an entire row.
in_Column | Index of the column where the cell is located. |
in_Row | Index of the row where the cell is located. |
CStatus ClearSelection | ( | ) |
Ensures that no cells are selected on the GridWidget.
CStatus SortColumn | ( | LONG | in_Column, |
bool | in_bAscending | ||
) |
Sorts the specified column in the direction indicated.
in_Column | Index of the column to sort. |
in_bAscending | True to sort in ascending order; false for descending. |
CStatus GetSelection | ( | CLongArray & | out_rArraySelection | ) | const |
Get the current selection.
out_rArraySelection | Column/row pairs representing the current selection. |