This class adds some convenience to QTableView:
More...
#include <bpstableview.h>
List of all members.
Detailed Description
This class adds some convenience to QTableView:
- Alternating row colors
- Resize all columns to content with Ctrl + Plus
- Variable size hint
- Get ordered list of selected row numbers
- Signals for context menu and data changes
Constructor & Destructor Documentation
| BpsTableView::BpsTableView |
( |
QWidget * |
aParent = 0 | ) |
|
Constructor for BpsTableView.
- Parameters:
-
| [in] | aParent | The parent widget. |
Member Function Documentation
| void BpsTableView::contextMenuRequested |
( |
const QPoint & |
aPosition, |
|
|
const QModelIndex & |
aIndex |
|
) |
| [signal] |
This signal is emitted when a context menu is requested on a table cell.
- Parameters:
-
| [in] | aPosition | The context menu position. |
| [in] | aIndex | The model index of the cell, or an invalid index when not on a cell. |
| void BpsTableView::dataGotChanged |
( |
const QModelIndex & |
aTopLeft, |
|
|
const QModelIndex & |
aBottomRight |
|
) |
| [signal] |
This signal is emitted when item data are changed in the model.
The changed items are those from aTopLeft to aBottomRight inclusive. If just one item is changed aTopLeft == aBottomRight.
- Parameters:
-
| [in] | aTopLeft | The top left index. |
| [in] | aBottomRight | The bottom right index. |
| void BpsTableView::focusInOutEvent |
( |
bool |
aFocusIn | ) |
[signal] |
This signal is emitted when the widget gets or loses the focus.
- Parameters:
-
| [in] | aFocusIn | True when getting focus, false when losing focus. |
| void BpsTableView::restoreHorizontalHeaderState |
( |
const QVariant & |
aData | ) |
|
Restores the horizontal header state from settings.
- Parameters:
-
| [in] | aData | The data from the settings to restore |
| QVariant BpsTableView::saveHorizontalHeaderState |
( |
| ) |
|
- Returns:
- The current horizontal header state to save in the settings.
| QList<int> BpsTableView::selectedRowNumbers |
( |
| ) |
const |
- Returns:
- A list of the selected row numbers, sorted ascending.
| void BpsTableView::setSizeHint |
( |
const QSize & |
aSize | ) |
|
Define the size hint.
- Parameters:
-
| [in] | aSize | The size to use as size hint. |
| virtual QSize BpsTableView::sizeHint |
( |
| ) |
const [virtual] |
- Returns:
- A QSize as size hint.
The documentation for this class was generated from the following file: