Navigation
API > API/Plugins > API/Plugins/TedsTableViewer
A table viewer widget can be used to show a visual representation of data in TEDS. The rows to display can be specified using a RowQueryStack, and the columns to display are directly input into the widget Example usage:
SNew(SHierarchyViewer) .QueryStack(MakeShared
| Name | SHierarchyViewer |
| Type | class |
| Header File | /Engine/Plugins/Experimental/EditorDataStorageFeatures/Source/TedsTableViewer/Public/Widgets/STedsHierarchyViewer.h |
| Include Path | #include "Widgets/STedsHierarchyViewer.h" |
Syntax
class SHierarchyViewer :
public SCompoundWidget ,
public UE::Editor::DataStorage::ITableViewer
Inheritance Hierarchy
- FSharedFromThisBase → TSharedFromThis → SWidget → SCompoundWidget → SHierarchyViewer
- FSlateControlledConstruction → SWidget → SCompoundWidget → SHierarchyViewer
Implements Interfaces
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
SHierarchyViewer() |
Widgets/STedsHierarchyViewer.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~SHierarchyViewer() |
Widgets/STedsHierarchyViewer.h |
Structs
| Name | Remarks |
|---|---|
| FArguments |
Enums
Public
| Name | Remarks |
|---|---|
| EExpansionState |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FOnSelectionChanged | TBaseDelegate_TwoParams< void, RowHandle, ESelectInfo::Type > | Delegate fired when the selection in the table viewer changes. | Widgets/STedsHierarchyViewer.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| InstanceCounter | int | Store the Instance count and the created name for use by the executor and identifier (so it can avoid recreation) | Widgets/STedsHierarchyViewer.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bExpandNewRows | bool | If any newly viewed rows (after initialization) should be expanded by default. | Widgets/STedsHierarchyViewer.h | |
| bExpansionStateChangeRequested | TOptional< bool > | If we need to update the expansion state of all rows the next time the model changes. | Widgets/STedsHierarchyViewer.h | |
| bModelInitialized | bool | If the model hasn't been initialized yet, will check during OnModelChanged and let any PostModelInitialization functions run. | Widgets/STedsHierarchyViewer.h | |
| bPersistUIRowsOnClose | bool | If we want to persist all Table Viewer Rows and their mapping to this table ID when the viewer is destructed (keeping them around will persist its data while the editor is open) | Widgets/STedsHierarchyViewer.h | |
| bShowWires | bool | Whether to show hierarchy lines visually. | Widgets/STedsHierarchyViewer.h | |
| DropHandler | TUniquePtr< FWidgetDropHandler > | Drag and Drop Handler. | Widgets/STedsHierarchyViewer.h | |
| EmptyRowsMessage | TAttribute< FText > | The message to show in place of the table viewer when there are no rows provided by the current query stack. | Widgets/STedsHierarchyViewer.h | |
| ExecutorInstanceName | FName | Widgets/STedsHierarchyViewer.h | ||
| GetCustomTableViewerRowMapping | TableViewerUtils::FGetTableViewerRowMapping | Delegate fired when getting the row mapping, will use the default 'TableId.DataRowHandle' if nothing is bound. | Widgets/STedsHierarchyViewer.h | |
| HeaderRowWidget | TSharedPtr< SHeaderRow > | The actual header widget. | Widgets/STedsHierarchyViewer.h | |
| HierarchyInterface | TSharedPtr< IHierarchyViewerDataInterface > | Hierarchy data that is used to extract information about the parent of a row. | Widgets/STedsHierarchyViewer.h | |
| Model | TSharedPtr< FTedsTableViewerModel > | Our model class. | Widgets/STedsHierarchyViewer.h | |
| OnSelectionChanged | FOnSelectionChanged | Delegate fired when the selection changes. | Widgets/STedsHierarchyViewer.h | |
| QueryStackExecutor | QueryStack::FExplicitUpdateExecutor | The executor used to update the hierarchy stack. | Widgets/STedsHierarchyViewer.h | |
| TableViewerIdentifier | FName | Unique identifier for this Hierarchy. | Widgets/STedsHierarchyViewer.h | |
| TedsWidget | TSharedPtr< ITedsWidget > | Wrapper Teds Widget around our contents so we can use Teds columns to specify behavior. | Widgets/STedsHierarchyViewer.h | |
| TopLevelRows | TArray< TableViewerItemPtr > | The cached list of top level rows. | Widgets/STedsHierarchyViewer.h | |
| TopLevelRowsNode | TSharedPtr< QueryStack::IRowNode > | A specialized query stack node to only contain the top level rows present in the actual query stack we are using. | Widgets/STedsHierarchyViewer.h | |
| TreeView | TSharedPtr< STedsTreeView > | The actual ListView widget that displays the rows. | Widgets/STedsHierarchyViewer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void CollapseAll() |
Recursively Collapse all rows currently present in the viewer. | Widgets/STedsHierarchyViewer.h | |
void Construct
(
const FArguments& InArgs, |
Widgets/STedsHierarchyViewer.h | ||
void ExpandAll() |
Recursively Expand all rows currently present in the viewer. | Widgets/STedsHierarchyViewer.h | |
void ExpandWithParents
(
RowHandle Row |
Expand this row and all its parents. | Widgets/STedsHierarchyViewer.h | |
void SetDropHandler
(
TUniquePtr< FWidgetDropHandler > InDropHandler |
Set a handler that this viewer will forward its drop operations to. | Widgets/STedsHierarchyViewer.h |
Public Virtual
Overridden from ITableViewer
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AddCustomRowWidget
(
const TSharedRef< FTedsTableViewerColumn >& InColumn |
Add a custom per-row widget to the table viewer (that doesn't necessarily map to a TEDS column) This means a new column for the hierarchy viewer | Widgets/STedsHierarchyViewer.h | |
virtual TSharedRef< SWidget > AsWidget() |
Get the table viewer as an SWidget. | Widgets/STedsHierarchyViewer.h | |
virtual void ClearSelection() |
Deselect all items in the table viewer. | Widgets/STedsHierarchyViewer.h | |
virtual void ForEachSelectedRow
(
TFunctionRef< void(RowHandle)> InCallback |
Execute the given callback for each row that is selected in the table viewer. | Widgets/STedsHierarchyViewer.h | |
virtual RowHandle GetWidgetRowHandle() |
Get the row handle for the widget row the table viewer's contents are stored in. | Widgets/STedsHierarchyViewer.h | |
virtual bool IsSelected
(
RowHandle InRow |
Get if a specific row is selected. | Widgets/STedsHierarchyViewer.h | |
virtual bool IsSelectedExclusively
(
RowHandle InRow |
Get if a specific row is selected exclusively. | Widgets/STedsHierarchyViewer.h | |
virtual void ScrollIntoView
(
RowHandle Row |
Scroll the given row into view in the table viewer. | Widgets/STedsHierarchyViewer.h | |
virtual void SetColumns
(
const TArray< TWeakObjectPtr< const UScriptStruct > >& InColumns |
Clear the current list of columns being displayed and set it to the given list. | Widgets/STedsHierarchyViewer.h | |
virtual void SetQueryStack
(
TSharedPtr< QueryStack::IRowNode > InRowQueryStack |
Clear the current QueryStack being displayed, set it to the given node, and recreate the sorting nodes. | Widgets/STedsHierarchyViewer.h | |
virtual void SetSelection
(
RowHandle Row, |
Select the given row in the table viewer. | Widgets/STedsHierarchyViewer.h | |
virtual void SetTableViewerIdentifier
(
const FName& NewIdentifier |
Sets the Table Identifier (Can be used in case data is dynamic and created post widget init) | Widgets/STedsHierarchyViewer.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
RowHandle AddOrFindTableViewerUIRow
(
const TableViewerItemPtr InItem |
Widgets/STedsHierarchyViewer.h | ||
void AddWidgetColumns() |
Widgets/STedsHierarchyViewer.h | ||
void CreateInternalWidget() |
Widgets/STedsHierarchyViewer.h | ||
TableViewerItemPtr GetParentRow
(
TableViewerItemPtr InItem |
Widgets/STedsHierarchyViewer.h | ||
| Widgets/STedsHierarchyViewer.h | |||
void InitializeAllTableViewerUIRows() |
Widgets/STedsHierarchyViewer.h | ||
bool IsItemVisible
(
TableViewerItemPtr InItem |
Widgets/STedsHierarchyViewer.h | ||
TSharedRef< ITableRow > MakeTableRowWidget
(
TableViewerItemPtr InItem, |
Widgets/STedsHierarchyViewer.h | ||
void OnExpansionChanged
(
TableViewerItemPtr Item, |
Widgets/STedsHierarchyViewer.h | ||
void OnListSelectionChanged
(
TableViewerItemPtr Item, |
Widgets/STedsHierarchyViewer.h | ||
void OnModelChanged() |
Widgets/STedsHierarchyViewer.h | ||
void OnSetExpansionRecursive
(
TableViewerItemPtr Item, |
Widgets/STedsHierarchyViewer.h | ||
void RefreshColumnWidgets() |
Widgets/STedsHierarchyViewer.h | ||
void SetExpansionState_Internal
(
FRowHandleArrayView Rows, |
Widgets/STedsHierarchyViewer.h |
Protected Virtual
Overridden from SWidget
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void OnDragEnter
(
const FGeometry& MyGeometry, |
Drag and Drop handlers. | Widgets/STedsHierarchyViewer.h | |
virtual void OnDragLeave
(
const FDragDropEvent& DragDropEvent |
Widgets/STedsHierarchyViewer.h | ||
virtual FReply OnDragOver
(
const FGeometry& MyGeometry, |
Widgets/STedsHierarchyViewer.h | ||
virtual FReply OnDrop
(
const FGeometry& MyGeometry, |
Widgets/STedsHierarchyViewer.h |