SCurveEditor

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

UnrealEd

Header

/Engine/Source/Editor/UnrealEd/Public/SCurveEditor.h

Include

#include "SCurveEditor.h"

Syntax

class SCurveEditor :
    public SCompoundWidget,
    public FGCObject,
    public FEditorUndoClient

Variables

Name Description

Protected variable

TAttribute< boo...

 

bAreCurvesVisible

Whether or not curves are being displayed

Protected variable

TAttribute< boo...

 

bInputSnappingEnabled

Whether or not input snapping is enabled.

Protected variable

bool

 

bIsUsingSlider

True if the sliders are being used to adjust point values

Protected variable

TAttribute< boo...

 

bOutputSnappingEnabled

Whether or not output snapping is enabled.

Protected variable

bool

 

bShowCurveSelector

Whether or not to show the curve selector widgets.

Protected variable

TAttribute< boo...

 

bShowTimeInFrames

Show time in frames.

Protected variable

bool

 

bShowZoomButtons

True if the internal zoom buttons should be visible.

Protected variable

bool

 

bZoomToFitHorizontal

True if you want the curve editor to fit to zoom

Protected variable

bool

 

bZoomToFitVertical

True if you want the curve editor to fit to zoom

Protected variable

TSharedPtr< STo...

 

CurveToolTip

The tooltip control for the curves.

Protected variable

FText

 

CurveToolTipInputText

The text for the input portion of the tooltip.

Protected variable

FText

 

CurveToolTipNameText

The text for the name portion of the tooltip.

Protected variable

FText

 

CurveToolTipOutputText

The text for the output portion of the tooltip.

Protected variable

TArray< TShared...

 

CurveViewModels

The view models for the curves.

Protected variable

FKeyHandle

 

DraggedKeyHandle

A handle to the key which was clicked to start a key drag operation.

Protected variable

EDragState

 

DragState

The state of the current drag operation happening with the widget, if any.

Protected variable

float

 

DragThreshold

The number of pixels which the mouse must move before a drag operation starts.

Protected variable

TWeakPtr< IMenu...

 

EntryPopupMenu

Generic Popup Entry

Protected variable

FLinearColor

 

GridColor

The color used to draw the grid lines.

Protected variable

FText

 

InputAxisName

The text to display for the input axis.

Protected variable

FText

 

InputFrameAxisName

The text to display for the input (frame) axis.

Protected variable

TAttribute< flo...

 

InputSnap

The snapping value for the input domain.

Protected variable

FVector2D

 

MouseDownLocation

The location of mouse during the last OnMouseButtonDown callback in widget local coordinates.

Protected variable

FVector2D

 

MouseMoveLocation

The location of the mouse during the last OnMouseMove callback in widget local coordinates.

Protected variable

EMovementAxisLo...

 

MovementAxisLock

The movement axis lock state

Protected variable

FText

 

OutputAxisName

The text to display for the output axis.

Protected variable

TAttribute< flo...

 

OutputSnap

The snapping value for the output domain.

Protected variable

TMap< FKeyHandl...

 

PreDragKeyLocations

A map of selected key handle to their starting locations at the beginning of a drag operation.

Protected variable

TMap< FKeyHandl...

 

PreDragTangents

A map of selected key handles to their tangent values at the beginning of a drag operation.

Protected variable

float

 

ReduceTolerance

The tolerance to use when reducing curves

Protected variable

TAttribute< flo...

 

TimelineLength

How long the overall timeline is

Protected variable

TAttribute< flo...

 

ViewMaxInput

Maximum input of view range

Protected variable

TAttribute< flo...

 

ViewMaxOutput

Min output view range

Protected variable

TAttribute< flo...

 

ViewMinInput

Minimum input of view range

Protected variable

TAttribute< flo...

 

ViewMinOutput

Max output view range

Destructors

Name Description

Public function

~SCurveEditor()

Destructor

Functions

Name Description

Protected function Const

bool

 

AnyCurveViewModelsSelected()

Return whether any curve view models are selected

Protected function

void

 

ClearSelectedCurveViewModels()

Clear the selected curve view models

Protected function

void

 

CloseEntryPopupMenu()

Closes the popup created by GenericTextEntryModeless

Public function

void

 

Construct

(
    const FArguments& InArgs
)

Public function

UObject *...

 

CreateCurveObject

(
    TSubclassOf< UCurveBase > CurveType,
    UObject* PackagePtr,
    FName& AssetName
)

Function to create a curve object and return its reference.

Protected function Const

float

 

FrameToTime

(
    int32 InFrame
)

Protected function

void

 

GenericTextEntryModeless

(
    const FText& DialogText,
    const FText& DefaultText,
    FOnTextCommitted OnTextComitted
)

Modeless Version of the String Entry Box

Public function Const

bool

 

GetAllowAutoFrame()

Gets or sets whether autoframing is allowed

Public function Const

bool

 

GetAutoFrame()

Gets whether autoframe will be invoked (combination of allow auto frame and curve editor auto frame setting)

Public function

TSharedPtr< ...

 

GetCommands()

Gets a list of the commands handled by this control

Public function

UCurveFactor...

 

GetCurveFactory()

Construct an object of type UCurveFactory and return it's reference

Public function Const

FCurveOwnerI...

 

GetCurveOwner()

Get the currently edited curve

Public function Const

TArray< FRea...

 

GetCurvesToFit()

Get the curves to will be used during a fit operation

Protected function Const

UCurveEditor...

 

GetSettings()

Access the user-supplied settings object

Protected function Virtual Const

float

 

GetTimeStep

(
    FTrackScaleInfo& ScaleInfo
)

Get Time Step for vertical line drawing

Public function

void

 

SetAllowAutoFrame

(
    bool bInAllowAutoFrame
)

Public function

void

 

SetCurveOwner

(
    FCurveOwnerInterface* InCurveO...,
    bool bCanEdit
)

Set the curve that is being edited by this track widget.

Protected function Virtual

void

 

SetDefaultOutput

(
    const float MinZoomRange
)

Set Default output values when range is too small

Protected function

void

 

SetInputMinMax

(
    float NewMin,
    float NewMax
)

Update view range

Protected function

void

 

SetOutputMinMax

(
    float NewMin,
    float NewMax
)

Public function

void

 

SetRequireFocusToZoom

(
    bool bInRequireFocusToZoom
)

Set flag that allows scrolling up/down over the widget from the outside without it handling the scroll wheel event

Protected function

void

 

SetSelectedCurveViewModel

(
    FRealCurve* Curve
)

Set the selected curve view model that matches the rich curve

Public function

void

 

SetZoomToFit

(
    bool bNewZoomToFitVertical,
    bool bNewZoomToFitHorizontal
)

Set new zoom to fit

Protected function Const

int32

 

TimeToFrame

(
    float InTime
)

Convert time to frames and vice versa

Protected function

void

 

ValidateSelection()

Ensure that selected keys and tangents are still valid

Public function

void

 

ZoomToFit

(
    const bool bZoomToFitAll
)

Public function

void

 

ZoomToFitHorizontal

(
    const bool bZoomToFitAll
)

Zoom to fit

Public function

void

 

ZoomToFitVertical

(
    const bool bZoomToFitAll
)

Overridden from SWidget

Name Description

Protected 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)

Protected 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.

Protected 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.

Protected function Virtual

void

 

OnMouseCaptureLost

(
    const FCaptureLostEvent& CaptureLo...
)

Called when this widget had captured the mouse, but that capture has been revoked for some reason.

Protected 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.

Protected function Virtual

FReply

 

OnMouseWheel

(
    const FGeometry& MyGeometry,
    const FPointerEvent& MouseEvent
)

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

Protected function Virtual Const

int32

 

OnPaint

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

The widget should respond by populating the OutDrawElements array with FDrawElements that represent it and any of its children.

Public function Virtual Const

TOptional< b...

 

OnQueryShowFocus

(
    const EFocusCause InFocusCause
)

Called to determine if we should render the focus brush.

Overridden from FGCObject

Name Description

Public function Virtual

void

 

AddReferencedObjects

(
    FReferenceCollector& Collector
)

Since we create a UFactory object, it needs to be serialized

Classes

Name

Description

Public struct

FArguments

Enums

Name

Description

Private enum

EDragState

Represents the different states of a drag operation

Private enum

EMovementAxisLock

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