|
Multi diag tools
|
Proxy model to provide some formatting. More...
#include <FormatProxyModel.h>
Inherits QIdentityProxyModel.
Public Member Functions | |
| FormatProxyModel (QObject *parent=nullptr) | |
| Constructor. | |
| void | setPriority (const std::array< FormatMapPriority, 3 > &priority) |
| Set priority when format conflics. More... | |
| void | setTextAlignmentForIndex (int row, int column, Qt::Alignment alignment) |
| Set text alignment for row and column. More... | |
| void | clearTextAlignmentForIndex (int row, int column) |
| Clear text alignment for row and column. More... | |
| void | setTextAlignmentForRow (int row, Qt::Alignment alignment) |
| Set text alignment for row. More... | |
| void | clearTextAlignmentForRow (int row) |
| Clear text alignment for row. More... | |
| void | setTextAlignmentForColumn (int column, Qt::Alignment alignment) |
| Set text alignment for column. More... | |
| void | clearTextAlignmentForColumn (int column) |
| Clear text alignment for column. More... | |
| QVariant | textAlignment (int row, int column) const |
| Get text alignment for given row and column. More... | |
| void | setTextFontForIndex (int row, int column, const QFont &font) |
| Set text font for row and column. More... | |
| void | clearTextFontForIndex (int row, int column) |
| Clear text font for row and column. More... | |
| void | setTextFontForRow (int row, const QFont &font) |
| Set text font for row. More... | |
| void | clearTextFontForRow (int row) |
| Clear text font for row. More... | |
| void | setTextFontForColumn (int column, const QFont &font) |
| Set text font for column. More... | |
| void | clearTextFontForColumn (int column) |
| Clear text font for column. More... | |
| QVariant | textFont (int row, int column) const |
| Get text font for given row and column. More... | |
| void | setTextColorForIndex (int row, int column, const QColor &color) |
| Set text color for row and column. More... | |
| void | clearTextColorForIndex (int row, int column) |
| Clear text color for row and column. More... | |
| void | setTextColorForRow (int row, const QColor &color) |
| Set text color for row. More... | |
| void | clearTextColorForRow (int row) |
| Clear text color for row. More... | |
| void | setTextColorForColumn (int column, const QColor &color) |
| Set text color for column. More... | |
| void | clearTextColorForColumn (int column) |
| Clear text color for column. More... | |
| QVariant | foregroundBrush (int row, int column) const |
| Get foreground brush for given row and column. More... | |
| void | setBackgroundBrushForIndex (int row, int column, const QBrush &brush) |
| Set background brush for row and column. More... | |
| void | setBackgroundColorForIndex (int row, int column, const QColor &color, Qt::BrushStyle style=Qt::SolidPattern) |
| Set background color for row and column. More... | |
| void | clearBackgroundBrushForIndex (int row, int column) |
| Clear background brush for row and column. More... | |
| void | setBackgroundBrushForRow (int row, const QBrush &brush) |
| Set background brush for row. More... | |
| void | setBackgroundColorForRow (int row, const QColor &color, Qt::BrushStyle style=Qt::SolidPattern) |
| Set background color for row. More... | |
| void | clearBackgroundBrushForRow (int row) |
| Clear background brush for row. More... | |
| void | setBackgroundBrushForColumn (int column, const QBrush &brush) |
| Set background brush for column. More... | |
| void | setBackgroundColorForColumn (int column, const QColor &color, Qt::BrushStyle style=Qt::SolidPattern) |
| Set background color for column. More... | |
| void | clearBackgroundBrushForColumn (int column) |
| Clear background brush for column. More... | |
| QVariant | backgroundBrush (int row, int column) const |
| Get background brush for given row and column. More... | |
| QVariant | data (const QModelIndex &index, int role=Qt::DisplayRole) const |
| Get data for given index and role. | |
Proxy model to provide some formatting.
Definition at line 37 of file FormatProxyModel.h.
| QVariant Mdt::ItemModel::FormatProxyModel::backgroundBrush | ( | int | row, |
| int | column | ||
| ) | const |
Get background brush for given row and column.
Returns a QVariant with value of type QBrush if a background brush was set for row and column, otherwise a null QVariant.
Definition at line 291 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearBackgroundBrushForColumn | ( | int | column | ) |
Clear background brush for column.
Definition at line 283 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearBackgroundBrushForIndex | ( | int | row, |
| int | column | ||
| ) |
Clear background brush for row and column.
Definition at line 236 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearBackgroundBrushForRow | ( | int | row | ) |
Clear background brush for row.
Definition at line 260 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextAlignmentForColumn | ( | int | column | ) |
Clear text alignment for column.
Definition at line 80 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextAlignmentForIndex | ( | int | row, |
| int | column | ||
| ) |
Clear text alignment for row and column.
Definition at line 47 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextAlignmentForRow | ( | int | row | ) |
Clear text alignment for row.
Definition at line 64 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextColorForColumn | ( | int | column | ) |
Clear text color for column.
Definition at line 201 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextColorForIndex | ( | int | row, |
| int | column | ||
| ) |
Clear text color for row and column.
Definition at line 168 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextColorForRow | ( | int | row | ) |
Clear text color for row.
Definition at line 185 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextFontForColumn | ( | int | column | ) |
Clear text font for column.
Definition at line 141 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextFontForIndex | ( | int | row, |
| int | column | ||
| ) |
Clear text font for row and column.
Definition at line 108 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::clearTextFontForRow | ( | int | row | ) |
Clear text font for row.
Definition at line 125 of file FormatProxyModel.cpp.
| QVariant Mdt::ItemModel::FormatProxyModel::foregroundBrush | ( | int | row, |
| int | column | ||
| ) | const |
Get foreground brush for given row and column.
Returns a QVariant with value of type QBrush if a text color was set for row and column, otherwise a null QVariant.
Definition at line 209 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundBrushForColumn | ( | int | column, |
| const QBrush & | brush | ||
| ) |
Set background brush for column.
Definition at line 268 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundBrushForIndex | ( | int | row, |
| int | column, | ||
| const QBrush & | brush | ||
| ) |
Set background brush for row and column.
Definition at line 219 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundBrushForRow | ( | int | row, |
| const QBrush & | brush | ||
| ) |
Set background brush for row.
Definition at line 245 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundColorForColumn | ( | int | column, |
| const QColor & | color, | ||
| Qt::BrushStyle | style = Qt::SolidPattern |
||
| ) |
Set background color for column.
Definition at line 276 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundColorForIndex | ( | int | row, |
| int | column, | ||
| const QColor & | color, | ||
| Qt::BrushStyle | style = Qt::SolidPattern |
||
| ) |
Set background color for row and column.
Definition at line 228 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setBackgroundColorForRow | ( | int | row, |
| const QColor & | color, | ||
| Qt::BrushStyle | style = Qt::SolidPattern |
||
| ) |
Set background color for row.
Definition at line 253 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setPriority | ( | const std::array< FormatMapPriority, 3 > & | priority | ) |
Set priority when format conflics.
Define which format should be choosen when many where set for a specific index.
For example:
Default is index, then row, then column.
Definition at line 31 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextAlignmentForColumn | ( | int | column, |
| Qt::Alignment | alignment | ||
| ) |
Set text alignment for column.
Definition at line 72 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextAlignmentForIndex | ( | int | row, |
| int | column, | ||
| Qt::Alignment | alignment | ||
| ) |
Set text alignment for row and column.
Definition at line 38 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextAlignmentForRow | ( | int | row, |
| Qt::Alignment | alignment | ||
| ) |
Set text alignment for row.
Definition at line 56 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextColorForColumn | ( | int | column, |
| const QColor & | color | ||
| ) |
Set text color for column.
Definition at line 193 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextColorForIndex | ( | int | row, |
| int | column, | ||
| const QColor & | color | ||
| ) |
Set text color for row and column.
Definition at line 159 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextColorForRow | ( | int | row, |
| const QColor & | color | ||
| ) |
Set text color for row.
Definition at line 177 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextFontForColumn | ( | int | column, |
| const QFont & | font | ||
| ) |
Set text font for column.
Definition at line 133 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextFontForIndex | ( | int | row, |
| int | column, | ||
| const QFont & | font | ||
| ) |
Set text font for row and column.
Definition at line 99 of file FormatProxyModel.cpp.
| void Mdt::ItemModel::FormatProxyModel::setTextFontForRow | ( | int | row, |
| const QFont & | font | ||
| ) |
Set text font for row.
Definition at line 117 of file FormatProxyModel.cpp.
| QVariant Mdt::ItemModel::FormatProxyModel::textAlignment | ( | int | row, |
| int | column | ||
| ) | const |
Get text alignment for given row and column.
Returns a QVariant with value of type Qt::Alignment if a alignment was set for row and column, otherwise a null QVariant.
Definition at line 89 of file FormatProxyModel.cpp.
| QVariant Mdt::ItemModel::FormatProxyModel::textFont | ( | int | row, |
| int | column | ||
| ) | const |
Get text font for given row and column.
Returns a QVariant with value of type QFont if a font was set for row and column, otherwise a null QVariant.
Definition at line 149 of file FormatProxyModel.cpp.
1.8.11