mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 06:01:14 +00:00
Make script templates follow the GDScript style guide
This commit is contained in:
parent
a0071029f2
commit
42df9ed059
11 changed files with 41 additions and 16 deletions
|
|
@ -68,14 +68,21 @@ Ref<Script> GDScriptLanguage::make_template(const String &p_template, const Stri
|
|||
if (!EDITOR_GET("text_editor/completion/add_type_hints")) {
|
||||
processed_template = processed_template.replace(": int", "")
|
||||
.replace(": String", "")
|
||||
.replace(": Array[String]", "")
|
||||
.replace(": float", "")
|
||||
.replace(":=", "=")
|
||||
.replace(" -> String", "")
|
||||
.replace(" -> int", "")
|
||||
.replace(" -> void", "");
|
||||
}
|
||||
#else
|
||||
processed_template = processed_template.replace(": int", "")
|
||||
.replace(": String", "")
|
||||
.replace(": Array[String]", "")
|
||||
.replace(": float", "")
|
||||
.replace(":=", "=")
|
||||
.replace(" -> String", "")
|
||||
.replace(" -> int", "")
|
||||
.replace(" -> void", "");
|
||||
#endif
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue