GridEditor Class

GridEditor virtual abstact class that describes the grid editor interface. More...

Header: #include <GridEditor>
Inherits: QObject
Inherited By:

GridEditorBase

Public Types

flags ActivationPolicy
enum ActivationPolicyFlag { NotActivate, ActivateByClickNoFocused, ActivateByClickFocused, ActivateByClick, ActivateByMousePressNoFocused, …, ActivateByAnyEvents }
enum Type { Auto, String, Memo, ComboBoxBlob, Numeric, …, Custom }

Detailed Description

Member Type Documentation

enum GridEditor::ActivationPolicyFlag
flags GridEditor::ActivationPolicy

Enumerator ActivationPolicyFlag describes the policy of activating the edit mode of the cell editor if the cell gets the focus. You can group the policy on your own using logical OR.

ConstantValueDescription
GridEditor::NotActivate0x0000Blank value. The editing mode may not be enabled. The cell can not be edited.
GridEditor::ActivateByClickNoFocused0x0001Edit mode of the cell editor is activated if you click on a cell that has no focus.
GridEditor::ActivateByClickFocused0x0002Edit mode of the cell editor is activated if you click on a cell that already has focus.
GridEditor::ActivateByClickActivateByClickNoFocused | ActivateByClickFocusedEdit mode of the cell editor is activated if you click on a cell. This policy does not depend on whether the cell has focus or not. Editor always activated when was a click on a cell.
GridEditor::ActivateByMousePressNoFocused0x0004Edit mode of the cell editor is activated if you press mouse on a cell that has no focus.
GridEditor::ActivateByMousePressFocused0x0008Edit mode of the cell editor is activated if you press mouse on a cell that already has focus.
GridEditor::ActivateByMousePressActivateByMousePressNoFocused | ActivateByMousePressFocusedEdit mode of the cell editor is activated if you press mouse on a cell. This policy does not depend on whether the cell has focus or not. Editor always activated when was a mouse press (mouse down) on a cell.
GridEditor::ActivateByDblClickNoFocused0x0010Edit mode of the cell editor is activated if you double-click on a cell that has no focus.
GridEditor::ActivateByDblClickFocused0x0020Edit mode of the cell editor is activated if you double-click on a cell that already has focus.
GridEditor::ActivateByDblClickActivateByDblClickNoFocused | ActivateByDblClickFocusedEdit mode of the cell editor is activated if you double-click on a cell. This policy does not depend on whether the cell has focus or not. Editor always activated when was a double-click on a cell.
GridEditor::ActivateByKeyboardFocus0x0040The cell becomes in the edit state if the focus was acquired by the keyboard (for instance by pressing the navigation buttons Up, Down, Left, Right etc).
GridEditor::ActivateByKeyPress0x0080The cell becomes in the edit state if the any key was pressed while cell has focus and is not in the edit state. You can filtering the value of the key by using the editorEditingStarting() signal.
GridEditor::ActivateByEnter0x0100The cell becomes in the edit state if the Enter key was pressed while cell already has focus.
GridEditor::ActivateByKeyPress_F20x0200The cell becomes in the edit state if the F2 key was pressed while cell already has focus.
GridEditor::ActivateByEditPressActivateByEnter | ActivateByKeyPress_F2ActivateByEnter plus ActivateByKeyPress_F2.
GridEditor::EatingKeyEvents0x0400Accessory flag, a sign that you need to send a key press event to the editor, after the beginning of the cell editing initiated by this event.
GridEditor::EatingMouseEvents0x0800Accessory flag, A sign that you need to send a mouse event to the editor, after the beginning of the cell editing initiated by this event.
GridEditor::SelectCurrentEvent0x1000Accessory flag, grid should start multi-select from this cell.
GridEditor::OtherMouseEvents0x2000Accessory flag, do not use it directly.
GridEditor::ActivateByKeyPress_WithEatingActivateByKeyPress | EatingKeyEventsActivateByKeyPress plus EatingKeyEvents. The cell becomes in the edit state if the any key was pressed while cell has focus. Unlike the ActivateByKeyPress, ActivateByKeyPress_WithEating eats first pressed symbol that caused the event. This first pressed symbol does not passed into the cell editor. You can filtering the value of the key by using the editorEditingStarting() signal.
GridEditor::ActivateByAnyEventsActivateByClick | ActivateByDblClick | ActivateByMousePress | ActivateByKeyPress | ActivateByEditPress | ActivateByKeyboardFocusThe start of cell editing will start at any event as soon as the cell gets focus.

The ActivationPolicy type is a typedef for QFlags<ActivationPolicyFlag>. It stores an OR combination of ActivationPolicyFlag values.

enum GridEditor::Type

Enumerator describes the possible types of grid cell editors for table view, banded table view, card view.

Qtitan::GridTableColumn* column = (Qtitan::GridTableColumn *)view->getColumnByModelColumnName("Photo");
column->setEditorType(GridEditor::Picture);
Qtitan::GridPictureEditorRepository* pictureEditor = (Qtitan::GridPictureEditorRepository *)column->editorRepository();
pictureEditor->setAspectRatioMode(Qt::KeepAspectRatio);
ConstantValueDescription
GridEditor::Auto0Automatic selection of the editor by edited value. By default.
GridEditor::String1The editor of an unary line. See GridStringEditorRepository for the details.
GridEditor::Memo2The editor of multi-line text. See GridMemoEditorRepository for the details.
GridEditor::ComboBoxBlob3The editor of multi-line text in popup window. See GridBlobEditorRepository for the details.
GridEditor::Numeric4The editor of numerical value. See GridNumericEditorRepository for the details.
GridEditor::CheckBox5The editor of boolean value. See GridCheckBoxEditorRepository for the details.
GridEditor::ComboBox7The editor allows to show combo boxes in the grid cell. See GridComboBoxEditorRepository for the details.
GridEditor::Table8The editor allows to specify the other datagrid as details for the editing value. Details grid will be shown in the popup window by clicking on the button that embeded to the grid cell. See GridTableEditorRepository for the details.
GridEditor::DateTime9The editor of DateTime value. See GridDateTimeEditorRepository for the details.
GridEditor::Time10The editor of Time value. See GridTimeEditorRepository for the details.
GridEditor::Date11The editor of Date value. See GridDateEditorRepository for the details.
GridEditor::Picture12The editor of picturies or images. See GridPictureEditorRepository for the details.
GridEditor::ComboBoxPicture13The editor of picturies and images. The pucture will be edited in the popup window like combobox. See GridPictureComboBoxEditorRepository for the details.
GridEditor::DelegateAdapter14The type of editor which allows you to use delegates from the regular table QTableView in the QtitanDataGrid. For more details see GridDelegateAdapterEditorRepository or follow this topic - QtitanDataGrid cell editor
GridEditor::ProgressBar15The editor for showing and editing numeric value. Custom ProgressBar widget is used for this purposes. See GridProgressEditorRepository for the details.
GridEditor::Custom16The editor of value creating by cutomer. Please read this article for more details - QtitanDataGrid cell editor