Instance Methodmigueldeicaza.swiftgodot 0.45.0SwiftGodot
setFavorites(dirs:)
Sets the list of favorite files and directories for this project.
EditorSettings.swift:335final func setFavorites(dirs: PackedStringArray)
Other members in extension
Type members
static let notificationEditorSettingsChanged: Int
Emitted after any editor setting has changed. It’s used by various editor plugins to update their visuals on theme changes or logic on configuration changes.
class var godotClassName: StringName
Instance members
var settingsChanged: SimpleSignal
Emitted after any editor setting has changed.
func addPropertyInfo(GDictionary
) Adds a custom property info to a property. The dictionary must contain:
func checkChangedSettingsInGroup(settingPrefix: String
) -> Bool Checks if any settings with the prefix
settingPrefix
exist in the set of changed settings. See alsogetChangedSettings
.func erase(property: String
) Erases the setting whose name is specified by
property
.func getChangedSettings(
) -> PackedStringArray Gets an array of the settings which have been changed since the last save. Note that internally
changed_settings
is cleared after a successful save, so generally the most appropriate place to use this method is when processingnotificationEditorSettingsChanged
.func getFavorites(
) -> PackedStringArray Returns the list of favorite files and directories for this project.
func getProjectMetadata(section: String, key: String, default: Variant
) -> Variant Returns project-specific metadata for the
section
andkey
specified. If the metadata doesn’t exist,default
will be returned instead. See alsosetProjectMetadata(section:key:data:)
.func getRecentDirs(
) -> PackedStringArray Returns the list of recently visited folders in the file dialog for this project.
func getSetting(name: String
) -> Variant Returns the value of the setting specified by
name
. This is equivalent to usingget(property:)
on the EditorSettings instance.func hasSetting(name: String
) -> Bool Returns
true
if the setting specified byname
exists,false
otherwise.func markSettingChanged(setting: String
) Marks the passed editor setting as being changed, see
getChangedSettings
. Only settings which exist (seehasSetting(name:)
) will be accepted.func setBuiltinActionOverride(name: String, actionsList: ObjectCollection<InputEvent>
) Overrides the built-in editor action
name
with the input actions defined inactionsList
.func setInitialValue(name: StringName, value: Variant, updateCurrent: Bool
) Sets the initial value of the setting specified by
name
tovalue
. This is used to provide a value for the Revert button in the Editor Settings. IfupdateCurrent
is true, the current value of the setting will be set tovalue
as well.func setProjectMetadata(section: String, key: String, data: Variant
) Sets project-specific metadata with the
section
,key
anddata
specified. This metadata is stored outside the project folder and therefore won’t be checked into version control. See alsogetProjectMetadata(section:key:`default`:)
.func setRecentDirs(PackedStringArray
) Sets the list of recently visited folders in the file dialog for this project.
func setSetting(name: String, value: Variant
) Sets the
value
of the setting specified byname
. This is equivalent to usingset(property:value:)
on the EditorSettings instance.