mirror of
https://github.com/godotengine/godot.git
synced 2025-10-20 00:13:30 +00:00
Fixed syntax highlighting setting not being saved
Fixed syntax highlighting setting not being saved
This commit is contained in:
parent
e20a28a7db
commit
4efcf9c943
2 changed files with 4 additions and 1 deletions
|
@ -66,6 +66,7 @@ void TextEditor::_change_syntax_highlighter(int p_idx) {
|
|||
el = el->next();
|
||||
}
|
||||
set_syntax_highlighter(highlighters[highlighter_menu->get_item_text(p_idx)]);
|
||||
EditorSettings::get_singleton()->set_project_metadata("text_editor", "syntax_highlighter", p_idx);
|
||||
}
|
||||
|
||||
void TextEditor::_load_theme_settings() {
|
||||
|
@ -298,7 +299,7 @@ void TextEditor::_notification(int p_what) {
|
|||
switch (p_what) {
|
||||
case NOTIFICATION_READY:
|
||||
_load_theme_settings();
|
||||
set_syntax_highlighter(NULL);
|
||||
_change_syntax_highlighter(EditorSettings::get_singleton()->get_project_metadata("text_editor", "syntax_highlighter", 0));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue