GridViewOptions Class

GridViewOptions class intended for configuring the behavior and appearance of different parts of the grid's view. More...

Header: #include <GridViewOptions>
Inherits: GridViewOptionsAbstract

Public Types

enum GroupSummaryPlace { SummaryHidden, SummaryRow, SummaryRowPlus, SummaryRowFooter }
enum PreviewRowExpandStyle { PreviewKeepExpanded, PreviewExpandTextButton, PreviewExpandButton }
enum RowStyle { GroupStandard, GroupOfficeOutlook }
enum SelectionPolicy { IgnoreSelection, RowSelection, CellSelection, MultiRowSelection, MultiCellSelection }

Public Functions

GridViewOptions(GridViewBase *view)
bool allowFilterEditor() const
bool alternatingRowColors() const
bool autoCreateColumns() const
QColor backgroundColor() const
const QColor &borderColor() const
bool borderStyled() const
int borderWidth() const
const QFont &cellFont() const
int cellHeight() const
const QPalette &cellPalette() const
int cellWidth() const
bool columnAutoScroll() const
const QFont &columnFont() const
bool columnHeaderHints() const
int columnHeight() const
const QPen &columnPen() const
bool dragEnabled() const
bool dropEnabled() const
bool fastScrollEffect() const
bool filterAutoHide() const
int filterPanelHeight() const
const QStringList &findColumnList() const
const QString &findPanelPlaceholderText() const
bool focusFrameEnabled() const
QBrush gridLineBrush() const
QColor gridLineColor() const
QPen gridLinePen() const
int gridLineWidth() const
Qtitan::LinesStyle gridLines() const
QPalette groupPalette(int depth) const
QFont groupRowFont(int depth = -1) const
int groupRowHeight() const
GridViewOptions::GroupSummaryPlace groupSummaryPlace() const
bool groupsHeader() const
QBrush groupsHeaderBrush() const
const QColor &groupsHeaderColor() const
const QString &groupsHeaderText() const
QColor groupsHeaderTextColor() const
QFont groupsHeaderTextFont() const
bool isColumnHidingEnabled() const
bool isColumnHidingOnGroupingEnabled() const
bool isColumnMovingEnabled() const
bool isFieldChooserEnabled() const
bool isFilterEnabled() const
bool isFindEnabled() const
bool isFocusFollowsMouse() const
bool isFooterSummaryVisible() const
bool isGestureEnabled() const
bool isGroupSortEnabled() const
bool isGroupingEnabled() const
bool isMainMenuDisabled() const
bool isPreviewRowEnabled() const
bool isSortEnabled() const
bool isSummaryMenuDisabled() const
bool isTransparentBackground() const
bool isZoomIndicatorActive() const
bool keepFocusedRow() const
int keepGroupLevelExpanded() const
bool modelDecoration() const
bool modelItemsDragEnabled() const
int newRowFlashInterval() const
Qtitan::HighlightEffect newRowHighlightEffect() const
double newRowOpacity() const
Qtitan::ItemPosition newRowPlace() const
const QString &newRowText() const
GridViewOptions::PreviewRowExpandStyle previewRowExpandStyle() const
bool rowAutoHeight() const
bool rowRemoveEnabled() const
GridViewOptions::RowStyle rowStyle() const
bool rowsAutoScroll() const
bool rubberBandSelection() const
Qtitan::ScrollBarsMode scrollBars() const
Qtitan::ScrollItemStyle scrollRowStyle() const
double selectedDecorationOpacity() const
GridViewOptions::SelectionPolicy selectionPolicy() const
void setAllowFilterEditor(bool allow)
void setAlternatingRowColors(bool alternating)
void setAutoCreateColumns(bool autoCreate)
void setBackgroundColor(const QColor &color)
void setBorderColor(const QColor &color)
void setBorderStyled(bool styled)
void setBorderWidth(int width)
void setCellFont(const QFont &font)
void setCellHeight(int height)
void setCellPalette(const QPalette &palette)
void setCellWidth(int width)
void setColumnAutoScroll(bool autoScroll)
void setColumnFont(const QFont &font)
void setColumnHeaderHints(bool headerHints)
void setColumnHeight(int height)
void setColumnHidingEnabled(bool enabled)
void setColumnHidingOnGroupingEnabled(bool enabled)
void setColumnMovingEnabled(bool enabled)
void setColumnPen(const QPen &pen)
void setDragEnabled(bool enabled)
void setDropEnabled(bool enabled)
void setFastScrollEffect(bool enabled)
void setFieldChooserEnabled(bool enabled)
void setFilterAutoHide(bool autoHide)
void setFilterEnabled(bool enabled)
void setFilterPanelHeight(int height)
void setFindColumnList(const QStringList &list)
void setFindEnabled(bool enabled)
void setFindPanelPlaceholderText(const QString &text)
void setFocusFollowsMouse(bool enabled)
void setFocusFrameEnabled(bool enabled)
void setFooterSummaryVisible(bool visible)
void setGestureEnabled(bool enabled)
void setGridLineBrush(const QBrush &brush)
void setGridLineColor(const QColor &color)
void setGridLinePen(const QPen &pen)
void setGridLineWidth(int width)
void setGridLines(Qtitan::LinesStyle lines)
void setGroupKeepLevelExpanded(int level)
void setGroupPalette(int depth, const QPalette &palette)
void setGroupRowFont(const QFont &font, int depth = -1)
void setGroupRowHeight(int height)
void setGroupSortEnabled(bool enabled)
void setGroupSummaryPlace(GridViewOptions::GroupSummaryPlace place)
void setGroupingEnabled(bool enabled)
void setGroupsHeader(bool groupsHeader)
void setGroupsHeaderBrush(const QBrush &brush)
void setGroupsHeaderColor(const QColor &color)
void setGroupsHeaderText(const QString &text)
void setGroupsHeaderTextColor(const QColor &color)
void setGroupsHeaderTextFont(const QFont &font)
void setKeepFocusedRow(bool keep)
void setMainMenuDisabled(bool disabled)
void setModelDecoration(bool enabled)
void setModelItemsDragEnabled(bool enabled)
void setNewRowFlashInterval(int interval)
void setNewRowHighlightEffect(Qtitan::HighlightEffect effect)
void setNewRowOpacity(double opacity)
void setNewRowPlace(Qtitan::ItemPosition place)
void setNewRowText(const QString &text)
void setPreviewRowEnabled(bool enabled)
void setPreviewRowExpandStyle(GridViewOptions::PreviewRowExpandStyle style)
void setRowAutoHeight(bool autoHeight)
void setRowRemoveEnabled(bool enabled)
void setRowStyle(GridViewOptions::RowStyle style)
void setRowsAutoScroll(bool autoScroll)
void setRubberBandSelection(bool enabled)
void setScrollBars(Qtitan::ScrollBarsMode mode)
void setScrollRowStyle(Qtitan::ScrollItemStyle style)
void setSelectedDecorationOpacity(double opacity)
void setSelectionPolicy(GridViewOptions::SelectionPolicy policy)
void setShowFocusDecoration(bool value)
void setShowWaitCursor(bool show)
void setSortEnabled(bool enabled)
void setSummaryMenuDisabled(bool disabled)
void setSupportedDropActions(Qt::DropActions actions)
void setTransparentBackground(bool transparent)
void setZoomEnabled(bool enabled)
void setZoomFactor(double factor)
void setZoomIndicatorActive(bool active)
bool showFocusDecoration() const
bool showWaitCursor()
Qt::DropActions supportedDropActions() const
bool zoomEnabled() const
double zoomFactor() const

Detailed Description

The options is a common for all all types of the views supported by the grid. To get this option use GridViewBase::options(). To get the options related to the specific view see GridTableView::tableOptions(), GridBandedTableView::bandedOptions(), GridCardView::cardOptions(), GridTreeView::treeOptions().

Member Type Documentation

enum GridViewOptions::GroupSummaryPlace

ConstantValueDescription
GridViewOptions::SummaryHidden0Hide group summaries. This value is used by default.
GridViewOptions::SummaryRow1Show summaries for group on the grop row direcly - style 1.
GridViewOptions::SummaryRowPlus2Show summaries for group on the grop row direcly - style 2.
GridViewOptions::SummaryRowFooter3Show summaries for group on the grop footer.

enum GridViewOptions::PreviewRowExpandStyle

The enumerator describes the behavior of the expanding mode for Preview Row.

ConstantValueDescription
GridViewOptions::PreviewKeepExpanded0Preview row is always open. The behavior is the same as for the ordinary cell.
GridViewOptions::PreviewExpandTextButton1Text button is used to open/close the preview row. Text can be changed.
GridViewOptions::PreviewExpandButton2Plus/minus button is used to open/close the preivew row.

enum GridViewOptions::RowStyle

The enumerator ways of grouping the grid rows.

ConstantValueDescription
GridViewOptions::GroupStandard?Standard way of grouping.
GridViewOptions::GroupOfficeOutlook?The way to emulate the behavior and appearance similar to the grouping in MS-Office Outlook.

enum GridViewOptions::SelectionPolicy

Enum describes policy for selection behaviour.

ConstantValueDescription
GridViewOptions::IgnoreSelection0Ignore focus selection. If this policy is used then selection based on change focus (by keyborad and mouse for instance) will be disabled. You can select rows by GridTableView::selectRange(), GridTableView::selectRowRange(), GridTableView::selectRow(), GridTableView::selectAll() functions only. By defaut this flag is false.
GridViewOptions::RowSelection1user can select only one row (by default).
GridViewOptions::CellSelection2user can select only one cell.
GridViewOptions::MultiRowSelection3user can select several rows at time. Hold shift key to select multiple rows.
GridViewOptions::MultiCellSelection4user can select several cells at time. Hold shift key to select multiple cells.

See also GridTableView::selectRange(), GridTableView::selectRowRange(), GridTableView::selectRow(), and GridTableView::selectAll().

Member Function Documentation

GridViewOptions::GridViewOptions(GridViewBase *view)

Constructor of GridViewOptions class. The constructor is called automatically when a grid view is created.

bool GridViewOptions::allowFilterEditor() const

Returns the value that indicates whether the built-in Filter Editor can be used to edit filter criteria.

See also setAllowFilterEditor().

bool GridViewOptions::alternatingRowColors() const

Returns the value of the flag that defines whether alternating colors should be used for drawing grid cells. If the returned value is true, the item background will be drawn using QPalette::Base and QPalette::AlternateBase; otherwise the background will be drawn using the QPalette::Base color. By default, this property is true.

See also setAlternatingRowColors().

bool GridViewOptions::autoCreateColumns() const

Returns autoCreateColumns value.

See also setAutoCreateColumns().

QColor GridViewOptions::backgroundColor() const

Returns the value of the color for the background of the grid view.

See also setBackgroundColor().

const QColor &GridViewOptions::borderColor() const

Returns the color of the border around the grid view. The default value is Qt::black.

See also setBorderColor().

bool GridViewOptions::borderStyled() const

Returns true if grid should use QStyle to render the grid view border.

See also setBorderStyled().

int GridViewOptions::borderWidth() const

Returns the grid view border width (in pixels). The default value is 1px. The border color is set by the borderColor() function.

See also setBorderWidth().

const QFont &GridViewOptions::cellFont() const

Returns the font that will be used for rendering text information in the grid cell.

See also setCellFont().

int GridViewOptions::cellHeight() const

Returns the height of the grid cell in pixels. By default the cellFont() value is used to calculate the cell height.

See also setCellHeight().

const QPalette &GridViewOptions::cellPalette() const

Returns the value of the palette that is used for rendering the grid cell.

See also setCellPalette().

int GridViewOptions::cellWidth() const

Returns the width of the grid cell in pixels. By default the cellFont() value is used to calculate the cell width.

See also setCellWidth().

bool GridViewOptions::columnAutoScroll() const

See also setColumnAutoScroll() and setRowsAutoScroll().

const QFont &GridViewOptions::columnFont() const

Returns font that used for drawing the text in the grid columns.

See also setColumnFont().

bool GridViewOptions::columnHeaderHints() const

Returns "true" if the component is configured to show a popup tip over the column header if the column does not completely fit on the screen and the user cannot read the column header.

See also setColumnHeaderHints().

int GridViewOptions::columnHeight() const

Returns the default value of the grid height. If the returned value is -1, the height will be calculated automatically and will depend on the size of the column font used for displaying text information.

See also setColumnHeight().

const QPen &GridViewOptions::columnPen() const

Returns pen that is used for displaying text in grid columns.

See also setColumnPen().

bool GridViewOptions::dragEnabled() const

Returns "true" if grid's view can act as a drag source. By default it is "true".

See also setDragEnabled().

bool GridViewOptions::dropEnabled() const

Returns "true" if grid's view can act as a drag target. By default it is "false".

See also setDropEnabled().

bool GridViewOptions::fastScrollEffect() const

If the option is true, then a special fade effect is enabled, which on fast data scrolling shows the frame of the rows without data inside the cells only. This allows you to increase the number of frames per second when rendering and avoid lag on large data.

See also setFastScrollEffect().

bool GridViewOptions::filterAutoHide() const

Returns the value that indicates whether the filter panel can automatically hide or not.

See also setFilterAutoHide().

int GridViewOptions::filterPanelHeight() const

Returns the height of filter panel in pixels.

See also setFilterPanelHeight().

const QStringList &GridViewOptions::findColumnList() const

Returns a list of column names in which text will be finding.

See also setFindColumnList().

const QString &GridViewOptions::findPanelPlaceholderText() const

Returns placeholder text for find panel edit box.

See also setFindPanelPlaceholderText().

bool GridViewOptions::focusFrameEnabled() const

Returns true if the doted frame around the cell that has focus is drawn in at the moment.

See also setFocusFrameEnabled().

QBrush GridViewOptions::gridLineBrush() const

Returns the value of the brush that used for drawing lines delimiting grid cells.

See also setGridLineBrush() and gridLinePen.

QColor GridViewOptions::gridLineColor() const

Returns the color of the line delimiting grid cells.

See also setGridLineColor().

QPen GridViewOptions::gridLinePen() const

Returns the value of the pen that used for drawing lines delimiting grid cells.

See also setGridLinePen() and gridLineBrush.

int GridViewOptions::gridLineWidth() const

Returns the width of the lines delimiting grid cells.

See also setGridLineWidth().

Qtitan::LinesStyle GridViewOptions::gridLines() const

Returns the style of the grid cell delimiting lines. Possible variants: show only horizontal, only vertical, horizontal and vertical, do not show lines.

See also setGridLines() and Qtitan::LinesStyle.

QPalette GridViewOptions::groupPalette(int depth) const

Returns the palette that used for displaying the visual elements of a row representing a group for the depth. For instance, margins, background, font color. By default, the grid widget palette is returned.

See also setGroupPalette().

QFont GridViewOptions::groupRowFont(int depth = -1) const

Returns the font that will be used for rendering text information in the grid group row for the grouping depth.

See also setGroupRowFont().

int GridViewOptions::groupRowHeight() const

Returns the height of group rows. If the returned value is -1, the height of the row will depend on the settings of the font used in the cells of the row. The default value is -1.

See also setGroupRowHeight().

GridViewOptions::GroupSummaryPlace GridViewOptions::groupSummaryPlace() const

Returns the place of a special panel to display the summaries for the group rows.

See also setGroupSummaryPlace() and GridViewOptions::GroupSummaryPlace.

bool GridViewOptions::groupsHeader() const

Returns the visibility value of the grid grouping panel.

See also setGroupsHeader().

QBrush GridViewOptions::groupsHeaderBrush() const

Returs the brush which is used for rendering of the group header panel's background.

See also setGroupsHeaderBrush().

const QColor &GridViewOptions::groupsHeaderColor() const

Returs the color which is used for filling the group header panel's background.

See also setGroupsHeaderColor().

const QString &GridViewOptions::groupsHeaderText() const

Returns the text to be displayed on the group header panel if the grouping is not fulfilled.

See also setGroupsHeaderText().

QColor GridViewOptions::groupsHeaderTextColor() const

Returns the color of the text which is specified by groupsHeaderText() property.

See also setGroupsHeaderTextColor().

QFont GridViewOptions::groupsHeaderTextFont() const

Returns the font of the text which is specified by groupsHeaderText() property.

See also setGroupsHeaderTextFont().

bool GridViewOptions::isColumnHidingEnabled() const

Returns "true" if the user can hide columns by dragging them outside the grid view. Returns "true" by default.

bool GridViewOptions::isColumnHidingOnGroupingEnabled() const

Returns the status of the grid column hiding function after the column was dragged onto the group panel and grouping was performed.

bool GridViewOptions::isColumnMovingEnabled() const

Returns "true" if the user can change the position of columns by dragging them. This flag is applied to all columns at once.

bool GridViewOptions::isFieldChooserEnabled() const

Returns true if field chooser button is visible, otherwise returns false.

bool GridViewOptions::isFilterEnabled() const

Returns a value that indicates whether or not to use any filtering mechanisms for the grid view.

bool GridViewOptions::isFindEnabled() const

Returns "true" if a find feature (find panel, find shortcurs and etc.) is enabled. By default it is "true".

bool GridViewOptions::isFocusFollowsMouse() const

Returns true if the cell's focus follow the mouse moves over the grid view.

bool GridViewOptions::isFooterSummaryVisible() const

Returns the visibility of the panel to display the summaries at the footer of the grid view.

bool GridViewOptions::isGestureEnabled() const

Returns "true" if the view can accept the gesture input. By the default it is "false".

bool GridViewOptions::isGroupSortEnabled() const

Returns the status of the flag enabling the user to sort by a column taking part in grouping.

bool GridViewOptions::isGroupingEnabled() const

Returns "true" if the user can group rows by a column by dragging the column onto the group panel. This flag is applied to all columns at once.

bool GridViewOptions::isMainMenuDisabled() const

Returns the accessibility of the grid main context menu which popup on the right mouse click.

bool GridViewOptions::isPreviewRowEnabled() const

Returns true if the grid shows the preview row below the row with a cells. By default it is false.

See also setPreviewRowEnabled().

bool GridViewOptions::isSortEnabled() const

Returns the status of the flag allowing the user to sort by a column.

bool GridViewOptions::isSummaryMenuDisabled() const

Returns the accessibility of the grid summary context menu which popup on the right mouse click on the summary group or footer panel.

bool GridViewOptions::isTransparentBackground() const

Returns the value of the background transparency for the view. If true, the background is transparent. By default the value is false.

bool GridViewOptions::isZoomIndicatorActive() const

Returns the flag of usage for the special blinking zoom indicator. Indicator momentarily highlights the current value of the zooming factor in percentage.

bool GridViewOptions::keepFocusedRow() const

Returns true if the grid will keep the focus row active on any data update. When this flag is enabled, there is no way to remove focus from the row at all. By default it is true.

See also setKeepFocusedRow().

int GridViewOptions::keepGroupLevelExpanded() const

Returns the max level of grouping that grid should keep expanded. By default returns -1, that means that the all created groups are collapsed.

bool GridViewOptions::modelDecoration() const

Returns the status of the flag allowing the use of decoration settings of the grid cells obtained from corresponding model roles, such as Qt::FontRole, Qt::DecorationRole, Qt::BackgroundRole and others. The default value is "true".

See also setModelDecoration().

bool GridViewOptions::modelItemsDragEnabled() const

See also setModelItemsDragEnabled.

int GridViewOptions::newRowFlashInterval() const

Returns interval of flashing for the grid row while the grid view in "New Row Editing" mode.

See also setNewRowFlashInterval(), newRowHighlightEffect(), and newRowOpacity().

Qtitan::HighlightEffect GridViewOptions::newRowHighlightEffect() const

Returns the effect of highlighting for the grid row while the grid view in "New Row Editing" mode.

See also setNewRowHighlightEffect(), newRowOpacity(), and newRowFlashInterval().

double GridViewOptions::newRowOpacity() const

Returns the value of opacity for the grid row while the grid view in "New Row Editing" mode.

See also setNewRowOpacity(), newRowHighlightEffect(), and newRowFlashInterval().

Qtitan::ItemPosition GridViewOptions::newRowPlace() const

Returns the location of a special line for creating and editing the new row of the grid.

See also setNewRowPlace() and Qtitan::ItemPosition.

const QString &GridViewOptions::newRowText() const

Returns the text that is typed on a special line for creating and editing the new row of the grid.

See also setNewRowText().

GridViewOptions::PreviewRowExpandStyle GridViewOptions::previewRowExpandStyle() const

Returns the behavior of the expanding mode for the preview row.

See also setPreviewRowExpandStyle().

bool GridViewOptions::rowAutoHeight() const

Returns the state of row auto height feature. By default it is "false".

See also setRowAutoHeight().

bool GridViewOptions::rowRemoveEnabled() const

Returns true if the end-user has the ability to remove the row from the view, overwise it returns false. By default it is true.

See also setRowRemoveEnabled().

GridViewOptions::RowStyle GridViewOptions::rowStyle() const

Returns the style for the grid rows layout.

See also setRowStyle() and GridViewOptions::RowStyle.

bool GridViewOptions::rowsAutoScroll() const

See also setRowsAutoScroll() and setColumnAutoScroll().

bool GridViewOptions::rubberBandSelection() const

Returns the status of the flag allowing the use of RubberBand for cell or row multi-selection. The default value is "true".

See also setRubberBandSelection().

Qtitan::ScrollBarsMode GridViewOptions::scrollBars() const

Returns the scrollbar display mode value.

See also setScrollBars() and Qtitan::ScrollBarsMode.

Qtitan::ScrollItemStyle GridViewOptions::scrollRowStyle() const

Returns the grid row scrolling mode value. Two types of scrolling are supported: by row and by pixel.

See also setScrollRowStyle() and ScrollItemStyle.

double GridViewOptions::selectedDecorationOpacity() const

Returns the opacity value that will be applied to brush obtained from the model with Qt::ForegroundRole, Qt::DecorationRole, Qt::BackgroundRole roles when the grid renders selected cells. By default it is 0.5.

See also setSelectedDecorationOpacity and setModelDecoration.

GridViewOptions::SelectionPolicy GridViewOptions::selectionPolicy() const

Returns the selection policy used in the grid view.

See also setSelectionPolicy().

void GridViewOptions::setAllowFilterEditor(bool allow)

Depending on allow flag determines whether the built-in Filter Editor can be used to edit filter criteria.

See also allowFilterEditor().

void GridViewOptions::setAlternatingRowColors(bool alternating)

Sets the flag indicating that alternating colors should be used for drawing grid cells. If the set value is "true", the item background will be drawn using QPalette::Base and QPalette::AlternateBase; otherwise the background will be drawn using the QPalette::Base color. By default, this property is set to "false".

See also alternatingRowColors().

void GridViewOptions::setAutoCreateColumns(bool autoCreate)

Sets autoCreateColumns to autoCreate. It enables automatically create a columns in the view which will correspond to the structure of the model. If this parameter is false then the columns will not be created at all. Later they can be created manually in the required composition. To create a column please use createColumn() function. Note that for banded view, automatic creation of columns works as well. Columns will be created and inserted into the first available band column. If there is no band column in the view it will be created first. By default it is "true".

See also autoCreateColumns().

void GridViewOptions::setBackgroundColor(const QColor &color)

Sets the value of the color for the background of the grid view.

See also backgroundColor().

void GridViewOptions::setBorderColor(const QColor &color)

Sets the color of the border around the grid view.

See also borderColor().

void GridViewOptions::setBorderStyled(bool styled)

Sets the styled flag that specifies if the grid should use QStyle to render the grid view border. By default it is "true". If the value is false then borderColor() is used to render the border.

See also borderStyled().

void GridViewOptions::setBorderWidth(int width)

Sets the grid view border width in pixels. The border color is set by the setBorderColor() function.

See also borderWidth().

void GridViewOptions::setCellFont(const QFont &font)

Sets the font to be used for rendering text in the grid cell. Font will be used for all cells of the grid view. If the widget is used to display the cell content, or the cell is in edit mode then this font will be applied to the embed widget.

See also cellFont().

void GridViewOptions::setCellHeight(int height)

Sets the exact height for the grid cell in pixels. If this function is called then the font height for cell is ignored.

See also cellHeight().

void GridViewOptions::setCellPalette(const QPalette &palette)

Sets the value of the palette that is used for rendering the grid cell. By default the grid's widget palette is used.

See also cellPalette().

void GridViewOptions::setCellWidth(int width)

Sets the exact width for the grid cell in pixels. If this function is called then the font width for cell is ignored. The value takes effect in Horizontal layout only.

See also cellWidth().

void GridViewOptions::setColumnAutoScroll(bool autoScroll)

Sets the flag autoScroll that specifies that grid should to try scroll the view to the columns that are outside of the view during the execution of drag-drop operations.

See also columnAutoScroll() and setRowsAutoScroll().

void GridViewOptions::setColumnFont(const QFont &font)

Sets the font that used for drawing text in grid columns.

See also columnFont().

void GridViewOptions::setColumnHeaderHints(bool headerHints)

Sets the flag headerHints that adds a popup hint over the column header if the header does not fit on the screen and the user cannot read the column header.

See also columnHeaderHints().

void GridViewOptions::setColumnHeight(int height)

Sets the default height of grid columns. If the passed value is -1, the height will be automatically calculated based on the column font used for displaying text information.

See also columnHeight().

void GridViewOptions::setColumnHidingEnabled(bool enabled)

Enables or disables the user's ability to hide columns by dragging them outside of the grid view depending on enabled flag.

See also isColumnHidingEnabled().

void GridViewOptions::setColumnHidingOnGroupingEnabled(bool enabled)

Enables or disables the grid column hiding function depending on enabled flag after the column was dragged onto the group panel and grouping was performed.

See also isColumnHidingOnGroupingEnabled().

void GridViewOptions::setColumnMovingEnabled(bool enabled)

Enables or disables the user's ability to change column positions by dragging. This enabled flag is applied to all columns at once. If you need to prohibit dragging for one column only, you need to change the corresponding property of this specific column - GridTableColumn::setMovingEnabled() - and leave the global flag set to "true".

See also isColumnMovingEnabled().

void GridViewOptions::setColumnPen(const QPen &pen)

Sets the pen that is used for displaying text in grid columns.

See also columnPen().

void GridViewOptions::setDragEnabled(bool enabled)

Sets the grid's view as a source of the dragging to enabled.

See also dragEnabled().

void GridViewOptions::setDropEnabled(bool enabled)

Sets the grid's view as a target of the dropping to enabled.

See also dropEnabled().

void GridViewOptions::setFastScrollEffect(bool enabled)

Sets the fastScrollEffect option to enabled.

See also fastScrollEffect().

void GridViewOptions::setFieldChooserEnabled(bool enabled)

Enables a field chooser. If enabled is false then the field chooser button will be hided.

See also isFieldChooserEnabled().

void GridViewOptions::setFilterAutoHide(bool autoHide)

Depending on autoHide flag determines whether the filter panel is able to automatically hiding if the user leads away the mouse from the panel.

See also filterAutoHide().

void GridViewOptions::setFilterEnabled(bool enabled)

Depending on enabled flag determines whether or not to use any filtering mechanisms for the grid view.

See also isFilterEnabled().

void GridViewOptions::setFilterPanelHeight(int height)

Sets the height of filter panel in pixels.

See also filterPanelHeight().

void GridViewOptions::setFindColumnList(const QStringList &list)

Sets a list of column names in which text will be finding. If this list is empty then search will be executed for all columns. By default it is empty.

See also findColumnList().

void GridViewOptions::setFindEnabled(bool enabled)

Enables or disables a find feature (find panel, find shortcurs and etc.) that allows to find a text in the grid cells. Also it's enables or disables all shortcuts related to the find feature.

See also isFindEnabled().

void GridViewOptions::setFindPanelPlaceholderText(const QString &text)

Sets placeholder text for find panel edit box.

See also findPanelPlaceholderText().

void GridViewOptions::setFocusFollowsMouse(bool enabled)

Sets a flag enabled that the focus of cells or rows of the grid will follow the mouse moves over the grid.

See also isFocusFollowsMouse().

void GridViewOptions::setFocusFrameEnabled(bool enabled)

Sets the painting the doted frame around the cell with focus to the enabled. By default frame is enabled.

See also focusFrameEnabled().

void GridViewOptions::setFooterSummaryVisible(bool visible)

Sets the visibility to visible of the panel to display the summaries at the footer of the grid view.

See also isFooterSummaryVisible().

void GridViewOptions::setGestureEnabled(bool enabled)

Sets to the enabled the ability to get gesture input.

See also isGestureEnabled().

void GridViewOptions::setGridLineBrush(const QBrush &brush)

Sets the brush used for drawing lines delimiting grid cells.

See also gridLineBrush() and setGridLinePen.

void GridViewOptions::setGridLineColor(const QColor &color)

Sets the color of the line delimiting grid cells.

See also gridLineColor().

void GridViewOptions::setGridLinePen(const QPen &pen)

Sets the pen used for drawing lines delimiting grid cells.

See also gridLinePen() and setGridLineBrush.

void GridViewOptions::setGridLineWidth(int width)

Sets the width of the lines delimiting grid cells.

See also gridLineWidth().

void GridViewOptions::setGridLines(Qtitan::LinesStyle lines)

Sets the style of the grid cell delimiting lines. Possible variants: show only horizontal, only vertical, horizontal and vertical, do not show lines.

See also gridLines().

void GridViewOptions::setGroupKeepLevelExpanded(int level)

