Navigation
API > API/Editor > API/Editor/UnrealEd
A helper class to store the state of the various editor modes.
| Name | FEditorModeTools |
| Type | class |
| Header File | /Engine/Source/Editor/UnrealEd/Public/EditorModeManager.h |
| Include Path | #include "EditorModeManager.h" |
Syntax
class FEditorModeTools :
public FGCObject ,
public FEditorUndoClient ,
public TSharedFromThis< FEditorModeTools >
Inheritance Hierarchy
- FGCObject → FEditorModeTools
- FEditorUndoClient → FEditorModeTools
- FSharedFromThisBase → TSharedFromThis → FEditorModeTools
Derived Classes
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FEditorModeTools() |
EditorModeManager.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FEditorModeTools() |
EditorModeManager.h |
Classes
| Name | Remarks |
|---|---|
| FCoordSystemChangedEvent | Delegate type for triggering when coordinate system changed |
| FEditorModeIDChangedEvent | Multicast delegate for OnModeEntered and OnModeExited callbacks. |
| FIsEditingDisallowedChangedEvent | Delegate type for triggering when a mode Editing Disallowed changed |
| FWidgetModeChangedEvent | Delegate type for triggering when widget mode changed |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| CVarEnableITFCursorOverrideSupport | TAutoConsoleVariable< int32 > | EditorModeManager.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| CachedLocation | FVector | EditorModeManager.h | ||
| GridBase | FVector | EditorModeManager.h | ||
| InfoString | FString | Draws in the top level corner of all FEditorViewportClient windows (can be used to relay info to the user). | EditorModeManager.h | |
| PivotLocation | FVector | EditorModeManager.h | ||
| PivotShown | bool | EditorModeManager.h | ||
| SnappedActor | bool | EditorModeManager.h | ||
| SnappedLocation | FVector | EditorModeManager.h | ||
| Snapping | bool | EditorModeManager.h | ||
| TranslateRotate2DAngle | float | The angles for the 2d translate rotate widget | EditorModeManager.h | |
| TranslateRotateXAxisAngle | float | The angle for the translate rotate widget | EditorModeManager.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bHasOngoingTransform | bool | Flag to track if we started a new TRS gizmo transform. | EditorModeManager.h | |
| bIsExitingModesDuringTick | bool | Guard to prevent modes from entering as part of their exit routine | EditorModeManager.h | |
| bIsTracking | bool | Flag set between calls to StartTracking() and EndTracking() | EditorModeManager.h | |
| CoordSystem | ECoordSystem | The coordinate system the widget is operating within. | EditorModeManager.h | |
| CoordSystemChangedEvent | FCoordSystemChangedEvent | Multicast delegate that is broadcast when the coordinate system is changed | EditorModeManager.h | |
| EditorModeIDChangedEvent | FEditorModeIDChangedEvent | Multicast delegate that is broadcast when a mode is entered or exited | EditorModeManager.h | |
| FocusedViewportClient | FEditorViewportClient * | EditorModeManager.h | ||
| HoveredViewportClient | FEditorViewportClient * | EditorModeManager.h | ||
| IsEditingDisallowedChangedEvent | FIsEditingDisallowedChangedEvent | Multicast delegate that is broadcast when a mode Editing Disallowed changed | EditorModeManager.h | |
| StoredSelectionSets | TMap< FName, FTypedElementSelectionSetState > | EditorModeManager.h | ||
| WeakGizmoContext | TWeakObjectPtr< UEditorTransformGizmoContextObject > | GizmoContext used to get context specific gizmo properties. | EditorModeManager.h | |
| WeakGizmoStateTarget | TWeakObjectPtr< UEditorGizmoStateTarget > | GizmoStateTarget used to handle a new TRS gizmo transform begin/end sequence. | EditorModeManager.h | |
| WidgetModeChangedEvent | FWidgetModeChangedEvent | Multicast delegate that is broadcast when a widget mode is changed | EditorModeManager.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void ActivateDefaultMode () |
Activates the default modes defined by this class. | EditorModeManager.h | |
void ActivateMode
(
FEditorModeID InID, |
Activates an editor mode. | EditorModeManager.h | |
void ActorMoveNotify() |
EditorModeManager.h | ||
void ActorPropChangeNotify() |
EditorModeManager.h | ||
| EditorModeManager.h | |||
void ActorSelectionChangeNotify() |
EditorModeManager.h | ||
void AddDefaultMode
(
const FEditorModeID DefaultModeID |
Adds a new default mode to this tool's list of default modes. | EditorModeManager.h | |
bool AllowsViewportDragTool() |
EditorModeManager.h | ||
bool AllowWidgetMove() |
True if we should allow widget movetrue if we should allow widget move | EditorModeManager.h | |
bool BeginTransform
(
const FGizmoState& InState |
EditorModeManager.h | ||
bool BoxSelect
(
FBox& InBox, |
Notifies all active modes of box selection attempts | EditorModeManager.h | |
void BroadcastCoordSystemChanged
(
ECoordSystem InCoordSystem |
Broadcasts the CoordSystemChangedEvent event | EditorModeManager.h | |
void BroadcastEditorModeIDChanged
(
const FEditorModeID& ModeID, |
Broadcasts the EditorModeIDChanged event | EditorModeManager.h | |
void BroadcastIsEditingDisallowedChanged() |
Broadcasts the IsEditingDisallowedChangedEvent event | EditorModeManager.h | |
void BroadcastWidgetModeChanged
(
UE::Widget::EWidgetMode InWidgetMode |
Broadcasts the WidgetModeChanged event | EditorModeManager.h | |
bool CanAutoSave() |
Sets the active Modes ToolBar Palette Tab to the named Palette returns true if all active EdModes are OK with an AutoSave happening now | EditorModeManager.h | |
bool CanCycleWidgetMode() |
Check with modes to see if the widget mode can be cycled | EditorModeManager.h | |
bool CapturedMouseMove
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of captured mouse movement | EditorModeManager.h | |
bool ComputeBoundingBoxForViewportFocus
(
AActor* Actor, |
Allows editor modes to override the bounding box used to focus the viewport on a selection | EditorModeManager.h | |
void CycleWidgetMode() |
Cycle the widget mode, forwarding queries to modesUsed to cycle widget modes | EditorModeManager.h | |
void DeactivateAllModes() |
Deactivates all modes, note some modes can never be deactivated. | EditorModeManager.h | |
void DeactivateMode
(
FEditorModeID InID |
Deactivates an editor mode. | EditorModeManager.h | |
void DeactivateOtherVisibleModes
(
FEditorModeID InMode |
EditorModeManager.h | ||
void DestroyMode
(
FEditorModeID InID |
Deactivate the mode and entirely purge it from memory. Used when a mode type is unregistered | EditorModeManager.h | |
bool DisallowMouseDeltaTracking() |
True if we should disallow mouse delta tracking. | EditorModeManager.h | |
void DrawActiveModes
(
const FSceneView* InView, |
Draws all active modesDraws all active mode components | EditorModeManager.h | |
void DrawHUD
(
FEditorViewportClient* InViewportClient, |
Draws the HUD for all active modes | EditorModeManager.h | |
void ElementSelectionChangeNotify() |
EditorModeManager.h | ||
bool EndTracking
(
FEditorViewportClient* InViewportClient, |
Mouse tracking interface. Passes tracking messages to all active modes | EditorModeManager.h | |
bool EndTransform
(
const FGizmoState& InState |
EditorModeManager.h | ||
bool EnsureNotInMode
(
FEditorModeID ModeID, |
Returns true if the current mode is not the specified ModeID. Also optionally warns the user. | EditorModeManager.h | |
bool FrustumSelect
(
const FConvexVolume& InFrustum, |
Notifies all active modes of frustum selection attempts | EditorModeManager.h | |
EEditAction::Type GetActionEditCopy() |
EditorModeManager.h | ||
EEditAction::Type GetActionEditCut() |
EditorModeManager.h | ||
EEditAction::Type GetActionEditDelete() |
EditorModeManager.h | ||
EEditAction::Type GetActionEditDuplicate() |
EditorModeManager.h | ||
EEditAction::Type GetActionEditPaste() |
EditorModeManager.h | ||
const FEdMode * GetActiveMode
(
FEditorModeID InID |
EditorModeManager.h | ||
FEdMode * GetActiveMode
(
FEditorModeID InID |
Returns a pointer to an active mode specified by the passed in ID If the editor mode is not active, NULL is returned | EditorModeManager.h | |
const SpecificModeType * GetActiveModeTyped
(
FEditorModeID InID |
EditorModeManager.h | ||
SpecificModeType * GetActiveModeTyped
(
FEditorModeID InID |
EditorModeManager.h | ||
UEdMode * GetActiveScriptableMode
(
FEditorModeID InID |
EditorModeManager.h | ||
const FModeTool * GetActiveTool
(
FEditorModeID InID |
Returns the active tool of the passed in editor mode. | EditorModeManager.h | |
ECoordSystem GetCoordSystem
(
bool bGetRawValue |
Returns the current CoordSystem | EditorModeManager.h | |
bool GetCursor
(
EMouseCursor::Type& OutCursor |
Get a cursor to override the default with, if any | EditorModeManager.h | |
FMatrix GetCustomDrawingCoordinateSystem() |
EditorModeManager.h | ||
FMatrix GetCustomInputCoordinateSystem() |
EditorModeManager.h | ||
virtual UTypedElementSelectionSet * GetEditorSelectionSet() |
Returns the selection set for the toolkit host. (i.e. the selection set for the level editor) | EditorModeManager.h | |
FMatrix GetExplicitCoordinateSystem() |
EditorModeManager.h | ||
FEditorViewportClient * GetFocusedViewportClient() |
Returns the currently focused viewport client | EditorModeManager.h | |
UEditorTransformGizmoContextObject * GetGizmoContext() |
EditorModeManager.h | ||
IGizmoStateTarget * GetGizmoStateTarget() |
Begin New TRS Gizmo interface | EditorModeManager.h | |
FEditorViewportClient * GetHoveredViewportClient() |
Returns the currently hovered viewport client | EditorModeManager.h | |
UModeManagerInteractiveToolsContext * GetInteractiveToolsContext() |
EditorModeManager.h | ||
FMatrix GetLocalCoordinateSystem() |
EditorModeManager.h | ||
bool GetOverrideCursorVisibility
(
bool& bWantsOverride, |
Get override cursor visibility settings | EditorModeManager.h | |
FMatrix GetParentSpaceCoordinateSystem() |
EditorModeManager.h | ||
bool GetPivotForOrbit
(
FVector& OutPivot |
Get a pivot point specified by any active modes around which the camera should orbit | EditorModeManager.h | |
const FRotationContext & GetRotationContext() |
EditorModeManager.h | ||
virtual USelection * GetSelectedActors() |
Returns the set of selected actors. | EditorModeManager.h | |
virtual USelection * GetSelectedComponents() |
Returns the set of selected components. | EditorModeManager.h | |
virtual USelection * GetSelectedObjects() |
EditorModeManager.h | ||
bool GetShowWidget() |
EditorModeManager.h | ||
TSharedPtr< IToolkitHost > GetToolkitHost() |
Returns the host for toolkits created via modes from this mode manager | EditorModeManager.h | |
virtual UTexture2D * GetVertexTexture() |
EditorModeManager.h | ||
EAxisList::Type GetWidgetAxisToDraw
(
UE::Widget::EWidgetMode InWidgetMode |
Gets the widget axis to be drawn | EditorModeManager.h | |
FVector GetWidgetLocation() |
Returns a good location to draw the widget at. | EditorModeManager.h | |
UE::Widget::EWidgetMode GetWidgetMode() |
Retrieves the current widget mode, taking overrides into account. | EditorModeManager.h | |
float GetWidgetScale() |
Get Widget ScaleGet Scale On The Widget | EditorModeManager.h | |
virtual UWorld * GetWorld() |
Returns the world that is being edited by this mode manager | EditorModeManager.h | |
bool HandleClick
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of mouse click messages. | EditorModeManager.h | |
bool HasOngoingTransform() |
EditorModeManager.h | ||
bool HasToolkitHost() |
Check if toolkit host exists | EditorModeManager.h | |
bool InputAxis
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of axis movement | EditorModeManager.h | |
bool InputDelta
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of any change in mouse movement | EditorModeManager.h | |
bool InputKey
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of keyboard input | EditorModeManager.h | |
bool IsDefaultMode
(
const FEditorModeID ModeID |
Returns whether or not the provided mode ID is a default mode | EditorModeManager.h | |
bool IsDefaultModeActive () |
Returns true if the default modes are active. | EditorModeManager.h | |
bool IsEditingDisallowed
(
AActor* InActor |
EditorModeManager.h | ||
bool IsModeActive
(
FEditorModeID InID |
Returns true if the passed in editor mode is active | EditorModeManager.h | |
bool IsOnlyActiveMode
(
FEditorModeID InMode |
EditorModeManager.h | ||
bool IsOnlyVisibleActiveMode
(
FEditorModeID InMode |
EditorModeManager.h | ||
bool IsOperationSupportedForCurrentAsset
(
EAssetOperation InOperation |
Returns true if all active EdModes are OK support operation on current asset | EditorModeManager.h | |
bool IsSelectionAllowed
(
AActor* InActor, |
EditorModeManager.h | ||
bool IsSelectionHandled
(
AActor* InActor, |
EditorModeManager.h | ||
bool IsSnapRotationEnabled() |
EditorModeManager.h | ||
bool IsTracking() |
EditorModeManager.h | ||
bool IsViewportUIHidden() |
Is the viewport UI hidden? | EditorModeManager.h | |
void LoadConfig() |
Loads the state that was saved in the INI file | EditorModeManager.h | |
void LoadWidgetSettings() |
Load Widget Settings from Ini file | EditorModeManager.h | |
bool LostFocus
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes that a viewport has lost focus | EditorModeManager.h | |
void MapChangeNotify() |
Notifies all active modes that a map change has occured | EditorModeManager.h | |
TSharedPtr< SWidget > MapCursor() |
Called to map a cursor reply to an actual widget to render. | EditorModeManager.h | |
bool MouseEnter
(
FEditorViewportClient* InViewportClient, |
EditorModeManager.h | ||
bool MouseLeave
(
FEditorViewportClient* InViewportClient, |
EditorModeManager.h | ||
bool MouseMove
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes that the mouse has moved | EditorModeManager.h | |
FCoordSystemChangedEvent & OnCoordSystemChanged() |
EditorModeManager.h | ||
FEditorModeIDChangedEvent & OnEditorModeIDChanged() |
EditorModeManager.h | ||
FIsEditingDisallowedChangedEvent & OnIsEditingDisallowedChanged() |
EditorModeManager.h | ||
bool OnRequestClose() |
Called by Editors when they are about to close | EditorModeManager.h | |
FWidgetModeChangedEvent & OnWidgetModeChanged() |
EditorModeManager.h | ||
bool PostConvertMouseMovement
(
FEditorViewportClient* InViewportClient |
Called after converting mouse movement to drag/rot | EditorModeManager.h | |
bool PreConvertMouseMovement
(
FEditorViewportClient* InViewportClient |
Called before converting mouse movement to drag/rot | EditorModeManager.h | |
bool ProcessCapturedMouseMoves
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes of all captured mouse movement | EditorModeManager.h | |
bool ProcessEditCopy() |
EditorModeManager.h | ||
bool ProcessEditCut() |
EditorModeManager.h | ||
bool ProcessEditDelete() |
EditorModeManager.h | ||
bool ProcessEditDuplicate() |
EditorModeManager.h | ||
bool ProcessEditPaste() |
EditorModeManager.h | ||
bool ReceivedFocus
(
FEditorViewportClient* InViewportClient, |
Notifies all active modes that a viewport has received focus | EditorModeManager.h | |
void RemoveAllDelegateHandlers() |
EditorModeManager.h | ||
void RemoveDefaultMode
(
const FEditorModeID DefaultModeID |
Removes a default mode | EditorModeManager.h | |
void Render
(
const FSceneView* InView, |
Renders all active modes | EditorModeManager.h | |
void RestoreSelection
(
FName SelectionStoreKey |
Restores the selection to the state that was stored using the given key. | EditorModeManager.h | |
void SaveConfig() |
Saves the current state to the INI file | EditorModeManager.h | |
void SaveWidgetSettings() |
Save Widget Settings to Ini file | EditorModeManager.h | |
bool SelectionHasSceneComponent() |
Whether or not the current selection has a scene component selected | EditorModeManager.h | |
void SelectNone() |
Notifies all active modes to empty their selections | EditorModeManager.h | |
void SetCoordSystem
(
ECoordSystem NewCoordSystem |
Sets the current CoordSystem | EditorModeManager.h | |
void SetCurrentWidgetAxis
(
EAxisList::Type NewAxis |
Sets the current widget axis | EditorModeManager.h | |
void SetDefaultMode
(
const FEditorModeID DefaultModeID |
Set the default editor mode for these tools | EditorModeManager.h | |
void SetHideViewportUI
(
bool bInHideViewportUI |
Sets the hide viewport UI state | EditorModeManager.h | |
void SetPivotLocation
(
const FVector& Location, |
Sets the pivot locations | EditorModeManager.h | |
void SetSelectionHasSceneComponent
(
bool bHasSceneComponent |
EditorModeManager.h | ||
void SetShowWidget
(
bool InShowWidget |
EditorModeManager.h | ||
void SetToolkitHost
(
TSharedRef< IToolkitHost > Host |
Sets the host for toolkits created via modes from this mode manager (can only be called once) | EditorModeManager.h | |
void SetWidgetMode
(
UE::Widget::EWidgetMode InWidgetMode |
Changes the current widget mode. | EditorModeManager.h | |
void SetWidgetModeOverride
(
UE::Widget::EWidgetMode InWidgetMode |
Allows you to temporarily override the widget mode. | EditorModeManager.h | |
void SetWidgetScale
(
float InScale |
Set Scale On The Widget | EditorModeManager.h | |
bool ShouldDrawBrushVertices() |
True if brush vertices should be drawn | EditorModeManager.h | |
bool ShouldDrawBrushWireframe
(
AActor* InActor |
True if the passed in brush actor should be drawn in wireframe | EditorModeManager.h | |
bool ShouldShowModeToolbox() |
Whether or not the mode toolbox (where mode details panels and some tools are) should be shown. | EditorModeManager.h | |
bool SnapRotatorToGridOverride
(
FRotator& InRotation |
EditorModeManager.h | ||
bool StartTracking
(
FEditorViewportClient* InViewportClient, |
Mouse tracking interface. Passes tracking messages to all active modes | EditorModeManager.h | |
void StoreSelection
(
FName SelectionStoreKey, |
Stores the current selection under the given key, and clears the current selection state if requested. | EditorModeManager.h | |
void Tick
(
FEditorViewportClient* ViewportClient, |
Ticks all active modes | EditorModeManager.h | |
void UpdateInternalData() |
EditorModeManager.h | ||
bool UsesTransformWidget () |
True if any active mode uses a transform widget | EditorModeManager.h | |
bool UsesTransformWidget
(
UE::Widget::EWidgetMode CheckMode |
True if any active mode uses the passed in transform widget | EditorModeManager.h |
Overridden from FGCObject
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AddReferencedObjects
(
FReferenceCollector& Collector |
EditorModeManager.h | ||
virtual FString GetReferencerName() |
EditorModeManager.h |
Overridden from FEditorUndoClient
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void PostRedo
(
bool bSuccess |
Signal that client should run any PostRedo code | EditorModeManager.h | |
virtual void PostUndo
(
bool bSuccess |
Begin FEditorUndoClient. | EditorModeManager.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void DeactivateModeAtIndex
(
int32 Index |
EditorModeManager.h | ||
virtual void DrawBrackets
(
FEditorViewportClient* ViewportClient, |
EditorModeManager.h | ||
void ExitAllModesPendingDeactivate() |
EditorModeManager.h | ||
void ExitMode
(
UEdMode* InMode |
Exits the given editor mode | EditorModeManager.h | |
void ForEachEdMode
(
TFunctionRef< bool(InterfaceToCastTo*)> InCallback |
EditorModeManager.h | ||
void ForEachEdMode
(
TFunctionRef< bool(UEdMode*)> InCalllback |
EditorModeManager.h | ||
FMatrix GetCustomCoordinateSystem
(
TUniqueFunction< void(const TTypedElement< ITypedElementWorldInterface >&, FTransform&)>&& InGetT... |
Returns the custom coordinate matrix using a callback-type request. | EditorModeManager.h | |
void OnEditorSelectionChanged
(
UObject* NewSelection |
End New TRS Gizmo interface Delegate handlers | EditorModeManager.h | |
void OnEditorSelectNone() |
EditorModeManager.h | ||
void OnModeUnregistered
(
FEditorModeID ModeID |
Removes the mode ID from the tools manager when a mode is unregistered | EditorModeManager.h | |
void OnWorldCleanup
(
UWorld* InWorld, |
Handles the notification when a world is going through GC to clean up any modes pending deactivation. | EditorModeManager.h | |
bool TestAllModes
(
TFunctionRef< bool(UEdMode*)> InCalllback, |
EditorModeManager.h |