Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
GDScriptSyntaxHighlighter
繼承: EditorSyntaxHighlighter < SyntaxHighlighter < Resource < RefCounted < Object
可用於 TextEdit 和 CodeEdit 節點的 GDScript 語法高亮元件。
說明
注意:此類別僅能用於編輯器外掛,因其依賴於編輯器設定。
var code_preview = TextEdit.new()
var highlighter = GDScriptSyntaxHighlighter.new()
code_preview.syntax_highlighter = highlighter
var codePreview = new TextEdit();
var highlighter = new GDScriptSyntaxHighlighter();
codePreview.SyntaxHighlighter = highlighter;