STreeMap

Graphical tree map widget with interactive controls

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

TreeMap

Header

/Engine/Source/Developer/TreeMap/Public/STreeMap.h

Include

#include "STreeMap.h"

Syntax

class STreeMap : public SLeafWidget

Remarks

Graphical tree map widget with interactive controls

Functions

Name Description

Protected function

void

 

ApplyVisualizationToNodes

(
    const FTreeMapNodeDataRef& Node
)

Called to apply the current 'size based on' and 'color based on' settings to the tree

Protected function

void

 

ApplyVisualizationToNodesRecursively

(
    const FTreeMapNodeDataRef& Node,
    const FLinearColor& DefaultColor,
    const int32 TreeDepth
)

Recursively applies the active visualization to all nodes, such as size by attribute, or color by attribute

Public function Const

bool

 

CanZoomOut()

Returns true if it is possible to zoom out

Public function

void

 

Construct

(
    const FArguments& InArgs,
    const TSharedRef< class FTreeMapNod...,
    const TSharedPtr< ITreeMapCustomiza...
)

Construct the widget

Protected function

FReply

 

DeleteHoveredNode()

Deletes the node under the mouse cursor, if any (undoable!)

Protected function Const

FTreeMapNode...

 

FindNodeInCopiedTree

(
    const FTreeMapNodeDataRef& NodeToF...,
    const FTreeMapNodeDataRef& Origina...,
    const FTreeMapNodeDataRef& CopiedR...
)

Searches for the specified node in an identical copy of the node tree.

Protected function

FTreeMapNode...

 

FindNodeVisualUnderCursor

(
    const FGeometry& MyGeometry,
    const FVector2D& ScreenSpaceCursor...
)

Finds the node visual that's under the cursor

Public function Const

FTreeMapNode...

 

GetTreeRoot()

Returns the current tree root, which is the largest node visible

Protected function

FReply

 

InsertNewNodeAsChildOfHoveredNode

(
    const FGeometry& MyGeometry
)

Insert a new node as a child of the node under the cursor

Protected function Const

bool

 

IsNavigationTransitionActive()

Protected function Const

void

 

MakeBlendedNodeVisual

(
    const int32 VisualIndex,
    const float NavigationAlpha,
    FTreeMapNodeVisualInfo& OutVisual
)

Blends between the current visual state and the state before the last navigation transition, by the specified amount

Public function

void

 

RebuildTreeMap

(
    const bool bShouldPlayTransition
)

Refreshes the tree map from its source data.

Protected function

void

 

Redo()

Redoes the last action

Protected function

void

 

RenamingNode_OnTextCommitted

(
    const FText& NewText,
    ETextCommit::Type,
    TSharedRef< FTreeMapNodeData > Node...
)

Called when the user commits a rename change

Protected function

void

 

ReparentNode

(
    const FTreeMapNodeDataRef DroppedNo...,
    const FTreeMapNodeDataRef NewParent...
)

Reparents DroppedNode to NewParentNode (undoable!)

Public function

void

 

SetTreeRoot

(
    const FTreeMapNodeDataRef& NewRoot,
    const bool bShouldPlayTransition
)

Sets a new "active root" for the tree.

Protected function

void

 

ShowOptionsMenuAt

(
    const FPointerEvent& InMouseEvent
)

Displays a context menu at the specified location with options for configuring the tree display

Protected function

void

 

StartRenamingNode

(
    const FGeometry& MyGeometry,
    const FTreeMapNodeDataRef& NodeDat...,
    const FVector2D& RelativePosition,
    const bool bIsNewNode
)

Pops up a box to allow the user to start renaming a node's title (undoable!)

Protected function

void

 

StopRenamingNode()

Stops renaming a node, committing whatever text was entered

Protected function

void

 

TakeUndoSnapshot()

Grabs a snapshot of the current tree so we can restore it if the user performs an Undo action

Protected function

void

 

Undo()

Undoes the last action

Public function

bool

 

ZoomOut()

Zooms out, setting root to it's parent if possible, returns false if not

Overridden from SWidget

Name Description

Public function Virtual Const

FVector2D

 

ComputeDesiredSize

(
    float
)

Overwritten from SWidget.

Public function Virtual

FReply

 

OnKeyDown

(
    const FGeometry& MyGeometry,
    const FKeyEvent& InKeyEvent
)

Called after a key is pressed when this widget has focus (this event bubbles if not handled)

Public function Virtual

FReply

 

OnMouseButtonDoubleClick

(
    const FGeometry& InMyGeometry,
    const FPointerEvent& InMouseEvent
)

Called when a mouse button is double clicked. Override this in derived classes.

Public function Virtual

FReply

 

OnMouseButtonDown

(
    const FGeometry& MyGeometry,
    const FPointerEvent& MouseEvent
)

MOUSE INPUT The system calls this method to notify the widget that a mouse button was pressed within it.

Public function Virtual

FReply

 

OnMouseButtonUp

(
    const FGeometry& MyGeometry,
    const FPointerEvent& MouseEvent
)

The system calls this method to notify the widget that a mouse button was release within it.

Public function Virtual

void

 

OnMouseLeave

(
    const FPointerEvent& MouseEvent
)

The system will use this event to notify a widget that the cursor has left it.

Public function Virtual

FReply

 

OnMouseMove

(
    const FGeometry& MyGeometry,
    const FPointerEvent& MouseEvent
)

The system calls this method to notify the widget that a mouse moved within it.

Public function Virtual

FReply

 

OnMouseWheel

(
    const FGeometry& MyGeometry,
    const FPointerEvent& MouseEvent
)

Called when the mouse wheel is spun. This event is bubbled.

Public function Virtual Const

int32

 

OnPaint

(
    const FPaintArgs& Args,
    const FGeometry& AllottedGeometry,
    const FSlateRect& MyCullingRect,
    FSlateWindowElementList& OutDrawEl...,
    int32 LayerId,
    const FWidgetStyle& InWidgetStyle,
    bool bParentEnabled
)

SWidget overrides

Public function Virtual Const

bool

 

SupportsKeyboardFocus()

Checks to see if this widget supports keyboard focus. Override this in derived classes.

Public function Virtual

void

 

Tick

(
    const FGeometry& AllottedGeometry,
    const double InCurrentTime,
    const float InDeltaTime
)

Ticks this widget with Geometry.

Classes

Name

Description

Public struct

FArguments

Typedefs

Name

Description

FOnTreeMapNodeInteracted

Delegate used when clicking or interacting with a specific node

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss