SSuggestionTextBox

Implements an editable text box that can show auto-complete histories and suggestions lists.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Slate

Header

/Engine/Source/Runtime/Slate/Public/Widgets/Input/SSuggestionTextBox.h

Include

#include "Widgets/Input/SSuggestionTextBox.h"

Syntax

class SSuggestionTextBox : public SCompoundWidget

Remarks

Implements an editable text box that can show auto-complete histories and suggestions lists.

Constructors

Name Description

Public function

SSuggestionTextBox()

Default constructor.

Functions

Name Description

Protected function

void

 

ClearSuggestions()

Clears the list of suggestions and hides the suggestions list.

Public function

void

 

Construct

(
    const FArguments& InArgs
)

Construct this widget. Called by the SNew()Slate macro.

Protected function

void

 

FocusTextBox()

Sets the keyboard focus to the text box.

Protected function Const

FString

 

GetSelectedSuggestionString()

Gets the string value of the currently selected suggestion.

Public function Const

FText

 

GetText()

Returns the text string.

Protected function

void

 

MarkActiveSuggestion()

Highlights the selected suggestion in the suggestion list.

Public function

void

 

SetError

(
    const FString& InError
)

Sets an optional error string.

Protected function

void

 

SetSuggestions

(
    TArray< FString >& SuggestionStrin...,
    bool InHistoryMode
)

Sets the list of suggestions.

Public function

void

 

SetText

(
    const TAttribute< FText >& InNewTe...
)

Sets the text string currently being edited

Overridden from SWidget

Name Description

Protected function Virtual

void

 

OnFocusLost

(
    const FFocusEvent& InFocusEvent
)

Called when this widget loses focus. This event does not bubble.

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 Const

bool

 

SupportsKeyboardFocus()

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

Classes

Name

Description

Public struct

FArguments

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