Sets the max level of grouping that grid should keep expanded.

void GridViewOptions::setGroupPalette(int depth, const QPalette &palette)

Sets the palette used for displaying the group row (background and text) for the depth.

Qtitan::GridTableView* view = grid->view<Qtitan::GridTableView>();
QPalette palette;
palette.setColor(QPalette::Highlight, Qt::red);
palette.setColor(QPalette::HighlightedText, Qt::white);
palette.setColor(QPalette::Dark, Qt::black);
palette.setColor(QPalette::BrightText, Qt::lightGray);
view->options().setGroupPalette(0, palette);

See also groupPalette().

void GridViewOptions::setGroupRowFont(const QFont &font, int depth = -1)

Sets the font to be used for rendering text in the grid group row for the grouping depth. Font will be used for all group rows of the grid view if parameter depth is -1.

See also groupRowFont().

void GridViewOptions::setGroupRowHeight(int height)

Sets the height of group rows. If the returned value is -1, the height of the row will depend on the settings of the font used in the cells of the row.

See also groupRowHeight().

void GridViewOptions::setGroupSortEnabled(bool enabled)

Sets the status of the flag to enabled allowing the user to sort by a column taking part in grouping.

See also isGroupSortEnabled().

void GridViewOptions::setGroupSummaryPlace(GridViewOptions::GroupSummaryPlace place)

Sets the place of a special panel to display the summaries. By default summaries for group rows are hidden.

See also groupSummaryPlace() and GridViewOptions::GroupSummaryPlace.

void GridViewOptions::setGroupingEnabled(bool enabled)

Enables or disables the user's ability to group rows by a column by dragging the column onto the group panel. This flag enabled is applied to all columns at once. If you need to prohibit grouping for one column only, you need to change the corresponding property of this specific column - GridTableColumn::setGroupingEnabled(), and leave the global flag set to "true".

See also isGroupingEnabled().

void GridViewOptions::setGroupsHeader(bool groupsHeader)

Sets the visibility status of the grid grouping panel to groupsHeader.

See also groupsHeader().

void GridViewOptions::setGroupsHeaderBrush(const QBrush &brush)

Sets the brush which will be used for rendering of the group header panel's background.

See also groupsHeaderBrush().

void GridViewOptions::setGroupsHeaderColor(const QColor &color)

Sets the color which will be used for filling the group header panel's background.

See also groupsHeaderColor().

void GridViewOptions::setGroupsHeaderText(const QString &text)

Sets the text to be displayed on the group header panel if the grouping is not fulfilled.

See also groupsHeaderText().

void GridViewOptions::setGroupsHeaderTextColor(const QColor &color)

Sets the color of the text which is specified by groupsHeaderText() property.

See also groupsHeaderTextColor().

void GridViewOptions::setGroupsHeaderTextFont(const QFont &font)

Sets the font of the text which is specified by groupsHeaderText() property.

See also groupsHeaderTextFont().

void GridViewOptions::setKeepFocusedRow(bool keep)

Sets the keepFocusedRow option to keep.

See also keepFocusedRow().

void GridViewOptions::setMainMenuDisabled(bool disabled)

Sets the accessibility of the grid main context menu which popup on the right mouse click to disabled.

See also isMainMenuDisabled().

void GridViewOptions::setModelDecoration(bool enabled)

Sets the status to enabled of the flag that allows the use of decoration settings of the grid cells obtained from corresponding model roles, such as Qt::FontRole, Qt::DecorationRole, Qt::BackgroundRole and others.

See also modelDecoration().

void GridViewOptions::setModelItemsDragEnabled(bool enabled)

The setting allows you to enable the drag flag for all items in the model without overriding the model. If the parameter enabled is "true", then the grid starts to ignore the check for flag Qt::ItemIsDragEnabled, believing this flag is constantly presented for all items in the model. By the default it is "false".

See also modelItemsDragEnabled().

void GridViewOptions::setNewRowFlashInterval(int interval)

Sets interval of flashing for the grid row while the grid view in "New Row Editing" mode.

See also newRowFlashInterval(), setNewRowHighlightEffect(), and setNewRowOpacity().

void GridViewOptions::setNewRowHighlightEffect(Qtitan::HighlightEffect effect)

Sets the effect of highlighting for the gird row while the grid view in "New Row Editing" mode.

See also newRowHighlightEffect(), setNewRowOpacity(), and setNewRowFlashInterval().

void GridViewOptions::setNewRowOpacity(double opacity)

Sets the value of opacity for the grid row while the grid view in "New Row Editing" mode.

See also newRowOpacity(), setNewRowHighlightEffect(), and setNewRowFlashInterval().

void GridViewOptions::setNewRowPlace(Qtitan::ItemPosition place)

Sets the location to place of a special line for creating and editing the new row of the grid.

See also newRowPlace() and Qtitan::ItemPosition.

void GridViewOptions::setNewRowText(const QString &text)

Sets the text that is typed on a special line for creating and editing the new row of the grid.

See also newRowText().

void GridViewOptions::setPreviewRowEnabled(bool enabled)

