summaryrefslogtreecommitdiff
path: root/editor
diff options
context:
space:
mode:
Diffstat (limited to 'editor')
-rw-r--r--editor/animation_track_editor.cpp4
-rw-r--r--editor/editor_command_palette.cpp2
-rw-r--r--editor/editor_node.cpp32
-rw-r--r--editor/editor_node.h16
-rw-r--r--editor/import/dynamic_font_import_settings.cpp7
-rw-r--r--editor/project_converter_3_to_4.cpp2
-rw-r--r--editor/scene_tree_dock.cpp1
7 files changed, 37 insertions, 27 deletions
diff --git a/editor/animation_track_editor.cpp b/editor/animation_track_editor.cpp
index c2e04e4be9..8919d23982 100644
--- a/editor/animation_track_editor.cpp
+++ b/editor/animation_track_editor.cpp
@@ -1445,7 +1445,9 @@ void AnimationTimelineEdit::_anim_loop_pressed() {
default:
break;
}
+ undo_redo->add_do_method(this, "update_values");
undo_redo->add_undo_method(animation.ptr(), "set_loop_mode", animation->get_loop_mode());
+ undo_redo->add_undo_method(this, "update_values");
undo_redo->commit_action();
} else {
String base_path = animation->get_path();
@@ -1913,6 +1915,8 @@ void AnimationTimelineEdit::_bind_methods() {
ADD_SIGNAL(MethodInfo("timeline_changed", PropertyInfo(Variant::FLOAT, "position"), PropertyInfo(Variant::BOOL, "drag"), PropertyInfo(Variant::BOOL, "timeline_only")));
ADD_SIGNAL(MethodInfo("track_added", PropertyInfo(Variant::INT, "track")));
ADD_SIGNAL(MethodInfo("length_changed", PropertyInfo(Variant::FLOAT, "size")));
+
+ ClassDB::bind_method(D_METHOD("update_values"), &AnimationTimelineEdit::update_values);
}
AnimationTimelineEdit::AnimationTimelineEdit() {
diff --git a/editor/editor_command_palette.cpp b/editor/editor_command_palette.cpp
index ba1f2fd6af..a0913265eb 100644
--- a/editor/editor_command_palette.cpp
+++ b/editor/editor_command_palette.cpp
@@ -130,7 +130,7 @@ void EditorCommandPalette::_update_command_search(const String &search_text) {
ti->set_metadata(0, entries[i].key_name);
ti->set_text_alignment(1, HORIZONTAL_ALIGNMENT_RIGHT);
ti->set_text(1, shortcut_text);
- Color c = Color(1, 1, 1, 0.5);
+ Color c = get_theme_color(SNAME("font_color"), SNAME("Editor")) * Color(1, 1, 1, 0.5);
ti->set_custom_color(1, c);
}
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp
index 8eaddcb7e1..cf24195b5b 100644
--- a/editor/editor_node.cpp
+++ b/editor/editor_node.cpp
@@ -2763,18 +2763,7 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) {
}
} else if (extensions.size()) {
String root_name = scene->get_name();
- // Very similar to node naming logic.
- switch (ProjectSettings::get_singleton()->get("editor/scene/scene_naming").operator int()) {
- case SCENE_NAME_CASING_AUTO:
- // Use casing of the root node.
- break;
- case SCENE_NAME_CASING_PASCAL_CASE: {
- root_name = root_name.to_pascal_case();
- } break;
- case SCENE_NAME_CASING_SNAKE_CASE:
- root_name = root_name.replace("-", "_").to_snake_case();
- break;
- }
+ root_name = EditorNode::adjust_scene_name_casing(root_name);
file->set_current_path(root_name + "." + extensions.front()->get().to_lower());
}
file->popup_file_dialog();
@@ -3090,6 +3079,19 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) {
}
}
+String EditorNode::adjust_scene_name_casing(const String &root_name) {
+ switch (ProjectSettings::get_singleton()->get("editor/scene/scene_naming").operator int()) {
+ case SCENE_NAME_CASING_AUTO:
+ // Use casing of the root node.
+ break;
+ case SCENE_NAME_CASING_PASCAL_CASE:
+ return root_name.to_pascal_case();
+ case SCENE_NAME_CASING_SNAKE_CASE:
+ return root_name.replace("-", "_").to_snake_case();
+ }
+ return root_name;
+}
+
void EditorNode::_request_screenshot() {
_screenshot();
}
@@ -3668,10 +3670,6 @@ bool EditorNode::is_changing_scene() const {
return changing_scene;
}
-void EditorNode::_clear_undo_history() {
- get_undo_redo()->clear_history(false);
-}
-
void EditorNode::set_current_scene(int p_idx) {
// Save the folding in case the scene gets reloaded.
if (editor_data.get_scene_path(p_idx) != "" && editor_data.get_edited_scene_root(p_idx)) {
@@ -5981,8 +5979,6 @@ void EditorNode::_bind_methods() {
ClassDB::bind_method("_set_main_scene_state", &EditorNode::_set_main_scene_state);
ClassDB::bind_method("_update_recent_scenes", &EditorNode::_update_recent_scenes);
- ClassDB::bind_method("_clear_undo_history", &EditorNode::_clear_undo_history);
-
ClassDB::bind_method("edit_item_resource", &EditorNode::edit_item_resource);
ClassDB::bind_method(D_METHOD("get_gui_base"), &EditorNode::get_gui_base);
diff --git a/editor/editor_node.h b/editor/editor_node.h
index 200d68908c..b0299744f1 100644
--- a/editor/editor_node.h
+++ b/editor/editor_node.h
@@ -125,6 +125,12 @@ public:
EDITOR_ASSETLIB
};
+ enum SceneNameCasing {
+ SCENE_NAME_CASING_AUTO,
+ SCENE_NAME_CASING_PASCAL_CASE,
+ SCENE_NAME_CASING_SNAKE_CASE
+ };
+
struct ExecuteThreadArgs {
String path;
List<String> args;
@@ -233,12 +239,6 @@ private:
MAX_BUILD_CALLBACKS = 128
};
- enum ScriptNameCasing {
- SCENE_NAME_CASING_AUTO,
- SCENE_NAME_CASING_PASCAL_CASE,
- SCENE_NAME_CASING_SNAKE_CASE
- };
-
struct BottomPanelItem {
String name;
Control *control = nullptr;
@@ -658,8 +658,6 @@ private:
void _update_layouts_menu();
void _layout_menu_option(int p_id);
- void _clear_undo_history();
-
void _update_addon_config();
void _toggle_distraction_free_mode();
@@ -720,6 +718,8 @@ public:
static HBoxContainer *get_menu_hb() { return singleton->menu_hb; }
static VSplitContainer *get_top_split() { return singleton->top_split; }
+ static String adjust_scene_name_casing(const String &root_name);
+
static bool has_unsaved_changes() { return singleton->unsaved_cache; }
static void disambiguate_filenames(const Vector<String> p_full_paths, Vector<String> &r_filenames);
static void add_io_error(const String &p_error);
diff --git a/editor/import/dynamic_font_import_settings.cpp b/editor/import/dynamic_font_import_settings.cpp
index d1f37179f3..c1761339b2 100644
--- a/editor/import/dynamic_font_import_settings.cpp
+++ b/editor/import/dynamic_font_import_settings.cpp
@@ -302,6 +302,7 @@ static UniRange unicode_ranges[] = {
{ 0x10D00, 0x10D3F, U"Hanifi Rohingya" },
{ 0x10E60, 0x10E7F, U"Rumi Numeral Symbols" },
{ 0x10E80, 0x10EBF, U"Yezidi" },
+ { 0x10EC0, 0x10EFF, U"Arabic Extended-C" },
{ 0x10F00, 0x10F2F, U"Old Sogdian" },
{ 0x10F30, 0x10F6F, U"Sogdian" },
{ 0x10F70, 0x10FAF, U"Old Uyghur" },
@@ -333,11 +334,13 @@ static UniRange unicode_ranges[] = {
{ 0x11A50, 0x11AAF, U"Soyombo" },
{ 0x11AB0, 0x11ABF, U"Unified Canadian Aboriginal Syllabics Extended-A" },
{ 0x11AC0, 0x11AFF, U"Pau Cin Hau" },
+ { 0x11B00, 0x11B5F, U"Devanagari Extended-A" },
{ 0x11C00, 0x11C6F, U"Bhaiksuki" },
{ 0x11C70, 0x11CBF, U"Marchen" },
{ 0x11D00, 0x11D5F, U"Masaram Gondi" },
{ 0x11D60, 0x11DAF, U"Gunjala Gondi" },
{ 0x11EE0, 0x11EFF, U"Makasar" },
+ { 0x11F00, 0x11F5F, U"Kawi" },
{ 0x11FB0, 0x11FBF, U"Lisu Supplement" },
{ 0x11FC0, 0x11FFF, U"Tamil Supplement" },
{ 0x12000, 0x123FF, U"Cuneiform" },
@@ -370,6 +373,7 @@ static UniRange unicode_ranges[] = {
{ 0x1D000, 0x1D0FF, U"Byzantine Musical Symbols" },
{ 0x1D100, 0x1D1FF, U"Musical Symbols" },
{ 0x1D200, 0x1D24F, U"Ancient Greek Musical Notation" },
+ { 0x1D2C0, 0x1D2DF, U"Kaktovik Numerals" },
{ 0x1D2E0, 0x1D2FF, U"Mayan Numerals" },
{ 0x1D300, 0x1D35F, U"Tai Xuan Jing Symbols" },
{ 0x1D360, 0x1D37F, U"Counting Rod Numerals" },
@@ -377,9 +381,11 @@ static UniRange unicode_ranges[] = {
{ 0x1D800, 0x1DAAF, U"Sutton SignWriting" },
{ 0x1DF00, 0x1DFFF, U"Latin Extended-G" },
{ 0x1E000, 0x1E02F, U"Glagolitic Supplement" },
+ { 0x1E030, 0x1E08F, U"Cyrillic Extended-D" },
{ 0x1E100, 0x1E14F, U"Nyiakeng Puachue Hmong" },
{ 0x1E290, 0x1E2BF, U"Toto" },
{ 0x1E2C0, 0x1E2FF, U"Wancho" },
+ { 0x1E4D0, 0x1E4FF, U"Nag Mundari" },
{ 0x1E7E0, 0x1E7FF, U"Ethiopic Extended-B" },
{ 0x1E800, 0x1E8DF, U"Mende Kikakui" },
{ 0x1E900, 0x1E95F, U"Adlam" },
@@ -409,6 +415,7 @@ static UniRange unicode_ranges[] = {
{ 0x2CEB0, 0x2EBEF, U"CJK Unified Ideographs Extension F" },
{ 0x2F800, 0x2FA1F, U"CJK Compatibility Ideographs Supplement" },
{ 0x30000, 0x3134F, U"CJK Unified Ideographs Extension G" },
+ { 0x31350, 0x323AF, U"CJK Unified Ideographs Extension H" },
//{ 0xE0000, 0xE007F, U"Tags" },
//{ 0xE0100, 0xE01EF, U"Variation Selectors Supplement" },
{ 0xF0000, 0xFFFFF, U"Supplementary Private Use Area-A" },
diff --git a/editor/project_converter_3_to_4.cpp b/editor/project_converter_3_to_4.cpp
index 39b30b31fb..3d46864b02 100644
--- a/editor/project_converter_3_to_4.cpp
+++ b/editor/project_converter_3_to_4.cpp
@@ -3950,6 +3950,8 @@ String ProjectConverter3To4::collect_string_from_vector(Vector<String> &vector)
#else // No RegEx.
+ProjectConverter3To4::ProjectConverter3To4(int _p_maximum_file_size_kb, int _p_maximum_line_length) {}
+
int ProjectConverter3To4::convert() {
ERR_FAIL_V_MSG(ERROR_CODE, "Can't run converter for Godot 3.x projects, because RegEx module is disabled.");
}
diff --git a/editor/scene_tree_dock.cpp b/editor/scene_tree_dock.cpp
index a437245c57..7714df9c4e 100644
--- a/editor/scene_tree_dock.cpp
+++ b/editor/scene_tree_dock.cpp
@@ -916,6 +916,7 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) {
String existing;
if (extensions.size()) {
String root_name(tocopy->get_name());
+ root_name = EditorNode::adjust_scene_name_casing(root_name);
existing = root_name + "." + extensions.front()->get().to_lower();
}
new_scene_from_dialog->set_current_path(existing);