# Editor Tools

Editor Tools Function Library

A collection of functions that can be used to perform various task in the Editor and Editor Utility functions.


# Widgets

# Spawn Tab

Spawn an Editor tab with the given Editor Utility Widget.

Parameters
TabTitle: Text
WidgetPath: string
(C++ Only) TabIcon: FSlateIcon
$ ^QuillscriptEditor.EditorTools.SpawnTab 'Tab Title' /Game/Path/To/MyWidget.MyWidget

#include "Utils/EditorTools.h"
...

UEditorTools::SpawnTab(
    TXT("Tab Title"),
    "/Game/Path/To/MyWidget.MyWidget",
    FSlateIcon(InStyleSetName, "LevelEditor.Tabs.Details")
);


# Files

# Prompt Save to Text File

Prompt developer to save content to a text file.

Parameters
FileContent: string
FileName: string = "filename",
BaseDirectory: EDirectory = Custom [Custom, Project, ProjectContent, ProjectSaved, ProjectConfig, ScreenShot, Launch]
FileType: string = "Text File|*.txt"
$ ^QuillscriptEditor.EditorTools.PromptSaveToTextFile 'File Content' 'filename' Custom 'Text File\|*.txt'

#include "Utils/EditorTools.h"
...

UEditorTools::PromptSaveToTextFile(
    'File Content',
    'filename',
    EDirectory::Custom,
    'Text File|*.txt'
);

# Prompt Load Text File

Prompt developer to load content from text file(s).

Parameters
FilesContents: array[string]
SubFolderPath: string = "",
BaseDirectory: EDirectory = Custom [Custom, Project, ProjectContent, ProjectSaved, ProjectConfig, ScreenShot, Launch]
FileType: string = "Text Files|*.txt"
FileDialogFlags: EFileSelection = Single [Single, Multiple]
$ ^QuillscriptEditor.EditorTools.PromptLoadTextFile 'Sub/Folder/Path' Custom 'Text Files\|*.txt' Single

#include "Utils/EditorTools.h"
...

UEditorTools::PromptLoadTextFile(
    'Files Contents',
    'Sub/Folder/Path',
    EDirectory::Custom,
    'Text Files|*.txt',
    EFileSelection::Single
);