Sets the previewRowEnabled option to enabled.

See also isPreviewRowEnabled().

void GridViewOptions::setPreviewRowExpandStyle(GridViewOptions::PreviewRowExpandStyle style)

Sets the behavior of the expanding mode for the preview row to style.

See also previewRowExpandStyle().

void GridViewOptions::setRowAutoHeight(bool autoHeight)

Sets the state of row auto height feature to autoHeight. Row auto height it is feature that allows to adjust height of the row to its contents.

See also rowAutoHeight().

void GridViewOptions::setRowRemoveEnabled(bool enabled)

Disables(or enables) the ability to remove the row from the view. It hides the remove button from item at CardView and hides the remove action from the grid context menu.

See also rowRemoveEnabled().

void GridViewOptions::setRowStyle(GridViewOptions::RowStyle style)

Sets the style for the grid rows layout to style.

See also rowStyle() and GridViewOptions::RowStyle.

void GridViewOptions::setRowsAutoScroll(bool autoScroll)

Sets the flag autoScroll that specifies that grid should to try scroll the view to the rows that are outside of the view during the execution of drag-drop operations.

See also rowsAutoScroll() and setColumnAutoScroll().

void GridViewOptions::setRubberBandSelection(bool enabled)

Sets the status to enabled of the flag allowing the use of RubberBand for cell or row multi-selection.

See also rubberBandSelection().

void GridViewOptions::setScrollBars(Qtitan::ScrollBarsMode mode)

Sets the scroll bars display mode. The default value is ScrollAuto.

See also scrollBars() and Qtitan::ScrollBarsMode.

void GridViewOptions::setScrollRowStyle(Qtitan::ScrollItemStyle style)

Sets the grid row scrolling mode to style. Two scrolling modes are supported: by row and by pixel.

See also scrollRowStyle() and ScrollItemStyle.

void GridViewOptions::setSelectedDecorationOpacity(double opacity)

Sets the opacity value that will be applied to brush obtained from the model with Qt::ForegroundRole, Qt::DecorationRole, Qt::BackgroundRole roles when the grid renders selected cells. Setting is useful when the cell color or brush conflicts with selected cells rendering for a specific platform.

See also selectedDecorationOpacity() and setModelDecoration.

void GridViewOptions::setSelectionPolicy(GridViewOptions::SelectionPolicy policy)

Sets the selection policy used in the grid view. If ignoreFocusSelection() is true then selectionPolicy() does not has any effects.

See also selectionPolicy() and GridViewOptions::SelectionPolicy.

void GridViewOptions::setShowFocusDecoration(bool value)

Sets indication value of how to highlight the row that has focus. If value is true then the QStyle prmitive will be used for painting background of the focused row. Otherwise, the grid will use the built-in bitmap. By default this value is false.

See also showFocusDecoration().

void GridViewOptions::setShowWaitCursor(bool show)

Enables or disables wait cursor if grid is busy for lengthy operations with data like sorting or grouping.

See also showWaitCursor().

void GridViewOptions::setSortEnabled(bool enabled)

Sets the status of the flag to enabled allowing the user to sort by a column.

See also isSortEnabled().

void GridViewOptions::setSummaryMenuDisabled(bool disabled)

Sets the accessibility of the grid summary context menu which popup on the right mouse click on the summary group or footer panel to disabled value.

See also isSummaryMenuDisabled().

void GridViewOptions::setSupportedDropActions(Qt::DropActions actions)

Sets the supported drop actions for the grid view. By default Qt::MoveAction and Qt::CopyAction are supported.

See also supportedDropActions().

void GridViewOptions::setTransparentBackground(bool transparent)

Sets a transparent background for the grid view.

See also isTransparentBackground().

void GridViewOptions::setZoomEnabled(bool enabled)

Enables or disables the zooming mechanism depending on flag enabled.

See also zoomEnabled().

void GridViewOptions::setZoomFactor(double factor)

Sets the current value of the zoom factor.

See also zoomFactor().

void GridViewOptions::setZoomIndicatorActive(bool active)

Sets the flag of usage for the special blinking indicator of zooming to active. By default it is "true".

See also isZoomIndicatorActive().

bool GridViewOptions::showFocusDecoration() const

Returns true if focus decoration adopted for the current operating system or for the current style.

See also setShowFocusDecoration().

bool GridViewOptions::showWaitCursor()

Indicates whether or not to show the wait cursor when the grid performs lengthy operations with data like sorting or grouping.

See also setShowWaitCursor().

Qt::DropActions GridViewOptions::supportedDropActions() const

Returns the supported drop actions for the grid view.

See also setSupportedDropActions().

bool GridViewOptions::zoomEnabled() const

Returns the value that shows the availability of zooming mechanism. By default the value is true.

See also setZoomEnabled().

double GridViewOptions::zoomFactor() const

Returns the current value of the zoom factor. Value of 1.0 means that elements of the grid view have the size to 100%. Value of 0.5 means 50%, 1.5 - 150% and so on. The default value is 1.0.

See also setZoomFactor().