CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
FxUITreeView.h
Go to the documentation of this file.
1//
2// (C) Copyright 2005-2023 by Graebert GmbH.
3//
4// Permission to use, copy, modify, and distribute this software in
5// object code form for any purpose and without fee is hereby granted,
6// provided that the above copyright notice appears in all copies and
7// that both that copyright notice and the limited warranty and
8// restricted rights notice below appear in all supporting
9// documentation.
10//
11// GRAEBERT PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
12// GRAEBERT SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
13// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. GRAEBERT GMBH
14// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
15// UNINTERRUPTED OR ERROR FREE.
16
17#pragma once
18
19#include "FxUIBaseView.h"
20#include "../../sdk/Core/FxUIAbstractItemModel.h"
21#include "../../sdk/Core/FxUIModelIndex.h"
22
28{
29public:
30
35 {
36 AlignLeft = 0x0001,
37 AlignRight = 0x0002,
38 AlignHCenter = 0x0004,
39 AlignTop = 0x0020,
40 AlignBottom = 0x0040,
41 AlignVCenter = 0x0080
42 };
43
48 {
51 SelectColumns
52 };
53
58 {
62 ExtendedSelection,
65
66 ContiguousSelection
67 };
68
73 {
78 Custom = Fixed
79 };
80
85 NoUpdate = 0x0000,
86 Clear = 0x0001,
87 Select = 0x0002,
88 Deselect = 0x0004,
89 Rows = 0x0020,
90 Columns = 0x0040,
91 ClearAndSelect = Clear | Select
92 };
93
94public:
95
98
101
107 void setParentNodeIcon( const CFxUIIcon & icon );
108
114 void setChildNodeIcon( const CFxUIIcon & icon );
115
116 void setMoveCursorMode(bool bItemMode);
117
124
133
140
146 void setHeaderStretchLastSection( bool bEnable );
147
153 void setSortingEnabled( bool bEnable );
154
161
168
174 void setRootIsDecorated( bool bShow );
175
181 void setAlternatingRowColors( bool bEnable );
182
190 void setColumnWidth( int iColumn, int iWidth );
191
198
200
207
214
220 void setAutoScroll( bool bEnable );
221
228
235
243 void setColumnHidden( int iColumn, bool bHide );
244
253
258
262 void expandAll();
263
268
274 void setExpandsOnDoubleClick( bool bEnable );
275
280
285
290
294 CFxUISignal< void( int, int ) >& keyWentDown();
295
298
299 //...
300
301};
#define COMMONUI_API
QIcon CFxUIIcon
Definition: FxUIObject.h:63
CFxUISignal< void(const CFxUIModelIndex &)> & itemDoubleClicked()
void setCurrentIndex(CFxUIModelIndex index)
void selectRow(CFxUITreeView::UISelectionFlag flag, CFxUIModelIndex index)
void setSelectionMode(CFxUITreeView::UISelectionMode mode)
@ SelectRows
This enum selects only the rows.
Definition: FxUITreeView.h:50
@ SelectItems
This enum selects the single items.
Definition: FxUITreeView.h:49
CFxUISignal< void(const CFxUIModelIndex &)> & collapsed()
CFxUISignal< void(const CFxUIModelIndex &)> & itemClicked()
void setExpandsOnDoubleClick(bool bEnable)
void expandAll()
void setSelectionBehavior(CFxUITreeView::UISelectionBehavior behavior)
@ Stretch
HeaderView will automatically resize the section to fill the available space.
Definition: FxUITreeView.h:75
@ ResizeToContents
HeaderView will automatically resize the section to its optimal size based on the contents of the ent...
Definition: FxUITreeView.h:77
@ Fixed
The user cannot resize the section.
Definition: FxUITreeView.h:76
@ Interactive
The user can resize the section.
Definition: FxUITreeView.h:74
void setCollapse(CFxUIModelIndex index)
void clearSelection()
CFxUISignal< void(int, int) > & keyWentDown()
void setAlternatingRowColors(bool bEnable)
CFxUISignal< void(const CFxUIModelIndex &)> & expanded()
void setHeaderResizeSection(CFxUITreeView::UIHeaderResizeMode mode)
void setHeaderAlignment(CFxUITreeView::UIHeaderAlignment align)
void setExpand(CFxUIModelIndex index)
void setColumnWidth(int iColumn, int iWidth)
@ MultiSelection
When the user selects an item in the usual way, the selection status of that item is toggled and the ...
Definition: FxUITreeView.h:61
@ NoSelection
Items cannot be selected.
Definition: FxUITreeView.h:59
@ SingleSelection
When the user selects an item, any already-selected item becomes unselected, and the user cannot unse...
Definition: FxUITreeView.h:60
CFxUIModelIndex currentIndex() const
void setParentNodeIcon(const CFxUIIcon &icon)
CFxUISignal< void(void)> & selectionChanged()
void setColumnHidden(int iColumn, bool bHide)
void setHeaderResizeSection(CFxUITreeView::UIHeaderResizeMode mode, int iColumn)
void setMoveCursorMode(bool bItemMode)
void setAutoScroll(bool bEnable)
void collapseAll()
void setChildNodeIcon(const CFxUIIcon &icon)
CFxUIAbstractItemModel * getModel()
void setRootIsDecorated(bool bShow)
void setHeaderStretchLastSection(bool bEnable)
void setModel(CFxUIAbstractItemModel *model)
void setSortingEnabled(bool bEnable)
typedef void(APIENTRYP PFNGLACTIVETEXTUREPROC)(GLenum texture)
GLuint index
Definition: gles2_ext.h:265