Version: 2023.1
LanguageEnglish
  • C#

IExternalCodeEditor

interface in Unity.CodeEditor

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

Defines the responsibilities of handling external script editor integration into UnityEditor.

Properties

InstallationsProvide the editor with a list of known and supported editors that this instance supports.

Public Methods

InitializeCallback to the IExternalCodeEditor when it has been chosen from the PreferenceWindow.
OnGUIUnity calls this method when it populates "Preferences/External Tools" in order to allow the code editor to generate necessary GUI. For example, when creating an an argument field for modifying the arguments sent to the code editor.
OpenProjectThe external code editor needs to handle the request to open a file.
SyncAllUnity calls this function during initialization in order to sync the Project. This is different from SyncIfNeeded in that it does not get a list of changes.
SyncIfNeededWhen you change Assets in Unity, this method for the current chosen instance of IExternalCodeEditor parses the new and changed Assets.
TryGetInstallationForPathUnity stores the path of the chosen editor. An instance of IExternalCodeEditor can take responsibility for this path, by returning true when this method is being called. The out variable installation need to be constructed with the path and the name that should be shown in the "External Tools" code editor list.
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961