diff options
Diffstat (limited to 'editor')
404 files changed, 21865 insertions, 8618 deletions
diff --git a/editor/SCsub b/editor/SCsub index d7392f8249..c46e443534 100644 --- a/editor/SCsub +++ b/editor/SCsub @@ -141,6 +141,30 @@ def make_translations_header(target, source, env): g.write("#endif") +def make_authors_header(target, source, env): + + src = source[0].srcnode().abspath + dst = target[0].srcnode().abspath + f = open(src, "rb") + g = open(dst, "wb") + + g.write("/* THIS FILE IS GENERATED DO NOT EDIT */\n") + g.write("#ifndef _EDITOR_AUTHORS_H\n") + g.write("#define _EDITOR_AUTHORS_H\n") + g.write("static const char *dev_names[] = {\n") + + name_count = -1 + for line in f: + if name_count >= 0: + if line.startswith(" "): + g.write("\t\"" + line.strip() + "\",\n") + name_count += 1 + elif line.strip() == "## Developers": + name_count = 0 + g.write("\t0\n") + g.write("};\n") + g.write("#define AUTHORS_COUNT " + str(name_count) + "\n") + g.write("#endif\n") if (env["tools"] == "yes"): @@ -188,6 +212,10 @@ if (env["tools"] == "yes"): env.Depends('#editor/builtin_fonts.h', flist) env.Command('#editor/builtin_fonts.h', flist, make_fonts_header) + # Authors + env.Depends('#editor/authors.h', "../AUTHORS.md") + env.Command('#editor/authors.h', "../AUTHORS.md", make_authors_header) + env.add_source_files(env.editor_sources, "*.cpp") diff --git a/editor/animation_editor.cpp b/editor/animation_editor.cpp index 447f57a73f..1798e66e8a 100644 --- a/editor/animation_editor.cpp +++ b/editor/animation_editor.cpp @@ -76,7 +76,7 @@ private: Ref<StyleBox> sb = get_stylebox("normal", "LineEdit"); sb->draw(ci, r); r.size -= sb->get_minimum_size(); - r.pos += sb->get_offset(); + r.position += sb->get_offset(); //VisualServer::get_singleton()->canvas_item_add Ref<Font> f = get_font("font", "Label"); @@ -111,7 +111,7 @@ private: iflp = 1.0 - iflp; } - VisualServer::get_singleton()->canvas_item_add_line(ci, r.pos + Point2(iflp * r.size.width, prev * r.size.height), r.pos + Point2(ifl * r.size.width, h * r.size.height), mcolor); + VisualServer::get_singleton()->canvas_item_add_line(ci, r.position + Point2(iflp * r.size.width, prev * r.size.height), r.position + Point2(ifl * r.size.width, h * r.size.height), mcolor); prev = h; } @@ -138,7 +138,7 @@ private: iflp = 1.0 - iflp; } - VisualServer::get_singleton()->canvas_item_add_line(ci, r.pos + Point2(iflp * r.size.width, prev * r.size.height), r.pos + Point2(ifl * r.size.width, h * r.size.height), color); + VisualServer::get_singleton()->canvas_item_add_line(ci, r.position + Point2(iflp * r.size.width, prev * r.size.height), r.position + Point2(ifl * r.size.width, h * r.size.height), color); prev = h; } } @@ -154,13 +154,15 @@ private: } } - void _gui_input(const InputEvent &p_ev) { - if (p_ev.type == InputEvent::MOUSE_MOTION && p_ev.mouse_motion.button_mask & BUTTON_MASK_LEFT) { + void _gui_input(const Ref<InputEvent> &p_ev) { + + Ref<InputEventMouseMotion> mm = p_ev; + if (mm.is_valid() && mm->get_button_mask() & BUTTON_MASK_LEFT) { if (mode == MODE_DISABLED) return; - float rel = p_ev.mouse_motion.relative_x; + float rel = mm->get_relative().x; if (rel == 0) return; @@ -1035,7 +1037,7 @@ void AnimationKeyEditor::_track_pos_draw() { //draw position int pixel = (timeline_pos - h_scroll->get_value()) * zoom_scale; pixel += name_limit; - track_pos->draw_line(ofs + Point2(pixel, 0), ofs + Point2(pixel, size.height), Color(1, 0.3, 0.3, 0.8)); + track_pos->draw_line(ofs + Point2(pixel, 0), ofs + Point2(pixel, size.height), get_color("highlight_color", "Editor")); } } @@ -1089,13 +1091,12 @@ void AnimationKeyEditor::_track_editor_draw() { int sep = get_constant("vseparation", "Tree"); int hsep = get_constant("hseparation", "Tree"); Color color = get_color("font_color", "Tree"); - Color sepcolor = get_color("guide_color", "Tree"); - Color timecolor = get_color("prop_subsection", "Editor"); - timecolor = Color::html("ff4a414f"); + Color sepcolor = get_color("light_color_1", "Editor"); + Color timecolor = get_color("dark_color_2", "Editor"); Color hover_color = Color(1, 1, 1, 0.05); Color select_color = Color(1, 1, 1, 0.1); Color invalid_path_color = Color(1, 0.6, 0.4, 0.5); - Color track_select_color = Color::html("ffbd8e8e"); + Color track_select_color = get_color("highlight_color", "Editor"); Ref<Texture> remove_icon = get_icon("Remove", "EditorIcons"); Ref<Texture> move_up_icon = get_icon("MoveUp", "EditorIcons"); @@ -1179,11 +1180,7 @@ void AnimationKeyEditor::_track_editor_draw() { int end_px = (l - h_scroll->get_value()) * scale; int begin_px = -h_scroll->get_value() * scale; - Color notimecol; - notimecol.r = timecolor.gray(); - notimecol.g = notimecol.r; - notimecol.b = notimecol.r; - notimecol.a = timecolor.a; + Color notimecol = get_color("light_color_1", "Editor"); { @@ -1483,7 +1480,9 @@ void AnimationKeyEditor::_track_editor_draw() { switch (click.click) { case ClickOver::CLICK_SELECT_KEYS: { - te->draw_rect(Rect2(click.at, click.to - click.at), Color(0.7, 0.7, 1.0, 0.5)); + Color box_color = get_color("highlight_color", "Editor"); + box_color.a = 0.35; + te->draw_rect(Rect2(click.at, click.to - click.at), box_color); } break; case ClickOver::CLICK_MOVE_KEYS: { @@ -1749,7 +1748,7 @@ void AnimationKeyEditor::_anim_delete_keys() { } } -void AnimationKeyEditor::_track_editor_gui_input(const InputEvent &p_input) { +void AnimationKeyEditor::_track_editor_gui_input(const Ref<InputEvent> &p_input) { Control *te = track_editor; Ref<StyleBox> style = get_stylebox("normal", "TextEdit"); @@ -1807,1073 +1806,1083 @@ void AnimationKeyEditor::_track_editor_gui_input(const InputEvent &p_input) { int settings_limit = size.width - right_separator_ofs; int name_limit = settings_limit * name_column_ratio; - switch (p_input.type) { + Ref<InputEventKey> key = p_input; + if (key.is_valid()) { - case InputEvent::KEY: { + if (key->get_scancode() == KEY_D && key->is_pressed() && key->get_command()) { - if (p_input.key.scancode == KEY_D && p_input.key.pressed && p_input.key.mod.command) { + if (key->get_shift()) + _menu_track(TRACK_MENU_DUPLICATE_TRANSPOSE); + else + _menu_track(TRACK_MENU_DUPLICATE); - if (p_input.key.mod.shift) - _menu_track(TRACK_MENU_DUPLICATE_TRANSPOSE); - else - _menu_track(TRACK_MENU_DUPLICATE); + accept_event(); - accept_event(); + } else if (key->get_scancode() == KEY_DELETE && key->is_pressed() && click.click == ClickOver::CLICK_NONE) { - } else if (p_input.key.scancode == KEY_DELETE && p_input.key.pressed && click.click == ClickOver::CLICK_NONE) { + _anim_delete_keys(); + } else if (animation.is_valid() && animation->get_track_count() > 0) { - _anim_delete_keys(); - } else if (animation.is_valid() && animation->get_track_count() > 0) { - - if (p_input.is_pressed() && (p_input.is_action("ui_up") || p_input.is_action("ui_page_up"))) { + if (key->is_pressed() && (key->is_action("ui_up") || key->is_action("ui_page_up"))) { - if (p_input.is_action("ui_up")) - selected_track--; - if (v_scroll->is_visible_in_tree() && p_input.is_action("ui_page_up")) - selected_track--; + if (key->is_action("ui_up")) + selected_track--; + if (v_scroll->is_visible_in_tree() && key->is_action("ui_page_up")) + selected_track--; - if (selected_track < 0) - selected_track = 0; + if (selected_track < 0) + selected_track = 0; - if (v_scroll->is_visible_in_tree()) { - if (v_scroll->get_value() > selected_track) - v_scroll->set_value(selected_track); - } - - track_editor->update(); - accept_event(); + if (v_scroll->is_visible_in_tree()) { + if (v_scroll->get_value() > selected_track) + v_scroll->set_value(selected_track); } - if (p_input.is_pressed() && (p_input.is_action("ui_down") || p_input.is_action("ui_page_down"))) { + track_editor->update(); + accept_event(); + } - if (p_input.is_action("ui_down")) - selected_track++; - else if (v_scroll->is_visible_in_tree() && p_input.is_action("ui_page_down")) - selected_track += v_scroll->get_page(); + if (key->is_pressed() && (key->is_action("ui_down") || key->is_action("ui_page_down"))) { - if (selected_track >= animation->get_track_count()) - selected_track = animation->get_track_count() - 1; + if (key->is_action("ui_down")) + selected_track++; + else if (v_scroll->is_visible_in_tree() && key->is_action("ui_page_down")) + selected_track += v_scroll->get_page(); - if (v_scroll->is_visible_in_tree() && v_scroll->get_page() + v_scroll->get_value() < selected_track + 1) { - v_scroll->set_value(selected_track - v_scroll->get_page() + 1); - } + if (selected_track >= animation->get_track_count()) + selected_track = animation->get_track_count() - 1; - track_editor->update(); - accept_event(); + if (v_scroll->is_visible_in_tree() && v_scroll->get_page() + v_scroll->get_value() < selected_track + 1) { + v_scroll->set_value(selected_track - v_scroll->get_page() + 1); } + + track_editor->update(); + accept_event(); } + } + } - } break; - case InputEvent::MOUSE_BUTTON: { + Ref<InputEventMouseButton> mb = p_input; - const InputEventMouseButton &mb = p_input.mouse_button; + if (mb.is_valid()) { - if (mb.button_index == BUTTON_WHEEL_UP && mb.pressed) { + if (mb->get_button_index() == BUTTON_WHEEL_UP && mb->is_pressed()) { - if (mb.mod.command) { - zoom->set_value(zoom->get_value() + zoom->get_step()); - } else { - v_scroll->set_value(v_scroll->get_value() - v_scroll->get_page() / 8); - } - } + if (mb->get_command()) { - if (mb.button_index == BUTTON_WHEEL_DOWN && mb.pressed) { + zoom->set_value(zoom->get_value() + zoom->get_step()); + } else { - if (mb.mod.command) { - zoom->set_value(zoom->get_value() - zoom->get_step()); - } else { - v_scroll->set_value(v_scroll->get_value() + v_scroll->get_page() / 8); - } + v_scroll->set_value(v_scroll->get_value() - v_scroll->get_page() * mb->get_factor() / 8); } + } - if (mb.button_index == BUTTON_RIGHT && mb.pressed) { + if (mb->get_button_index() == BUTTON_WHEEL_DOWN && mb->is_pressed()) { - Point2 mpos = Point2(mb.x, mb.y) - ofs; + if (mb->get_command()) { - if (selection.size() == 0) { - // Auto-select on right-click if nothing is selected - // Note: This code is pretty much duplicated from the left click code, - // both codes could be moved into a function to avoid the duplicated code. - Point2 mpos = Point2(mb.x, mb.y) - ofs; + zoom->set_value(zoom->get_value() - zoom->get_step()); + } else { - if (mpos.y < h) { - return; - } + v_scroll->set_value(v_scroll->get_value() + v_scroll->get_page() * mb->get_factor() / 8); + } + } - mpos.y -= h; + if (mb->get_button_index() == BUTTON_WHEEL_RIGHT && mb->is_pressed()) { - int idx = mpos.y / h; - idx += v_scroll->get_value(); - if (idx < 0 || idx >= animation->get_track_count()) - break; + h_scroll->set_value(h_scroll->get_value() - h_scroll->get_page() * mb->get_factor() / 8); + } - if (mpos.x < name_limit) { - } else if (mpos.x < settings_limit) { - float pos = mpos.x - name_limit; - pos /= _get_zoom_scale(); - pos += h_scroll->get_value(); - float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; + if (mb->get_button_index() == BUTTON_WHEEL_LEFT && mb->is_pressed()) { - int kidx = animation->track_find_key(idx, pos); - int kidx_n = kidx + 1; - int key = -1; + v_scroll->set_value(v_scroll->get_value() + v_scroll->get_page() * mb->get_factor() / 8); + } - if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { + if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed()) { - float kpos = animation->track_get_key_time(idx, kidx); - if (ABS(pos - kpos) <= w_time) { + Point2 mpos = mb->get_position() - ofs; - key = kidx; - } - } + if (selection.size() == 0) { + // Auto-select on right-click if nothing is selected + // Note: This code is pretty much duplicated from the left click code, + // both codes could be moved into a function to avoid the duplicated code. + Point2 mpos = mb->get_position() - ofs; - if (key == -1 && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { + if (mpos.y < h) { + return; + } - float kpos = animation->track_get_key_time(idx, kidx_n); - if (ABS(pos - kpos) <= w_time) { + mpos.y -= h; - key = kidx_n; - } - } + int idx = mpos.y / h; + idx += v_scroll->get_value(); + if (idx < 0 || idx >= animation->get_track_count()) + return; - if (key == -1) { + if (mpos.x < name_limit) { + } else if (mpos.x < settings_limit) { + float pos = mpos.x - name_limit; + pos /= _get_zoom_scale(); + pos += h_scroll->get_value(); + float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; - click.click = ClickOver::CLICK_SELECT_KEYS; - click.at = Point2(mb.x, mb.y); - click.to = click.at; - click.shift = mb.mod.shift; - selected_track = idx; - track_editor->update(); - //drag select region - return; + int kidx = animation->track_find_key(idx, pos); + int kidx_n = kidx + 1; + int key = -1; + + if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { + + float kpos = animation->track_get_key_time(idx, kidx); + if (ABS(pos - kpos) <= w_time) { + + key = kidx; } + } - SelectedKey sk; - sk.track = idx; - sk.key = key; - KeyInfo ki; - ki.pos = animation->track_get_key_time(idx, key); - click.shift = mb.mod.shift; - click.selk = sk; + if (key == -1 && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { - if (!mb.mod.shift && !selection.has(sk)) - _clear_selection(); + float kpos = animation->track_get_key_time(idx, kidx_n); + if (ABS(pos - kpos) <= w_time) { + + key = kidx_n; + } + } - selection.insert(sk, ki); + if (key == -1) { - click.click = ClickOver::CLICK_MOVE_KEYS; - click.at = Point2(mb.x, mb.y); + click.click = ClickOver::CLICK_SELECT_KEYS; + click.at = mb->get_position(); click.to = click.at; - update(); + click.shift = mb->get_shift(); selected_track = idx; track_editor->update(); - - if (_edit_if_single_selection() && mb.mod.command) { - edit_button->set_pressed(true); - key_editor_tab->show(); - } + //drag select region + return; } - } - if (selection.size()) { - // User has right clicked and we have a selection, show a popup menu with options - track_menu->clear(); - track_menu->set_size(Point2(1, 1)); - track_menu->add_item(TTR("Duplicate Selection"), RIGHT_MENU_DUPLICATE); - track_menu->add_item(TTR("Duplicate Transposed"), RIGHT_MENU_DUPLICATE_TRANSPOSE); - track_menu->add_item(TTR("Remove Selection"), RIGHT_MENU_REMOVE); + SelectedKey sk; + sk.track = idx; + sk.key = key; + KeyInfo ki; + ki.pos = animation->track_get_key_time(idx, key); + click.shift = mb->get_shift(); + click.selk = sk; - track_menu->set_position(te->get_global_position() + mpos); + if (!mb->get_shift() && !selection.has(sk)) + _clear_selection(); - interp_editing = -1; - cont_editing = -1; - wrap_editing = -1; + selection.insert(sk, ki); - track_menu->popup(); + click.click = ClickOver::CLICK_MOVE_KEYS; + click.at = mb->get_position(); + click.to = click.at; + update(); + selected_track = idx; + track_editor->update(); + + if (_edit_if_single_selection() && mb->get_command()) { + edit_button->set_pressed(true); + key_editor_tab->show(); + } } } - if (mb.button_index == BUTTON_LEFT && !(mb.button_mask & ~BUTTON_MASK_LEFT)) { + if (selection.size()) { + // User has right clicked and we have a selection, show a popup menu with options + track_menu->clear(); + track_menu->set_size(Point2(1, 1)); + track_menu->add_item(TTR("Duplicate Selection"), RIGHT_MENU_DUPLICATE); + track_menu->add_item(TTR("Duplicate Transposed"), RIGHT_MENU_DUPLICATE_TRANSPOSE); + track_menu->add_item(TTR("Remove Selection"), RIGHT_MENU_REMOVE); - if (mb.pressed) { + track_menu->set_position(te->get_global_position() + mpos); - Point2 mpos = Point2(mb.x, mb.y) - ofs; + interp_editing = -1; + cont_editing = -1; + wrap_editing = -1; - if (mpos.y < h) { + track_menu->popup(); + } + } - if (mpos.x < name_limit && mpos.x > (name_limit - hsep - hsize_icon->get_width())) { + if (mb->get_button_index() == BUTTON_LEFT && !(mb->get_button_mask() & ~BUTTON_MASK_LEFT)) { - click.click = ClickOver::CLICK_RESIZE_NAMES; - click.at = Point2(mb.x, mb.y); - click.to = click.at; - click.at.y = name_limit; - } + if (mb->is_pressed()) { - if (mpos.x >= name_limit && mpos.x < settings_limit) { - //seek - //int zoomw = settings_limit-name_limit; - float scale = _get_zoom_scale(); - float pos = h_scroll->get_value() + (mpos.x - name_limit) / scale; - if (animation->get_step()) - pos = Math::stepify(pos, animation->get_step()); - - if (pos < 0) - pos = 0; - if (pos >= animation->get_length()) - pos = animation->get_length(); - timeline_pos = pos; - click.click = ClickOver::CLICK_DRAG_TIMELINE; - click.at = Point2(mb.x, mb.y); - click.to = click.at; - emit_signal("timeline_changed", pos, false); - } + Point2 mpos = mb->get_position() - ofs; - return; - } + if (mpos.y < h) { - mpos.y -= h; + if (mpos.x < name_limit && mpos.x > (name_limit - hsep - hsize_icon->get_width())) { - int idx = mpos.y / h; - idx += v_scroll->get_value(); - if (idx < 0) - break; + click.click = ClickOver::CLICK_RESIZE_NAMES; + click.at = mb->get_position(); + click.to = click.at; + click.at.y = name_limit; + } - if (idx >= animation->get_track_count()) { + if (mpos.x >= name_limit && mpos.x < settings_limit) { + //seek + //int zoomw = settings_limit-name_limit; + float scale = _get_zoom_scale(); + float pos = h_scroll->get_value() + (mpos.x - name_limit) / scale; + if (animation->get_step()) + pos = Math::stepify(pos, animation->get_step()); - if (mpos.x >= name_limit && mpos.x < settings_limit) { + if (pos < 0) + pos = 0; + if (pos >= animation->get_length()) + pos = animation->get_length(); + timeline_pos = pos; + click.click = ClickOver::CLICK_DRAG_TIMELINE; + click.at = mb->get_position(); + click.to = click.at; + emit_signal("timeline_changed", pos, false); + } - click.click = ClickOver::CLICK_SELECT_KEYS; - click.at = Point2(mb.x, mb.y); - click.to = click.at; - //drag select region - } + return; + } - break; - } + mpos.y -= h; - if (mpos.x < name_limit) { - //name column + int idx = mpos.y / h; + idx += v_scroll->get_value(); + if (idx < 0) + return; - // area - if (idx != selected_track) { + if (idx >= animation->get_track_count()) { - selected_track = idx; - track_editor->update(); - break; - } + if (mpos.x >= name_limit && mpos.x < settings_limit) { - Rect2 area(ofs.x, ofs.y + ((int(mpos.y) / h) + 1) * h, name_limit, h); - track_name->set_text(animation->track_get_path(idx)); - track_name->set_position(te->get_global_position() + area.pos); - track_name->set_size(area.size); - track_name->show_modal(); - track_name->grab_focus(); - track_name->select_all(); - track_name_editing = idx; + click.click = ClickOver::CLICK_SELECT_KEYS; + click.at = mb->get_position(); + click.to = click.at; + //drag select region + } - } else if (mpos.x < settings_limit) { + return; + } - float pos = mpos.x - name_limit; - pos /= _get_zoom_scale(); - pos += h_scroll->get_value(); - float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; + if (mpos.x < name_limit) { + //name column - int kidx = animation->track_find_key(idx, pos); - int kidx_n = kidx + 1; - int key = -1; + // area + if (idx != selected_track) { - if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { + selected_track = idx; + track_editor->update(); + return; + } - float kpos = animation->track_get_key_time(idx, kidx); - if (ABS(pos - kpos) <= w_time) { + Rect2 area(ofs.x, ofs.y + ((int(mpos.y) / h) + 1) * h, name_limit, h); + track_name->set_text(animation->track_get_path(idx)); + track_name->set_position(te->get_global_position() + area.position); + track_name->set_size(area.size); + track_name->show_modal(); + track_name->grab_focus(); + track_name->select_all(); + track_name_editing = idx; - key = kidx; - } - } + } else if (mpos.x < settings_limit) { - if (key == -1 && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { + float pos = mpos.x - name_limit; + pos /= _get_zoom_scale(); + pos += h_scroll->get_value(); + float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; - float kpos = animation->track_get_key_time(idx, kidx_n); - if (ABS(pos - kpos) <= w_time) { + int kidx = animation->track_find_key(idx, pos); + int kidx_n = kidx + 1; + int key = -1; - key = kidx_n; - } - } + if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { - if (key == -1) { + float kpos = animation->track_get_key_time(idx, kidx); + if (ABS(pos - kpos) <= w_time) { - click.click = ClickOver::CLICK_SELECT_KEYS; - click.at = Point2(mb.x, mb.y); - click.to = click.at; - click.shift = mb.mod.shift; - selected_track = idx; - track_editor->update(); - //drag select region - return; + key = kidx; } + } - SelectedKey sk; - sk.track = idx; - sk.key = key; - KeyInfo ki; - ki.pos = animation->track_get_key_time(idx, key); - click.shift = mb.mod.shift; - click.selk = sk; + if (key == -1 && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { - if (!mb.mod.shift && !selection.has(sk)) - _clear_selection(); + float kpos = animation->track_get_key_time(idx, kidx_n); + if (ABS(pos - kpos) <= w_time) { - selection.insert(sk, ki); + key = kidx_n; + } + } + + if (key == -1) { - click.click = ClickOver::CLICK_MOVE_KEYS; - click.at = Point2(mb.x, mb.y); + click.click = ClickOver::CLICK_SELECT_KEYS; + click.at = mb->get_position(); click.to = click.at; - update(); + click.shift = mb->get_shift(); selected_track = idx; track_editor->update(); + //drag select region + return; + } - if (_edit_if_single_selection() && mb.mod.command) { - edit_button->set_pressed(true); - key_editor_tab->show(); - } - } else { - //button column - int ofsx = size.width - mpos.x; - if (ofsx < 0) - break; - /* - if (ofsx < remove_icon->get_width()) { + SelectedKey sk; + sk.track = idx; + sk.key = key; + KeyInfo ki; + ki.pos = animation->track_get_key_time(idx, key); + click.shift = mb->get_shift(); + click.selk = sk; - undo_redo->create_action("Remove Anim Track"); - undo_redo->add_do_method(animation.ptr(),"remove_track",idx); - undo_redo->add_undo_method(animation.ptr(),"add_track",animation->track_get_type(idx),idx); - undo_redo->add_undo_method(animation.ptr(),"track_set_path",idx,animation->track_get_path(idx)); - //todo interpolation - for(int i=0;i<animation->track_get_key_count(idx);i++) { + if (!mb->get_shift() && !selection.has(sk)) + _clear_selection(); - Variant v = animation->track_get_key_value(idx,i); - float time = animation->track_get_key_time(idx,i); - float trans = animation->track_get_key_transition(idx,i); + selection.insert(sk, ki); - undo_redo->add_undo_method(animation.ptr(),"track_insert_key",idx,time,v); - undo_redo->add_undo_method(animation.ptr(),"track_set_key_transition",idx,i,trans); + click.click = ClickOver::CLICK_MOVE_KEYS; + click.at = mb->get_position(); + click.to = click.at; + update(); + selected_track = idx; + track_editor->update(); - } + if (_edit_if_single_selection() && mb->get_command()) { + edit_button->set_pressed(true); + key_editor_tab->show(); + } + } else { + //button column + int ofsx = size.width - mpos.x; + if (ofsx < 0) + return; + /* + if (ofsx < remove_icon->get_width()) { - undo_redo->add_undo_method(animation.ptr(),"track_set_interpolation_type",idx,animation->track_get_interpolation_type(idx)); - if (animation->track_get_type(idx)==Animation::TYPE_VALUE) { - undo_redo->add_undo_method(animation.ptr(),"value_track_set_continuous",idx,animation->value_track_is_continuous(idx)); + undo_redo->create_action("Remove Anim Track"); + undo_redo->add_do_method(animation.ptr(),"remove_track",idx); + undo_redo->add_undo_method(animation.ptr(),"add_track",animation->track_get_type(idx),idx); + undo_redo->add_undo_method(animation.ptr(),"track_set_path",idx,animation->track_get_path(idx)); + //todo interpolation + for(int i=0;i<animation->track_get_key_count(idx);i++) { - } + Variant v = animation->track_get_key_value(idx,i); + float time = animation->track_get_key_time(idx,i); + float trans = animation->track_get_key_transition(idx,i); - undo_redo->commit_action(); + undo_redo->add_undo_method(animation.ptr(),"track_insert_key",idx,time,v); + undo_redo->add_undo_method(animation.ptr(),"track_set_key_transition",idx,i,trans); - - return; } - ofsx-=hsep+remove_icon->get_width(); - - if (ofsx < move_down_icon->get_width()) { + undo_redo->add_undo_method(animation.ptr(),"track_set_interpolation_type",idx,animation->track_get_interpolation_type(idx)); + if (animation->track_get_type(idx)==Animation::TYPE_VALUE) { + undo_redo->add_undo_method(animation.ptr(),"value_track_set_continuous",idx,animation->value_track_is_continuous(idx)); - if (idx < animation->get_track_count() -1) { - undo_redo->create_action("Move Anim Track Down"); - undo_redo->add_do_method(animation.ptr(),"track_move_up",idx); - undo_redo->add_undo_method(animation.ptr(),"track_move_down",idx+1); - undo_redo->commit_action(); - } - return; } - ofsx-=hsep+move_down_icon->get_width(); + undo_redo->commit_action(); - if (ofsx < move_up_icon->get_width()) { - if (idx >0) { - undo_redo->create_action("Move Anim Track Up"); - undo_redo->add_do_method(animation.ptr(),"track_move_down",idx); - undo_redo->add_undo_method(animation.ptr(),"track_move_up",idx-1); - undo_redo->commit_action(); - } - return; - } + return; + } + ofsx-=hsep+remove_icon->get_width(); - ofsx-=hsep*3+move_up_icon->get_width(); - */ + if (ofsx < move_down_icon->get_width()) { + + if (idx < animation->get_track_count() -1) { + undo_redo->create_action("Move Anim Track Down"); + undo_redo->add_do_method(animation.ptr(),"track_move_up",idx); + undo_redo->add_undo_method(animation.ptr(),"track_move_down",idx+1); + undo_redo->commit_action(); + } + return; + } - if (ofsx < track_ofs[1]) { + ofsx-=hsep+move_down_icon->get_width(); - track_menu->clear(); - track_menu->set_size(Point2(1, 1)); - static const char *interp_name[2] = { "Clamp Loop Interp", "Wrap Loop Interp" }; - for (int i = 0; i < 2; i++) { - track_menu->add_icon_item(wrap_icon[i], interp_name[i]); - } + if (ofsx < move_up_icon->get_width()) { - int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; - int popup_x = size.width - track_ofs[1]; + if (idx >0) { + undo_redo->create_action("Move Anim Track Up"); + undo_redo->add_do_method(animation.ptr(),"track_move_down",idx); + undo_redo->add_undo_method(animation.ptr(),"track_move_up",idx-1); + undo_redo->commit_action(); + } + return; + } - track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); - wrap_editing = idx; - interp_editing = -1; - cont_editing = -1; + ofsx-=hsep*3+move_up_icon->get_width(); + */ - track_menu->popup(); + if (ofsx < track_ofs[1]) { - return; + track_menu->clear(); + track_menu->set_size(Point2(1, 1)); + static const char *interp_name[2] = { "Clamp Loop Interp", "Wrap Loop Interp" }; + for (int i = 0; i < 2; i++) { + track_menu->add_icon_item(wrap_icon[i], interp_name[i]); } - if (ofsx < track_ofs[2]) { + int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; + int popup_x = size.width - track_ofs[1]; - track_menu->clear(); - track_menu->set_size(Point2(1, 1)); - static const char *interp_name[3] = { "Nearest", "Linear", "Cubic" }; - for (int i = 0; i < 3; i++) { - track_menu->add_icon_item(interp_icon[i], interp_name[i]); - } + track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); - int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; - int popup_x = size.width - track_ofs[2]; + wrap_editing = idx; + interp_editing = -1; + cont_editing = -1; - track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); + track_menu->popup(); - interp_editing = idx; - cont_editing = -1; - wrap_editing = -1; + return; + } - track_menu->popup(); + if (ofsx < track_ofs[2]) { - return; + track_menu->clear(); + track_menu->set_size(Point2(1, 1)); + static const char *interp_name[3] = { "Nearest", "Linear", "Cubic" }; + for (int i = 0; i < 3; i++) { + track_menu->add_icon_item(interp_icon[i], interp_name[i]); } - if (ofsx < track_ofs[3]) { + int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; + int popup_x = size.width - track_ofs[2]; - track_menu->clear(); - track_menu->set_size(Point2(1, 1)); - String cont_name[3] = { TTR("Continuous"), TTR("Discrete"), TTR("Trigger") }; - for (int i = 0; i < 3; i++) { - track_menu->add_icon_item(cont_icon[i], cont_name[i]); - } + track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); - int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; - int popup_x = size.width - track_ofs[3]; + interp_editing = idx; + cont_editing = -1; + wrap_editing = -1; - track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); + track_menu->popup(); - interp_editing = -1; - wrap_editing = -1; - cont_editing = idx; + return; + } - track_menu->popup(); + if (ofsx < track_ofs[3]) { - return; + track_menu->clear(); + track_menu->set_size(Point2(1, 1)); + String cont_name[3] = { TTR("Continuous"), TTR("Discrete"), TTR("Trigger") }; + for (int i = 0; i < 3; i++) { + track_menu->add_icon_item(cont_icon[i], cont_name[i]); } - if (ofsx < track_ofs[4]) { + int popup_y = ofs.y + ((int(mpos.y) / h) + 2) * h; + int popup_x = size.width - track_ofs[3]; - Animation::TrackType tt = animation->track_get_type(idx); + track_menu->set_position(te->get_global_position() + Point2(popup_x, popup_y)); - float pos = timeline_pos; - int existing = animation->track_find_key(idx, pos, true); + interp_editing = -1; + wrap_editing = -1; + cont_editing = idx; - Variant newval; + track_menu->popup(); - if (tt == Animation::TYPE_TRANSFORM) { - Dictionary d; - d["loc"] = Vector3(); - d["rot"] = Quat(); - d["scale"] = Vector3(); - newval = d; + return; + } - } else if (tt == Animation::TYPE_METHOD) { + if (ofsx < track_ofs[4]) { - Dictionary d; - d["method"] = ""; - d["args"] = Vector<Variant>(); + Animation::TrackType tt = animation->track_get_type(idx); - newval = d; - } else if (tt == Animation::TYPE_VALUE) { + float pos = timeline_pos; + int existing = animation->track_find_key(idx, pos, true); - NodePath np; - PropertyInfo inf = _find_hint_for_track(idx, np); - if (inf.type != Variant::NIL) { + Variant newval; - Variant::CallError err; - newval = Variant::construct(inf.type, NULL, 0, err); - } + if (tt == Animation::TYPE_TRANSFORM) { + Dictionary d; + d["loc"] = Vector3(); + d["rot"] = Quat(); + d["scale"] = Vector3(); + newval = d; - if (newval.get_type() == Variant::NIL) { - //popup a new type - cvi_track = idx; - cvi_pos = pos; + } else if (tt == Animation::TYPE_METHOD) { - type_menu->set_position(get_global_position() + mpos + ofs); - type_menu->popup(); - return; - } - } + Dictionary d; + d["method"] = ""; + d["args"] = Vector<Variant>(); - undo_redo->create_action(TTR("Anim Add Key")); + newval = d; + } else if (tt == Animation::TYPE_VALUE) { - undo_redo->add_do_method(animation.ptr(), "track_insert_key", idx, pos, newval, 1); - undo_redo->add_undo_method(animation.ptr(), "track_remove_key_at_pos", idx, pos); + NodePath np; + PropertyInfo inf = _find_hint_for_track(idx, np); + if (inf.type != Variant::NIL) { - if (existing != -1) { - Variant v = animation->track_get_key_value(idx, existing); - float trans = animation->track_get_key_transition(idx, existing); - undo_redo->add_undo_method(animation.ptr(), "track_insert_key", idx, pos, v, trans); + Variant::CallError err; + newval = Variant::construct(inf.type, NULL, 0, err); } - undo_redo->commit_action(); + if (newval.get_type() == Variant::NIL) { + //popup a new type + cvi_track = idx; + cvi_pos = pos; - return; + type_menu->set_position(get_global_position() + mpos + ofs); + type_menu->popup(); + return; + } } - } - } else { + undo_redo->create_action(TTR("Anim Add Key")); - switch (click.click) { - case ClickOver::CLICK_SELECT_KEYS: { + undo_redo->add_do_method(animation.ptr(), "track_insert_key", idx, pos, newval, 1); + undo_redo->add_undo_method(animation.ptr(), "track_remove_key_at_pos", idx, pos); - float zoom_scale = _get_zoom_scale(); - float keys_from = h_scroll->get_value(); - float keys_to = keys_from + (settings_limit - name_limit) / zoom_scale; + if (existing != -1) { + Variant v = animation->track_get_key_value(idx, existing); + float trans = animation->track_get_key_transition(idx, existing); + undo_redo->add_undo_method(animation.ptr(), "track_insert_key", idx, pos, v, trans); + } - float from_time = keys_from + (click.at.x - (name_limit + ofs.x)) / zoom_scale; - float to_time = keys_from + (click.to.x - (name_limit + ofs.x)) / zoom_scale; + undo_redo->commit_action(); - if (to_time < from_time) - SWAP(from_time, to_time); + return; + } + } - if (from_time > keys_to || to_time < keys_from) - break; + } else { - if (from_time < keys_from) - from_time = keys_from; + switch (click.click) { + case ClickOver::CLICK_SELECT_KEYS: { - if (to_time >= keys_to) - to_time = keys_to; + float zoom_scale = _get_zoom_scale(); + float keys_from = h_scroll->get_value(); + float keys_to = keys_from + (settings_limit - name_limit) / zoom_scale; - int from_track = int(click.at.y - ofs.y - h - sep) / h + v_scroll->get_value(); - int to_track = int(click.to.y - ofs.y - h - sep) / h + v_scroll->get_value(); - int from_mod = int(click.at.y - ofs.y - sep) % h; - int to_mod = int(click.to.y - ofs.y - sep) % h; + float from_time = keys_from + (click.at.x - (name_limit + ofs.x)) / zoom_scale; + float to_time = keys_from + (click.to.x - (name_limit + ofs.x)) / zoom_scale; - if (to_track < from_track) { + if (to_time < from_time) + SWAP(from_time, to_time); - SWAP(from_track, to_track); - SWAP(from_mod, to_mod); - } + if (from_time > keys_to || to_time < keys_from) + break; - if ((from_mod > (h / 2)) && ((click.at.y - ofs.y) >= (h + sep))) { - from_track++; - } + if (from_time < keys_from) + from_time = keys_from; - if (to_mod < h / 2) { - to_track--; - } + if (to_time >= keys_to) + to_time = keys_to; - if (from_track > to_track) { - if (!click.shift) - _clear_selection(); - _edit_if_single_selection(); - break; - } + int from_track = int(click.at.y - ofs.y - h - sep) / h + v_scroll->get_value(); + int to_track = int(click.to.y - ofs.y - h - sep) / h + v_scroll->get_value(); + int from_mod = int(click.at.y - ofs.y - sep) % h; + int to_mod = int(click.to.y - ofs.y - sep) % h; + + if (to_track < from_track) { - int tracks_from = v_scroll->get_value(); - int tracks_to = v_scroll->get_value() + fit - 1; - if (tracks_to >= animation->get_track_count()) - tracks_to = animation->get_track_count() - 1; + SWAP(from_track, to_track); + SWAP(from_mod, to_mod); + } - tracks_from = 0; + if ((from_mod > (h / 2)) && ((click.at.y - ofs.y) >= (h + sep))) { + from_track++; + } + + if (to_mod < h / 2) { + to_track--; + } + + if (from_track > to_track) { + if (!click.shift) + _clear_selection(); + _edit_if_single_selection(); + break; + } + + int tracks_from = v_scroll->get_value(); + int tracks_to = v_scroll->get_value() + fit - 1; + if (tracks_to >= animation->get_track_count()) tracks_to = animation->get_track_count() - 1; - if (to_track > tracks_to) - to_track = tracks_to; - if (from_track < tracks_from) - from_track = tracks_from; - - if (from_track > tracks_to || to_track < tracks_from) { - if (!click.shift) - _clear_selection(); - _edit_if_single_selection(); - break; - } + tracks_from = 0; + tracks_to = animation->get_track_count() - 1; + if (to_track > tracks_to) + to_track = tracks_to; + if (from_track < tracks_from) + from_track = tracks_from; + + if (from_track > tracks_to || to_track < tracks_from) { if (!click.shift) _clear_selection(); + _edit_if_single_selection(); + break; + } - int higher_track = 0x7FFFFFFF; - for (int i = from_track; i <= to_track; i++) { + if (!click.shift) + _clear_selection(); - int kc = animation->track_get_key_count(i); - for (int j = 0; j < kc; j++) { + int higher_track = 0x7FFFFFFF; + for (int i = from_track; i <= to_track; i++) { - float t = animation->track_get_key_time(i, j); - if (t < from_time) - continue; - if (t > to_time) - break; + int kc = animation->track_get_key_count(i); + for (int j = 0; j < kc; j++) { - if (i < higher_track) - higher_track = i; + float t = animation->track_get_key_time(i, j); + if (t < from_time) + continue; + if (t > to_time) + break; - SelectedKey sk; - sk.track = i; - sk.key = j; - KeyInfo ki; - ki.pos = t; - selection[sk] = ki; - } - } + if (i < higher_track) + higher_track = i; - if (higher_track != 0x7FFFFFFF) { - selected_track = higher_track; - track_editor->update(); + SelectedKey sk; + sk.track = i; + sk.key = j; + KeyInfo ki; + ki.pos = t; + selection[sk] = ki; } + } - _edit_if_single_selection(); + if (higher_track != 0x7FFFFFFF) { + selected_track = higher_track; + track_editor->update(); + } - } break; - case ClickOver::CLICK_MOVE_KEYS: { + _edit_if_single_selection(); - if (selection.empty()) - break; - if (click.at == click.to) { + } break; + case ClickOver::CLICK_MOVE_KEYS: { - if (!click.shift) { + if (selection.empty()) + break; + if (click.at == click.to) { - KeyInfo ki = selection[click.selk]; - _clear_selection(); - selection[click.selk] = ki; - _edit_if_single_selection(); - } + if (!click.shift) { - break; + KeyInfo ki = selection[click.selk]; + _clear_selection(); + selection[click.selk] = ki; + _edit_if_single_selection(); } - float from_t = 1e20; + break; + } - for (Map<SelectedKey, KeyInfo>::Element *E = selection.front(); E; E = E->next()) { - float t = animation->track_get_key_time(E->key().track, E->key().key); - if (t < from_t) - from_t = t; - } + float from_t = 1e20; - float motion = from_t + (click.to.x - click.at.x) / _get_zoom_scale(); - if (step->get_value()) - motion = Math::stepify(motion, step->get_value()); + for (Map<SelectedKey, KeyInfo>::Element *E = selection.front(); E; E = E->next()) { + float t = animation->track_get_key_time(E->key().track, E->key().key); + if (t < from_t) + from_t = t; + } - undo_redo->create_action(TTR("Anim Move Keys")); + float motion = from_t + (click.to.x - click.at.x) / _get_zoom_scale(); + if (step->get_value()) + motion = Math::stepify(motion, step->get_value()); - List<_AnimMoveRestore> to_restore; + undo_redo->create_action(TTR("Anim Move Keys")); - // 1-remove the keys - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + List<_AnimMoveRestore> to_restore; - undo_redo->add_do_method(animation.ptr(), "track_remove_key", E->key().track, E->key().key); - } - // 2- remove overlapped keys - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + // 1-remove the keys + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { - float newtime = E->get().pos - from_t + motion; - int idx = animation->track_find_key(E->key().track, newtime, true); - if (idx == -1) - continue; - SelectedKey sk; - sk.key = idx; - sk.track = E->key().track; - if (selection.has(sk)) - continue; //already in selection, don't save + undo_redo->add_do_method(animation.ptr(), "track_remove_key", E->key().track, E->key().key); + } + // 2- remove overlapped keys + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + + float newtime = E->get().pos - from_t + motion; + int idx = animation->track_find_key(E->key().track, newtime, true); + if (idx == -1) + continue; + SelectedKey sk; + sk.key = idx; + sk.track = E->key().track; + if (selection.has(sk)) + continue; //already in selection, don't save + + undo_redo->add_do_method(animation.ptr(), "track_remove_key_at_pos", E->key().track, newtime); + _AnimMoveRestore amr; + + amr.key = animation->track_get_key_value(E->key().track, idx); + amr.track = E->key().track; + amr.time = newtime; + amr.transition = animation->track_get_key_transition(E->key().track, idx); + + to_restore.push_back(amr); + } - undo_redo->add_do_method(animation.ptr(), "track_remove_key_at_pos", E->key().track, newtime); - _AnimMoveRestore amr; + // 3-move the keys (re insert them) + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { - amr.key = animation->track_get_key_value(E->key().track, idx); - amr.track = E->key().track; - amr.time = newtime; - amr.transition = animation->track_get_key_transition(E->key().track, idx); + float newpos = E->get().pos - from_t + motion; + /* + if (newpos<0) + continue; //no add at the beginning + */ + undo_redo->add_do_method(animation.ptr(), "track_insert_key", E->key().track, newpos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key)); + } - to_restore.push_back(amr); - } + // 4-(undo) remove inserted keys + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { - // 3-move the keys (re insert them) - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + float newpos = E->get().pos + -from_t + motion; + /* + if (newpos<0) + continue; //no remove what no inserted + */ + undo_redo->add_undo_method(animation.ptr(), "track_remove_key_at_pos", E->key().track, newpos); + } - float newpos = E->get().pos - from_t + motion; - /* - if (newpos<0) - continue; //no add at the beginning - */ - undo_redo->add_do_method(animation.ptr(), "track_insert_key", E->key().track, newpos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key)); - } + // 5-(undo) reinsert keys + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { - // 4-(undo) remove inserted keys - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + undo_redo->add_undo_method(animation.ptr(), "track_insert_key", E->key().track, E->get().pos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key)); + } - float newpos = E->get().pos + -from_t + motion; - /* - if (newpos<0) - continue; //no remove what no inserted - */ - undo_redo->add_undo_method(animation.ptr(), "track_remove_key_at_pos", E->key().track, newpos); - } + // 6-(undo) reinsert overlapped keys + for (List<_AnimMoveRestore>::Element *E = to_restore.front(); E; E = E->next()) { - // 5-(undo) reinsert keys - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + _AnimMoveRestore &amr = E->get(); + undo_redo->add_undo_method(animation.ptr(), "track_insert_key", amr.track, amr.time, amr.key, amr.transition); + } - undo_redo->add_undo_method(animation.ptr(), "track_insert_key", E->key().track, E->get().pos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key)); - } + // 6-(undo) reinsert overlapped keys + for (List<_AnimMoveRestore>::Element *E = to_restore.front(); E; E = E->next()) { - // 6-(undo) reinsert overlapped keys - for (List<_AnimMoveRestore>::Element *E = to_restore.front(); E; E = E->next()) { + _AnimMoveRestore &amr = E->get(); + undo_redo->add_undo_method(animation.ptr(), "track_insert_key", amr.track, amr.time, amr.key, amr.transition); + } - _AnimMoveRestore &amr = E->get(); - undo_redo->add_undo_method(animation.ptr(), "track_insert_key", amr.track, amr.time, amr.key, amr.transition); - } + undo_redo->add_do_method(this, "_clear_selection_for_anim", animation); + undo_redo->add_undo_method(this, "_clear_selection_for_anim", animation); - // 6-(undo) reinsert overlapped keys - for (List<_AnimMoveRestore>::Element *E = to_restore.front(); E; E = E->next()) { + // 7-reselect - _AnimMoveRestore &amr = E->get(); - undo_redo->add_undo_method(animation.ptr(), "track_insert_key", amr.track, amr.time, amr.key, amr.transition); - } + for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { - undo_redo->add_do_method(this, "_clear_selection_for_anim", animation); - undo_redo->add_undo_method(this, "_clear_selection_for_anim", animation); + float oldpos = E->get().pos; + float newpos = oldpos - from_t + motion; + //if (newpos>=0) + undo_redo->add_do_method(this, "_select_at_anim", animation, E->key().track, newpos); + undo_redo->add_undo_method(this, "_select_at_anim", animation, E->key().track, oldpos); + } - // 7-reselect + undo_redo->commit_action(); + _edit_if_single_selection(); - for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) { + } break; + default: {} + } - float oldpos = E->get().pos; - float newpos = oldpos - from_t + motion; - //if (newpos>=0) - undo_redo->add_do_method(this, "_select_at_anim", animation, E->key().track, newpos); - undo_redo->add_undo_method(this, "_select_at_anim", animation, E->key().track, oldpos); - } + //button released + click.click = ClickOver::CLICK_NONE; + track_editor->update(); + } + } + } - undo_redo->commit_action(); - _edit_if_single_selection(); + Ref<InputEventMouseMotion> mm = p_input; - } break; - default: {} - } + if (mm.is_valid()) { - //button released - click.click = ClickOver::CLICK_NONE; - track_editor->update(); - } - } + mouse_over.over = MouseOver::OVER_NONE; + mouse_over.track = -1; + te->update(); + track_editor->set_tooltip(""); - } break; + if (!track_editor->has_focus() && (!get_focus_owner() || !get_focus_owner()->is_text_field())) + track_editor->call_deferred("grab_focus"); - case InputEvent::MOUSE_MOTION: { + if (click.click != ClickOver::CLICK_NONE) { - const InputEventMouseMotion &mb = p_input.mouse_motion; + switch (click.click) { + case ClickOver::CLICK_RESIZE_NAMES: { - mouse_over.over = MouseOver::OVER_NONE; - mouse_over.track = -1; - te->update(); - track_editor->set_tooltip(""); + float base = click.at.y; + float clickp = click.at.x - ofs.x; + float dif = base - clickp; - if (!track_editor->has_focus() && (!get_focus_owner() || !get_focus_owner()->is_text_field())) - track_editor->call_deferred("grab_focus"); + float target = mm->get_position().x + dif - ofs.x; - if (click.click != ClickOver::CLICK_NONE) { + float ratio = target / settings_limit; - switch (click.click) { - case ClickOver::CLICK_RESIZE_NAMES: { + if (ratio > 0.9) + ratio = 0.9; + else if (ratio < 0.2) + ratio = 0.2; - float base = click.at.y; - float clickp = click.at.x - ofs.x; - float dif = base - clickp; + name_column_ratio = ratio; - float target = mb.x + dif - ofs.x; + } break; + case ClickOver::CLICK_DRAG_TIMELINE: { - float ratio = target / settings_limit; + Point2 mpos = mm->get_position() - ofs; + /* + if (mpos.x<name_limit) + mpos.x=name_limit; + if (mpos.x>settings_limit) + mpos.x=settings_limit; + */ - if (ratio > 0.9) - ratio = 0.9; - else if (ratio < 0.2) - ratio = 0.2; + //int zoomw = settings_limit-name_limit; + float scale = _get_zoom_scale(); + float pos = h_scroll->get_value() + (mpos.x - name_limit) / scale; + if (animation->get_step()) { + pos = Math::stepify(pos, animation->get_step()); + } + if (pos < 0) + pos = 0; + if (pos >= animation->get_length()) + pos = animation->get_length(); + + if (pos < h_scroll->get_value()) { + h_scroll->set_value(pos); + } else if (pos > h_scroll->get_value() + (settings_limit - name_limit) / scale) { + h_scroll->set_value(pos - (settings_limit - name_limit) / scale); + } - name_column_ratio = ratio; + timeline_pos = pos; + emit_signal("timeline_changed", pos, true); - } break; - case ClickOver::CLICK_DRAG_TIMELINE: { - - Point2 mpos = Point2(mb.x, mb.y) - ofs; - /* - if (mpos.x<name_limit) - mpos.x=name_limit; - if (mpos.x>settings_limit) - mpos.x=settings_limit; - */ + } break; + case ClickOver::CLICK_SELECT_KEYS: { - //int zoomw = settings_limit-name_limit; - float scale = _get_zoom_scale(); - float pos = h_scroll->get_value() + (mpos.x - name_limit) / scale; - if (animation->get_step()) { - pos = Math::stepify(pos, animation->get_step()); - } - if (pos < 0) - pos = 0; - if (pos >= animation->get_length()) - pos = animation->get_length(); + click.to = mm->get_position(); + if (click.to.y < h && click.at.y > h && mm->get_relative().y < 0) { - if (pos < h_scroll->get_value()) { - h_scroll->set_value(pos); - } else if (pos > h_scroll->get_value() + (settings_limit - name_limit) / scale) { - h_scroll->set_value(pos - (settings_limit - name_limit) / scale); - } + float prev = v_scroll->get_value(); + v_scroll->set_value(v_scroll->get_value() - 1); + if (prev != v_scroll->get_value()) + click.at.y += h; + } + if (click.to.y > size.height && click.at.y < size.height && mm->get_relative().y > 0) { - timeline_pos = pos; - emit_signal("timeline_changed", pos, true); + float prev = v_scroll->get_value(); + v_scroll->set_value(v_scroll->get_value() + 1); + if (prev != v_scroll->get_value()) + click.at.y -= h; + } - } break; - case ClickOver::CLICK_SELECT_KEYS: { + } break; + case ClickOver::CLICK_MOVE_KEYS: { - click.to = Point2(mb.x, mb.y); - if (click.to.y < h && click.at.y > h && mb.relative_y < 0) { + click.to = mm->get_position(); + } break; + default: {} + } - float prev = v_scroll->get_value(); - v_scroll->set_value(v_scroll->get_value() - 1); - if (prev != v_scroll->get_value()) - click.at.y += h; - } - if (click.to.y > size.height && click.at.y < size.height && mb.relative_y > 0) { + return; + } else if (mm->get_button_mask() & BUTTON_MASK_MIDDLE) { - float prev = v_scroll->get_value(); - v_scroll->set_value(v_scroll->get_value() + 1); - if (prev != v_scroll->get_value()) - click.at.y -= h; - } + int rel = mm->get_relative().x; + float relf = rel / _get_zoom_scale(); + h_scroll->set_value(h_scroll->get_value() - relf); + } - } break; - case ClickOver::CLICK_MOVE_KEYS: { + if (mm->get_button_mask() == 0) { - click.to = Point2(mb.x, mb.y); - } break; - default: {} - } + Point2 mpos = mm->get_position() - ofs; + if (mpos.y < h) { +#if 0 + //seek + //int zoomw = settings_limit-name_limit; + float scale = _get_zoom_scale(); + float pos = h_scroll->get_val() + (mpos.y-name_limit) / scale; + if (pos<0 ) + pos=0; + if (pos>=animation->get_length()) + pos=animation->get_length(); + timeline->set_val(pos); +#endif return; - } else if (mb.button_mask & BUTTON_MASK_MIDDLE) { - - int rel = mb.relative_x; - float relf = rel / _get_zoom_scale(); - h_scroll->set_value(h_scroll->get_value() - relf); } - if (mb.button_mask == 0) { + mpos.y -= h; - Point2 mpos = Point2(mb.x, mb.y) - ofs; + int idx = mpos.y / h; + idx += v_scroll->get_value(); + if (idx < 0 || idx >= animation->get_track_count()) + return; - if (mpos.y < h) { -#if 0 - //seek - //int zoomw = settings_limit-name_limit; - float scale = _get_zoom_scale(); - float pos = h_scroll->get_val() + (mpos.y-name_limit) / scale; - if (pos<0 ) - pos=0; - if (pos>=animation->get_length()) - pos=animation->get_length(); - timeline->set_val(pos); -#endif - return; - } + mouse_over.track = idx; - mpos.y -= h; + if (mpos.x < name_limit) { + //name column - int idx = mpos.y / h; - idx += v_scroll->get_value(); - if (idx < 0 || idx >= animation->get_track_count()) - break; + mouse_over.over = MouseOver::OVER_NAME; - mouse_over.track = idx; + } else if (mpos.x < settings_limit) { - if (mpos.x < name_limit) { - //name column + float pos = mpos.x - name_limit; + pos /= _get_zoom_scale(); + pos += h_scroll->get_value(); + float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; - mouse_over.over = MouseOver::OVER_NAME; + int kidx = animation->track_find_key(idx, pos); + int kidx_n = kidx + 1; - } else if (mpos.x < settings_limit) { + bool found = false; - float pos = mpos.x - name_limit; - pos /= _get_zoom_scale(); - pos += h_scroll->get_value(); - float w_time = (type_icon[0]->get_width() / _get_zoom_scale()) / 2.0; + if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { - int kidx = animation->track_find_key(idx, pos); - int kidx_n = kidx + 1; + float kpos = animation->track_get_key_time(idx, kidx); + if (ABS(pos - kpos) <= w_time) { - bool found = false; + mouse_over.over = MouseOver::OVER_KEY; + mouse_over.track = idx; + mouse_over.over_key = kidx; + found = true; + } + } - if (kidx >= 0 && kidx < animation->track_get_key_count(idx)) { + if (!found && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { - float kpos = animation->track_get_key_time(idx, kidx); - if (ABS(pos - kpos) <= w_time) { + float kpos = animation->track_get_key_time(idx, kidx_n); + if (ABS(pos - kpos) <= w_time) { - mouse_over.over = MouseOver::OVER_KEY; - mouse_over.track = idx; - mouse_over.over_key = kidx; - found = true; - } + mouse_over.over = MouseOver::OVER_KEY; + mouse_over.track = idx; + mouse_over.over_key = kidx_n; + found = true; } + } - if (!found && kidx_n >= 0 && kidx_n < animation->track_get_key_count(idx)) { + if (found) { - float kpos = animation->track_get_key_time(idx, kidx_n); - if (ABS(pos - kpos) <= w_time) { + String text; + text = "time: " + rtos(animation->track_get_key_time(idx, mouse_over.over_key)) + "\n"; - mouse_over.over = MouseOver::OVER_KEY; - mouse_over.track = idx; - mouse_over.over_key = kidx_n; - found = true; - } - } + switch (animation->track_get_type(idx)) { - if (found) { - - String text; - text = "time: " + rtos(animation->track_get_key_time(idx, mouse_over.over_key)) + "\n"; - - switch (animation->track_get_type(idx)) { - - case Animation::TYPE_TRANSFORM: { - - Dictionary d = animation->track_get_key_value(idx, mouse_over.over_key); - if (d.has("loc")) - text += "loc: " + String(d["loc"]) + "\n"; - if (d.has("rot")) - text += "rot: " + String(d["rot"]) + "\n"; - if (d.has("scale")) - text += "scale: " + String(d["scale"]) + "\n"; - } break; - case Animation::TYPE_VALUE: { - - Variant v = animation->track_get_key_value(idx, mouse_over.over_key); - //text+="value: "+String(v)+"\n"; - - bool prop_exists = false; - Variant::Type valid_type = Variant::NIL; - Object *obj = NULL; - - RES res; - Node *node = root->get_node_and_resource(animation->track_get_path(idx), res); - - if (res.is_valid()) { - obj = res.ptr(); - } else if (node) { - obj = node; - } - - if (obj) { - valid_type = obj->get_static_property_type(animation->track_get_path(idx).get_property(), &prop_exists); - } - - text += "type: " + Variant::get_type_name(v.get_type()) + "\n"; - if (prop_exists && !Variant::can_convert(v.get_type(), valid_type)) { - text += "value: " + String(v) + " (Invalid, expected type: " + Variant::get_type_name(valid_type) + ")\n"; - } else { - text += "value: " + String(v) + "\n"; - } - - } break; - case Animation::TYPE_METHOD: { - - Dictionary d = animation->track_get_key_value(idx, mouse_over.over_key); - if (d.has("method")) - text += String(d["method"]); - text += "("; - Vector<Variant> args; - if (d.has("args")) - args = d["args"]; - for (int i = 0; i < args.size(); i++) { - - if (i > 0) - text += ", "; - text += String(args[i]); - } - text += ")\n"; - - } break; - } - text += "easing: " + rtos(animation->track_get_key_transition(idx, mouse_over.over_key)); + case Animation::TYPE_TRANSFORM: { - track_editor->set_tooltip(text); - return; - } + Dictionary d = animation->track_get_key_value(idx, mouse_over.over_key); + if (d.has("loc")) + text += "loc: " + String(d["loc"]) + "\n"; + if (d.has("rot")) + text += "rot: " + String(d["rot"]) + "\n"; + if (d.has("scale")) + text += "scale: " + String(d["scale"]) + "\n"; + } break; + case Animation::TYPE_VALUE: { - } else { - //button column - int ofsx = size.width - mpos.x; - if (ofsx < 0) - break; - /* - if (ofsx < remove_icon->get_width()) { + Variant v = animation->track_get_key_value(idx, mouse_over.over_key); + //text+="value: "+String(v)+"\n"; - mouse_over.over=MouseOver::OVER_REMOVE; + bool prop_exists = false; + Variant::Type valid_type = Variant::NIL; + Object *obj = NULL; - return; - } + RES res; + Node *node = root->get_node_and_resource(animation->track_get_path(idx), res); - ofsx-=hsep+remove_icon->get_width(); + if (res.is_valid()) { + obj = res.ptr(); + } else if (node) { + obj = node; + } - if (ofsx < move_down_icon->get_width()) { + if (obj) { + valid_type = obj->get_static_property_type(animation->track_get_path(idx).get_property(), &prop_exists); + } - mouse_over.over=MouseOver::OVER_DOWN; - return; + text += "type: " + Variant::get_type_name(v.get_type()) + "\n"; + if (prop_exists && !Variant::can_convert(v.get_type(), valid_type)) { + text += "value: " + String(v) + " (Invalid, expected type: " + Variant::get_type_name(valid_type) + ")\n"; + } else { + text += "value: " + String(v) + "\n"; + } + + } break; + case Animation::TYPE_METHOD: { + + Dictionary d = animation->track_get_key_value(idx, mouse_over.over_key); + if (d.has("method")) + text += String(d["method"]); + text += "("; + Vector<Variant> args; + if (d.has("args")) + args = d["args"]; + for (int i = 0; i < args.size(); i++) { + + if (i > 0) + text += ", "; + text += String(args[i]); + } + text += ")\n"; + + } break; } + text += "easing: " + rtos(animation->track_get_key_transition(idx, mouse_over.over_key)); - ofsx-=hsep+move_down_icon->get_width(); + track_editor->set_tooltip(text); + return; + } - if (ofsx < move_up_icon->get_width()) { + } else { + //button column + int ofsx = size.width - mpos.x; + if (ofsx < 0) + return; + /* + if (ofsx < remove_icon->get_width()) { - mouse_over.over=MouseOver::OVER_UP; - return; - } + mouse_over.over=MouseOver::OVER_REMOVE; - ofsx-=hsep*3+move_up_icon->get_width(); + return; + } - */ + ofsx-=hsep+remove_icon->get_width(); - if (ofsx < down_icon->get_width() + wrap_icon[0]->get_width() + hsep * 3) { + if (ofsx < move_down_icon->get_width()) { - mouse_over.over = MouseOver::OVER_WRAP; - return; - } + mouse_over.over=MouseOver::OVER_DOWN; + return; + } - ofsx -= hsep * 3 + wrap_icon[0]->get_width() + down_icon->get_width(); + ofsx-=hsep+move_down_icon->get_width(); - if (ofsx < down_icon->get_width() + interp_icon[0]->get_width() + hsep * 3) { + if (ofsx < move_up_icon->get_width()) { - mouse_over.over = MouseOver::OVER_INTERP; - return; - } + mouse_over.over=MouseOver::OVER_UP; + return; + } - ofsx -= hsep * 2 + interp_icon[0]->get_width() + down_icon->get_width(); + ofsx-=hsep*3+move_up_icon->get_width(); - if (ofsx < down_icon->get_width() + cont_icon[0]->get_width() + hsep * 3) { +*/ - mouse_over.over = MouseOver::OVER_VALUE; - return; - } + if (ofsx < down_icon->get_width() + wrap_icon[0]->get_width() + hsep * 3) { - ofsx -= hsep * 3 + cont_icon[0]->get_width() + down_icon->get_width(); + mouse_over.over = MouseOver::OVER_WRAP; + return; + } - if (ofsx < add_key_icon->get_width()) { + ofsx -= hsep * 3 + wrap_icon[0]->get_width() + down_icon->get_width(); - mouse_over.over = MouseOver::OVER_ADD_KEY; - return; - } + if (ofsx < down_icon->get_width() + interp_icon[0]->get_width() + hsep * 3) { + + mouse_over.over = MouseOver::OVER_INTERP; + return; } - } - } break; + ofsx -= hsep * 2 + interp_icon[0]->get_width() + down_icon->get_width(); + + if (ofsx < down_icon->get_width() + cont_icon[0]->get_width() + hsep * 3) { + + mouse_over.over = MouseOver::OVER_VALUE; + return; + } + + ofsx -= hsep * 3 + cont_icon[0]->get_width() + down_icon->get_width(); + + if (ofsx < add_key_icon->get_width()) { + + mouse_over.over = MouseOver::OVER_ADD_KEY; + return; + } + } + } } } @@ -2891,6 +2900,8 @@ void AnimationKeyEditor::_notification(int p_what) { key_editor->edit(key_edit); zoomicon->set_texture(get_icon("Zoom", "EditorIcons")); + zoomicon->set_custom_minimum_size(Size2(24 * EDSCALE, 0)); + zoomicon->set_stretch_mode(TextureRect::STRETCH_KEEP_CENTERED); menu_add_track->set_icon(get_icon("AddTrack", "EditorIcons")); menu_add_track->get_popup()->add_icon_item(get_icon("KeyValue", "EditorIcons"), "Add Normal Track", ADD_TRACK_MENU_ADD_VALUE_TRACK); @@ -3928,6 +3939,7 @@ AnimationKeyEditor::AnimationKeyEditor() { v_scroll->set_value(0); key_editor_tab = memnew(TabContainer); + key_editor_tab->set_tab_align(TabContainer::ALIGN_LEFT); hb->add_child(key_editor_tab); key_editor_tab->set_custom_minimum_size(Size2(200, 0)); diff --git a/editor/animation_editor.h b/editor/animation_editor.h index 0f6cc95634..128481c837 100644 --- a/editor/animation_editor.h +++ b/editor/animation_editor.h @@ -273,7 +273,7 @@ class AnimationKeyEditor : public VBoxContainer { float _get_zoom_scale() const; void _track_editor_draw(); - void _track_editor_gui_input(const InputEvent &p_input); + void _track_editor_gui_input(const Ref<InputEvent> &p_input); void _track_pos_draw(); void _track_name_changed(const String &p_name); diff --git a/editor/asset_library_editor_plugin.cpp b/editor/asset_library_editor_plugin.cpp index ca99541bbd..fcb92e13b4 100644 --- a/editor/asset_library_editor_plugin.cpp +++ b/editor/asset_library_editor_plugin.cpp @@ -144,7 +144,7 @@ EditorAssetLibraryItem::EditorAssetLibraryItem() { rating_hb->add_child(stars[i]); } price = memnew(Label); - price->set_text("Free"); + price->set_text(TTR("Free")); vb->add_child(price); set_custom_minimum_size(Size2(250, 100)); @@ -226,12 +226,12 @@ void EditorAssetLibraryItemDescription::configure(const String &p_title, int p_a sha256 = p_sha256_hash; item->configure(p_title, p_asset_id, p_category, p_category_id, p_author, p_author_id, p_rating, p_cost); description->clear(); - description->add_text("Version: " + p_version_string + "\n"); - description->add_text("Contents: "); + description->add_text(TTR("Version:") + " " + p_version_string + "\n"); + description->add_text(TTR("Contents:") + " "); description->push_meta(p_browse_url); - description->add_text("View Files"); + description->add_text(TTR("View Files")); description->pop(); - description->add_text("\nDescription:\n\n"); + description->add_text("\n" + TTR("Description:") + "\n\n"); description->append_bbcode(p_description); set_title(p_title); } @@ -280,7 +280,6 @@ EditorAssetLibraryItemDescription::EditorAssetLibraryItemDescription() { description = memnew(RichTextLabel); description->connect("meta_clicked", this, "_link_click"); - //desc_vbox->add_child(description); desc_bg->add_child(description); desc_bg->add_style_override("panel", get_stylebox("normal", "TextEdit")); @@ -301,8 +300,8 @@ EditorAssetLibraryItemDescription::EditorAssetLibraryItemDescription() { preview_hb->set_v_size_flags(SIZE_EXPAND_FILL); previews->add_child(preview_hb); - get_ok()->set_text("Install"); - get_cancel()->set_text("Close"); + get_ok()->set_text(TTR("Install")); + get_cancel()->set_text(TTR("Close")); } /////////////////////////////////////////////////////////////////////////////////// @@ -314,48 +313,49 @@ void EditorAssetLibraryItemDownload::_http_download_completed(int p_status, int switch (p_status) { case HTTPRequest::RESULT_CANT_RESOLVE: { - error_text = ("Can't resolve hostname: " + host); - status->set_text("Can't resolve."); + error_text = TTR("Can't resolve hostname:") + " " + host; + status->set_text(TTR("Can't resolve.")); } break; case HTTPRequest::RESULT_BODY_SIZE_LIMIT_EXCEEDED: case HTTPRequest::RESULT_CONNECTION_ERROR: case HTTPRequest::RESULT_CHUNKED_BODY_SIZE_MISMATCH: { - error_text = ("Connection error, please try again."); - status->set_text("Can't connect."); + error_text = TTR("Connection error, please try again."); + status->set_text(TTR("Can't connect.")); } break; case HTTPRequest::RESULT_SSL_HANDSHAKE_ERROR: case HTTPRequest::RESULT_CANT_CONNECT: { - error_text = ("Can't connect to host: " + host); - status->set_text("Can't connect."); + error_text = TTR("Can't connect to host:") + " " + host; + status->set_text(TTR("Can't connect.")); } break; case HTTPRequest::RESULT_NO_RESPONSE: { - error_text = ("No response from host: " + host); - status->set_text("No response."); + error_text = TTR("No response from host:") + " " + host; + status->set_text(TTR("No response.")); } break; case HTTPRequest::RESULT_REQUEST_FAILED: { - error_text = ("Request failed, return code: " + itos(p_code)); - status->set_text("Req. Failed."); + error_text = TTR("Request failed, return code:") + " " + itos(p_code); + status->set_text(TTR("Req. Failed.")); } break; case HTTPRequest::RESULT_REDIRECT_LIMIT_REACHED: { - error_text = ("Request failed, too many redirects"); - status->set_text("Redirect Loop."); + error_text = TTR("Request failed, too many redirects"); + status->set_text(TTR("Redirect Loop.")); } break; default: { if (p_code != 200) { - error_text = ("Request failed, return code: " + itos(p_code)); - status->set_text("Failed: " + itos(p_code)); + error_text = TTR("Request failed, return code:") + " " + itos(p_code); + status->set_text(TTR("Failed:") + " " + itos(p_code)); } else if (sha256 != "") { String download_sha256 = FileAccess::get_sha256(download->get_download_file()); if (sha256 != download_sha256) { - error_text = "Bad download hash, assuming file has been tampered with.\nExpected: " + sha256 + "\nGot: " + download_sha256; - status->set_text("Failed sha256 hash check"); + error_text = TTR("Bad download hash, assuming file has been tampered with.") + "\n"; + error_text += TTR("Expected:") + " " + sha256 + "\n" + TTR("Got:") + " " + download_sha256; + status->set_text(TTR("Failed sha256 hash check")); } } } break; } if (error_text != String()) { - download_error->set_text("Asset Download Error:\n" + error_text); + download_error->set_text(TTR("Asset Download Error:") + "\n" + error_text); download_error->popup_centered_minsize(); return; } @@ -368,7 +368,7 @@ void EditorAssetLibraryItemDownload::_http_download_completed(int p_status, int progress->set_value(download->get_downloaded_bytes()); - status->set_text("Success! (" + String::humanize_size(download->get_downloaded_bytes()) + ")"); + status->set_text(TTR("Success!") + " (" + String::humanize_size(download->get_downloaded_bytes()) + ")"); set_process(false); } @@ -396,19 +396,19 @@ void EditorAssetLibraryItemDownload::_notification(int p_what) { int cstatus = download->get_http_client_status(); if (cstatus == HTTPClient::STATUS_BODY) - status->set_text("Fetching: " + String::humanize_size(download->get_downloaded_bytes())); + status->set_text(TTR("Fetching:") + " " + String::humanize_size(download->get_downloaded_bytes())); if (cstatus != prev_status) { switch (cstatus) { case HTTPClient::STATUS_RESOLVING: { - status->set_text("Resolving.."); + status->set_text(TTR("Resolving..")); } break; case HTTPClient::STATUS_CONNECTING: { - status->set_text("Connecting.."); + status->set_text(TTR("Connecting..")); } break; case HTTPClient::STATUS_REQUESTING: { - status->set_text("Requesting.."); + status->set_text(TTR("Requesting..")); } break; default: {} } @@ -442,7 +442,7 @@ void EditorAssetLibraryItemDownload::_make_request() { Error err = download->request(host); if (err != OK) { - status->set_text("Error making request"); + status->set_text(TTR("Error making request")); } else { set_process(true); } @@ -483,7 +483,7 @@ EditorAssetLibraryItemDownload::EditorAssetLibraryItemDownload() { vb->add_spacer(); - status = memnew(Label("Idle")); + status = memnew(Label(TTR("Idle"))); vb->add_child(status); status->add_color_override("font_color", Color(0.5, 0.5, 0.5)); progress = memnew(ProgressBar); @@ -494,12 +494,12 @@ EditorAssetLibraryItemDownload::EditorAssetLibraryItemDownload() { hb2->add_spacer(); install = memnew(Button); - install->set_text("Install"); + install->set_text(TTR("Install")); install->set_disabled(true); install->connect("pressed", this, "_install"); retry = memnew(Button); - retry->set_text("Retry"); + retry->set_text(TTR("Retry")); retry->connect("pressed", this, "_make_request"); hb2->add_child(retry); @@ -512,7 +512,7 @@ EditorAssetLibraryItemDownload::EditorAssetLibraryItemDownload() { download_error = memnew(AcceptDialog); add_child(download_error); - download_error->set_title("Download Error"); + download_error->set_title(TTR("Download Error")); asset_installer = memnew(EditorAssetInstaller); add_child(asset_installer); @@ -585,7 +585,7 @@ void EditorAssetLibrary::_install_asset() { if (d && d->get_asset_id() == description->get_asset_id()) { if (EditorNode::get_singleton() != NULL) - EditorNode::get_singleton()->show_warning("Download for this asset is already in progress!"); + EditorNode::get_singleton()->show_warning(TTR("Download for this asset is already in progress!")); return; } } @@ -683,17 +683,18 @@ void EditorAssetLibrary::_image_update(bool use_cache, bool final, const PoolByt int len = image_data.size(); PoolByteArray::Read r = image_data.read(); - Image image(r.ptr(), len); - if (!image.empty()) { + Ref<Image> image = Ref<Image>(memnew(Image(r.ptr(), len))); + + if (!image->empty()) { float max_height = 10000; switch (image_queue[p_queue_id].image_type) { case IMAGE_QUEUE_ICON: max_height = 80; break; case IMAGE_QUEUE_THUMBNAIL: max_height = 80; break; case IMAGE_QUEUE_SCREENSHOT: max_height = 345; break; } - float scale_ratio = max_height / image.get_height(); + float scale_ratio = max_height / image->get_height(); if (scale_ratio < 1) { - image.resize(image.get_width() * scale_ratio, image.get_height() * scale_ratio, Image::INTERPOLATE_CUBIC); + image->resize(image->get_width() * scale_ratio, image->get_height() * scale_ratio, Image::INTERPOLATE_CUBIC); } Ref<ImageTexture> tex; @@ -902,7 +903,7 @@ HBoxContainer *EditorAssetLibrary::_make_pages(int p_page, int p_page_count, int if (p_page != 0) { LinkButton *first = memnew(LinkButton); - first->set_text("first"); + first->set_text(TTR("first")); first->add_color_override("font_color", gray); first->set_underline_mode(LinkButton::UNDERLINE_MODE_ON_HOVER); first->connect("pressed", this, "_search", varray(0)); @@ -911,7 +912,7 @@ HBoxContainer *EditorAssetLibrary::_make_pages(int p_page, int p_page_count, int if (p_page > 0) { LinkButton *prev = memnew(LinkButton); - prev->set_text("prev"); + prev->set_text(TTR("prev")); prev->add_color_override("font_color", gray); prev->set_underline_mode(LinkButton::UNDERLINE_MODE_ON_HOVER); prev->connect("pressed", this, "_search", varray(p_page - 1)); @@ -939,7 +940,7 @@ HBoxContainer *EditorAssetLibrary::_make_pages(int p_page, int p_page_count, int if (p_page < p_page_count - 1) { LinkButton *next = memnew(LinkButton); - next->set_text("next"); + next->set_text(TTR("next")); next->add_color_override("font_color", gray); next->set_underline_mode(LinkButton::UNDERLINE_MODE_ON_HOVER); next->connect("pressed", this, "_search", varray(p_page + 1)); @@ -949,7 +950,7 @@ HBoxContainer *EditorAssetLibrary::_make_pages(int p_page, int p_page_count, int if (p_page != p_page_count - 1) { LinkButton *last = memnew(LinkButton); - last->set_text("last"); + last->set_text(TTR("last")); last->add_color_override("font_color", gray); last->set_underline_mode(LinkButton::UNDERLINE_MODE_ON_HOVER); hbc->add_child(last); @@ -992,30 +993,30 @@ void EditorAssetLibrary::_http_request_completed(int p_status, int p_code, const switch (p_status) { case HTTPRequest::RESULT_CANT_RESOLVE: { - error_label->set_text("Can't resolve hostname: " + host); + error_label->set_text(TTR("Can't resolve hostname:") + " " + host); } break; case HTTPRequest::RESULT_BODY_SIZE_LIMIT_EXCEEDED: case HTTPRequest::RESULT_CONNECTION_ERROR: case HTTPRequest::RESULT_CHUNKED_BODY_SIZE_MISMATCH: { - error_label->set_text("Connection error, please try again."); + error_label->set_text(TTR("Connection error, please try again.")); } break; case HTTPRequest::RESULT_SSL_HANDSHAKE_ERROR: case HTTPRequest::RESULT_CANT_CONNECT: { - error_label->set_text("Can't connect to host: " + host); + error_label->set_text(TTR("Can't connect to host:") + " " + host); } break; case HTTPRequest::RESULT_NO_RESPONSE: { - error_label->set_text("No response from host: " + host); + error_label->set_text(TTR("No response from host:") + " " + host); } break; case HTTPRequest::RESULT_REQUEST_FAILED: { - error_label->set_text("Request failed, return code: " + itos(p_code)); + error_label->set_text(TTR("Request failed, return code:") + " " + itos(p_code)); } break; case HTTPRequest::RESULT_REDIRECT_LIMIT_REACHED: { - error_label->set_text("Request failed, too many redirects"); + error_label->set_text(TTR("Request failed, too many redirects")); } break; default: { if (p_code != 200) { - error_label->set_text("Request failed, return code: " + itos(p_code)); + error_label->set_text(TTR("Request failed, return code:") + " " + itos(p_code)); } else { error_abort = false; @@ -1048,7 +1049,7 @@ void EditorAssetLibrary::_http_request_completed(int p_status, int p_code, const case REQUESTING_CONFIG: { categories->clear(); - categories->add_item("All"); + categories->add_item(TTR("All")); categories->set_item_metadata(0, 0); if (d.has("categories")) { Array clist = d["categories"]; @@ -1283,7 +1284,7 @@ EditorAssetLibrary::EditorAssetLibrary(bool p_templates_only) { search_hb->add_child(filter); filter->set_h_size_flags(SIZE_EXPAND_FILL); filter->connect("text_entered", this, "_search"); - search = memnew(Button("Search")); + search = memnew(Button(TTR("Search"))); search->connect("pressed", this, "_search"); search_hb->add_child(search); @@ -1291,12 +1292,12 @@ EditorAssetLibrary::EditorAssetLibrary(bool p_templates_only) { search_hb->add_child(memnew(VSeparator)); Button *open_asset = memnew(Button); - open_asset->set_text("Import"); + open_asset->set_text(TTR("Import")); search_hb->add_child(open_asset); open_asset->connect("pressed", this, "_asset_open"); Button *plugins = memnew(Button); - plugins->set_text("Plugins"); + plugins->set_text(TTR("Plugins")); search_hb->add_child(plugins); plugins->connect("pressed", this, "_manage_plugins"); @@ -1342,9 +1343,9 @@ EditorAssetLibrary::EditorAssetLibrary(bool p_templates_only) { search_hb2->add_child(memnew(Label(TTR("Site:") + " "))); repository = memnew(OptionButton); - repository->add_item("Godot"); + repository->add_item("godotengine.org"); repository->set_item_metadata(0, "https://godotengine.org/asset-library/api"); - repository->add_item("Localhost"); // TODO: Maybe remove? + repository->add_item("localhost"); // TODO: Maybe remove? repository->set_item_metadata(1, "http://127.0.0.1/asset-library/api"); repository->connect("item_selected", this, "_repository_changed"); diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp index 20525dd028..2e406fb23d 100644 --- a/editor/code_editor.cpp +++ b/editor/code_editor.cpp @@ -94,17 +94,16 @@ void FindReplaceBar::_notification(int p_what) { } } -void FindReplaceBar::_unhandled_input(const InputEvent &p_event) { +void FindReplaceBar::_unhandled_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_event; + if (k.is_valid()) { - const InputEventKey &k = p_event.key; - - if (k.pressed && (text_edit->has_focus() || text_vbc->is_a_parent_of(get_focus_owner()))) { + if (k->is_pressed() && (text_edit->has_focus() || text_vbc->is_a_parent_of(get_focus_owner()))) { bool accepted = true; - switch (k.scancode) { + switch (k->get_scancode()) { case KEY_ESCAPE: { @@ -957,23 +956,27 @@ FindReplaceDialog::FindReplaceDialog() { /*** CODE EDITOR ****/ -void CodeTextEditor::_text_editor_gui_input(const InputEvent &p_event) { +void CodeTextEditor::_text_editor_gui_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::MOUSE_BUTTON) { + Ref<InputEventMouseButton> mb = p_event; - const InputEventMouseButton &mb = p_event.mouse_button; + if (mb.is_valid()) { - if (mb.pressed && mb.mod.command) { + if (mb->is_pressed() && mb->get_command()) { - if (mb.button_index == BUTTON_WHEEL_UP) { + if (mb->get_button_index() == BUTTON_WHEEL_UP) { _zoom_in(); - } else if (mb.button_index == BUTTON_WHEEL_DOWN) { + } else if (mb->get_button_index() == BUTTON_WHEEL_DOWN) { _zoom_out(); } } - } else if (p_event.type == InputEvent::KEY) { + } + + Ref<InputEventKey> k = p_event; + + if (k.is_valid()) { - if (p_event.key.pressed) { + if (k->is_pressed()) { if (ED_IS_SHORTCUT("script_editor/zoom_in", p_event)) { _zoom_in(); } @@ -1071,7 +1074,8 @@ void CodeTextEditor::update_editor_settings() { text_editor->set_auto_brace_completion(EditorSettings::get_singleton()->get("text_editor/completion/auto_brace_complete")); text_editor->set_scroll_pass_end_of_file(EditorSettings::get_singleton()->get("text_editor/cursor/scroll_past_end_of_file")); - text_editor->set_tab_size(EditorSettings::get_singleton()->get("text_editor/indent/tab_size")); + text_editor->set_indent_using_spaces(EditorSettings::get_singleton()->get("text_editor/indent/type")); + text_editor->set_indent_size(EditorSettings::get_singleton()->get("text_editor/indent/size")); text_editor->set_draw_tabs(EditorSettings::get_singleton()->get("text_editor/indent/draw_tabs")); text_editor->set_show_line_numbers(EditorSettings::get_singleton()->get("text_editor/line_numbers/show_line_numbers")); text_editor->set_line_numbers_zero_padded(EditorSettings::get_singleton()->get("text_editor/line_numbers/line_numbers_zero_padded")); diff --git a/editor/code_editor.h b/editor/code_editor.h index 44d526fda9..8d48c56503 100644 --- a/editor/code_editor.h +++ b/editor/code_editor.h @@ -100,7 +100,7 @@ class FindReplaceBar : public HBoxContainer { protected: void _notification(int p_what); - void _unhandled_input(const InputEvent &p_event); + void _unhandled_input(const Ref<InputEvent> &p_event); bool _search(uint32_t p_flags, int p_from_line, int p_from_col); @@ -213,7 +213,7 @@ class CodeTextEditor : public VBoxContainer { void _complete_request(); void _font_resize_timeout(); - void _text_editor_gui_input(const InputEvent &p_event); + void _text_editor_gui_input(const Ref<InputEvent> &p_event); void _zoom_in(); void _zoom_out(); void _reset_zoom(); diff --git a/editor/connections_dialog.cpp b/editor/connections_dialog.cpp index 9c6624d9e5..9762bd2000 100644 --- a/editor/connections_dialog.cpp +++ b/editor/connections_dialog.cpp @@ -239,7 +239,6 @@ void ConnectDialog::_add_bind() { case Variant::BASIS: value = Basis(); break; case Variant::TRANSFORM: value = Transform(); break; case Variant::COLOR: value = Color(); break; - case Variant::IMAGE: value = Image(); break; default: { ERR_FAIL(); } break; } @@ -327,7 +326,6 @@ ConnectDialog::ConnectDialog() { type_list->add_item("Transform", Variant::TRANSFORM); //type_list->add_separator(); type_list->add_item("Color", Variant::COLOR); - type_list->add_item("Image", Variant::IMAGE); type_list->select(0); Button *add_bind = memnew(Button); @@ -419,6 +417,10 @@ void ConnectionsDock::_notification(int p_what) { //RID ci = get_canvas_item(); //get_stylebox("panel","PopupMenu")->draw(ci,Rect2(Point2(),get_size())); } + + if (p_what == EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED) { + update_tree(); + } } void ConnectionsDock::_close() { @@ -767,7 +769,7 @@ void ConnectionsDock::_something_activated() { Ref<Script> script = c.target->get_script(); - if (script.is_valid() && ScriptEditor::get_singleton()->script_go_to_method(script, c.method)) { + if (script.is_valid() && ScriptEditor::get_singleton()->script_goto_method(script, c.method)) { editor->call("_editor_select", EditorNode::EDITOR_SCRIPT); } } diff --git a/editor/create_dialog.cpp b/editor/create_dialog.cpp index dc28fc9020..1089068344 100644 --- a/editor/create_dialog.cpp +++ b/editor/create_dialog.cpp @@ -109,14 +109,15 @@ void CreateDialog::_text_changed(const String &p_newtext) { _update_search(); } -void CreateDialog::_sbox_input(const InputEvent &p_ie) { +void CreateDialog::_sbox_input(const Ref<InputEvent> &p_ie) { - if (p_ie.type == InputEvent::KEY && (p_ie.key.scancode == KEY_UP || - p_ie.key.scancode == KEY_DOWN || - p_ie.key.scancode == KEY_PAGEUP || - p_ie.key.scancode == KEY_PAGEDOWN)) { + Ref<InputEventKey> k = p_ie; + if (k.is_valid() && (k->get_scancode() == KEY_UP || + k->get_scancode() == KEY_DOWN || + k->get_scancode() == KEY_PAGEUP || + k->get_scancode() == KEY_PAGEDOWN)) { - search_options->call("_gui_input", p_ie); + search_options->call("_gui_input", k); search_box->accept_event(); } } @@ -202,7 +203,7 @@ void CreateDialog::_update_search() { } List<StringName>::Element *I = type_list.front(); - TreeItem *to_select = NULL; + TreeItem *to_select = search_box->get_text() == base_type ? root : NULL; for (; I; I = I->next()) { @@ -488,11 +489,13 @@ void CreateDialog::_favorite_selected() { void CreateDialog::_history_activated() { + _history_selected(); _confirmed(); } void CreateDialog::_favorite_activated() { + _favorite_selected(); _confirmed(); } diff --git a/editor/create_dialog.h b/editor/create_dialog.h index 6170149c6b..02ce762726 100644 --- a/editor/create_dialog.h +++ b/editor/create_dialog.h @@ -69,7 +69,7 @@ class CreateDialog : public ConfirmationDialog { void _history_activated(); void _favorite_activated(); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _confirmed(); void _text_changed(const String &p_newtext); diff --git a/editor/doc/doc_data.cpp b/editor/doc/doc_data.cpp index af95f8d919..6a79f99354 100644 --- a/editor/doc/doc_data.cpp +++ b/editor/doc/doc_data.cpp @@ -295,8 +295,8 @@ void DocData::generate(bool p_basic_types) { case Variant::REAL: //keep it break; - case Variant::STRING: // 15 - case Variant::NODE_PATH: // 15 + case Variant::STRING: + case Variant::NODE_PATH: default_arg_text = "\"" + default_arg_text + "\""; break; case Variant::TRANSFORM: @@ -307,19 +307,19 @@ void DocData::generate(bool p_basic_types) { default_arg_text = Variant::get_type_name(default_arg.get_type()) + "(" + default_arg_text + ")"; break; - case Variant::RECT3: //sorry naming convention fail :( not like it's used often // 10 + case Variant::RECT3: case Variant::COLOR: case Variant::PLANE: case Variant::POOL_BYTE_ARRAY: case Variant::POOL_INT_ARRAY: case Variant::POOL_REAL_ARRAY: - case Variant::POOL_STRING_ARRAY: //25 + case Variant::POOL_STRING_ARRAY: case Variant::POOL_VECTOR2_ARRAY: case Variant::POOL_VECTOR3_ARRAY: case Variant::POOL_COLOR_ARRAY: default_arg_text = Variant::get_type_name(default_arg.get_type()) + "(" + default_arg_text + ")"; break; - case Variant::VECTOR2: // 5 + case Variant::VECTOR2: case Variant::RECT2: case Variant::VECTOR3: case Variant::QUAT: @@ -331,15 +331,10 @@ void DocData::generate(bool p_basic_types) { default_arg_text = "NULL"; break; } - case Variant::INPUT_EVENT: case Variant::DICTIONARY: // 20 case Variant::ARRAY: case Variant::_RID: - case Variant::IMAGE: - //case Variant::RESOURCE: - default_arg_text = Variant::get_type_name(default_arg.get_type()) + "()"; - break; default: {} } @@ -481,97 +476,78 @@ void DocData::generate(bool p_basic_types) { if (i == Variant::OBJECT) continue; //use the core type instead - int loops = 1; - - if (i == Variant::INPUT_EVENT) - loops = InputEvent::TYPE_MAX; - - for (int j = 0; j < loops; j++) { - - String cname = Variant::get_type_name(Variant::Type(i)); - - if (i == Variant::INPUT_EVENT) { - static const char *ie_type[InputEvent::TYPE_MAX] = { - "", "Key", "MouseMotion", "MouseButton", "JoypadMotion", "JoypadButton", "ScreenTouch", "ScreenDrag", "Action" - }; - cname += ie_type[j]; - } - - class_list[cname] = ClassDoc(); - ClassDoc &c = class_list[cname]; - c.name = cname; - c.category = "Built-In Types"; + String cname = Variant::get_type_name(Variant::Type(i)); - Variant::CallError cerror; - Variant v = Variant::construct(Variant::Type(i), NULL, 0, cerror); - - if (i == Variant::INPUT_EVENT) { - v.set("type", j); - } + class_list[cname] = ClassDoc(); + ClassDoc &c = class_list[cname]; + c.name = cname; + c.category = "Built-In Types"; - List<MethodInfo> method_list; - v.get_method_list(&method_list); - method_list.sort(); - Variant::get_constructor_list(Variant::Type(i), &method_list); + Variant::CallError cerror; + Variant v = Variant::construct(Variant::Type(i), NULL, 0, cerror); - for (List<MethodInfo>::Element *E = method_list.front(); E; E = E->next()) { + List<MethodInfo> method_list; + v.get_method_list(&method_list); + method_list.sort(); + Variant::get_constructor_list(Variant::Type(i), &method_list); - MethodInfo &mi = E->get(); - MethodDoc method; + for (List<MethodInfo>::Element *E = method_list.front(); E; E = E->next()) { - method.name = mi.name; + MethodInfo &mi = E->get(); + MethodDoc method; - for (int i = 0; i < mi.arguments.size(); i++) { + method.name = mi.name; - ArgumentDoc arg; - PropertyInfo pi = mi.arguments[i]; + for (int i = 0; i < mi.arguments.size(); i++) { - arg.name = pi.name; - //print_line("arg name: "+arg.name); - if (pi.type == Variant::NIL) - arg.type = "var"; - else - arg.type = Variant::get_type_name(pi.type); - int defarg = mi.default_arguments.size() - mi.arguments.size() + i; - if (defarg >= 0) - arg.default_value = mi.default_arguments[defarg]; + ArgumentDoc arg; + PropertyInfo pi = mi.arguments[i]; - method.arguments.push_back(arg); - } + arg.name = pi.name; + //print_line("arg name: "+arg.name); + if (pi.type == Variant::NIL) + arg.type = "var"; + else + arg.type = Variant::get_type_name(pi.type); + int defarg = mi.default_arguments.size() - mi.arguments.size() + i; + if (defarg >= 0) + arg.default_value = mi.default_arguments[defarg]; - if (mi.return_val.type == Variant::NIL) { - if (mi.return_val.name != "") - method.return_type = "var"; + method.arguments.push_back(arg); + } - } else { - method.return_type = Variant::get_type_name(mi.return_val.type); - } + if (mi.return_val.type == Variant::NIL) { + if (mi.return_val.name != "") + method.return_type = "var"; - c.methods.push_back(method); + } else { + method.return_type = Variant::get_type_name(mi.return_val.type); } - List<PropertyInfo> properties; - v.get_property_list(&properties); - for (List<PropertyInfo>::Element *E = properties.front(); E; E = E->next()) { + c.methods.push_back(method); + } - PropertyInfo pi = E->get(); - PropertyDoc property; - property.name = pi.name; - property.type = Variant::get_type_name(pi.type); + List<PropertyInfo> properties; + v.get_property_list(&properties); + for (List<PropertyInfo>::Element *E = properties.front(); E; E = E->next()) { - c.properties.push_back(property); - } + PropertyInfo pi = E->get(); + PropertyDoc property; + property.name = pi.name; + property.type = Variant::get_type_name(pi.type); + + c.properties.push_back(property); + } - List<StringName> constants; - Variant::get_numeric_constants_for_type(Variant::Type(i), &constants); + List<StringName> constants; + Variant::get_numeric_constants_for_type(Variant::Type(i), &constants); - for (List<StringName>::Element *E = constants.front(); E; E = E->next()) { + for (List<StringName>::Element *E = constants.front(); E; E = E->next()) { - ConstantDoc constant; - constant.name = E->get(); - constant.value = itos(Variant::get_numeric_constant_value(Variant::Type(i), E->get())); - c.constants.push_back(constant); - } + ConstantDoc constant; + constant.name = E->get(); + constant.value = itos(Variant::get_numeric_constant_value(Variant::Type(i), E->get())); + c.constants.push_back(constant); } } diff --git a/editor/doc/doc_dump.cpp b/editor/doc/doc_dump.cpp index bda4d80f4d..79a8f79a7c 100644 --- a/editor/doc/doc_dump.cpp +++ b/editor/doc/doc_dump.cpp @@ -165,8 +165,8 @@ void DocDump::dump(const String &p_file) { case Variant::REAL: //keep it break; - case Variant::STRING: // 15 - case Variant::NODE_PATH: // 15 + case Variant::STRING: + case Variant::NODE_PATH: default_arg_text = "\"" + default_arg_text + "\""; break; case Variant::TRANSFORM: @@ -177,32 +177,27 @@ void DocDump::dump(const String &p_file) { default_arg_text = Variant::get_type_name(default_arg.get_type()) + "(" + default_arg_text + ")"; break; - case Variant::VECTOR2: // 5 + case Variant::VECTOR2: case Variant::RECT2: case Variant::VECTOR3: case Variant::PLANE: case Variant::QUAT: - case Variant::RECT3: //sorry naming convention fail :( not like it's used often // 10 + case Variant::RECT3: case Variant::BASIS: case Variant::COLOR: case Variant::POOL_BYTE_ARRAY: case Variant::POOL_INT_ARRAY: case Variant::POOL_REAL_ARRAY: - case Variant::POOL_STRING_ARRAY: //25 + case Variant::POOL_STRING_ARRAY: case Variant::POOL_VECTOR3_ARRAY: case Variant::POOL_COLOR_ARRAY: default_arg_text = Variant::get_type_name(default_arg.get_type()) + "(" + default_arg_text + ")"; break; case Variant::OBJECT: - case Variant::INPUT_EVENT: case Variant::DICTIONARY: // 20 case Variant::ARRAY: case Variant::_RID: - case Variant::IMAGE: - //case Variant::RESOURCE: - default_arg_text = Variant::get_type_name(default_arg.get_type()) + "()"; - break; default: {} } diff --git a/editor/editor_asset_installer.cpp b/editor/editor_asset_installer.cpp index 5a54f9b46f..96bfb295ea 100644 --- a/editor/editor_asset_installer.cpp +++ b/editor/editor_asset_installer.cpp @@ -113,13 +113,13 @@ void EditorAssetInstaller::open(const String &p_path, int p_depth) { extension_guess["png"] = get_icon("Texture", "EditorIcons"); extension_guess["jpg"] = get_icon("Texture", "EditorIcons"); extension_guess["tex"] = get_icon("Texture", "EditorIcons"); - extension_guess["atex"] = get_icon("Texture", "EditorIcons"); + extension_guess["atlastex"] = get_icon("Texture", "EditorIcons"); extension_guess["dds"] = get_icon("Texture", "EditorIcons"); extension_guess["scn"] = get_icon("PackedScene", "EditorIcons"); extension_guess["tscn"] = get_icon("PackedScene", "EditorIcons"); extension_guess["xml"] = get_icon("PackedScene", "EditorIcons"); extension_guess["xscn"] = get_icon("PackedScene", "EditorIcons"); - extension_guess["mtl"] = get_icon("Material", "EditorIcons"); + extension_guess["material"] = get_icon("Material", "EditorIcons"); extension_guess["shd"] = get_icon("Shader", "EditorIcons"); extension_guess["gd"] = get_icon("GDScript", "EditorIcons"); } @@ -184,6 +184,7 @@ void EditorAssetInstaller::open(const String &p_path, int p_depth) { dir_map[path] = ti; ti->set_text(0, path.get_file() + "/"); ti->set_icon(0, get_icon("folder", "FileDialog")); + ti->set_metadata(0, String()); } else { String file = path.get_file(); String extension = file.get_extension().to_lower(); @@ -305,6 +306,7 @@ void EditorAssetInstaller::ok_pressed() { if (EditorNode::get_singleton() != NULL) EditorNode::get_singleton()->show_warning("Package Installed Successfully!", "Success!"); } + EditorFileSystem::get_singleton()->scan_changes(); } void EditorAssetInstaller::_bind_methods() { diff --git a/editor/editor_audio_buses.cpp b/editor/editor_audio_buses.cpp index 6ef32a6afd..e3e5793ec8 100644 --- a/editor/editor_audio_buses.cpp +++ b/editor/editor_audio_buses.cpp @@ -342,7 +342,7 @@ void EditorAudioBus::_effect_edited() { if (effect->get_metadata(0) == Variant()) { Rect2 area = effects->get_item_rect(effect); - effect_options->set_position(effects->get_global_position() + area.pos + Vector2(0, area.size.y)); + effect_options->set_position(effects->get_global_position() + area.position + Vector2(0, area.size.y)); effect_options->popup(); //add effect } else { @@ -385,15 +385,18 @@ void EditorAudioBus::_effect_add(int p_which) { ur->commit_action(); } -void EditorAudioBus::_gui_input(const InputEvent &p_event) { +void EditorAudioBus::_gui_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::KEY && p_event.key.pressed && p_event.key.scancode == KEY_DELETE && !p_event.key.echo) { + Ref<InputEventKey> k = p_event; + if (k.is_valid() && k->is_pressed() && k->get_scancode() == KEY_DELETE && !k->is_echo()) { accept_event(); emit_signal("delete_request"); } - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 2 && p_event.mouse_button.pressed) { - Vector2 pos = Vector2(p_event.mouse_button.x, p_event.mouse_button.y); + Ref<InputEventMouseButton> mb = p_event; + if (mb.is_valid() && mb->get_button_index() == 2 && mb->is_pressed()) { + + Vector2 pos = Vector2(mb->get_position().x, mb->get_position().y); delete_popup->set_position(get_global_position() + pos); delete_popup->popup(); } @@ -629,21 +632,24 @@ EditorAudioBus::EditorAudioBus(EditorAudioBuses *p_buses) { solo = memnew(ToolButton); solo->set_text("S"); solo->set_toggle_mode(true); - solo->set_modulate(Color(0.8, 1.2, 0.8)); + solo->add_color_override("font_color_pressed", Color(0.2, 0.9, 0.2)); + solo->add_color_override("font_color_hover", Color(0.6, 0.9, 0.6)); solo->set_focus_mode(FOCUS_NONE); solo->connect("pressed", this, "_solo_toggled"); hbc->add_child(solo); mute = memnew(ToolButton); mute->set_text("M"); mute->set_toggle_mode(true); - mute->set_modulate(Color(1.2, 0.8, 0.8)); + mute->add_color_override("font_color_pressed", Color(0.9, 0.2, 0.2)); + mute->add_color_override("font_color_hover", Color(0.9, 0.6, 0.6)); mute->set_focus_mode(FOCUS_NONE); mute->connect("pressed", this, "_mute_toggled"); hbc->add_child(mute); bypass = memnew(ToolButton); bypass->set_text("B"); bypass->set_toggle_mode(true); - bypass->set_modulate(Color(1.1, 1.1, 0.8)); + bypass->add_color_override("font_color_pressed", Color(0.9, 0.9, 0.2)); + bypass->add_color_override("font_color_hover", Color(0.9, 0.9, 0.6)); bypass->set_focus_mode(FOCUS_NONE); bypass->connect("pressed", this, "_bypass_toggled"); hbc->add_child(bypass); @@ -1105,9 +1111,9 @@ EditorAudioBuses::EditorAudioBuses() { file_dialog = memnew(EditorFileDialog); List<String> ext; - ResourceLoader::get_recognized_extensions_for_type("AudioServerState", &ext); + ResourceLoader::get_recognized_extensions_for_type("AudioBusLayout", &ext); for (List<String>::Element *E = ext.front(); E; E = E->next()) { - file_dialog->add_filter("*." + E->get() + "; Audio Bus State"); + file_dialog->add_filter("*." + E->get() + "; Audio Bus Layout"); } add_child(file_dialog); file_dialog->connect("file_selected", this, "_file_dialog_callback"); diff --git a/editor/editor_audio_buses.h b/editor/editor_audio_buses.h index 4a3d784796..f5bf464fd0 100644 --- a/editor/editor_audio_buses.h +++ b/editor/editor_audio_buses.h @@ -75,7 +75,7 @@ class EditorAudioBus : public PanelContainer { bool updating_bus; - void _gui_input(const InputEvent &p_event); + void _gui_input(const Ref<InputEvent> &p_event); void _delete_pressed(int p_option); void _name_changed(const String &p_new_name); diff --git a/editor/editor_data.cpp b/editor/editor_data.cpp index 31c1402c8f..58ffa223fb 100644 --- a/editor/editor_data.cpp +++ b/editor/editor_data.cpp @@ -675,7 +675,12 @@ String EditorData::get_scene_title(int p_idx) const { return "[empty]"; if (edited_scene[p_idx].root->get_filename() == "") return "[unsaved]"; - return edited_scene[p_idx].root->get_filename().get_file(); + bool show_ext = EDITOR_DEF("interface/scene_tabs/show_extension", false); + String name = edited_scene[p_idx].root->get_filename().get_file(); + if (!show_ext) { + name = name.get_basename(); + } + return name; } String EditorData::get_scene_path(int p_idx) const { diff --git a/editor/editor_export.cpp b/editor/editor_export.cpp index 7dc5db4c7d..5cd00738a2 100644 --- a/editor/editor_export.cpp +++ b/editor/editor_export.cpp @@ -28,13 +28,13 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ #include "editor_export.h" + #include "editor/editor_file_system.h" #include "editor/plugins/script_editor_plugin.h" #include "editor_node.h" #include "editor_settings.h" #include "global_config.h" #include "io/config_file.h" -#include "io/md5.h" #include "io/resource_loader.h" #include "io/resource_saver.h" #include "io/zip_io.h" @@ -43,6 +43,8 @@ #include "script_language.h" #include "version.h" +#include "thirdparty/misc/md5.h" + static int _get_pad(int p_alignment, int p_n) { int rest = p_n % p_alignment; @@ -208,7 +210,8 @@ EditorExportPreset::EditorExportPreset() { void EditorExportPlatform::gen_debug_flags(Vector<String> &r_flags, int p_flags) { - String host = EditorSettings::get_singleton()->get("network/debug_host"); + String host = EditorSettings::get_singleton()->get("network/debug/remote_host"); + int remote_port = (int)EditorSettings::get_singleton()->get("network/debug/remote_port"); if (p_flags & DEBUG_FLAG_REMOTE_DEBUG_LOCALHOST) host = "localhost"; @@ -228,7 +231,7 @@ void EditorExportPlatform::gen_debug_flags(Vector<String> &r_flags, int p_flags) r_flags.push_back("-rdebug"); - r_flags.push_back(host + ":" + String::num(GLOBAL_DEF("network/debug/remote_port", 6007))); + r_flags.push_back(host + ":" + String::num(remote_port)); List<String> breakpoints; ScriptEditor::get_singleton()->get_breakpoints(&breakpoints); @@ -319,7 +322,7 @@ Error EditorExportPlatform::_save_zip_file(void *p_userdata, const String &p_pat return OK; } -String EditorExportPlatform::find_export_template(String template_file_name) const { +String EditorExportPlatform::find_export_template(String template_file_name, String *err) const { String base_name = itos(VERSION_MAJOR) + "." + itos(VERSION_MINOR) + "-" + _MKSTR(VERSION_STATUS) + "/" + template_file_name; String user_file = EditorSettings::get_singleton()->get_settings_path() + "/templates/" + base_name; @@ -340,9 +343,20 @@ String EditorExportPlatform::find_export_template(String template_file_name) con return system_file; } } - print_line("none,sorry"); - return String(); //not found + // Not found + if (err) { + *err += "No export template found at \"" + user_file + "\""; + if (has_system_path) + *err += "\n or \"" + system_file + "\"."; + else + *err += "."; + } + return String(); // not found +} + +bool EditorExportPlatform::exists_export_template(String template_file_name, String *err) const { + return find_export_template(template_file_name, err) != ""; } Ref<EditorExportPreset> EditorExportPlatform::create_preset() { @@ -607,7 +621,8 @@ Error EditorExportPlatform::save_zip(const Ref<EditorExportPreset> &p_preset, co void EditorExportPlatform::gen_export_flags(Vector<String> &r_flags, int p_flags) { - String host = EditorSettings::get_singleton()->get("network/debug_host"); + String host = EditorSettings::get_singleton()->get("network/debug/remote_host"); + int remote_port = (int)EditorSettings::get_singleton()->get("network/debug/remote_port"); if (p_flags & DEBUG_FLAG_REMOTE_DEBUG_LOCALHOST) host = "localhost"; @@ -627,7 +642,7 @@ void EditorExportPlatform::gen_export_flags(Vector<String> &r_flags, int p_flags r_flags.push_back("-rdebug"); - r_flags.push_back(host + ":" + String::num(GLOBAL_DEF("network/debug/remote_port", 6007))); + r_flags.push_back(host + ":" + String::num(remote_port)); List<String> breakpoints; ScriptEditor::get_singleton()->get_breakpoints(&breakpoints); @@ -923,19 +938,47 @@ Ref<Texture> EditorExportPlatformPC::get_logo() const { bool EditorExportPlatformPC::can_export(const Ref<EditorExportPreset> &p_preset, String &r_error, bool &r_missing_templates) const { - r_missing_templates = false; + String err; + bool valid = true; + + if (use64 && (!exists_export_template(debug_file_64, &err) || !exists_export_template(release_file_64, &err))) { + valid = false; + } - if (find_export_template(release_file_32) == String()) { - r_missing_templates = true; - } else if (find_export_template(debug_file_32) == String()) { - r_missing_templates = true; - } else if (find_export_template(release_file_64) == String()) { - r_missing_templates = true; - } else if (find_export_template(debug_file_64) == String()) { - r_missing_templates = true; + if (!use64 && (!exists_export_template(debug_file_32, &err) || !exists_export_template(release_file_32, &err))) { + valid = false; } - return !r_missing_templates; + String custom_debug_binary = p_preset->get("custom_template/debug"); + String custom_release_binary = p_preset->get("custom_template/release"); + + if (custom_debug_binary == "" && custom_release_binary == "") { + if (!err.empty()) + r_error = err; + return valid; + } + + bool dvalid = true; + bool rvalid = true; + + if (!FileAccess::exists(custom_debug_binary)) { + dvalid = false; + err = "Custom debug binary not found.\n"; + } + + if (!FileAccess::exists(custom_release_binary)) { + rvalid = false; + err += "Custom release binary not found.\n"; + } + + if (dvalid || rvalid) + valid = true; + else + valid = false; + + if (!err.empty()) + r_error = err; + return valid; } String EditorExportPlatformPC::get_binary_extension() const { @@ -1379,8 +1422,8 @@ Vector<StringName> EditorExportPlatform::get_dependencies(bool p_bundles) const Set<StringName> exported; - if (FileAccess::exists("res://godot.cfg")) - exported.insert("res://godot.cfg"); + if (FileAccess::exists("res://project.godot")) + exported.insert("res://project.godot"); if (EditorImportExport::get_singleton()->get_export_filter()!=EditorImportExport::EXPORT_SELECTED) { @@ -1495,40 +1538,6 @@ Vector<StringName> EditorExportPlatform::get_dependencies(bool p_bundles) const } -String EditorExportPlatform::find_export_template(String template_file_name, String *err) const { - String user_file = EditorSettings::get_singleton()->get_settings_path() - +"/templates/"+template_file_name; - String system_file=OS::get_singleton()->get_installed_templates_path(); - bool has_system_path=(system_file!=""); - system_file+=template_file_name; - - // Prefer user file - if (FileAccess::exists(user_file)) { - return user_file; - } - - // Now check system file - if (has_system_path) { - if (FileAccess::exists(system_file)) { - return system_file; - } - } - - // Not found - if (err) { - *err+="No export template found at \""+user_file+"\""; - if (has_system_path) - *err+="\n or \""+system_file+"\"."; - else - *err+="."; - } - return ""; -} - -bool EditorExportPlatform::exists_export_template(String template_file_name, String *err) const { - return find_export_template(template_file_name,err)!=""; -} - /////////////////////////////////////// @@ -1934,14 +1943,14 @@ Error EditorExportPlatform::export_project_files(EditorExportSaveFunction p_func atex->set_region(region); atex->set_margin(margin); - String path = EditorSettings::get_singleton()->get_settings_path()+"/tmp/tmpatlas.atex"; + String path = EditorSettings::get_singleton()->get_settings_path()+"/tmp/tmpatlas.atlastex"; Error err = ResourceSaver::save(path,atex); if (err!=OK) { EditorNode::add_io_error(TTR("Could not save atlas subtexture:")+" "+path); return ERR_CANT_CREATE; } Vector<uint8_t> data = FileAccess::get_file_as_array(path); - String dst_path = F->get().operator String().get_basename()+".atex"; + String dst_path = F->get().operator String().get_basename()+".atlastex"; err = p_func(p_udata,dst_path,data,counter++,files.size()); saved.insert(dst_path); if (err) @@ -1976,7 +1985,7 @@ Error EditorExportPlatform::export_project_files(EditorExportSaveFunction p_func } - StringName engine_cfg="res://godot.cfg"; + StringName engine_cfg="res://project.godot"; StringName boot_splash; { String splash=GlobalConfig::get_singleton()->get("application/boot_splash"); //avoid splash from being converted @@ -2030,7 +2039,7 @@ Error EditorExportPlatform::export_project_files(EditorExportSaveFunction p_func { - //make binary godot.cfg config + //make binary project.godot config Map<String,Variant> custom; @@ -2101,7 +2110,8 @@ static int _get_pad(int p_alignment, int p_n) { void EditorExportPlatform::gen_export_flags(Vector<String> &r_flags, int p_flags) { - String host = EditorSettings::get_singleton()->get("network/debug_host"); + String host = EditorSettings::get_singleton()->get("network/debug/remote_host"); + int remote_port = (int)EditorSettings::get_singleton()->get("network/debug/remote_port"); if (p_flags&EXPORT_REMOTE_DEBUG_LOCALHOST) host="localhost"; @@ -2121,7 +2131,7 @@ void EditorExportPlatform::gen_export_flags(Vector<String> &r_flags, int p_flags r_flags.push_back("-rdebug"); - r_flags.push_back(host+":"+String::num(GLOBAL_DEF("network/debug/remote_port", 6007))); + r_flags.push_back(host+":"+String::num(remote_port)); List<String> breakpoints; ScriptEditor::get_singleton()->get_breakpoints(&breakpoints); @@ -2428,50 +2438,6 @@ void EditorExportPlatformPC::set_binary_extension(const String& p_extension) { binary_extension=p_extension; } -bool EditorExportPlatformPC::can_export(String *r_error) const { - - String err; - bool valid=true; - - if (use64 && (!exists_export_template(debug_binary64) || !exists_export_template(release_binary64))) { - valid=false; - err="No 64 bits export templates found.\nDownload and install export templates.\n"; - } - - if (!use64 && (!exists_export_template(debug_binary32) || !exists_export_template(release_binary32))) { - valid=false; - err="No 32 bits export templates found.\nDownload and install export templates.\n"; - } - - if(custom_debug_binary=="" && custom_release_binary=="") { - if (r_error) *r_error=err; - return valid; - } - - bool dvalid = true; - bool rvalid = true; - - if(!FileAccess::exists(custom_debug_binary)) { - dvalid = false; - err = "Custom debug binary not found.\n"; - } - - if(!FileAccess::exists(custom_release_binary)) { - rvalid = false; - err = "Custom release binary not found.\n"; - } - - if (dvalid || rvalid) - valid = true; - else - valid = false; - - if (r_error) - *r_error=err; - return valid; -} - - EditorExportPlatformPC::EditorExportPlatformPC() { export_mode=EXPORT_PACK; diff --git a/editor/editor_export.h b/editor/editor_export.h index a78762ad80..740f05174b 100644 --- a/editor/editor_export.h +++ b/editor/editor_export.h @@ -154,7 +154,8 @@ private: protected: virtual void get_preset_features(const Ref<EditorExportPreset> &p_preset, List<String> *r_features) = 0; - String find_export_template(String template_file_name) const; + bool exists_export_template(String template_file_name, String *err) const; + String find_export_template(String template_file_name, String *err = NULL) const; void gen_export_flags(Vector<String> &r_flags, int p_flags); public: @@ -258,6 +259,8 @@ class EditorExportPlatformPC : public EditorExportPlatform { String debug_file_32; String debug_file_64; + bool use64; + public: virtual void get_preset_features(const Ref<EditorExportPreset> &p_preset, List<String> *r_features); diff --git a/editor/editor_file_dialog.cpp b/editor/editor_file_dialog.cpp index 1f97aba221..c2a408e8ab 100644 --- a/editor/editor_file_dialog.cpp +++ b/editor/editor_file_dialog.cpp @@ -95,11 +95,13 @@ void EditorFileDialog::_notification(int p_what) { } } -void EditorFileDialog::_unhandled_input(const InputEvent &p_event) { +void EditorFileDialog::_unhandled_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::KEY && is_window_modal_on_top()) { + Ref<InputEventKey> k = p_event; - if (p_event.key.pressed) { + if (k.is_valid() && is_window_modal_on_top()) { + + if (k->is_pressed()) { bool handled = false; @@ -488,8 +490,9 @@ void EditorFileDialog::update_file_list() { if (!has_icon("ResizedFolder", "EditorIcons")) { Ref<ImageTexture> folder = get_icon("FolderBig", "EditorIcons"); - Image img = folder->get_data(); - img.resize(thumbnail_size, thumbnail_size); + Ref<Image> img = folder->get_data(); + img = img->duplicate(); + img->resize(thumbnail_size, thumbnail_size); Ref<ImageTexture> resized_folder = Ref<ImageTexture>(memnew(ImageTexture)); resized_folder->create_from_image(img, 0); Theme::get_default()->set_icon("ResizedFolder", "EditorIcons", resized_folder); @@ -499,8 +502,9 @@ void EditorFileDialog::update_file_list() { if (!has_icon("ResizedFile", "EditorIcons")) { Ref<ImageTexture> file = get_icon("FileBig", "EditorIcons"); - Image img = file->get_data(); - img.resize(thumbnail_size, thumbnail_size); + Ref<Image> img = file->get_data(); + img = img->duplicate(); + img->resize(thumbnail_size, thumbnail_size); Ref<ImageTexture> resized_file = Ref<ImageTexture>(memnew(ImageTexture)); resized_file->create_from_image(img, 0); Theme::get_default()->set_icon("ResizedFile", "EditorIcons", resized_file); @@ -552,8 +556,8 @@ void EditorFileDialog::update_file_list() { dirs.push_back(".."); } - dirs.sort_custom<NoCaseComparator>(); - files.sort_custom<NoCaseComparator>(); + dirs.sort_custom<NaturalNoCaseComparator>(); + files.sort_custom<NaturalNoCaseComparator>(); while (!dirs.empty()) { const String &dir_name = dirs.front()->get(); @@ -1296,16 +1300,21 @@ EditorFileDialog::EditorFileDialog() { favorite->connect("toggled", this, "_favorite_toggled"); pathhb->add_child(favorite); + Ref<ButtonGroup> view_mode_group; + view_mode_group.instance(); + mode_thumbnails = memnew(ToolButton); mode_thumbnails->connect("pressed", this, "set_display_mode", varray(DISPLAY_THUMBNAILS)); mode_thumbnails->set_toggle_mode(true); mode_thumbnails->set_pressed(display_mode == DISPLAY_THUMBNAILS); + mode_thumbnails->set_button_group(view_mode_group); pathhb->add_child(mode_thumbnails); mode_list = memnew(ToolButton); mode_list->connect("pressed", this, "set_display_mode", varray(DISPLAY_LIST)); mode_list->set_toggle_mode(true); mode_list->set_pressed(display_mode == DISPLAY_LIST); + mode_list->set_button_group(view_mode_group); pathhb->add_child(mode_list); drives = memnew(OptionButton); diff --git a/editor/editor_file_dialog.h b/editor/editor_file_dialog.h index f8c85c4ad1..f44193c70b 100644 --- a/editor/editor_file_dialog.h +++ b/editor/editor_file_dialog.h @@ -169,7 +169,7 @@ private: void _thumbnail_done(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata); void _request_single_thumbnail(const String &p_path); - void _unhandled_input(const InputEvent &p_event); + void _unhandled_input(const Ref<InputEvent> &p_event); protected: void _notification(int p_what); diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp index 2612a2af16..f314f772d1 100644 --- a/editor/editor_file_system.cpp +++ b/editor/editor_file_system.cpp @@ -153,6 +153,7 @@ EditorFileSystemDirectory::EditorFileSystemDirectory() { modified_time = 0; parent = NULL; + verified = false; } EditorFileSystemDirectory::~EditorFileSystemDirectory() { @@ -509,7 +510,7 @@ void EditorFileSystem::_scan_new_dir(EditorFileSystemDirectory *p_dir, DirAccess if (f.begins_with(".")) //ignore hidden and . / .. continue; - if (FileAccess::exists(cd.plus_file(f).plus_file("godot.cfg"))) // skip if another project inside this + if (FileAccess::exists(cd.plus_file(f).plus_file("project.godot"))) // skip if another project inside this continue; dirs.push_back(f); @@ -522,8 +523,8 @@ void EditorFileSystem::_scan_new_dir(EditorFileSystemDirectory *p_dir, DirAccess da->list_dir_end(); - dirs.sort(); - files.sort(); + dirs.sort_custom<NaturalNoCaseComparator>(); + files.sort_custom<NaturalNoCaseComparator>(); int total = dirs.size() + files.size(); int idx = 0; @@ -688,7 +689,7 @@ void EditorFileSystem::_scan_fs_changes(EditorFileSystemDirectory *p_dir, const int idx = p_dir->find_dir_index(f); if (idx == -1) { - if (FileAccess::exists(cd.plus_file(f).plus_file("godot.cfg"))) // skip if another project inside this + if (FileAccess::exists(cd.plus_file(f).plus_file("project.godot"))) // skip if another project inside this continue; EditorFileSystemDirectory *efd = memnew(EditorFileSystemDirectory); @@ -1040,7 +1041,10 @@ bool EditorFileSystem::_find_file(const String &p_file, EditorFileSystemDirector if (idx == -1) { //does not exist, create i guess? EditorFileSystemDirectory *efsd = memnew(EditorFileSystemDirectory); + efsd->name = path[i]; + efsd->parent = fs; + int idx2 = 0; for (int j = 0; j < fs->get_subdir_count(); j++) { @@ -1421,6 +1425,7 @@ EditorFileSystem::EditorFileSystem() { singleton = this; filesystem = memnew(EditorFileSystemDirectory); //like, empty + filesystem->parent = NULL; thread = NULL; scanning = false; @@ -1429,7 +1434,9 @@ EditorFileSystem::EditorFileSystem() { thread_sources = NULL; new_filesystem = NULL; + abort_scan = false; scanning_changes = false; + scanning_changes_done = false; ResourceSaver::set_save_callback(_resource_saved); DirAccess *da = DirAccess::create(DirAccess::ACCESS_RESOURCES); diff --git a/editor/editor_file_system.h b/editor/editor_file_system.h index b5d61d47d3..3522a1ab1d 100644 --- a/editor/editor_file_system.h +++ b/editor/editor_file_system.h @@ -168,8 +168,6 @@ class EditorFileSystem : public Node { void _scan_fs_changes(EditorFileSystemDirectory *p_dir, const ScanProgress &p_progress); - int md_count; - Set<String> valid_extensions; Set<String> import_extensions; diff --git a/editor/editor_fonts.cpp b/editor/editor_fonts.cpp index dc4c2b21bc..0873b90f22 100644 --- a/editor/editor_fonts.cpp +++ b/editor/editor_fonts.cpp @@ -49,8 +49,8 @@ static Ref<BitmapFont> make_font(int p_height, int p_ascent, int p_valign, int p int chr = c[0]; Rect2 frect; - frect.pos.x = c[1]; - frect.pos.y = c[2]; + frect.position.x = c[1]; + frect.position.y = c[2]; frect.size.x = c[3]; frect.size.y = c[4]; Point2 align(c[5], c[6] + p_valign); diff --git a/editor/editor_help.cpp b/editor/editor_help.cpp index 11fa9396a0..11cb61370d 100644 --- a/editor/editor_help.cpp +++ b/editor/editor_help.cpp @@ -61,14 +61,16 @@ void EditorHelpSearch::_text_changed(const String &p_newtext) { _update_search(); } -void EditorHelpSearch::_sbox_input(const InputEvent &p_ie) { +void EditorHelpSearch::_sbox_input(const Ref<InputEvent> &p_ie) { - if (p_ie.type == InputEvent::KEY && (p_ie.key.scancode == KEY_UP || - p_ie.key.scancode == KEY_DOWN || - p_ie.key.scancode == KEY_PAGEUP || - p_ie.key.scancode == KEY_PAGEDOWN)) { + Ref<InputEventKey> k = p_ie; - search_options->call("_gui_input", p_ie); + if (k.is_valid() && (k->get_scancode() == KEY_UP || + k->get_scancode() == KEY_DOWN || + k->get_scancode() == KEY_PAGEUP || + k->get_scancode() == KEY_PAGEDOWN)) { + + search_options->call("_gui_input", k); search_box->accept_event(); } } @@ -250,8 +252,8 @@ void EditorHelpSearch::_confirmed() { return; String mdata = ti->get_metadata(0); + EditorNode::get_singleton()->set_visible_editor(EditorNode::EDITOR_SCRIPT); emit_signal("go_to_help", mdata); - editor->call("_editor_select", EditorNode::EDITOR_SCRIPT); // in case EditorHelpSearch beeen invoked on top of other editor window // go to that hide(); } @@ -286,7 +288,6 @@ void EditorHelpSearch::_bind_methods() { EditorHelpSearch::EditorHelpSearch() { - editor = EditorNode::get_singleton(); VBoxContainer *vbc = memnew(VBoxContainer); add_child(vbc); @@ -360,8 +361,8 @@ void EditorHelpIndex::_tree_item_selected() { if (!s) return; + EditorNode::get_singleton()->set_visible_editor(EditorNode::EDITOR_SCRIPT); emit_signal("open_class", s->get_text(0)); - hide(); //_goto_desc(s->get_text(0)); @@ -448,14 +449,16 @@ void EditorHelpIndex::_update_class_list() { } } -void EditorHelpIndex::_sbox_input(const InputEvent &p_ie) { +void EditorHelpIndex::_sbox_input(const Ref<InputEvent> &p_ie) { + + Ref<InputEventKey> k = p_ie; - if (p_ie.type == InputEvent::KEY && (p_ie.key.scancode == KEY_UP || - p_ie.key.scancode == KEY_DOWN || - p_ie.key.scancode == KEY_PAGEUP || - p_ie.key.scancode == KEY_PAGEDOWN)) { + if (k.is_valid() && (k->get_scancode() == KEY_UP || + k->get_scancode() == KEY_DOWN || + k->get_scancode() == KEY_PAGEUP || + k->get_scancode() == KEY_PAGEDOWN)) { - class_list->call("_gui_input", p_ie); + class_list->call("_gui_input", k); search_box->accept_event(); } } @@ -499,11 +502,14 @@ EditorHelpIndex::EditorHelpIndex() { /// ///////////////////////////////// DocData *EditorHelp::doc = NULL; -void EditorHelp::_unhandled_key_input(const InputEvent &p_ev) { +void EditorHelp::_unhandled_key_input(const Ref<InputEvent> &p_ev) { if (!is_visible_in_tree()) return; - if (p_ev.key.mod.control && p_ev.key.scancode == KEY_F) { + + Ref<InputEventKey> k = p_ev; + + if (k.is_valid() && k->get_control() && k->get_scancode() == KEY_F) { search->grab_focus(); search->select_all(); @@ -598,8 +604,11 @@ void EditorHelp::_class_desc_select(const String &p_select) { } } -void EditorHelp::_class_desc_input(const InputEvent &p_input) { - if (p_input.type == InputEvent::MOUSE_BUTTON && p_input.mouse_button.pressed && p_input.mouse_button.button_index == 1) { +void EditorHelp::_class_desc_input(const Ref<InputEvent> &p_input) { + + Ref<InputEventMouseButton> mb = p_input; + + if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == 1) { class_desc->set_selection_enabled(false); class_desc->set_selection_enabled(true); } @@ -1269,7 +1278,7 @@ Error EditorHelp::_goto_desc(const String &p_class, int p_vscr) { void EditorHelp::_request_help(const String &p_string) { Error err = _goto_desc(p_string); if (err == OK) { - editor->call("_editor_select", EditorNode::EDITOR_SCRIPT); + EditorNode::get_singleton()->set_visible_editor(EditorNode::EDITOR_SCRIPT); } //100 palabras } @@ -1679,8 +1688,6 @@ void EditorHelp::_bind_methods() { EditorHelp::EditorHelp() { - editor = EditorNode::get_singleton(); - VBoxContainer *vbc = this; EDITOR_DEF("text_editor/help/sort_functions_alphabetically", true); @@ -1776,7 +1783,7 @@ void EditorHelpBit::_bind_methods() { void EditorHelpBit::_notification(int p_what) { if (p_what == NOTIFICATION_ENTER_TREE) { - add_style_override("panel", get_stylebox("normal", "TextEdit")); + add_style_override("panel", get_stylebox("ScriptPanel", "EditorStyles")); } } diff --git a/editor/editor_help.h b/editor/editor_help.h index d22d61b91d..46d83490f4 100644 --- a/editor/editor_help.h +++ b/editor/editor_help.h @@ -49,14 +49,13 @@ class EditorHelpSearch : public ConfirmationDialog { GDCLASS(EditorHelpSearch, ConfirmationDialog) - EditorNode *editor; LineEdit *search_box; Tree *search_options; String base_type; void _update_search(); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _confirmed(); void _text_changed(const String &p_newtext); @@ -81,7 +80,7 @@ class EditorHelpIndex : public ConfirmationDialog { void _tree_item_selected(); void _text_changed(const String &p_text); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _update_class_list(); @@ -119,7 +118,6 @@ class EditorHelp : public VBoxContainer { String edited_class; - EditorNode *editor; Map<String, int> method_line; Map<String, int> signal_line; Map<String, int> property_line; @@ -147,7 +145,7 @@ class EditorHelp : public VBoxContainer { void _scroll_changed(double p_scroll); void _class_list_select(const String &p_select); void _class_desc_select(const String &p_select); - void _class_desc_input(const InputEvent &p_input); + void _class_desc_input(const Ref<InputEvent> &p_input); Error _goto_desc(const String &p_class, int p_vscr = -1); //void _update_history_buttons(); @@ -157,7 +155,7 @@ class EditorHelp : public VBoxContainer { void _search(const String &p_str); void _search_cbk(); - void _unhandled_key_input(const InputEvent &p_ev); + void _unhandled_key_input(const Ref<InputEvent> &p_ev); protected: void _notification(int p_what); diff --git a/editor/editor_log.cpp b/editor/editor_log.cpp index c15eac67fb..5d13c7c254 100644 --- a/editor/editor_log.cpp +++ b/editor/editor_log.cpp @@ -87,6 +87,9 @@ void EditorLog::_notification(int p_what) { log->add_color_override("default_color", get_color("font_color", "Tree")); //button->set_icon(get_icon("Console","EditorIcons")); } + if (p_what == EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED) { + _override_logger_styles(); + } /*if (p_what==NOTIFICATION_DRAW) { diff --git a/editor/editor_name_dialog.cpp b/editor/editor_name_dialog.cpp index 972857fd88..d4c418bfc9 100644 --- a/editor/editor_name_dialog.cpp +++ b/editor/editor_name_dialog.cpp @@ -32,14 +32,16 @@ #include "class_db.h" #include "os/keyboard.h" -void EditorNameDialog::_line_gui_input(const InputEvent &p_event) { +void EditorNameDialog::_line_gui_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_event; - if (!p_event.key.pressed) + if (k.is_valid()) { + + if (!k->is_pressed()) return; - switch (p_event.key.scancode) { + switch (k->get_scancode()) { case KEY_ENTER: case KEY_RETURN: { @@ -79,9 +81,11 @@ void EditorNameDialog::_bind_methods() { } EditorNameDialog::EditorNameDialog() { + makevb = memnew(VBoxContainer); + add_child(makevb); name = memnew(LineEdit); - add_child(name); - move_child(name, get_label()->get_index() + 1); + makevb->add_child(name); + makevb->move_child(name, get_label()->get_index() + 1); name->set_margin(MARGIN_TOP, 5); name->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_BEGIN, 5); name->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 5); diff --git a/editor/editor_name_dialog.h b/editor/editor_name_dialog.h index a98db4ffe6..57586951d1 100644 --- a/editor/editor_name_dialog.h +++ b/editor/editor_name_dialog.h @@ -38,9 +38,10 @@ class EditorNameDialog : public ConfirmationDialog { GDCLASS(EditorNameDialog, ConfirmationDialog); + VBoxContainer *makevb; LineEdit *name; - void _line_gui_input(const InputEvent &p_event); + void _line_gui_input(const Ref<InputEvent> &p_event); protected: static void _bind_methods(); diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 1223abd76c..56b62cdf6e 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -30,6 +30,7 @@ #include "editor_node.h" #include "animation_editor.h" +#include "authors.h" #include "bind/core_bind.h" #include "class_db.h" #include "core/io/resource_loader.h" @@ -72,10 +73,10 @@ #include "plugins/collision_polygon_2d_editor_plugin.h" #include "plugins/collision_polygon_editor_plugin.h" #include "plugins/collision_shape_2d_editor_plugin.h" -#include "plugins/color_ramp_editor_plugin.h" #include "plugins/cube_grid_theme_editor_plugin.h" #include "plugins/curve_editor_plugin.h" #include "plugins/gi_probe_editor_plugin.h" +#include "plugins/gradient_editor_plugin.h" #include "plugins/gradient_texture_editor_plugin.h" #include "plugins/item_list_editor_plugin.h" #include "plugins/light_occluder_2d_editor_plugin.h" @@ -173,12 +174,13 @@ void EditorNode::_update_title() { OS::get_singleton()->set_window_title(title); } -void EditorNode::_unhandled_input(const InputEvent &p_event) { +void EditorNode::_unhandled_input(const Ref<InputEvent> &p_event) { if (Node::get_viewport()->get_modal_stack_top()) return; //ignore because of modal window - if (p_event.type == InputEvent::KEY && p_event.key.pressed && !p_event.key.echo && !gui_base->get_viewport()->gui_has_modal_stack()) { + Ref<InputEventKey> k = p_event; + if (k.is_valid() && k->is_pressed() && !k->is_echo() && !gui_base->get_viewport()->gui_has_modal_stack()) { if (ED_IS_SHORTCUT("editor/next_tab", p_event)) { int next_tab = editor_data.get_edited_scene() + 1; @@ -194,28 +196,20 @@ void EditorNode::_unhandled_input(const InputEvent &p_event) { filesystem_dock->focus_on_filter(); } - switch (p_event.key.scancode) { - - /*case KEY_F1: - if (!p_event.key.mod.shift && !p_event.key.mod.command) - _editor_select(EDITOR_SCRIPT); - break;*/ - case KEY_F1: - if (!p_event.key.mod.shift && !p_event.key.mod.command) - _editor_select(EDITOR_2D); - break; - case KEY_F2: - if (!p_event.key.mod.shift && !p_event.key.mod.command) - _editor_select(EDITOR_3D); - break; - case KEY_F3: - if (!p_event.key.mod.shift && !p_event.key.mod.command) - _editor_select(EDITOR_SCRIPT); - break; - /* case KEY_F5: _menu_option_confirm((p_event.key.mod.control&&p_event.key.mod.shift)?RUN_PLAY_CUSTOM_SCENE:RUN_PLAY,true); break; - case KEY_F6: _menu_option_confirm(RUN_PLAY_SCENE,true); break; - //case KEY_F7: _menu_option_confirm(RUN_PAUSE,true); break; - case KEY_F8: _menu_option_confirm(RUN_STOP,true); break;*/ + if (ED_IS_SHORTCUT("editor/editor_2d", p_event)) { + _editor_select(EDITOR_2D); + } else if (ED_IS_SHORTCUT("editor/editor_3d", p_event)) { + _editor_select(EDITOR_3D); + } else if (ED_IS_SHORTCUT("editor/editor_script", p_event)) { + _editor_select(EDITOR_SCRIPT); + } else if (ED_IS_SHORTCUT("editor/editor_help", p_event)) { + emit_signal("request_help_search", ""); + } else if (ED_IS_SHORTCUT("editor/editor_assetlib", p_event)) { + _editor_select(EDITOR_ASSETLIB); + } else if (ED_IS_SHORTCUT("editor/editor_next", p_event)) { + _editor_select_next(); + } else if (ED_IS_SHORTCUT("editor/editor_prev", p_event)) { + _editor_select_prev(); } } } @@ -276,28 +270,9 @@ void EditorNode::_notification(int p_what) { update_menu->set_icon(gui_base->get_icon("Progress" + itos(circle_step + 1), "EditorIcons")); } } - editor_selection->update(); - { - uint32_t p32 = 0; //AudioServer::get_singleton()->read_output_peak()>>8; - - float peak = p32 == 0 ? -80 : Math::linear2db(p32 / 65535.0); - - if (peak < -80) - peak = -80; - float vu = audio_vu->get_value(); - - if (peak > vu) { - audio_vu->set_value(peak); - } else { - float new_vu = vu - get_process_delta_time() * 70.0; - if (new_vu < -80) - new_vu = -80; - if (new_vu != -80 && vu != -80) - audio_vu->set_value(new_vu); - } - } + scene_root->set_size_override(true, Size2(GlobalConfig::get_singleton()->get("display/window/width"), GlobalConfig::get_singleton()->get("display/window/height"))); ResourceImporterTexture::get_singleton()->update_imports(); } @@ -356,10 +331,25 @@ void EditorNode::_notification(int p_what) { if (p_what == MainLoop::NOTIFICATION_WM_QUIT_REQUEST) { _menu_option_confirm(FILE_QUIT, false); - }; + } if (p_what == EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED) { scene_tabs->set_tab_close_display_policy((bool(EDITOR_DEF("interface/always_show_close_button_in_scene_tabs", false)) ? Tabs::CLOSE_BUTTON_SHOW_ALWAYS : Tabs::CLOSE_BUTTON_SHOW_ACTIVE_ONLY)); + property_editor->set_enable_capitalize_paths(bool(EDITOR_DEF("interface/capitalize_properties", true))); + Ref<Theme> theme = create_editor_theme(); + theme_base->set_theme(theme); + gui_base->add_style_override("panel", gui_base->get_stylebox("Background", "EditorStyles")); + play_button_panel->add_style_override("panel", gui_base->get_stylebox("PlayButtonPanel", "EditorStyles")); + scene_root_parent->add_style_override("panel", gui_base->get_stylebox("Content", "EditorStyles")); + bottom_panel->add_style_override("panel", gui_base->get_stylebox("Content", "EditorStyles")); + scene_tabs->add_style_override("tab_fg", gui_base->get_stylebox("SceneTabFG", "EditorStyles")); + scene_tabs->add_style_override("tab_bg", gui_base->get_stylebox("SceneTabBG", "EditorStyles")); + if (bool(EDITOR_DEF("interface/scene_tabs/resize_if_many_tabs", true))) { + scene_tabs->set_min_width(int(EDITOR_DEF("interface/scene_tabs/minimum_width", 50)) * EDSCALE); + } else { + scene_tabs->set_min_width(0); + } + _update_scene_tabs(); } } @@ -435,7 +425,7 @@ void EditorNode::_sources_changed(bool p_exist) { if (defer_load_scene != "") { - print_line("loading scene DEFERED"); + print_line("loading scene DEFERRED"); load_scene(defer_load_scene); defer_load_scene = ""; } @@ -447,24 +437,36 @@ void EditorNode::_sources_changed(bool p_exist) { void EditorNode::_vp_resized() { } -void EditorNode::_rebuild_import_menu() { - PopupMenu *p = import_menu->get_popup(); - p->clear(); -//p->add_item(TTR("Node From Scene"), FILE_IMPORT_SUBSCENE); -//p->add_separator(); -#if 0 - for (int i = 0; i < editor_import_export->get_import_plugin_count(); i++) { - p->add_item(editor_import_export->get_import_plugin(i)->get_visible_name(), IMPORT_PLUGIN_BASE + i); - } -#endif -} - void EditorNode::_node_renamed() { if (property_editor) property_editor->update_tree(); } +void EditorNode::_editor_select_next() { + + int editor = _get_current_main_editor(); + + if (editor == editor_table.size() - 1) { + editor = 0; + } else { + editor++; + } + _editor_select(editor); +} + +void EditorNode::_editor_select_prev() { + + int editor = _get_current_main_editor(); + + if (editor == 0) { + editor = editor_table.size() - 1; + } else { + editor--; + } + _editor_select(editor); +} + Error EditorNode::load_resource(const String &p_scene) { RES res = ResourceLoader::load(p_scene); @@ -831,56 +833,54 @@ void EditorNode::_save_scene_with_preview(String p_file) { } save.step(TTR("Creating Thumbnail"), 1); //current view? - int screen = -1; - for (int i = 0; i < editor_table.size(); i++) { - if (editor_plugin_screen == editor_table[i]) { - screen = i; - break; - } + + Ref<Image> img; + if (is2d) { + img = scene_root->get_texture()->get_data(); + } else { + img = SpatialEditor::get_singleton()->get_editor_viewport(0)->get_viewport_node()->get_texture()->get_data(); } - _editor_select(is2d ? EDITOR_2D : EDITOR_3D); + if (img.is_valid()) { + save.step(TTR("Creating Thumbnail"), 2); + save.step(TTR("Creating Thumbnail"), 3); - save.step(TTR("Creating Thumbnail"), 2); - save.step(TTR("Creating Thumbnail"), 3); -#if 0 - Image img = VS::get_singleton()->viewport_texture(scree_capture(viewport); - int preview_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - preview_size*=EDSCALE; - int width,height; - if (img.get_width() > preview_size && img.get_width() >= img.get_height()) { + int preview_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); + preview_size *= EDSCALE; + int width, height; + if (img->get_width() > preview_size && img->get_width() >= img->get_height()) { - width=preview_size; - height = img.get_height() * preview_size / img.get_width(); - } else if (img.get_height() > preview_size && img.get_height() >= img.get_width()) { + width = preview_size; + height = img->get_height() * preview_size / img->get_width(); + } else if (img->get_height() > preview_size && img->get_height() >= img->get_width()) { - height=preview_size; - width = img.get_width() * preview_size / img.get_height(); - } else { + height = preview_size; + width = img->get_width() * preview_size / img->get_height(); + } else { - width=img.get_width(); - height=img.get_height(); - } + width = img->get_width(); + height = img->get_height(); + } - img.convert(Image::FORMAT_RGB8); - img.resize(width,height); + img->convert(Image::FORMAT_RGB8); + img->resize(width, height); + img->flip_y(); - String pfile = EditorSettings::get_singleton()->get_settings_path().plus_file("tmp/last_scene_preview.png"); - img.save_png(pfile); - Vector<uint8_t> imgdata = FileAccess::get_file_as_array(pfile); + //save thumbnail directly, as thumbnailer may not update due to actual scene not changing md5 + String temp_path = EditorSettings::get_singleton()->get_settings_path().plus_file("tmp"); + String cache_base = GlobalConfig::get_singleton()->globalize_path(p_file).md5_text(); + cache_base = temp_path.plus_file("resthumb-" + cache_base); - //print_line("img data is "+itos(imgdata.size())); + //does not have it, try to load a cached thumbnail - if (editor_data.get_edited_scene_import_metadata().is_null()) - editor_data.set_edited_scene_import_metadata(Ref<ResourceImportMetadata>( memnew( ResourceImportMetadata ) ) ); - editor_data.get_edited_scene_import_metadata()->set_option("thumbnail",imgdata); -#endif - //tamanio tel thumbnail - if (screen != -1) { - _editor_select(screen); + String file = cache_base + ".png"; + + img->save_png(file); } + save.step(TTR("Saving Scene"), 4); _save_scene(p_file); + EditorResourcePreview::get_singleton()->check_for_invalidation(p_file); } void EditorNode::_save_scene(String p_file, int idx) { @@ -898,6 +898,7 @@ void EditorNode::_save_scene(String p_file, int idx) { } editor_data.apply_changes_in_editors(); + _save_default_environment(); _set_scene_metadata(p_file, idx); @@ -959,7 +960,7 @@ void EditorNode::_save_scene(String p_file, int idx) { _dialog_display_file_error(p_file, err); } -}; +} void EditorNode::_import_action(const String &p_action) { #if 0 @@ -1092,6 +1093,7 @@ void EditorNode::_dialog_action(String p_file) { GlobalConfig::get_singleton()->set("application/main_scene", p_file); GlobalConfig::get_singleton()->save(); //would be nice to show the project manager opened with the highlighted field.. + _run(false, ""); // automatically run the project } break; case FILE_SAVE_OPTIMIZED: { @@ -1122,6 +1124,7 @@ void EditorNode::_dialog_action(String p_file) { if (file->get_mode() == EditorFileDialog::MODE_SAVE_FILE) { //_save_scene(p_file); + _save_default_environment(); _save_scene_with_preview(p_file); } @@ -1131,6 +1134,7 @@ void EditorNode::_dialog_action(String p_file) { if (file->get_mode() == EditorFileDialog::MODE_SAVE_FILE) { //_save_scene(p_file); + _save_default_environment(); _save_scene_with_preview(p_file); _call_build(); _run(true); @@ -1384,6 +1388,17 @@ void EditorNode::_property_editor_back() { _edit_current(); } +void EditorNode::_save_default_environment() { + + Ref<Environment> fallback = get_tree()->get_root()->get_world()->get_fallback_environment(); + + if (fallback.is_valid() && fallback->get_path().is_resource_file()) { + Map<RES, bool> processed; + _find_and_save_edited_subresources(fallback.ptr(), processed, 0); + save_resource_in_path(fallback, fallback->get_path()); + } +} + void EditorNode::_imported(Node *p_node) { /* @@ -1462,11 +1477,16 @@ void EditorNode::_edit_current() { Node *current_node = current_obj->cast_to<Node>(); ERR_FAIL_COND(!current_node); - ERR_FAIL_COND(!current_node->is_inside_tree()); + // ERR_FAIL_COND(!current_node->is_inside_tree()); property_editor->edit(current_node); - node_dock->set_node(current_node); - scene_tree_dock->set_selected(current_node); + if (current_node->is_inside_tree()) { + node_dock->set_node(current_node); + scene_tree_dock->set_selected(current_node); + } else { + node_dock->set_node(NULL); + scene_tree_dock->set_selected(NULL); + } object_menu->get_popup()->clear(); //top_pallete->set_current_tab(0); @@ -1662,7 +1682,7 @@ void EditorNode::_run(bool p_current, const String &p_custom) { current_option = -1; //accept->get_cancel()->hide(); - pick_main_scene->set_text(TTR("No main scene has ever been defined, select one?\nYou can change it later in later in \"Project Settings\" under the 'application' category.")); + pick_main_scene->set_text(TTR("No main scene has ever been defined, select one?\nYou can change it later in \"Project Settings\" under the 'application' category.")); pick_main_scene->popup_centered_minsize(); return; } @@ -1960,17 +1980,20 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { } } // else: ignore new scenes } + + _save_default_environment(); } break; case FILE_SAVE_BEFORE_RUN: { if (!p_confirmed) { - accept->get_ok()->set_text(TTR("Yes")); - accept->set_text(TTR("This scene has never been saved. Save before running?")); - accept->popup_centered_minsize(); + confirmation->get_cancel()->set_text(TTR("No")); + confirmation->get_ok()->set_text(TTR("Yes")); + confirmation->set_text(TTR("This scene has never been saved. Save before running?")); + confirmation->popup_centered_minsize(); break; } _menu_option(FILE_SAVE_AS_SCENE); - _menu_option_confirm(FILE_SAVE_AND_RUN, true); + _menu_option_confirm(FILE_SAVE_AND_RUN, false); } break; case FILE_SAVE_OPTIMIZED: { @@ -2393,6 +2416,8 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { } break; case RUN_PLAY_SCENE: { + + _save_default_environment(); _menu_option_confirm(RUN_STOP, true); _call_build(); _run(true); @@ -2445,28 +2470,28 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { case RUN_FILE_SERVER: { //file_server - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_FILE_SERVER)); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_FILE_SERVER)); if (ischecked) { file_server->stop(); run_native->set_deploy_dumb(false); - //debug_button->set_icon(gui_base->get_icon("FileServer","EditorIcons")); - //debug_button->get_popup()->set_item_text( debug_button->get_popup()->get_item_index(RUN_FILE_SERVER),"Enable File Server"); + //debug_menu->set_icon(gui_base->get_icon("FileServer","EditorIcons")); + //debug_menu->get_popup()->set_item_text( debug_menu->get_popup()->get_item_index(RUN_FILE_SERVER),"Enable File Server"); } else { file_server->start(); run_native->set_deploy_dumb(true); - //debug_button->set_icon(gui_base->get_icon("FileServerActive","EditorIcons")); - //debug_button->get_popup()->set_item_text( debug_button->get_popup()->get_item_index(RUN_FILE_SERVER),"Disable File Server"); + //debug_menu->set_icon(gui_base->get_icon("FileServerActive","EditorIcons")); + //debug_menu->get_popup()->set_item_text( debug_menu->get_popup()->get_item_index(RUN_FILE_SERVER),"Disable File Server"); } - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_FILE_SERVER), !ischecked); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_FILE_SERVER), !ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_file_server", !ischecked); } break; case RUN_LIVE_DEBUG: { - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_LIVE_DEBUG)); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_LIVE_DEBUG)); - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_LIVE_DEBUG), !ischecked); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_LIVE_DEBUG), !ischecked); ScriptEditor::get_singleton()->get_debugger()->set_live_debugging(!ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_live_debug", !ischecked); @@ -2474,23 +2499,23 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { /*case RUN_DEPLOY_DUMB_CLIENTS: { - bool ischecked = debug_button->get_popup()->is_item_checked( debug_button->get_popup()->get_item_index(RUN_DEPLOY_DUMB_CLIENTS)); - debug_button->get_popup()->set_item_checked( debug_button->get_popup()->get_item_index(RUN_DEPLOY_DUMB_CLIENTS),!ischecked); + bool ischecked = debug_menu->get_popup()->is_item_checked( debug_menu->get_popup()->get_item_index(RUN_DEPLOY_DUMB_CLIENTS)); + debug_menu->get_popup()->set_item_checked( debug_menu->get_popup()->get_item_index(RUN_DEPLOY_DUMB_CLIENTS),!ischecked); run_native->set_deploy_dumb(!ischecked); } break;*/ case RUN_DEPLOY_REMOTE_DEBUG: { - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_DEPLOY_REMOTE_DEBUG)); - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_DEPLOY_REMOTE_DEBUG), !ischecked); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEPLOY_REMOTE_DEBUG)); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEPLOY_REMOTE_DEBUG), !ischecked); run_native->set_deploy_debug_remote(!ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_deploy_remote_debug", !ischecked); } break; case RUN_DEBUG_COLLISONS: { - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_DEBUG_COLLISONS)); - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_DEBUG_COLLISONS), !ischecked); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEBUG_COLLISONS)); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEBUG_COLLISONS), !ischecked); run_native->set_debug_collisions(!ischecked); editor_run.set_debug_collisions(!ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_debug_collisons", !ischecked); @@ -2498,8 +2523,8 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { } break; case RUN_DEBUG_NAVIGATION: { - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_DEBUG_NAVIGATION)); - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_DEBUG_NAVIGATION), !ischecked); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEBUG_NAVIGATION)); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_DEBUG_NAVIGATION), !ischecked); run_native->set_debug_navigation(!ischecked); editor_run.set_debug_navigation(!ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_debug_navigation", !ischecked); @@ -2507,8 +2532,8 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { } break; case RUN_RELOAD_SCRIPTS: { - bool ischecked = debug_button->get_popup()->is_item_checked(debug_button->get_popup()->get_item_index(RUN_RELOAD_SCRIPTS)); - debug_button->get_popup()->set_item_checked(debug_button->get_popup()->get_item_index(RUN_RELOAD_SCRIPTS), !ischecked); + bool ischecked = debug_menu->get_popup()->is_item_checked(debug_menu->get_popup()->get_item_index(RUN_RELOAD_SCRIPTS)); + debug_menu->get_popup()->set_item_checked(debug_menu->get_popup()->get_item_index(RUN_RELOAD_SCRIPTS), !ischecked); ScriptEditor::get_singleton()->set_live_auto_reload_running_scripts(!ischecked); EditorSettings::get_singleton()->set_project_metadata("debug_options", "run_reload_scripts", !ischecked); @@ -2570,8 +2595,25 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) { file->popup_centered_ratio(); } break; - case SETTINGS_ABOUT: { - + case HELP_CLASSES: { + emit_signal("request_help_index", ""); + } break; + case HELP_SEARCH: { + emit_signal("request_help_search", ""); + } break; + case HELP_DOCS: { + OS::get_singleton()->shell_open("http://docs.godotengine.org/"); + } break; + case HELP_QA: { + OS::get_singleton()->shell_open("https://godotengine.org/qa/"); + } break; + case HELP_ISSUES: { + OS::get_singleton()->shell_open("https://github.com/godotengine/godot/issues"); + } break; + case HELP_COMMUNITY: { + OS::get_singleton()->shell_open("https://godotengine.org/community"); + } break; + case HELP_ABOUT: { about->popup_centered_minsize(Size2(500, 130) * EDSCALE); } break; case SOURCES_REIMPORT: { @@ -2700,6 +2742,14 @@ void EditorNode::_editor_select(int p_which) { editor_plugin_screen = new_editor; editor_plugin_screen->make_visible(true); editor_plugin_screen->selected_notify(); + + if (EditorSettings::get_singleton()->get("interface/separate_distraction_mode")) { + if (p_which == EDITOR_SCRIPT) { + set_distraction_free_mode(script_distraction); + } else { + set_distraction_free_mode(scene_distraction); + } + } } void EditorNode::add_editor_plugin(EditorPlugin *p_editor) { @@ -2710,6 +2760,8 @@ void EditorNode::add_editor_plugin(EditorPlugin *p_editor) { tb->set_toggle_mode(true); tb->connect("pressed", singleton, "_editor_select", varray(singleton->main_editor_buttons.size())); tb->set_text(p_editor->get_name()); + tb->set_icon(p_editor->get_base_control()->get_icon(p_editor->get_name(), "EditorIcons")); + tb->set_name(p_editor->get_name()); singleton->main_editor_buttons.push_back(tb); singleton->main_editor_button_vb->add_child(tb); singleton->editor_table.push_back(p_editor); @@ -3569,7 +3621,7 @@ bool EditorNode::is_scene_in_use(const String &p_path) { void EditorNode::register_editor_types() { ClassDB::register_class<EditorPlugin>(); - // ClassDB::register_class<EditorImportPlugin>(); + ClassDB::register_class<EditorImportPlugin>(); // ClassDB::register_class<EditorExportPlugin>(); // ClassDB::register_class<EditorScenePostImport>(); ClassDB::register_class<EditorScript>(); @@ -3689,11 +3741,13 @@ void EditorNode::show_warning(const String &p_text, const String &p_title) { warning->popup_centered_minsize(); } -void EditorNode::_dock_select_input(const InputEvent &p_input) { +void EditorNode::_dock_select_input(const Ref<InputEvent> &p_input) { + + Ref<InputEventMouse> me = p_input; - if (p_input.type == InputEvent::MOUSE_BUTTON || p_input.type == InputEvent::MOUSE_MOTION) { + if (me.is_valid()) { - Vector2 point(p_input.mouse_motion.x, p_input.mouse_motion.y); + Vector2 point = me->get_position(); int nrect = -1; for (int i = 0; i < DOCK_SLOT_MAX; i++) { @@ -3711,7 +3765,9 @@ void EditorNode::_dock_select_input(const InputEvent &p_input) { if (nrect == -1) return; - if (p_input.type == InputEvent::MOUSE_BUTTON && p_input.mouse_button.button_index == 1 && p_input.mouse_button.pressed && dock_popup_selected != nrect) { + Ref<InputEventMouseButton> mb = me; + + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed() && dock_popup_selected != nrect) { Control *dock = dock_slot[dock_popup_selected]->get_current_tab_control(); if (dock) { dock_slot[dock_popup_selected]->remove_child(dock); @@ -3801,7 +3857,7 @@ void EditorNode::_dock_select_draw() { unusable.a = 0.1; Rect2 unr(s.x * 2, 0, s.x * 2, s.y * 2); - unr.pos += Vector2(2, 5); + unr.position += Vector2(2, 5); unr.size -= Vector2(4, 7); dock_select->draw_rect(unr, unusable); @@ -3854,7 +3910,7 @@ void EditorNode::_dock_select_draw() { Rect2 r(ofs, s); dock_select_rect[i] = r; - r.pos += Vector2(2, 5); + r.position += Vector2(2, 5); r.size -= Vector2(4, 7); if (i == dock_select_rect_over) { @@ -4222,7 +4278,47 @@ void EditorNode::_scene_tab_closed(int p_tab) { } } +void EditorNode::_scene_tab_hover(int p_tab) { + if (bool(EDITOR_DEF("interface/scene_tabs/show_thumbnail_on_hover", true)) == false) { + return; + } + int current_tab = scene_tabs->get_current_tab(); + + if (p_tab == current_tab || p_tab < 0) { + tab_preview_panel->hide(); + } else { + String path = editor_data.get_scene_path(p_tab); + EditorResourcePreview::get_singleton()->queue_resource_preview(path, this, "_thumbnail_done", p_tab); + } +} + +void EditorNode::_scene_tab_exit() { + tab_preview_panel->hide(); +} + +void EditorNode::_scene_tab_input(const Ref<InputEvent> &p_input) { + Ref<InputEventMouseButton> mb = p_input; + + if (mb.is_valid()) { + if (mb->get_button_index() == BUTTON_MIDDLE && mb->is_pressed() && scene_tabs->get_hovered_tab() >= 0) { + _scene_tab_closed(scene_tabs->get_hovered_tab()); + } + } +} + +void EditorNode::_thumbnail_done(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata) { + int p_tab = p_udata.operator signed int(); + if (p_preview.is_valid()) { + Rect2 rect = scene_tabs->get_tab_rect(p_tab); + rect.position += scene_tabs->get_global_position(); + tab_preview->set_texture(p_preview); + tab_preview_panel->set_position(rect.position + Vector2(0, rect.size.height)); + tab_preview_panel->show(); + } +} + void EditorNode::_scene_tab_changed(int p_tab) { + tab_preview_panel->hide(); //print_line("set current 1 "); bool unsaved = (saved_version != editor_data.get_undo_redo().get_version()); @@ -4393,7 +4489,25 @@ bool EditorNode::get_docks_visible() const { void EditorNode::_toggle_distraction_free_mode() { - set_distraction_free_mode(distraction_free->is_pressed()); + if (EditorSettings::get_singleton()->get("interface/separate_distraction_mode")) { + int screen = -1; + for (int i = 0; i < editor_table.size(); i++) { + if (editor_plugin_screen == editor_table[i]) { + screen = i; + break; + } + } + + if (screen == EDITOR_SCRIPT) { + script_distraction = !script_distraction; + set_distraction_free_mode(script_distraction); + } else { + scene_distraction = !scene_distraction; + set_distraction_free_mode(scene_distraction); + } + } else { + set_distraction_free_mode(distraction_free->is_pressed()); + } } void EditorNode::set_distraction_free_mode(bool p_enter) { @@ -4448,8 +4562,9 @@ Variant EditorNode::drag_resource(const Ref<Resource> &p_res, Control *p_from) { { //todo make proper previews Ref<ImageTexture> pic = gui_base->get_icon("FileBig", "EditorIcons"); - Image img = pic->get_data(); - img.resize(48, 48); //meh + Ref<Image> img = pic->get_data(); + img = img->duplicate(); + img->resize(48, 48); //meh Ref<ImageTexture> resized_pic = Ref<ImageTexture>(memnew(ImageTexture)); resized_pic->create_from_image(img); preview = resized_pic; @@ -4693,6 +4808,22 @@ void EditorNode::_dim_timeout() { } } +void EditorNode::_check_gui_base_size() { + if (gui_base->get_size().width > 1200 * EDSCALE) { + for (int i = 0; i < singleton->main_editor_button_vb->get_child_count(); i++) { + ToolButton *btn = singleton->main_editor_button_vb->get_child(i)->cast_to<ToolButton>(); + if (btn == singleton->distraction_free) continue; + btn->set_text(btn->get_name()); + } + } else { + for (int i = 0; i < singleton->main_editor_button_vb->get_child_count(); i++) { + ToolButton *btn = singleton->main_editor_button_vb->get_child(i)->cast_to<ToolButton>(); + if (btn == singleton->distraction_free) continue; + btn->set_text(""); + } + } +} + void EditorNode::open_export_template_manager() { export_template_manager->popup_manager(); @@ -4754,6 +4885,10 @@ void EditorNode::_bind_methods() { ClassDB::bind_method("set_current_version", &EditorNode::set_current_version); ClassDB::bind_method("_scene_tab_changed", &EditorNode::_scene_tab_changed); ClassDB::bind_method("_scene_tab_closed", &EditorNode::_scene_tab_closed); + ClassDB::bind_method("_scene_tab_hover", &EditorNode::_scene_tab_hover); + ClassDB::bind_method("_scene_tab_exit", &EditorNode::_scene_tab_exit); + ClassDB::bind_method("_scene_tab_input", &EditorNode::_scene_tab_input); + ClassDB::bind_method("_thumbnail_done", &EditorNode::_thumbnail_done); ClassDB::bind_method("_scene_tab_script_edited", &EditorNode::_scene_tab_script_edited); ClassDB::bind_method("_set_main_scene_state", &EditorNode::_set_main_scene_state); ClassDB::bind_method("_update_scene_tabs", &EditorNode::_update_scene_tabs); @@ -4775,11 +4910,14 @@ void EditorNode::_bind_methods() { ClassDB::bind_method(D_METHOD("_open_imported"), &EditorNode::_open_imported); ClassDB::bind_method(D_METHOD("_inherit_imported"), &EditorNode::_inherit_imported); ClassDB::bind_method(D_METHOD("_dim_timeout"), &EditorNode::_dim_timeout); + ClassDB::bind_method(D_METHOD("_check_gui_base_size"), &EditorNode::_check_gui_base_size); ADD_SIGNAL(MethodInfo("play_pressed")); ADD_SIGNAL(MethodInfo("pause_pressed")); ADD_SIGNAL(MethodInfo("stop_pressed")); ADD_SIGNAL(MethodInfo("request_help")); + ADD_SIGNAL(MethodInfo("request_help_search")); + ADD_SIGNAL(MethodInfo("request_help_index")); ADD_SIGNAL(MethodInfo("script_add_function_request", PropertyInfo(Variant::OBJECT, "obj"), PropertyInfo(Variant::STRING, "function"), PropertyInfo(Variant::POOL_STRING_ARRAY, "args"))); ADD_SIGNAL(MethodInfo("resource_saved", PropertyInfo(Variant::OBJECT, "obj"))); } @@ -4794,6 +4932,7 @@ EditorNode::EditorNode() { Resource::_get_local_scene_func = _resource_get_edited_scene; VisualServer::get_singleton()->textures_keep_original(true); + VisualServer::get_singleton()->set_debug_generate_wireframes(true); EditorHelp::generate_doc(); //before any editor classes are crated SceneState::set_disable_placeholders(true); @@ -4817,6 +4956,9 @@ EditorNode::EditorNode() { _initializing_addons = false; docks_visible = true; + scene_distraction = false; + script_distraction = false; + FileAccess::set_backup_save(true); TranslationServer::get_singleton()->set_enabled(false); @@ -4904,17 +5046,19 @@ EditorNode::EditorNode() { ClassDB::set_class_enabled("CollisionShape2D", true); ClassDB::set_class_enabled("CollisionPolygon2D", true); - Control *theme_base = memnew(Control); + theme_base = memnew(Control); add_child(theme_base); theme_base->set_area_as_parent_rect(); gui_base = memnew(Panel); theme_base->add_child(gui_base); gui_base->set_area_as_parent_rect(); + gui_base->connect("item_rect_changed", this, "_check_gui_base_size"); Ref<Theme> theme = create_editor_theme(); theme_base->set_theme(theme); gui_base->set_theme(create_custom_theme()); + gui_base->add_style_override("panel", gui_base->get_stylebox("Background", "EditorStyles")); resource_preview = memnew(EditorResourcePreview); add_child(resource_preview); @@ -4929,6 +5073,7 @@ EditorNode::EditorNode() { main_vbox = memnew(VBoxContainer); gui_base->add_child(main_vbox); main_vbox->set_area_as_parent_rect(8); + main_vbox->set_margin(MARGIN_TOP, 5); #if 0 PanelContainer *top_dark_panel = memnew( PanelContainer ); @@ -5060,14 +5205,12 @@ EditorNode::EditorNode() { dock_select_rect_over = -1; dock_popup_selected = -1; //dock_select_popoup->set_(Size2(20,20)); - for (int i = 0; i < DOCK_SLOT_MAX; i++) { dock_slot[i]->set_custom_minimum_size(Size2(230, 220) * EDSCALE); dock_slot[i]->set_v_size_flags(Control::SIZE_EXPAND_FILL); dock_slot[i]->set_popup(dock_select_popoup); dock_slot[i]->connect("pre_popup_pressed", this, "_dock_pre_popup", varray(i)); - - //dock_slot[i]->set_tab_align(TabContainer::ALIGN_LEFT); + dock_slot[i]->set_tab_align(TabContainer::ALIGN_LEFT); } dock_drag_timer = memnew(Timer); @@ -5090,18 +5233,47 @@ EditorNode::EditorNode() { main_editor_tabs->connect("tab_changed",this,"_editor_select"); main_editor_tabs->set_tab_close_display_policy(Tabs::SHOW_NEVER); */ + tab_preview_panel = memnew(Panel); + tab_preview_panel->set_size(Size2(100, 100) * EDSCALE); + tab_preview_panel->hide(); + tab_preview_panel->set_self_modulate(Color(1, 1, 1, 0.7)); + gui_base->add_child(tab_preview_panel); + + tab_preview = memnew(TextureRect); + tab_preview->set_stretch_mode(TextureRect::STRETCH_KEEP_ASPECT_CENTERED); + tab_preview->set_size(Size2(96, 96) * EDSCALE); + tab_preview->set_position(Point2(2, 2) * EDSCALE); + tab_preview_panel->add_child(tab_preview); + scene_tabs = memnew(Tabs); + scene_tabs->add_style_override("tab_fg", gui_base->get_stylebox("SceneTabFG", "EditorStyles")); + scene_tabs->add_style_override("tab_bg", gui_base->get_stylebox("SceneTabBG", "EditorStyles")); scene_tabs->add_tab("unsaved"); - scene_tabs->set_tab_align(Tabs::ALIGN_CENTER); + scene_tabs->set_tab_align(Tabs::ALIGN_LEFT); scene_tabs->set_tab_close_display_policy((bool(EDITOR_DEF("interface/always_show_close_button_in_scene_tabs", false)) ? Tabs::CLOSE_BUTTON_SHOW_ALWAYS : Tabs::CLOSE_BUTTON_SHOW_ACTIVE_ONLY)); + scene_tabs->set_min_width(int(EDITOR_DEF("interface/scene_tabs/minimum_width", 50)) * EDSCALE); scene_tabs->connect("tab_changed", this, "_scene_tab_changed"); scene_tabs->connect("right_button_pressed", this, "_scene_tab_script_edited"); scene_tabs->connect("tab_close", this, "_scene_tab_closed"); + scene_tabs->connect("tab_hover", this, "_scene_tab_hover"); + scene_tabs->connect("mouse_exited", this, "_scene_tab_exit"); + scene_tabs->connect("gui_input", this, "_scene_tab_input"); - srt->add_child(scene_tabs); + HBoxContainer *tabbar_container = memnew(HBoxContainer); + scene_tabs->set_h_size_flags(Control::SIZE_EXPAND_FILL); + + srt->add_child(tabbar_container); + tabbar_container->add_child(scene_tabs); + distraction_free = memnew(ToolButton); + tabbar_container->add_child(distraction_free); + distraction_free->set_shortcut(ED_SHORTCUT("editor/distraction_free_mode", TTR("Distraction Free Mode"), KEY_MASK_CMD | KEY_MASK_SHIFT | KEY_F11)); + distraction_free->connect("pressed", this, "_toggle_distraction_free_mode"); + distraction_free->set_icon(gui_base->get_icon("DistractionFree", "EditorIcons")); + distraction_free->set_toggle_mode(true); scene_root_parent = memnew(PanelContainer); scene_root_parent->set_custom_minimum_size(Size2(0, 80) * EDSCALE); + scene_root_parent->add_style_override("panel", gui_base->get_stylebox("Content", "EditorStyles")); //Ref<StyleBox> sp = scene_root_parent->get_stylebox("panel","TabContainer"); //scene_root_parent->add_style_override("panel",sp); @@ -5127,23 +5299,53 @@ EditorNode::EditorNode() { viewport = memnew(VBoxContainer); viewport->set_v_size_flags(Control::SIZE_EXPAND_FILL); + viewport->add_constant_override("separation", 0); /*for(int i=0;i<4;i++) { viewport->set_margin(Margin(i),sp->get_margin(Margin(i))); }*/ scene_root_parent->add_child(viewport); PanelContainer *top_region = memnew(PanelContainer); - top_region->add_style_override("panel", gui_base->get_stylebox("hover", "Button")); + top_region->add_style_override("panel", gui_base->get_stylebox("MenuPanel", "EditorStyles")); HBoxContainer *left_menu_hb = memnew(HBoxContainer); top_region->add_child(left_menu_hb); menu_hb->add_child(top_region); PopupMenu *p; + project_menu = memnew(MenuButton); + project_menu->set_tooltip(TTR("Miscellaneous project or scene-wide tools.")); + project_menu->set_text(TTR("Project")); + project_menu->add_style_override("hover", gui_base->get_stylebox("MenuHover", "EditorStyles")); + left_menu_hb->add_child(project_menu); + + p = project_menu->get_popup(); + p->connect("id_pressed", this, "_menu_option"); + p->add_item(TTR("Run Script"), FILE_RUN_SCRIPT, KEY_MASK_SHIFT + KEY_MASK_CMD + KEY_R); + p->add_item(TTR("Export"), FILE_EXPORT_PROJECT); + + PopupMenu *tool_menu = memnew(PopupMenu); + tool_menu->set_name("Tools"); + tool_menu->connect("id_pressed", this, "_menu_option"); + p->add_child(tool_menu); + p->add_submenu_item(TTR("Tools"), "Tools"); + tool_menu->add_item(TTR("Orphan Resource Explorer"), TOOLS_ORPHAN_RESOURCES); + p->add_separator(); + p->add_item(TTR("Project Settings"), RUN_SETTINGS); + p->add_separator(); + +#ifdef OSX_ENABLED + p->add_item(TTR("Quit to Project List"), RUN_PROJECT_MANAGER, KEY_MASK_SHIFT + KEY_MASK_ALT + KEY_Q); +#else + p->add_item(TTR("Quit to Project List"), RUN_PROJECT_MANAGER, KEY_MASK_SHIFT + KEY_MASK_CTRL + KEY_Q); +#endif + p->add_item(TTR("Quit"), FILE_QUIT, KEY_MASK_CMD + KEY_Q); + file_menu = memnew(MenuButton); file_menu->set_text(TTR("Scene")); //file_menu->set_icon(gui_base->get_icon("Save","EditorIcons")); left_menu_hb->add_child(file_menu); + file_menu->add_style_override("hover", gui_base->get_stylebox("MenuHover", "EditorStyles")); prev_scene = memnew(ToolButton); prev_scene->set_icon(gui_base->get_icon("PrevScene", "EditorIcons")); @@ -5191,18 +5393,7 @@ EditorNode::EditorNode() { p->add_shortcut(ED_SHORTCUT("editor/undo", TTR("Undo"), KEY_MASK_CMD + KEY_Z), EDIT_UNDO, true); p->add_shortcut(ED_SHORTCUT("editor/redo", TTR("Redo"), KEY_MASK_SHIFT + KEY_MASK_CMD + KEY_Z), EDIT_REDO, true); p->add_separator(); - p->add_item(TTR("Run Script"), FILE_RUN_SCRIPT, KEY_MASK_SHIFT + KEY_MASK_CMD + KEY_R); - p->add_separator(); - p->add_item(TTR("Project Settings"), RUN_SETTINGS); - p->add_separator(); p->add_item(TTR("Revert Scene"), EDIT_REVERT); - p->add_separator(); -#ifdef OSX_ENABLED - p->add_item(TTR("Quit to Project List"), RUN_PROJECT_MANAGER, KEY_MASK_SHIFT + KEY_MASK_ALT + KEY_Q); -#else - p->add_item(TTR("Quit to Project List"), RUN_PROJECT_MANAGER, KEY_MASK_SHIFT + KEY_MASK_CTRL + KEY_Q); -#endif - p->add_item(TTR("Quit"), FILE_QUIT, KEY_MASK_CMD + KEY_Q); recent_scenes = memnew(PopupMenu); recent_scenes->set_name("RecentScenes"); @@ -5216,17 +5407,11 @@ EditorNode::EditorNode() { } PanelContainer *editor_region = memnew(PanelContainer); - editor_region->add_style_override("panel", gui_base->get_stylebox("hover", "Button")); main_editor_button_vb = memnew(HBoxContainer); editor_region->add_child(main_editor_button_vb); - menu_hb->add_child(editor_region); - distraction_free = memnew(ToolButton); - main_editor_button_vb->add_child(distraction_free); - distraction_free->set_shortcut(ED_SHORTCUT("editor/distraction_free_mode", TTR("Distraction Free Mode"), KEY_MASK_CMD | KEY_MASK_SHIFT | KEY_F11)); - distraction_free->connect("pressed", this, "_toggle_distraction_free_mode"); - distraction_free->set_icon(gui_base->get_icon("DistractionFree", "EditorIcons")); - distraction_free->set_toggle_mode(true); + menu_hb->add_spacer(); + menu_hb->add_child(editor_region); //menu_hb->add_spacer(); #if 0 @@ -5257,34 +5442,66 @@ EditorNode::EditorNode() { menu_panel->add_child( resource_menu ); #endif - import_menu = memnew(MenuButton); - import_menu->set_tooltip(TTR("Import assets to the project.")); - import_menu->set_text(TTR("Import")); - //import_menu->set_icon(gui_base->get_icon("Save","EditorIcons")); - left_menu_hb->add_child(import_menu); - - p = import_menu->get_popup(); + debug_menu = memnew(MenuButton); + debug_menu->set_text(TTR("Debug")); + debug_menu->add_style_override("hover", gui_base->get_stylebox("MenuHover", "EditorStyles")); + left_menu_hb->add_child(debug_menu); + p = debug_menu->get_popup(); + p->set_hide_on_item_selection(false); + p->add_check_item(TTR("Deploy with Remote Debug"), RUN_DEPLOY_REMOTE_DEBUG); + p->set_item_tooltip(p->get_item_count() - 1, TTR("When exporting or deploying, the resulting executable will attempt to connect to the IP of this computer in order to be debugged.")); + p->add_check_item(TTR("Small Deploy with Network FS"), RUN_FILE_SERVER); + p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is enabled, export or deploy will produce a minimal executable.\nThe filesystem will be provided from the project by the editor over the network.\nOn Android, deploy will use the USB cable for faster performance. This option speeds up testing for games with a large footprint.")); + p->add_separator(); + p->add_check_item(TTR("Visible Collision Shapes"), RUN_DEBUG_COLLISONS); + p->set_item_tooltip(p->get_item_count() - 1, TTR("Collision shapes and raycast nodes (for 2D and 3D) will be visible on the running game if this option is turned on.")); + p->add_check_item(TTR("Visible Navigation"), RUN_DEBUG_NAVIGATION); + p->set_item_tooltip(p->get_item_count() - 1, TTR("Navigation meshes and polygons will be visible on the running game if this option is turned on.")); + p->add_separator(); + p->add_check_item(TTR("Sync Scene Changes"), RUN_LIVE_DEBUG); + p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is turned on, any changes made to the scene in the editor will be replicated in the running game.\nWhen used remotely on a device, this is more efficient with network filesystem.")); + p->add_check_item(TTR("Sync Script Changes"), RUN_RELOAD_SCRIPTS); + p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is turned on, any script that is saved will be reloaded on the running game.\nWhen used remotely on a device, this is more efficient with network filesystem.")); p->connect("id_pressed", this, "_menu_option"); - tool_menu = memnew(MenuButton); - tool_menu->set_tooltip(TTR("Miscellaneous project or scene-wide tools.")); - tool_menu->set_text(TTR("Tools")); - - //tool_menu->set_icon(gui_base->get_icon("Save","EditorIcons")); - left_menu_hb->add_child(tool_menu); + menu_hb->add_spacer(); - p = tool_menu->get_popup(); - p->connect("id_pressed", this, "_menu_option"); - p->add_item(TTR("Orphan Resource Explorer"), TOOLS_ORPHAN_RESOURCES); + settings_menu = memnew(MenuButton); + left_menu_hb->add_child(settings_menu); + settings_menu->set_text(TTR("Editor")); + settings_menu->add_style_override("hover", gui_base->get_stylebox("MenuHover", "EditorStyles")); + //settings_menu->set_anchor(MARGIN_RIGHT,ANCHOR_END); + p = settings_menu->get_popup(); - export_button = memnew(ToolButton); - export_button->set_tooltip(TTR("Export the project to many platforms.")); - export_button->set_text(TTR("Export")); - export_button->connect("pressed", this, "_menu_option", varray(FILE_EXPORT_PROJECT)); - export_button->set_focus_mode(Control::FOCUS_NONE); - left_menu_hb->add_child(export_button); + //p->add_item("Export Settings",SETTINGS_EXPORT_PREFERENCES); + p->add_item(TTR("Editor Settings"), SETTINGS_PREFERENCES); + //p->add_item("Optimization Presets",SETTINGS_OPTIMIZED_PRESETS); + p->add_separator(); + editor_layouts = memnew(PopupMenu); + editor_layouts->set_name("Layouts"); + p->add_child(editor_layouts); + editor_layouts->connect("id_pressed", this, "_layout_menu_option"); + p->add_submenu_item(TTR("Editor Layout"), "Layouts"); + p->add_shortcut(ED_SHORTCUT("editor/fullscreen_mode", TTR("Toggle Fullscreen"), KEY_MASK_SHIFT | KEY_F11), SETTINGS_TOGGLE_FULLSCREN); + p->add_separator(); + p->add_item(TTR("Manage Export Templates"), SETTINGS_MANAGE_EXPORT_TEMPLATES); - menu_hb->add_spacer(); + // Help Menu + MenuButton *help_menu = memnew(MenuButton); + left_menu_hb->add_child(help_menu); + help_menu->set_text(TTR("Help")); + help_menu->add_style_override("hover", gui_base->get_stylebox("MenuHover", "EditorStyles")); + p = help_menu->get_popup(); + p->connect("id_pressed", this, "_menu_option"); + p->add_icon_item(gui_base->get_icon("ClassList", "EditorIcons"), TTR("Classes"), HELP_CLASSES); + p->add_icon_item(gui_base->get_icon("Help", "EditorIcons"), TTR("Search"), HELP_SEARCH); + p->add_separator(); + p->add_icon_item(gui_base->get_icon("Instance", "EditorIcons"), TTR("Online Docs"), HELP_DOCS); + p->add_icon_item(gui_base->get_icon("Instance", "EditorIcons"), TTR("Q&A"), HELP_QA); + p->add_icon_item(gui_base->get_icon("Instance", "EditorIcons"), TTR("Issue Tracker"), HELP_ISSUES); + p->add_icon_item(gui_base->get_icon("Instance", "EditorIcons"), TTR("Community"), HELP_COMMUNITY); + p->add_separator(); + p->add_icon_item(gui_base->get_icon("GodotDocs", "EditorIcons"), TTR("About"), HELP_ABOUT); //Separator *s1 = memnew( VSeparator ); //menu_panel->add_child(s1); @@ -5293,17 +5510,17 @@ EditorNode::EditorNode() { play_cc = memnew(CenterContainer); play_cc->set_mouse_filter(Control::MOUSE_FILTER_IGNORE); - gui_base->add_child(play_cc); + menu_hb->add_child(play_cc); play_cc->set_area_as_parent_rect(); play_cc->set_anchor_and_margin(MARGIN_BOTTOM, Control::ANCHOR_BEGIN, 10); play_cc->set_margin(MARGIN_TOP, 5); - top_region = memnew(PanelContainer); - top_region->add_style_override("panel", gui_base->get_stylebox("hover", "Button")); - play_cc->add_child(top_region); + play_button_panel = memnew(PanelContainer); + play_button_panel->add_style_override("panel", gui_base->get_stylebox("PlayButtonPanel", "EditorStyles")); + play_cc->add_child(play_button_panel); HBoxContainer *play_hb = memnew(HBoxContainer); - top_region->add_child(play_hb); + play_button_panel->add_child(play_hb); play_button = memnew(ToolButton); play_hb->add_child(play_button); @@ -5364,33 +5581,6 @@ EditorNode::EditorNode() { play_custom_scene_button->set_tooltip(TTR("Play custom scene")); play_custom_scene_button->set_shortcut(ED_SHORTCUT("editor/play_custom_scene", TTR("Play Custom Scene"), KEY_MASK_CMD | KEY_MASK_SHIFT | KEY_F5)); - debug_button = memnew(MenuButton); - debug_button->set_flat(true); - play_hb->add_child(debug_button); - //debug_button->set_toggle_mode(true); - debug_button->set_focus_mode(Control::FOCUS_NONE); - debug_button->set_icon(gui_base->get_icon("Remote", "EditorIcons")); - //debug_button->connect("pressed", this,"_menu_option",make_binds(RUN_LIVE_DEBUG)); - debug_button->set_tooltip(TTR("Debug options")); - - p = debug_button->get_popup(); - p->set_hide_on_item_selection(false); - p->add_check_item(TTR("Deploy with Remote Debug"), RUN_DEPLOY_REMOTE_DEBUG); - p->set_item_tooltip(p->get_item_count() - 1, TTR("When exporting or deploying, the resulting executable will attempt to connect to the IP of this computer in order to be debugged.")); - p->add_check_item(TTR("Small Deploy with Network FS"), RUN_FILE_SERVER); - p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is enabled, export or deploy will produce a minimal executable.\nThe filesystem will be provided from the project by the editor over the network.\nOn Android, deploy will use the USB cable for faster performance. This option speeds up testing for games with a large footprint.")); - p->add_separator(); - p->add_check_item(TTR("Visible Collision Shapes"), RUN_DEBUG_COLLISONS); - p->set_item_tooltip(p->get_item_count() - 1, TTR("Collision shapes and raycast nodes (for 2D and 3D) will be visible on the running game if this option is turned on.")); - p->add_check_item(TTR("Visible Navigation"), RUN_DEBUG_NAVIGATION); - p->set_item_tooltip(p->get_item_count() - 1, TTR("Navigation meshes and polygons will be visible on the running game if this option is turned on.")); - p->add_separator(); - p->add_check_item(TTR("Sync Scene Changes"), RUN_LIVE_DEBUG); - p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is turned on, any changes made to the scene in the editor will be replicated in the running game.\nWhen used remotely on a device, this is more efficient with network filesystem.")); - p->add_check_item(TTR("Sync Script Changes"), RUN_RELOAD_SCRIPTS); - p->set_item_tooltip(p->get_item_count() - 1, TTR("When this option is turned on, any script that is saved will be reloaded on the running game.\nWhen used remotely on a device, this is more efficient with network filesystem.")); - p->connect("id_pressed", this, "_menu_option"); - /* run_settings_button = memnew( ToolButton ); //menu_hb->add_child(run_settings_button); @@ -5410,63 +5600,24 @@ EditorNode::EditorNode() { */ progress_hb = memnew(BackgroundProgress); - menu_hb->add_child(progress_hb); + //menu_hb->add_child(progress_hb); { Control *sp = memnew(Control); sp->set_custom_minimum_size(Size2(30, 0) * EDSCALE); - menu_hb->add_child(sp); + //menu_hb->add_child(sp); } - PanelContainer *vu_cont = memnew(PanelContainer); - vu_cont->add_style_override("panel", gui_base->get_stylebox("hover", "Button")); - menu_hb->add_child(vu_cont); - - audio_vu = memnew(TextureProgress); - CenterContainer *vu_cc = memnew(CenterContainer); - vu_cc->add_child(audio_vu); - vu_cont->add_child(vu_cc); - audio_vu->set_under_texture(gui_base->get_icon("VuEmpty", "EditorIcons")); - audio_vu->set_progress_texture(gui_base->get_icon("VuFull", "EditorIcons")); - audio_vu->set_max(24); - audio_vu->set_min(-80); - audio_vu->set_step(0.01); - audio_vu->set_value(0); - { Control *sp = memnew(Control); sp->set_custom_minimum_size(Size2(30, 0) * EDSCALE); - menu_hb->add_child(sp); + //menu_hb->add_child(sp); } top_region = memnew(PanelContainer); - top_region->add_style_override("panel", gui_base->get_stylebox("hover", "Button")); HBoxContainer *right_menu_hb = memnew(HBoxContainer); - top_region->add_child(right_menu_hb); - menu_hb->add_child(top_region); - - settings_menu = memnew(MenuButton); - settings_menu->set_text(TTR("Settings")); - //settings_menu->set_anchor(MARGIN_RIGHT,ANCHOR_END); - right_menu_hb->add_child(settings_menu); - p = settings_menu->get_popup(); - - //p->add_item("Export Settings",SETTINGS_EXPORT_PREFERENCES); - p->add_item(TTR("Editor Settings"), SETTINGS_PREFERENCES); - //p->add_item("Optimization Presets",SETTINGS_OPTIMIZED_PRESETS); - p->add_separator(); - editor_layouts = memnew(PopupMenu); - editor_layouts->set_name("Layouts"); - p->add_child(editor_layouts); - editor_layouts->connect("id_pressed", this, "_layout_menu_option"); - p->add_submenu_item(TTR("Editor Layout"), "Layouts"); - - p->add_shortcut(ED_SHORTCUT("editor/fullscreen_mode", TTR("Toggle Fullscreen"), KEY_MASK_SHIFT | KEY_F11), SETTINGS_TOGGLE_FULLSCREN); - - p->add_separator(); - p->add_item(TTR("Manage Export Templates"), SETTINGS_MANAGE_EXPORT_TEMPLATES); - p->add_separator(); - p->add_item(TTR("About"), SETTINGS_ABOUT); + //top_region->add_child(right_menu_hb); + menu_hb->add_child(right_menu_hb); layout_dialog = memnew(EditorNameDialog); gui_base->add_child(layout_dialog); @@ -5474,16 +5625,11 @@ EditorNode::EditorNode() { layout_dialog->set_size(Size2(175, 70) * EDSCALE); layout_dialog->connect("name_confirmed", this, "_dialog_action"); - sources_button = memnew(ToolButton); - right_menu_hb->add_child(sources_button); - sources_button->set_icon(gui_base->get_icon("DependencyOk", "EditorIcons")); - sources_button->connect("pressed", this, "_menu_option", varray(SOURCES_REIMPORT)); - sources_button->set_tooltip(TTR("Alerts when an external resource has changed.")); - update_menu = memnew(MenuButton); update_menu->set_tooltip(TTR("Spins when the editor window repaints!")); right_menu_hb->add_child(update_menu); update_menu->set_icon(gui_base->get_icon("Progress1", "EditorIcons")); + update_menu->get_popup()->connect("id_pressed", this, "_menu_option"); p = update_menu->get_popup(); p->add_check_item(TTR("Update Always"), SETTINGS_UPDATE_ALWAYS); p->add_check_item(TTR("Update Changes"), SETTINGS_UPDATE_CHANGES); @@ -5642,6 +5788,7 @@ EditorNode::EditorNode() { property_editor->set_show_categories(true); property_editor->set_v_size_flags(Control::SIZE_EXPAND_FILL); property_editor->set_use_doc_hints(true); + property_editor->set_enable_capitalize_paths(bool(EDITOR_DEF("interface/capitalize_properties", true))); property_editor->hide_top_label(); property_editor->register_text_enter(search_box); @@ -5695,7 +5842,7 @@ EditorNode::EditorNode() { _update_layouts_menu(); bottom_panel = memnew(PanelContainer); - bottom_panel->add_style_override("panel", gui_base->get_stylebox("panelf", "Panel")); + bottom_panel->add_style_override("panel", gui_base->get_stylebox("Content", "EditorStyles")); center_split->add_child(bottom_panel); center_split->set_dragger_visibility(SplitContainer::DRAGGER_HIDDEN); @@ -5800,14 +5947,49 @@ EditorNode::EditorNode() { about->get_ok()->set_text(TTR("Thanks!")); about->set_hide_on_ok(true); gui_base->add_child(about); + VBoxContainer *vbc = memnew(VBoxContainer); HBoxContainer *hbc = memnew(HBoxContainer); - about->add_child(hbc); + hbc->set_h_size_flags(Control::SIZE_EXPAND_FILL); + hbc->set_alignment(BoxContainer::ALIGN_CENTER); + about->add_child(vbc); + vbc->add_child(hbc); Label *about_text = memnew(Label); - about_text->set_text(VERSION_FULL_NAME "\n(c) 2008-2017 Juan Linietsky, Ariel Manzur.\n"); + about_text->set_text(VERSION_FULL_NAME + String::utf8("\n\u00A9 2007-2017 Juan Linietsky, Ariel Manzur.\n\u00A9 2014-2017 ") + TTR("Godot Engine contributors") + "\n"); TextureRect *logo = memnew(TextureRect); logo->set_texture(gui_base->get_icon("Logo", "EditorIcons")); hbc->add_child(logo); hbc->add_child(about_text); + TabContainer *tc = memnew(TabContainer); + tc->set_custom_minimum_size(Vector2(740, 300)); + vbc->add_child(tc); + ScrollContainer *dev_base = memnew(ScrollContainer); + dev_base->set_name(TTR("Developers")); + tc->add_child(dev_base); + HBoxContainer *dev_hbc = memnew(HBoxContainer); + dev_hbc->set_h_size_flags(Control::SIZE_EXPAND_FILL); + dev_base->add_child(dev_hbc); + for (int i = 0; i < 3; i++) { + Label *dev_label = memnew(Label); + dev_label->set_h_size_flags(Control::SIZE_EXPAND); + dev_label->set_v_size_flags(Control::SIZE_FILL); + dev_hbc->add_child(dev_label); + } + int dev_name_index = 0; + int dev_name_column = 0; + const int dev_index_max = AUTHORS_COUNT / 3 + (AUTHORS_COUNT % 3 == 0 ? 0 : 1); + String dev_name = ""; + const char **dev_names_ptr = dev_names; + while (*dev_names_ptr) { + dev_name += String::utf8(*dev_names_ptr++); + if (++dev_name_index == dev_index_max || !*dev_names_ptr) { + dev_hbc->get_child(dev_name_column)->cast_to<Label>()->set_text(dev_name); + dev_name_column++; + dev_name = ""; + dev_name_index = 0; + } else { + dev_name += "\n"; + } + } warning = memnew(AcceptDialog); gui_base->add_child(warning); @@ -5867,7 +6049,6 @@ EditorNode::EditorNode() { file_menu->get_popup()->connect("id_pressed", this, "_menu_option"); object_menu->get_popup()->connect("id_pressed", this, "_menu_option"); - update_menu->get_popup()->connect("id_pressed", this, "_menu_option"); settings_menu->get_popup()->connect("id_pressed", this, "_menu_option"); file->connect("file_selected", this, "_dialog_action"); @@ -5925,13 +6106,13 @@ EditorNode::EditorNode() { add_editor_plugin(memnew(Particles2DEditorPlugin(this))); add_editor_plugin(memnew(GIProbeEditorPlugin(this))); add_editor_plugin(memnew(Path2DEditorPlugin(this))); - //add_editor_plugin( memnew( PathEditorPlugin(this) ) ); + add_editor_plugin(memnew(PathEditorPlugin(this))); //add_editor_plugin( memnew( BakedLightEditorPlugin(this) ) ); add_editor_plugin(memnew(Line2DEditorPlugin(this))); add_editor_plugin(memnew(Polygon2DEditorPlugin(this))); add_editor_plugin(memnew(LightOccluder2DEditorPlugin(this))); add_editor_plugin(memnew(NavigationPolygonEditorPlugin(this))); - add_editor_plugin(memnew(ColorRampEditorPlugin(this))); + add_editor_plugin(memnew(GradientEditorPlugin(this))); add_editor_plugin(memnew(GradientTextureEditorPlugin(this))); add_editor_plugin(memnew(CollisionShape2DEditorPlugin(this))); add_editor_plugin(memnew(CurveTextureEditorPlugin(this))); @@ -5947,23 +6128,21 @@ EditorNode::EditorNode() { plugin_init_callbacks[i](); } - /*resource_preview->add_preview_generator( Ref<EditorTexturePreviewPlugin>( memnew(EditorTexturePreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorPackedScenePreviewPlugin>( memnew(EditorPackedScenePreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorMaterialPreviewPlugin>( memnew(EditorMaterialPreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorScriptPreviewPlugin>( memnew(EditorScriptPreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorSamplePreviewPlugin>( memnew(EditorSamplePreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorMeshPreviewPlugin>( memnew(EditorMeshPreviewPlugin ))); - resource_preview->add_preview_generator( Ref<EditorBitmapPreviewPlugin>( memnew(EditorBitmapPreviewPlugin ))); -*/ + resource_preview->add_preview_generator(Ref<EditorTexturePreviewPlugin>(memnew(EditorTexturePreviewPlugin))); + resource_preview->add_preview_generator(Ref<EditorPackedScenePreviewPlugin>(memnew(EditorPackedScenePreviewPlugin))); + resource_preview->add_preview_generator(Ref<EditorMaterialPreviewPlugin>(memnew(EditorMaterialPreviewPlugin))); + resource_preview->add_preview_generator(Ref<EditorScriptPreviewPlugin>(memnew(EditorScriptPreviewPlugin))); + //resource_preview->add_preview_generator( Ref<EditorSamplePreviewPlugin>( memnew(EditorSamplePreviewPlugin ))); + resource_preview->add_preview_generator(Ref<EditorMeshPreviewPlugin>(memnew(EditorMeshPreviewPlugin))); + resource_preview->add_preview_generator(Ref<EditorBitmapPreviewPlugin>(memnew(EditorBitmapPreviewPlugin))); circle_step_msec = OS::get_singleton()->get_ticks_msec(); circle_step_frame = Engine::get_singleton()->get_frames_drawn(); circle_step = 0; - _rebuild_import_menu(); - editor_plugin_screen = NULL; editor_plugins_over = memnew(EditorPluginList); + editor_plugins_force_input_forwarding = memnew(EditorPluginList); //force_top_viewport(true); _edit_current(); @@ -6074,7 +6253,10 @@ EditorNode::EditorNode() { { _initializing_addons = true; - Vector<String> addons = GlobalConfig::get_singleton()->get("editor_plugins/enabled"); + Vector<String> addons; + if (GlobalConfig::get_singleton()->has("editor_plugins/enabled")) { + addons = GlobalConfig::get_singleton()->get("editor_plugins/enabled"); + } for (int i = 0; i < addons.size(); i++) { set_addon_plugin_enabled(addons[i], true); @@ -6094,6 +6276,14 @@ EditorNode::EditorNode() { _dim_timer->set_wait_time(0.01666f); _dim_timer->connect("timeout", this, "_dim_timeout"); add_child(_dim_timer); + + ED_SHORTCUT("editor/editor_2d", TTR("Open 2D Editor"), KEY_F2); + ED_SHORTCUT("editor/editor_3d", TTR("Open 3D Editor"), KEY_F3); + ED_SHORTCUT("editor/editor_script", TTR("Open Script Editor"), KEY_F4); + ED_SHORTCUT("editor/editor_help", TTR("Search Help"), KEY_F1); + ED_SHORTCUT("editor/editor_assetlib", TTR("Open Asset Library")); + ED_SHORTCUT("editor/editor_next", TTR("Open the next Editor")); + ED_SHORTCUT("editor/editor_prev", TTR("Open the previous Editor")); } EditorNode::~EditorNode() { @@ -6101,6 +6291,7 @@ EditorNode::~EditorNode() { memdelete(EditorHelp::get_doc_data()); memdelete(editor_selection); memdelete(editor_plugins_over); + memdelete(editor_plugins_force_input_forwarding); memdelete(file_server); EditorSettings::destroy(); } @@ -6123,7 +6314,7 @@ void EditorPluginList::edit(Object *p_object) { } } -bool EditorPluginList::forward_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { +bool EditorPluginList::forward_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { bool discard = false; @@ -6136,10 +6327,14 @@ bool EditorPluginList::forward_gui_input(const Transform2D &p_canvas_xform, cons return discard; } -bool EditorPluginList::forward_spatial_gui_input(Camera *p_camera, const InputEvent &p_event) { +bool EditorPluginList::forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event, bool serve_when_force_input_enabled) { bool discard = false; for (int i = 0; i < plugins_list.size(); i++) { + if ((!serve_when_force_input_enabled) && plugins_list[i]->is_input_event_forwarding_always_enabled()) { + continue; + } + if (plugins_list[i]->forward_spatial_gui_input(p_camera, p_event)) { discard = true; } @@ -6155,6 +6350,10 @@ void EditorPluginList::forward_draw_over_canvas(const Transform2D &p_canvas_xfor } } +void EditorPluginList::add_plugin(EditorPlugin *p_plugin) { + plugins_list.push_back(p_plugin); +} + bool EditorPluginList::empty() { return plugins_list.empty(); } diff --git a/editor/editor_node.h b/editor/editor_node.h index e7f4085fc5..3870edb7c6 100644 --- a/editor/editor_node.h +++ b/editor/editor_node.h @@ -186,12 +186,19 @@ private: SETTINGS_PICK_MAIN_SCENE, SETTINGS_TOGGLE_FULLSCREN, SETTINGS_HELP, - SETTINGS_ABOUT, SOURCES_REIMPORT, DEPENDENCY_LOAD_CHANGED_IMAGES, DEPENDENCY_UPDATE_IMPORTED, SCENE_TAB_CLOSE, + HELP_CLASSES, + HELP_SEARCH, + HELP_DOCS, + HELP_QA, + HELP_ISSUES, + HELP_COMMUNITY, + HELP_ABOUT, + IMPORT_PLUGIN_BASE = 100, OBJECT_METHOD_BASE = 500, @@ -205,8 +212,10 @@ private: //Ref<ResourceImportMetadata> scene_import_metadata; PanelContainer *scene_root_parent; + Control *theme_base; Control *gui_base; VBoxContainer *main_vbox; + PanelContainer *play_button_panel; //split @@ -224,6 +233,8 @@ private: //main tabs Tabs *scene_tabs; + Panel *tab_preview_panel; + TextureRect *tab_preview; int tab_closing; bool exiting; @@ -242,8 +253,9 @@ private: HBoxContainer *menu_hb; Control *viewport; MenuButton *file_menu; - MenuButton *import_menu; - MenuButton *tool_menu; + MenuButton *project_menu; + MenuButton *debug_menu; + PopupMenu *tool_menu; ToolButton *export_button; ToolButton *prev_scene; MenuButton *object_menu; @@ -255,7 +267,6 @@ private: ToolButton *run_settings_button; ToolButton *play_scene_button; ToolButton *play_custom_scene_button; - MenuButton *debug_button; ToolButton *search_button; TextureProgress *audio_vu; //MenuButton *fileserver_menu; @@ -311,7 +322,7 @@ private: LineEdit *file_export_password; String current_path; MenuButton *update_menu; - ToolButton *sources_button; + //TabContainer *prop_pallete; //TabContainer *top_pallete; String defer_load_scene; @@ -358,6 +369,9 @@ private: bool docks_visible; ToolButton *distraction_free; + bool scene_distraction; + bool script_distraction; + String _tmp_import_path; EditorExport *editor_export; @@ -384,6 +398,7 @@ private: Vector<EditorPlugin *> editor_plugins; EditorPlugin *editor_plugin_screen; EditorPluginList *editor_plugins_over; + EditorPluginList *editor_plugins_force_input_forwarding; EditorHistory editor_history; EditorData editor_data; @@ -438,6 +453,8 @@ private: void _imported(Node *p_node); void _node_renamed(); + void _editor_select_next(); + void _editor_select_prev(); void _editor_select(int p_which); void _set_scene_metadata(const String &p_file, int p_idx = -1); void _get_scene_metadata(const String &p_file); @@ -447,8 +464,6 @@ private: void _show_messages(); void _vp_resized(); - void _rebuild_import_menu(); - void _save_scene(String p_file, int idx = -1); void _instance_request(const Vector<String> &p_files); @@ -478,7 +493,7 @@ private: bool convert_old; - void _unhandled_input(const InputEvent &p_event); + void _unhandled_input(const Ref<InputEvent> &p_event); static void _load_error_notify(void *p_ud, const String &p_text); @@ -535,7 +550,7 @@ private: bool _find_scene_in_use(Node *p_node, const String &p_path) const; - void _dock_select_input(const InputEvent &p_input); + void _dock_select_input(const Ref<InputEvent> &p_input); void _dock_move_left(); void _dock_move_right(); void _dock_select_draw(); @@ -544,6 +559,10 @@ private: void _dock_popup_exit(); void _scene_tab_changed(int p_tab); void _scene_tab_closed(int p_tab); + void _scene_tab_hover(int p_tab); + void _scene_tab_exit(); + void _scene_tab_input(const Ref<InputEvent> &p_input); + void _thumbnail_done(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata); void _scene_tab_script_edited(int p_tab); Dictionary _get_main_scene_state(); @@ -581,6 +600,7 @@ private: static int plugin_init_callback_count; static EditorPluginInitializeCallback plugin_init_callbacks[MAX_INIT_CALLBACKS]; + void _save_default_environment(); void _call_build(); static int build_callback_count; @@ -607,6 +627,7 @@ private: void _start_dimming(bool p_dimming); void _dim_timeout(); + void _check_gui_base_size(); protected: void _notification(int p_what); @@ -618,7 +639,8 @@ public: enum EditorTable { EDITOR_2D = 0, EDITOR_3D, - EDITOR_SCRIPT + EDITOR_SCRIPT, + EDITOR_ASSETLIB }; void set_visible_editor(EditorTable p_table) { _editor_select(p_table); } @@ -626,6 +648,7 @@ public: EditorPlugin *get_editor_plugin_screen() { return editor_plugin_screen; } EditorPluginList *get_editor_plugins_over() { return editor_plugins_over; } + EditorPluginList *get_editor_plugins_force_input_forwarding() { return editor_plugins_force_input_forwarding; } PropertyEditor *get_property_editor() { return property_editor; } VBoxContainer *get_property_editor_vb() { return prop_editor_vb; } @@ -801,9 +824,10 @@ public: void make_visible(bool p_visible); void edit(Object *p_object); - bool forward_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event); - bool forward_spatial_gui_input(Camera *p_camera, const InputEvent &p_event); + bool forward_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event); + bool forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event, bool serve_when_force_input_enabled); void forward_draw_over_canvas(const Transform2D &p_canvas_xform, Control *p_canvas); + void add_plugin(EditorPlugin *p_plugin); void clear(); bool empty(); diff --git a/editor/editor_path.cpp b/editor/editor_path.cpp index 98e0808ba5..8ce4f88590 100644 --- a/editor/editor_path.cpp +++ b/editor/editor_path.cpp @@ -69,9 +69,10 @@ void EditorPath::_add_children_to_popup(Object *p_obj, int p_depth) { } } -void EditorPath::_gui_input(const InputEvent &p_event) { +void EditorPath::_gui_input(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == BUTTON_LEFT && p_event.mouse_button.pressed) { + Ref<InputEventMouseButton> mb = p_event; + if (mb.is_valid() && mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) { Object *obj = ObjectDB::get_instance(history->get_path_object(history->get_path_size() - 1)); if (!obj) diff --git a/editor/editor_path.h b/editor/editor_path.h index a142cba44c..7b73e7ebb6 100644 --- a/editor/editor_path.h +++ b/editor/editor_path.h @@ -46,7 +46,7 @@ class EditorPath : public Control { EditorPath(); void _popup_select(int p_idx); - void _gui_input(const InputEvent &p_event); + void _gui_input(const Ref<InputEvent> &p_event); void _add_children_to_popup(Object *p_obj, int p_depth = 0); protected: diff --git a/editor/editor_plugin.cpp b/editor/editor_plugin.cpp index 405784a7e2..75ab1e8a44 100644 --- a/editor/editor_plugin.cpp +++ b/editor/editor_plugin.cpp @@ -147,6 +147,12 @@ void EditorPlugin::remove_tool_menu_item(const String &p_name) { //EditorNode::get_singleton()->remove_tool_menu_item(p_name); } +void EditorPlugin::set_input_event_forwarding_always_enabled() { + input_event_forwarding_always_enabled = true; + EditorPluginList *always_input_forwarding_list = EditorNode::get_singleton()->get_editor_plugins_force_input_forwarding(); + always_input_forwarding_list->add_plugin(this); +} + Ref<SpatialEditorGizmo> EditorPlugin::create_spatial_gizmo(Spatial *p_spatial) { //?? if (get_script_instance() && get_script_instance()->has_method("create_spatial_gizmo")) { @@ -156,7 +162,7 @@ Ref<SpatialEditorGizmo> EditorPlugin::create_spatial_gizmo(Spatial *p_spatial) { return Ref<SpatialEditorGizmo>(); } -bool EditorPlugin::forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { +bool EditorPlugin::forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { if (get_script_instance() && get_script_instance()->has_method("forward_canvas_gui_input")) { return get_script_instance()->call("forward_canvas_gui_input", p_canvas_xform, p_event); @@ -175,7 +181,7 @@ void EditorPlugin::update_canvas() { CanvasItemEditor::get_singleton()->get_viewport_control()->update(); } -bool EditorPlugin::forward_spatial_gui_input(Camera *p_camera, const InputEvent &p_event) { +bool EditorPlugin::forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event) { if (get_script_instance() && get_script_instance()->has_method("forward_spatial_gui_input")) { return get_script_instance()->call("forward_spatial_gui_input", p_camera, p_event); @@ -276,6 +282,16 @@ bool EditorPlugin::get_remove_list(List<Node *> *p_list) { void EditorPlugin::restore_global_state() {} void EditorPlugin::save_global_state() {} +void EditorPlugin::add_import_plugin(const Ref<EditorImportPlugin> &p_importer) { + ResourceFormatImporter::get_singleton()->add_importer(p_importer); + EditorFileSystem::get_singleton()->scan_changes(); +} + +void EditorPlugin::remove_import_plugin(const Ref<EditorImportPlugin> &p_importer) { + ResourceFormatImporter::get_singleton()->remove_importer(p_importer); + EditorFileSystem::get_singleton()->scan_changes(); +} + void EditorPlugin::set_window_layout(Ref<ConfigFile> p_layout) { if (get_script_instance() && get_script_instance()->has_method("set_window_layout")) { @@ -360,10 +376,12 @@ void EditorPlugin::_bind_methods() { ClassDB::bind_method(D_METHOD("get_editor_settings:EditorSettings"), &EditorPlugin::get_editor_settings); ClassDB::bind_method(D_METHOD("queue_save_layout"), &EditorPlugin::queue_save_layout); ClassDB::bind_method(D_METHOD("edit_resource"), &EditorPlugin::edit_resource); - - ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::BOOL, "forward_canvas_gui_input", PropertyInfo(Variant::TRANSFORM2D, "canvas_xform"), PropertyInfo(Variant::INPUT_EVENT, "event"))); + ClassDB::bind_method(D_METHOD("add_import_plugin"), &EditorPlugin::add_import_plugin); + ClassDB::bind_method(D_METHOD("remove_import_plugin"), &EditorPlugin::remove_import_plugin); + ClassDB::bind_method(D_METHOD("set_input_event_forwarding_always_enabled"), &EditorPlugin::set_input_event_forwarding_always_enabled); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::BOOL, "forward_canvas_gui_input", PropertyInfo(Variant::TRANSFORM2D, "canvas_xform"), PropertyInfo(Variant::OBJECT, "event", PROPERTY_HINT_RESOURCE_TYPE, "InputEvent"))); ClassDB::add_virtual_method(get_class_static(), MethodInfo("forward_draw_over_canvas", PropertyInfo(Variant::TRANSFORM2D, "canvas_xform"), PropertyInfo(Variant::OBJECT, "canvas:Control"))); - ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::BOOL, "forward_spatial_gui_input", PropertyInfo(Variant::OBJECT, "camera", PROPERTY_HINT_RESOURCE_TYPE, "Camera"), PropertyInfo(Variant::INPUT_EVENT, "event"))); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::BOOL, "forward_spatial_gui_input", PropertyInfo(Variant::OBJECT, "camera", PROPERTY_HINT_RESOURCE_TYPE, "Camera"), PropertyInfo(Variant::OBJECT, "event", PROPERTY_HINT_RESOURCE_TYPE, "InputEvent"))); MethodInfo gizmo = MethodInfo(Variant::OBJECT, "create_spatial_gizmo", PropertyInfo(Variant::OBJECT, "for_spatial:Spatial")); gizmo.return_val.hint = PROPERTY_HINT_RESOURCE_TYPE; gizmo.return_val.hint_string = "EditorSpatialGizmo"; @@ -403,6 +421,7 @@ void EditorPlugin::_bind_methods() { EditorPlugin::EditorPlugin() { undo_redo = NULL; + input_event_forwarding_always_enabled = false; } EditorPlugin::~EditorPlugin() { diff --git a/editor/editor_plugin.h b/editor/editor_plugin.h index 5df1f63fbe..57a22a8b2f 100644 --- a/editor/editor_plugin.h +++ b/editor/editor_plugin.h @@ -30,6 +30,7 @@ #ifndef EDITOR_PLUGIN_H #define EDITOR_PLUGIN_H +#include "editor/import/editor_import_plugin.h" #include "io/config_file.h" #include "scene/gui/tool_button.h" #include "scene/main/node.h" @@ -60,6 +61,8 @@ class EditorPlugin : public Node { UndoRedo *_get_undo_redo() { return undo_redo; } + bool input_event_forwarding_always_enabled; + protected: static void _bind_methods(); UndoRedo &get_undo_redo() { return *undo_redo; } @@ -105,10 +108,13 @@ public: void add_tool_submenu_item(const String &p_name, Object *p_submenu); void remove_tool_menu_item(const String &p_name); + void set_input_event_forwarding_always_enabled(); + bool is_input_event_forwarding_always_enabled() { return input_event_forwarding_always_enabled; } + virtual Ref<SpatialEditorGizmo> create_spatial_gizmo(Spatial *p_spatial); - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event); + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event); virtual void forward_draw_over_canvas(const Transform2D &p_canvas_xform, Control *p_canvas); - virtual bool forward_spatial_gui_input(Camera *p_camera, const InputEvent &p_event); + virtual bool forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event); virtual String get_name() const; virtual bool has_main_screen() const; virtual void make_visible(bool p_visible); @@ -146,6 +152,9 @@ public: virtual void restore_global_state(); virtual void save_global_state(); + void add_import_plugin(const Ref<EditorImportPlugin> &p_importer); + void remove_import_plugin(const Ref<EditorImportPlugin> &p_importer); + EditorPlugin(); virtual ~EditorPlugin(); }; diff --git a/editor/editor_profiler.cpp b/editor/editor_profiler.cpp index 8f4312111a..64cf275c3a 100644 --- a/editor/editor_profiler.cpp +++ b/editor/editor_profiler.cpp @@ -344,14 +344,16 @@ void EditorProfiler::_update_plot() { wr = PoolVector<uint8_t>::Write(); - Image img(w, h, 0, Image::FORMAT_RGBA8, graph_image); + Ref<Image> img; + img.instance(); + img->create(w, h, 0, Image::FORMAT_RGBA8, graph_image); if (reset_texture) { if (graph_texture.is_null()) { graph_texture.instance(); } - graph_texture->create(img.get_width(), img.get_height(), img.get_format(), Texture::FLAG_VIDEO_SURFACE); + graph_texture->create(img->get_width(), img->get_height(), img->get_format(), Texture::FLAG_VIDEO_SURFACE); } graph_texture->set_data(img); @@ -481,16 +483,20 @@ void EditorProfiler::_cursor_metric_changed(double) { _update_frame(); } -void EditorProfiler::_graph_tex_input(const InputEvent &p_ev) { +void EditorProfiler::_graph_tex_input(const Ref<InputEvent> &p_ev) { if (last_metric < 0) return; + Ref<InputEventMouse> me = p_ev; + Ref<InputEventMouseButton> mb = p_ev; + Ref<InputEventMouseMotion> mm = p_ev; + if ( - (p_ev.type == InputEvent::MOUSE_BUTTON && p_ev.mouse_button.button_index == BUTTON_LEFT && p_ev.mouse_button.pressed) || - (p_ev.type == InputEvent::MOUSE_MOTION)) { + (mb.is_valid() && mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) || + (mm.is_valid())) { - int x = p_ev.mouse_button.x; + int x = me->get_position().x; x = x * frame_metrics.size() / graph->get_size().width; bool show_hover = x >= 0 && x < frame_metrics.size(); @@ -517,7 +523,7 @@ void EditorProfiler::_graph_tex_input(const InputEvent &p_ev) { hover_metric = -1; } - if (p_ev.type == InputEvent::MOUSE_BUTTON || p_ev.mouse_motion.button_mask & BUTTON_MASK_LEFT) { + if (mb.is_valid() || mm->get_button_mask() & BUTTON_MASK_LEFT) { //cursor_metric=x; updating_frame = true; diff --git a/editor/editor_profiler.h b/editor/editor_profiler.h index 35b5ae366c..4998d45a89 100644 --- a/editor/editor_profiler.h +++ b/editor/editor_profiler.h @@ -143,7 +143,7 @@ private: void _graph_tex_mouse_exit(); void _graph_tex_draw(); - void _graph_tex_input(const InputEvent &p_ev); + void _graph_tex_input(const Ref<InputEvent> &p_ev); int _get_cursor_index() const; diff --git a/editor/editor_resource_preview.cpp b/editor/editor_resource_preview.cpp index 0b1887e8a2..5d68de3bb6 100644 --- a/editor/editor_resource_preview.cpp +++ b/editor/editor_resource_preview.cpp @@ -190,7 +190,7 @@ void EditorResourcePreview::_thread() { } else { preview_mutex->unlock(); - Ref<Texture> texture; + Ref<ImageTexture> texture; //print_line("pop from queue "+item.path); @@ -229,6 +229,7 @@ void EditorResourcePreview::_thread() { bool cache_valid = true; if (tsize != thumbnail_size) { + cache_valid = false; memdelete(f); } else if (last_modtime != modtime) { @@ -240,6 +241,7 @@ void EditorResourcePreview::_thread() { if (last_md5 != md5) { cache_valid = false; + } else { //update modified time @@ -252,14 +254,20 @@ void EditorResourcePreview::_thread() { memdelete(f); } - cache_valid = false; + //cache_valid = false; if (cache_valid) { - texture = ResourceLoader::load(cache_base + ".png", "ImageTexture", true); - if (!texture.is_valid()) { + Ref<Image> img; + img.instance(); + + if (img->load(cache_base + ".png") != OK) { //well fuck cache_valid = false; + } else { + + texture.instance(); + texture->create_from_image(img, Texture::FLAG_FILTER); } } diff --git a/editor/editor_run.cpp b/editor/editor_run.cpp index d36b8cece5..a8106b4eec 100644 --- a/editor/editor_run.cpp +++ b/editor/editor_run.cpp @@ -41,6 +41,8 @@ Error EditorRun::run(const String &p_scene, const String p_custom_args, const Li List<String> args; String resource_path = GlobalConfig::get_singleton()->get_resource_path(); + String remote_host = EditorSettings::get_singleton()->get("network/debug/remote_host"); + int remote_port = (int)EditorSettings::get_singleton()->get("network/debug/remote_port"); if (resource_path != "") { args.push_back("-path"); @@ -49,7 +51,7 @@ Error EditorRun::run(const String &p_scene, const String p_custom_args, const Li if (true) { args.push_back("-rdebug"); - args.push_back("localhost:" + String::num(GLOBAL_GET("network/debug/remote_port"))); + args.push_back(remote_host + ":" + String::num(remote_port)); } args.push_back("-epid"); @@ -72,17 +74,17 @@ Error EditorRun::run(const String &p_scene, const String p_custom_args, const Li } Rect2 screen_rect; - screen_rect.pos = OS::get_singleton()->get_screen_position(screen); + screen_rect.position = OS::get_singleton()->get_screen_position(screen); screen_rect.size = OS::get_singleton()->get_screen_size(screen); Size2 desired_size; - desired_size.x = GlobalConfig::get_singleton()->get("display/width"); - desired_size.y = GlobalConfig::get_singleton()->get("display/height"); + desired_size.x = GlobalConfig::get_singleton()->get("display/window/width"); + desired_size.y = GlobalConfig::get_singleton()->get("display/window/height"); Size2 test_size; - test_size.x = GlobalConfig::get_singleton()->get("display/test_width"); - test_size.y = GlobalConfig::get_singleton()->get("display/test_height"); + test_size.x = GlobalConfig::get_singleton()->get("display/window/test_width"); + test_size.y = GlobalConfig::get_singleton()->get("display/window/test_height"); if (test_size.x > 0 && test_size.y > 0) { desired_size = test_size; @@ -94,21 +96,21 @@ Error EditorRun::run(const String &p_scene, const String p_custom_args, const Li case 0: { // default args.push_back("-p"); - args.push_back(itos(screen_rect.pos.x) + "x" + itos(screen_rect.pos.y)); + args.push_back(itos(screen_rect.position.x) + "x" + itos(screen_rect.position.y)); } break; case 1: { // centered - Vector2 pos = screen_rect.pos + ((screen_rect.size - desired_size) / 2).floor(); + Vector2 pos = screen_rect.position + ((screen_rect.size - desired_size) / 2).floor(); args.push_back("-p"); args.push_back(itos(pos.x) + "x" + itos(pos.y)); } break; case 2: { // custom pos Vector2 pos = EditorSettings::get_singleton()->get("run/window_placement/rect_custom_position"); - pos += screen_rect.pos; + pos += screen_rect.position; args.push_back("-p"); args.push_back(itos(pos.x) + "x" + itos(pos.y)); } break; case 3: { // force maximized - Vector2 pos = screen_rect.pos; + Vector2 pos = screen_rect.position; args.push_back("-p"); args.push_back(itos(pos.x) + "x" + itos(pos.y)); args.push_back("-mx"); @@ -116,7 +118,7 @@ Error EditorRun::run(const String &p_scene, const String p_custom_args, const Li } break; case 4: { // force fullscreen - Vector2 pos = screen_rect.pos; + Vector2 pos = screen_rect.position; args.push_back("-p"); args.push_back(itos(pos.x) + "x" + itos(pos.y)); args.push_back("-f"); diff --git a/editor/editor_run_native.cpp b/editor/editor_run_native.cpp index 5a519a1dbd..4a767621ef 100644 --- a/editor/editor_run_native.cpp +++ b/editor/editor_run_native.cpp @@ -43,11 +43,12 @@ void EditorRunNative::_notification(int p_what) { continue; Ref<ImageTexture> icon = eep->get_logo(); if (!icon.is_null()) { - Image im = icon->get_data(); - im.clear_mipmaps(); - if (!im.empty()) { + Ref<Image> im = icon->get_data(); + im = im->duplicate(); + im->clear_mipmaps(); + if (!im->empty()) { - im.resize(16, 16); + im->resize(16, 16); Ref<ImageTexture> small_icon; small_icon.instance(); small_icon->create_from_image(im, 0); diff --git a/editor/editor_settings.cpp b/editor/editor_settings.cpp index 8ea5d16bbf..485f8236de 100644 --- a/editor/editor_settings.cpp +++ b/editor/editor_settings.cpp @@ -65,7 +65,7 @@ bool EditorSettings::_set(const StringName &p_name, const Variant &p_value) { for (int i = 0; i < arr.size(); i += 2) { String name = arr[i]; - InputEvent shortcut = arr[i + 1]; + Ref<InputEvent> shortcut = arr[i + 1]; Ref<ShortCut> sc; sc.instance(); @@ -109,8 +109,8 @@ bool EditorSettings::_get(const StringName &p_name, Variant &r_ret) const { continue; //this came from settings but is not any longer used } - InputEvent original = sc->get_meta("original"); - if (sc->is_shortcut(original) || (original.type == InputEvent::NONE && sc->get_shortcut().type == InputEvent::NONE)) + Ref<InputEvent> original = sc->get_meta("original"); + if (sc->is_shortcut(original) || (original.is_null() && sc->get_shortcut().is_null())) continue; //not changed from default, don't save } @@ -292,6 +292,12 @@ void EditorSettings::create() { dir->change_dir(".."); } + if (dir->change_dir("script_templates") != OK) { + dir->make_dir("script_templates"); + } else { + dir->change_dir(".."); + } + if (dir->change_dir("tmp") != OK) { dir->make_dir("tmp"); } else { @@ -407,13 +413,12 @@ void EditorSettings::setup_network() { IP::get_singleton()->get_local_addresses(&local_ip); String lip; String hint; - String current = get("network/debug_host"); + String current = has("network/debug/remote_host") ? get("network/debug/remote_host") : ""; + int port = has("network/debug/remote_port") ? (int)get("network/debug/remote_port") : 6007; for (List<IP_Address>::Element *E = local_ip.front(); E; E = E->next()) { String ip = E->get(); - if (ip == "127.0.0.1") - continue; if (lip == "") lip = ip; @@ -424,8 +429,11 @@ void EditorSettings::setup_network() { hint += ip; } - set("network/debug_host", lip); - add_property_hint(PropertyInfo(Variant::STRING, "network/debug_host", PROPERTY_HINT_ENUM, hint)); + set("network/debug/remote_host", lip); + add_property_hint(PropertyInfo(Variant::STRING, "network/debug/remote_host", PROPERTY_HINT_ENUM, hint)); + + set("network/debug/remote_port", port); + add_property_hint(PropertyInfo(Variant::INT, "network/debug/remote_port", PROPERTY_HINT_RANGE, "1,65535,1")); } void EditorSettings::save() { @@ -500,15 +508,32 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("interface/source_font_size", 14); hints["interface/source_font_size"] = PropertyInfo(Variant::INT, "interface/source_font_size", PROPERTY_HINT_RANGE, "8,96,1", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); set("interface/custom_font", ""); - hints["interface/custom_font"] = PropertyInfo(Variant::STRING, "interface/custom_font", PROPERTY_HINT_GLOBAL_FILE, "*.fnt", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); - set("interface/custom_theme", ""); - hints["interface/custom_theme"] = PropertyInfo(Variant::STRING, "interface/custom_theme", PROPERTY_HINT_GLOBAL_FILE, "*.res,*.tres,*.theme", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + hints["interface/custom_font"] = PropertyInfo(Variant::STRING, "interface/custom_font", PROPERTY_HINT_GLOBAL_FILE, "*.font", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); set("interface/dim_editor_on_dialog_popup", true); set("interface/dim_amount", 0.6f); hints["interface/dim_amount"] = PropertyInfo(Variant::REAL, "interface/dim_amount", PROPERTY_HINT_RANGE, "0,1,0.01", PROPERTY_USAGE_DEFAULT); - set("interface/dim_transition_time", 0.11f); + set("interface/dim_transition_time", 0.08f); hints["interface/dim_transition_time"] = PropertyInfo(Variant::REAL, "interface/dim_transition_time", PROPERTY_HINT_RANGE, "0,1,0.001", PROPERTY_USAGE_DEFAULT); + set("interface/separate_distraction_mode", false); + + set("interface/theme/preset", 0); + hints["interface/theme/preset"] = PropertyInfo(Variant::INT, "interface/theme/preset", PROPERTY_HINT_ENUM, "Default,Grey,Godot 2,Arc,Custom", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + set("interface/theme/base_color", Color::html("#273241")); + hints["interface/theme/highlight_color"] = PropertyInfo(Variant::COLOR, "interface/theme/highlight_color", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + set("interface/theme/highlight_color", Color::html("#b79047")); + hints["interface/theme/base_color"] = PropertyInfo(Variant::COLOR, "interface/theme/base_color", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + set("interface/theme/contrast", 0.2); + hints["interface/theme/contrast"] = PropertyInfo(Variant::REAL, "interface/theme/contrast", PROPERTY_HINT_RANGE, "0.01, 1, 0.01"); + set("interface/theme/custom_theme", ""); + hints["interface/theme/custom_theme"] = PropertyInfo(Variant::STRING, "interface/theme/custom_theme", PROPERTY_HINT_GLOBAL_FILE, "*.res,*.tres,*.theme", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + + set("interface/scene_tabs/show_extension", false); + set("interface/scene_tabs/show_thumbnail_on_hover", true); + set("interface/scene_tabs/resize_if_many_tabs", true); + set("interface/scene_tabs/minimum_width", 50); + hints["interface/scene_tabs/minimum_width"] = PropertyInfo(Variant::INT, "interface/scene_tabs/minimum_width", PROPERTY_HINT_RANGE, "50,500,1", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); + set("filesystem/directories/autoscan_project_path", ""); hints["filesystem/directories/autoscan_project_path"] = PropertyInfo(Variant::STRING, "filesystem/directories/autoscan_project_path", PROPERTY_HINT_GLOBAL_DIR); set("filesystem/directories/default_project_path", ""); @@ -529,8 +554,11 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("text_editor/highlighting/highlight_all_occurrences", true); set("text_editor/cursor/scroll_past_end_of_file", false); - set("text_editor/indent/tab_size", 4); - hints["text_editor/indent/tab_size"] = PropertyInfo(Variant::INT, "text_editor/indent/tab_size", PROPERTY_HINT_RANGE, "1, 64, 1"); // size of 0 crashes. + set("text_editor/indent/type", 0); + hints["text_editor/indent/type"] = PropertyInfo(Variant::INT, "text_editor/indent/type", PROPERTY_HINT_ENUM, "Tabs,Spaces"); + set("text_editor/indent/size", 4); + hints["text_editor/indent/size"] = PropertyInfo(Variant::INT, "text_editor/indent/size", PROPERTY_HINT_RANGE, "1, 64, 1"); // size of 0 crashes. + set("text_editor/indent/convert_indent_on_save", false); set("text_editor/indent/draw_tabs", true); set("text_editor/line_numbers/show_line_numbers", true); @@ -540,6 +568,8 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("text_editor/line_numbers/line_length_guideline_column", 80); hints["text_editor/line_numbers/line_length_guideline_column"] = PropertyInfo(Variant::INT, "text_editor/line_numbers/line_length_guideline_column", PROPERTY_HINT_RANGE, "20, 160, 10"); + set("text_editor/open_scripts/show_members_overview", true); + set("text_editor/files/trim_trailing_whitespace_on_save", false); set("text_editor/completion/idle_parse_delay", 2); set("text_editor/tools/create_signal_callbacks", true); @@ -551,9 +581,12 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { hints["text_editor/cursor/caret_blink_speed"] = PropertyInfo(Variant::REAL, "text_editor/cursor/caret_blink_speed", PROPERTY_HINT_RANGE, "0.1, 10, 0.1"); set("text_editor/theme/font", ""); - hints["text_editor/theme/font"] = PropertyInfo(Variant::STRING, "text_editor/theme/font", PROPERTY_HINT_GLOBAL_FILE, "*.fnt"); + hints["text_editor/theme/font"] = PropertyInfo(Variant::STRING, "text_editor/theme/font", PROPERTY_HINT_GLOBAL_FILE, "*.font"); set("text_editor/completion/auto_brace_complete", false); set("text_editor/files/restore_scripts_on_load", true); + set("text_editor/completion/complete_file_paths", true); + set("text_editor/files/maximum_recent_files", 20); + hints["text_editor/files/maximum_recent_files"] = PropertyInfo(Variant::INT, "text_editor/files/maximum_recent_files", PROPERTY_HINT_RANGE, "1, 200, 0"); //set("docks/scene_tree/display_old_action_buttons",false); set("docks/scene_tree/start_create_dialog_fully_expanded", false); @@ -565,7 +598,7 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("editors/3d/grid_color", Color(0, 1, 0, 0.2)); hints["editors/3d/grid_color"] = PropertyInfo(Variant::COLOR, "editors/3d/grid_color", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED); - set("editors/3d/default_fov", 45.0); + set("editors/3d/default_fov", 55.0); set("editors/3d/default_z_near", 0.1); set("editors/3d/default_z_far", 500.0); @@ -583,17 +616,22 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) { set("editors/3d/emulate_3_button_mouse", false); set("editors/3d/warped_mouse_panning", true); + set("editors/3d/freelook_base_speed", 1); + set("editors/3d/freelook_modifier_speed_factor", 5.0); + set("editors/2d/bone_width", 5); set("editors/2d/bone_color1", Color(1.0, 1.0, 1.0, 0.9)); set("editors/2d/bone_color2", Color(0.75, 0.75, 0.75, 0.9)); set("editors/2d/bone_selected_color", Color(0.9, 0.45, 0.45, 0.9)); set("editors/2d/bone_ik_color", Color(0.9, 0.9, 0.45, 0.9)); - set("editors/2d/keep_margins_when_changing_anchors", false); - set("editors/2d/warped_mouse_panning", true); + set("editors/2d/scroll_to_pan", false); + set("editors/2d/pan_speed", 20); + + set("editors/poly_editor/point_grab_radius", 8); - set("run/window_placement/rect", 0); + set("run/window_placement/rect", 1); hints["run/window_placement/rect"] = PropertyInfo(Variant::INT, "run/window_placement/rect", PROPERTY_HINT_ENUM, "Default,Centered,Custom Position,Force Maximized,Force Full Screen"); String screen_hints = TTR("Default (Same as Editor)"); for (int i = 0; i < OS::get_singleton()->get_screen_count(); i++) { @@ -920,6 +958,25 @@ bool EditorSettings::save_text_editor_theme_as(String p_file) { return false; } +Vector<String> EditorSettings::get_script_templates(const String &p_extension) { + + Vector<String> templates; + DirAccess *d = DirAccess::open(settings_path + "/script_templates"); + if (d) { + d->list_dir_begin(); + String file = d->get_next(); + while (file != String()) { + if (file.get_extension() == p_extension) { + templates.push_back(file.get_basename()); + } + file = d->get_next(); + } + d->list_dir_end(); + memdelete(d); + } + return templates; +} + bool EditorSettings::_save_text_editor_theme(String p_file) { String theme_section = "color_theme"; Ref<ConfigFile> cf = memnew(ConfigFile); // hex is better? @@ -966,7 +1023,7 @@ void EditorSettings::add_shortcut(const String &p_name, Ref<ShortCut> &p_shortcu shortcuts[p_name] = p_shortcut; } -bool EditorSettings::is_shortcut(const String &p_name, const InputEvent &p_event) const { +bool EditorSettings::is_shortcut(const String &p_name, const Ref<InputEvent> &p_event) const { const Map<String, Ref<ShortCut> >::Element *E = shortcuts.find(p_name); if (!E) { @@ -1083,15 +1140,16 @@ Ref<ShortCut> ED_GET_SHORTCUT(const String &p_path) { Ref<ShortCut> ED_SHORTCUT(const String &p_path, const String &p_name, uint32_t p_keycode) { - InputEvent ie; + Ref<InputEventKey> ie; if (p_keycode) { - ie.type = InputEvent::KEY; - ie.key.unicode = p_keycode & KEY_CODE_MASK; - ie.key.scancode = p_keycode & KEY_CODE_MASK; - ie.key.mod.shift = bool(p_keycode & KEY_MASK_SHIFT); - ie.key.mod.alt = bool(p_keycode & KEY_MASK_ALT); - ie.key.mod.control = bool(p_keycode & KEY_MASK_CTRL); - ie.key.mod.meta = bool(p_keycode & KEY_MASK_META); + ie.instance(); + + ie->set_unicode(p_keycode & KEY_CODE_MASK); + ie->set_scancode(p_keycode & KEY_CODE_MASK); + ie->set_shift(bool(p_keycode & KEY_MASK_SHIFT)); + ie->set_alt(bool(p_keycode & KEY_MASK_ALT)); + ie->set_control(bool(p_keycode & KEY_MASK_CTRL)); + ie->set_metakey(bool(p_keycode & KEY_MASK_META)); } Ref<ShortCut> sc = EditorSettings::get_singleton()->get_shortcut(p_path); diff --git a/editor/editor_settings.h b/editor/editor_settings.h index a876f23134..d5adb84b63 100644 --- a/editor/editor_settings.h +++ b/editor/editor_settings.h @@ -159,8 +159,10 @@ public: bool save_text_editor_theme(); bool save_text_editor_theme_as(String p_file); + Vector<String> get_script_templates(const String &p_extension); + void add_shortcut(const String &p_name, Ref<ShortCut> &p_shortcut); - bool is_shortcut(const String &p_name, const InputEvent &p_event) const; + bool is_shortcut(const String &p_name, const Ref<InputEvent> &p_event) const; Ref<ShortCut> get_shortcut(const String &p_name) const; void get_shortcut_list(List<String> *r_shortcuts); diff --git a/editor/editor_themes.cpp b/editor/editor_themes.cpp index 3b5dbf7fc7..e6df58bc60 100644 --- a/editor/editor_themes.cpp +++ b/editor/editor_themes.cpp @@ -35,25 +35,423 @@ #include "editor_scale.h" #include "editor_settings.h" +static Ref<StyleBoxTexture> make_stylebox(Ref<Texture> texture, float p_left, float p_top, float p_right, float p_botton, float p_margin_left = -1, float p_margin_top = -1, float p_margin_right = -1, float p_margin_botton = -1, bool p_draw_center = true) { + Ref<StyleBoxTexture> style(memnew(StyleBoxTexture)); + style->set_texture(texture); + style->set_margin_size(MARGIN_LEFT, p_left * EDSCALE); + style->set_margin_size(MARGIN_RIGHT, p_right * EDSCALE); + style->set_margin_size(MARGIN_BOTTOM, p_botton * EDSCALE); + style->set_margin_size(MARGIN_TOP, p_top * EDSCALE); + style->set_default_margin(MARGIN_LEFT, p_margin_left * EDSCALE); + style->set_default_margin(MARGIN_RIGHT, p_margin_right * EDSCALE); + style->set_default_margin(MARGIN_BOTTOM, p_margin_botton * EDSCALE); + style->set_default_margin(MARGIN_TOP, p_margin_top * EDSCALE); + style->set_draw_center(p_draw_center); + return style; +} + +static Ref<StyleBoxEmpty> make_empty_stylebox(float p_margin_left = -1, float p_margin_top = -1, float p_margin_right = -1, float p_margin_bottom = -1) { + Ref<StyleBoxEmpty> style(memnew(StyleBoxEmpty)); + style->set_default_margin(MARGIN_LEFT, p_margin_left * EDSCALE); + style->set_default_margin(MARGIN_RIGHT, p_margin_right * EDSCALE); + style->set_default_margin(MARGIN_BOTTOM, p_margin_bottom * EDSCALE); + style->set_default_margin(MARGIN_TOP, p_margin_top * EDSCALE); + return style; +} + +static Ref<StyleBoxFlat> make_flat_stylebox(Color color, float p_margin_left = -1, float p_margin_top = -1, float p_margin_right = -1, float p_margin_bottom = -1) { + Ref<StyleBoxFlat> style(memnew(StyleBoxFlat)); + style->set_bg_color(color); + style->set_default_margin(MARGIN_LEFT, p_margin_left * EDSCALE); + style->set_default_margin(MARGIN_RIGHT, p_margin_right * EDSCALE); + style->set_default_margin(MARGIN_BOTTOM, p_margin_bottom * EDSCALE); + style->set_default_margin(MARGIN_TOP, p_margin_top * EDSCALE); + return style; +} + +static Ref<StyleBoxFlat> change_border_color(Ref<StyleBoxFlat> p_style, Color p_color) { + Ref<StyleBoxFlat> style = p_style->duplicate(); + style->set_light_color(p_color); + style->set_dark_color(p_color); + return style; +} + +static Ref<StyleBoxFlat> add_additional_border(Ref<StyleBoxFlat> p_style, int p_left, int p_top, int p_right, int p_bottom) { + Ref<StyleBoxFlat> style = p_style->duplicate(); + style->_set_additional_border_size(MARGIN_LEFT, p_left * EDSCALE); + style->_set_additional_border_size(MARGIN_RIGHT, p_right * EDSCALE); + style->_set_additional_border_size(MARGIN_TOP, p_top * EDSCALE); + style->_set_additional_border_size(MARGIN_BOTTOM, p_bottom * EDSCALE); + return style; +} + +#define HIGHLIGHT_COLOR_LIGHT highlight_color.linear_interpolate(Color(1, 1, 1, 1), 0.3) +#define HIGHLIGHT_COLOR_DARK highlight_color.linear_interpolate(Color(0, 0, 0, 1), 0.5) + Ref<Theme> create_editor_theme() { Ref<Theme> theme = Ref<Theme>(memnew(Theme)); editor_register_fonts(theme); editor_register_icons(theme); - Ref<StyleBoxTexture> focus_sbt = memnew(StyleBoxTexture); - focus_sbt->set_texture(theme->get_icon("EditorFocus", "EditorIcons")); - for (int i = 0; i < 4; i++) { - focus_sbt->set_margin_size(Margin(i), 16 * EDSCALE); - focus_sbt->set_default_margin(Margin(i), 16 * EDSCALE); + // Define colors + Color highlight_color = EDITOR_DEF("interface/theme/highlight_color", Color::html("#b79047")); + Color base_color = EDITOR_DEF("interface/theme/base_color", Color::html("#273241")); + float contrast = EDITOR_DEF("interface/theme/contrast", 0.25); + int preset = EDITOR_DEF("interface/theme/preset", 0); + + switch (preset) { + case 0: { // Default + highlight_color = Color::html("#b79047"); + base_color = Color::html("#273241"); + contrast = 0.25; + } break; + case 1: { // Grey + highlight_color = Color::html("#3e3e3e"); + base_color = Color::html("#3d3d3d"); + contrast = 0.2; + } break; + case 2: { // Godot 2 + highlight_color = Color::html("#86ace2"); + base_color = Color::html("#3C3A44"); + contrast = 0.25; + } break; + case 3: { // Arc + highlight_color = Color::html("#68a7f2"); + base_color = Color::html("#434a59"); + contrast = 0.2; + } break; } + + Color dark_color_1 = base_color.linear_interpolate(Color(0, 0, 0, 1), contrast); + Color dark_color_2 = base_color.linear_interpolate(Color(0, 0, 0, 1), contrast * 1.5); + Color dark_color_3 = base_color.linear_interpolate(Color(0, 0, 0, 1), contrast * 2); + + Color light_color_1 = base_color.linear_interpolate(Color(1, 1, 1, 1), contrast); + Color light_color_2 = base_color.linear_interpolate(Color(1, 1, 1, 1), contrast * 1.5); + + theme->set_color("highlight_color", "Editor", highlight_color); + theme->set_color("base_color", "Editor", base_color); + theme->set_color("dark_color_1", "Editor", dark_color_1); + theme->set_color("dark_color_2", "Editor", dark_color_2); + theme->set_color("dark_color_3", "Editor", dark_color_3); + theme->set_color("light_color_1", "Editor", light_color_1); + theme->set_color("light_color_2", "Editor", light_color_2); + + // Checkbox icon + theme->set_icon("checked", "CheckBox", theme->get_icon("Checked", "EditorIcons")); + theme->set_icon("unchecked", "CheckBox", theme->get_icon("Unchecked", "EditorIcons")); + theme->set_icon("checked", "PopupMenu", theme->get_icon("Checked", "EditorIcons")); + theme->set_icon("unchecked", "PopupMenu", theme->get_icon("Unchecked", "EditorIcons")); + + // Editor background + Ref<StyleBoxFlat> style_panel = make_flat_stylebox(dark_color_2, 4, 4, 4, 4); + theme->set_stylebox("Background", "EditorStyles", style_panel); + + // Focus + Ref<StyleBoxFlat> focus_sbt = make_flat_stylebox(light_color_1, 4, 4, 4, 4); focus_sbt->set_draw_center(false); - theme->set_stylebox("EditorFocus", "EditorStyles", focus_sbt); - theme->set_color("prop_category", "Editor", Color::hex(0x3f3a44ff)); - theme->set_color("prop_section", "Editor", Color::hex(0x35313aff)); - theme->set_color("prop_subsection", "Editor", Color::hex(0x312e37ff)); + focus_sbt->set_border_size(1 * EDSCALE); + focus_sbt = change_border_color(focus_sbt, light_color_2); + theme->set_stylebox("Focus", "EditorStyles", focus_sbt); + + // Menu + Ref<StyleBoxEmpty> style_menu = make_empty_stylebox(4, 4, 4, 4); + theme->set_stylebox("panel", "PanelContainer", style_menu); + theme->set_stylebox("MenuPanel", "EditorStyles", style_menu); + + // Play button group + theme->set_stylebox("PlayButtonPanel", "EditorStyles", make_stylebox(theme->get_icon("PlayButtonGroup", "EditorIcons"), 16, 16, 16, 16, 8, 4, 8, 4)); + + Ref<StyleBoxFlat> style_menu_hover_border = make_flat_stylebox(highlight_color, 4, 4, 4, 4); + Ref<StyleBoxFlat> style_menu_hover_bg = make_flat_stylebox(dark_color_2, 4, 4, 4, 4); + + style_menu_hover_border->set_draw_center(false); + style_menu_hover_border->_set_additional_border_size(MARGIN_BOTTOM, 1 * EDSCALE); + theme->set_stylebox("normal", "MenuButton", style_menu); + theme->set_stylebox("hover", "MenuButton", style_menu); + theme->set_stylebox("pressed", "MenuButton", style_menu); + theme->set_stylebox("focus", "MenuButton", style_menu); + theme->set_stylebox("disabled", "MenuButton", style_menu); + + theme->set_stylebox("normal", "PopupMenu", style_menu); + theme->set_stylebox("hover", "PopupMenu", style_menu_hover_bg); + theme->set_stylebox("pressed", "PopupMenu", style_menu); + theme->set_stylebox("focus", "PopupMenu", style_menu); + theme->set_stylebox("disabled", "PopupMenu", style_menu); + + theme->set_stylebox("normal", "ToolButton", style_menu); + theme->set_stylebox("hover", "ToolButton", style_menu); + theme->set_stylebox("pressed", "ToolButton", style_menu); + theme->set_stylebox("focus", "ToolButton", style_menu); + theme->set_stylebox("disabled", "ToolButton", style_menu); + + theme->set_color("font_color_hover", "MenuButton", HIGHLIGHT_COLOR_LIGHT); + theme->set_color("font_color_hover", "ToolButton", HIGHLIGHT_COLOR_LIGHT); + theme->set_color("font_color_pressed", "ToolButton", highlight_color); + + theme->set_stylebox("MenuHover", "EditorStyles", style_menu_hover_border); + + // Content of each tab + Ref<StyleBoxFlat> style_content_panel = make_flat_stylebox(base_color, 1, 4, 1, 1); + theme->set_stylebox("panel", "TabContainer", style_content_panel); + theme->set_stylebox("Content", "EditorStyles", style_content_panel); + + // Button + Ref<StyleBoxFlat> style_button = make_flat_stylebox(dark_color_1, 4, 4, 4, 4); + style_button->set_draw_center(true); + style_button->set_border_size(2 * EDSCALE); + style_button->set_light_color(light_color_1); + style_button->set_dark_color(light_color_1); + style_button->set_border_blend(false); + theme->set_stylebox("normal", "Button", style_button); + theme->set_stylebox("hover", "Button", style_button); + theme->set_stylebox("pressed", "Button", style_button); + theme->set_stylebox("focus", "Button", style_button); + theme->set_stylebox("disabled", "Button", style_button); + theme->set_color("font_color_hover", "Button", HIGHLIGHT_COLOR_LIGHT); + theme->set_color("font_color_pressed", "Button", highlight_color); + theme->set_color("icon_color_hover", "Button", HIGHLIGHT_COLOR_LIGHT); + // make icon color value bigger because icon image is not complete white + theme->set_color("icon_color_pressed", "Button", Color(highlight_color.r * 1.15, highlight_color.g * 1.15, highlight_color.b * 1.15, highlight_color.a)); + + // OptionButton + Ref<StyleBoxFlat> style_option_button = make_flat_stylebox(dark_color_1, 4, 4, 4, 4); + style_option_button->set_border_size(1 * EDSCALE); + style_option_button->set_light_color(light_color_1); + style_option_button->set_dark_color(light_color_1); + style_option_button->_set_additional_border_size(MARGIN_RIGHT, -16 * EDSCALE); + theme->set_stylebox("hover", "OptionButton", change_border_color(style_option_button, HIGHLIGHT_COLOR_LIGHT)); + theme->set_stylebox("pressed", "OptionButton", change_border_color(style_option_button, highlight_color)); + theme->set_stylebox("focus", "OptionButton", change_border_color(style_option_button, highlight_color)); + theme->set_stylebox("disabled", "OptionButton", style_option_button); + theme->set_stylebox("normal", "OptionButton", style_option_button); + theme->set_icon("arrow", "OptionButton", theme->get_icon("OptionArrow", "EditorIcons")); + + // PopupMenu + Ref<StyleBoxFlat> style_popup_menu = make_flat_stylebox(dark_color_1, 8, 8, 8, 8); + style_popup_menu->set_border_size(2 * EDSCALE); + style_popup_menu->set_light_color(light_color_1); + style_popup_menu->set_dark_color(light_color_1); + theme->set_stylebox("panel", "PopupMenu", style_popup_menu); + + // Tree & script background + Ref<StyleBoxFlat> style_bg = make_flat_stylebox(dark_color_1, 0, 0, 0, 0); + theme->set_stylebox("bg", "Tree", style_bg); + theme->set_stylebox("ScriptPanel", "EditorStyles", style_bg); + + // Tree + theme->set_icon("checked", "Tree", theme->get_icon("Checked", "EditorIcons")); + theme->set_icon("unchecked", "Tree", theme->get_icon("Unchecked", "EditorIcons")); + theme->set_icon("arrow", "Tree", theme->get_icon("TreeArrowDown", "EditorIcons")); + theme->set_icon("arrow_collapsed", "Tree", theme->get_icon("TreeArrowRight", "EditorIcons")); + theme->set_icon("select_arrow", "Tree", theme->get_icon("Dropdown", "EditorIcons")); + theme->set_stylebox("bg_focus", "Tree", focus_sbt); + theme->set_stylebox("custom_button", "Tree", style_button); + theme->set_stylebox("custom_button_pressed", "Tree", style_button); + theme->set_stylebox("custom_button_hover", "Tree", style_button); + theme->set_color("custom_button_font_highlight", "Tree", HIGHLIGHT_COLOR_LIGHT); + + Ref<StyleBox> style_tree_btn = make_flat_stylebox(light_color_1, 2, 4, 2, 4); + theme->set_stylebox("button_pressed", "Tree", style_tree_btn); + + Ref<StyleBoxFlat> style_tree_focus = make_flat_stylebox(HIGHLIGHT_COLOR_DARK, 4, 4, 4, 4); + theme->set_stylebox("selected_focus", "Tree", style_tree_focus); + + Ref<StyleBoxFlat> style_tree_selected = make_flat_stylebox(light_color_1, 4, 4, 4, 4); + theme->set_stylebox("selected", "Tree", style_tree_selected); + + Ref<StyleBoxFlat> style_tree_cursor = make_flat_stylebox(HIGHLIGHT_COLOR_DARK, 4, 4, 4, 4); + style_tree_cursor->set_draw_center(false); + style_tree_cursor->set_border_size(1 * EDSCALE); + style_tree_cursor->set_light_color(light_color_1); + style_tree_cursor->set_dark_color(light_color_1); + Ref<StyleBoxFlat> style_tree_title = make_flat_stylebox(dark_color_3, 4, 4, 4, 4); + theme->set_stylebox("cursor", "Tree", style_tree_cursor); + theme->set_stylebox("cursor_unfocused", "Tree", style_tree_cursor); + theme->set_stylebox("title_button_normal", "Tree", style_tree_title); + theme->set_stylebox("title_button_hover", "Tree", style_tree_title); + theme->set_stylebox("title_button_pressed", "Tree", style_tree_title); + + theme->set_color("prop_category", "Editor", dark_color_3); + theme->set_color("prop_section", "Editor", dark_color_1); + theme->set_color("prop_subsection", "Editor", dark_color_2); theme->set_color("fg_selected", "Editor", Color::html("ffbd8e8e")); theme->set_color("fg_error", "Editor", Color::html("ffbd8e8e")); + theme->set_color("drop_position_color", "Tree", highlight_color); + + // ItemList + Ref<StyleBoxFlat> style_itemlist_cursor = make_flat_stylebox(highlight_color, 4, 4, 4, 4); + style_itemlist_cursor->set_draw_center(false); + style_itemlist_cursor->set_border_size(1 * EDSCALE); + style_itemlist_cursor->set_light_color(light_color_1); + style_itemlist_cursor->set_dark_color(light_color_1); + theme->set_stylebox("cursor", "ItemList", style_itemlist_cursor); + theme->set_stylebox("cursor_unfocused", "ItemList", style_itemlist_cursor); + theme->set_stylebox("selected_focus", "ItemList", style_tree_focus); + theme->set_stylebox("selected", "ItemList", style_tree_selected); + theme->set_stylebox("bg_focus", "ItemList", focus_sbt); + theme->set_stylebox("bg", "ItemList", style_bg); + theme->set_constant("vseparation", "ItemList", 5 * EDSCALE); + + Ref<StyleBoxFlat> style_tab_fg = make_flat_stylebox(base_color, 15, 5, 15, 5); + Ref<StyleBoxFlat> style_tab_bg = make_flat_stylebox(base_color, 15, 5, 15, 5); + style_tab_bg->set_draw_center(false); + + // Tabs & TabContainer + theme->set_stylebox("tab_fg", "TabContainer", style_tab_fg); + theme->set_stylebox("tab_bg", "TabContainer", style_tab_bg); + theme->set_stylebox("tab_fg", "Tabs", style_tab_fg); + theme->set_stylebox("tab_bg", "Tabs", style_tab_bg); + theme->set_color("font_color_fg", "TabContainer", Color(1, 1, 1, 1)); + theme->set_color("font_color_bg", "TabContainer", light_color_2); + theme->set_icon("menu", "TabContainer", theme->get_icon("TabMenu", "EditorIcons")); + theme->set_icon("menu_hl", "TabContainer", theme->get_icon("TabMenu", "EditorIcons")); + theme->set_stylebox("SceneTabFG", "EditorStyles", make_flat_stylebox(base_color, 10, 5, 10, 5)); + theme->set_stylebox("SceneTabBG", "EditorStyles", make_empty_stylebox(6, 5, 6, 5)); + + // Debugger + Ref<StyleBoxFlat> style_panel_debugger = make_flat_stylebox(dark_color_2, 0, 4, 0, 0); + theme->set_stylebox("DebuggerPanel", "EditorStyles", style_panel_debugger); + + Ref<StyleBoxFlat> style_tab_fg_debugger = make_flat_stylebox(dark_color_2, 10, 5, 10, 5); + Ref<StyleBoxFlat> style_tab_bg_debugger = make_flat_stylebox(dark_color_2, 10, 5, 10, 5); + style_tab_bg_debugger->set_draw_center(false); + + theme->set_stylebox("DebuggerTabFG", "EditorStyles", style_tab_fg_debugger); + theme->set_stylebox("DebuggerTabBG", "EditorStyles", style_tab_bg_debugger); + + // LineEdit + Ref<StyleBoxFlat> style_lineedit = make_flat_stylebox(dark_color_1, 4, 4, 4, 4); + style_lineedit->set_border_size(1 * EDSCALE); + style_lineedit = change_border_color(style_lineedit, light_color_1); + Ref<StyleBoxFlat> style_lineedit_disabled = style_lineedit->duplicate(); + style_lineedit_disabled->set_bg_color(light_color_1); + Ref<StyleBoxFlat> style_lineedit_focus = change_border_color(style_lineedit, highlight_color); + style_lineedit_focus->set_draw_center(false); + theme->set_stylebox("normal", "LineEdit", style_lineedit); + theme->set_stylebox("focus", "LineEdit", style_lineedit_focus); + theme->set_stylebox("read_only", "LineEdit", style_lineedit_disabled); + + // TextEdit + Ref<StyleBoxFlat> style_textedit_normal(memnew(StyleBoxFlat)); + style_textedit_normal->set_bg_color(dark_color_2); + style_textedit_normal->set_default_margin(MARGIN_LEFT, 0); + style_textedit_normal->set_default_margin(MARGIN_RIGHT, 0); + style_textedit_normal->set_default_margin(MARGIN_BOTTOM, 0); + style_textedit_normal->set_default_margin(MARGIN_TOP, 0); + theme->set_stylebox("normal", "TextEdit", style_textedit_normal); + theme->set_stylebox("focus", "TextEdit", focus_sbt); + theme->set_constant("side_margin", "TabContainer", 0); + + // H/VSplitContainer + theme->set_stylebox("bg", "VSplitContainer", make_stylebox(theme->get_icon("VsplitBg", "EditorIcons"), 1, 1, 1, 1)); + theme->set_stylebox("bg", "HSplitContainer", make_stylebox(theme->get_icon("HsplitBg", "EditorIcons"), 1, 1, 1, 1)); + + theme->set_icon("grabber", "VSplitContainer", theme->get_icon("Vsplitter", "EditorIcons")); + theme->set_icon("grabber", "HSplitContainer", theme->get_icon("Hsplitter", "EditorIcons")); + + theme->set_constant("separation", "HSplitContainer", 8 * EDSCALE); + theme->set_constant("separation", "VSplitContainer", 8 * EDSCALE); + + // WindowDialog + Ref<StyleBoxFlat> style_window = make_flat_stylebox(dark_color_2, 4, 4, 4, 4); + style_window->set_border_size(2 * EDSCALE); + style_window->set_border_blend(false); + style_window->set_light_color(light_color_2); + style_window->set_dark_color(light_color_2); + style_window->_set_additional_border_size(MARGIN_TOP, 24 * EDSCALE); + theme->set_stylebox("panel", "WindowDialog", style_window); + + // HScrollBar + Ref<Texture> empty_icon = memnew(ImageTexture); + + theme->set_stylebox("scroll", "HScrollBar", make_stylebox(theme->get_icon("ScrollBg", "EditorIcons"), 5, 5, 5, 5, 0, 0, 0, 0)); + theme->set_stylebox("scroll_focus", "HScrollBar", make_stylebox(theme->get_icon("ScrollBg", "EditorIcons"), 5, 5, 5, 5, 0, 0, 0, 0)); + theme->set_stylebox("grabber", "HScrollBar", make_stylebox(theme->get_icon("ScrollGrabber", "EditorIcons"), 6, 6, 6, 6, 2, 2, 2, 2)); + theme->set_stylebox("grabber_highlight", "HScrollBar", make_stylebox(theme->get_icon("ScrollGrabberHl", "EditorIcons"), 5, 5, 5, 5, 2, 2, 2, 2)); + + theme->set_icon("increment", "HScrollBar", empty_icon); + theme->set_icon("increment_highlight", "HScrollBar", empty_icon); + theme->set_icon("decrement", "HScrollBar", empty_icon); + theme->set_icon("decrement_highlight", "HScrollBar", empty_icon); + + // VScrollBar + theme->set_stylebox("scroll", "VScrollBar", make_stylebox(theme->get_icon("ScrollBg", "EditorIcons"), 5, 5, 5, 5, 0, 0, 0, 0)); + theme->set_stylebox("scroll_focus", "VScrollBar", make_stylebox(theme->get_icon("ScrollBg", "EditorIcons"), 5, 5, 5, 5, 0, 0, 0, 0)); + theme->set_stylebox("grabber", "VScrollBar", make_stylebox(theme->get_icon("ScrollGrabber", "EditorIcons"), 6, 6, 6, 6, 2, 2, 2, 2)); + theme->set_stylebox("grabber_highlight", "VScrollBar", make_stylebox(theme->get_icon("ScrollGrabberHl", "EditorIcons"), 5, 5, 5, 5, 2, 2, 2, 2)); + + theme->set_icon("increment", "VScrollBar", empty_icon); + theme->set_icon("increment_highlight", "VScrollBar", empty_icon); + theme->set_icon("decrement", "VScrollBar", empty_icon); + theme->set_icon("decrement_highlight", "VScrollBar", empty_icon); + + // HSlider + theme->set_stylebox("slider", "HSlider", make_stylebox(theme->get_icon("HsliderBg", "EditorIcons"), 4, 4, 4, 4)); + theme->set_icon("grabber", "HSlider", theme->get_icon("SliderGrabber", "EditorIcons")); + theme->set_icon("grabber_highlight", "HSlider", theme->get_icon("SliderGrabberHl", "EditorIcons")); + + // VSlider + theme->set_stylebox("slider", "VSlider", make_stylebox(theme->get_icon("VsliderBg", "EditorIcons"), 4, 4, 4, 4)); + theme->set_icon("grabber", "VSlider", theme->get_icon("SliderGrabber", "EditorIcons")); + theme->set_icon("grabber_highlight", "VSlider", theme->get_icon("SliderGrabberHl", "EditorIcons")); + + // Panel + theme->set_stylebox("panel", "Panel", style_panel); + + // TooltipPanel + Ref<StyleBoxFlat> style_tooltip = make_flat_stylebox(Color(1, 1, 1, 0.8), 8, 8, 8, 8); + style_tooltip->set_border_size(2 * EDSCALE); + style_tooltip->set_border_blend(false); + style_tooltip->set_light_color(Color(1, 1, 1, 0.9)); + style_tooltip->set_dark_color(Color(1, 1, 1, 0.9)); + theme->set_stylebox("panel", "TooltipPanel", style_tooltip); + + // PopupPanel + Ref<StyleBoxFlat> style_dock_select = make_flat_stylebox(base_color); + style_dock_select->set_light_color(light_color_1); + style_dock_select->set_dark_color(light_color_1); + style_dock_select = add_additional_border(style_dock_select, 2, 2, 2, 2); + theme->set_stylebox("panel", "PopupPanel", style_dock_select); + + // SpinBox + theme->set_icon("updown", "SpinBox", theme->get_icon("SpinboxUpdown", "EditorIcons")); + + // GraphNode + Ref<StyleBoxFlat> graphsb = make_flat_stylebox(Color(0, 0, 0, 0.3), 16, 24, 16, 5); + graphsb->set_border_blend(false); + graphsb->set_border_size(2); + graphsb->set_light_color(Color(1, 1, 1, 0.6)); + graphsb->set_dark_color(Color(1, 1, 1, 0.6)); + graphsb = add_additional_border(graphsb, 0, -22, 0, 0); + Ref<StyleBoxFlat> graphsbselected = make_flat_stylebox(Color(0, 0, 0, 0.4), 16, 24, 16, 5); + graphsbselected->set_border_blend(false); + graphsbselected->set_border_size(2); + graphsbselected->set_light_color(Color(1, 1, 1, 0.9)); + graphsbselected->set_dark_color(Color(1, 1, 1, 0.9)); + graphsbselected = add_additional_border(graphsbselected, 0, -22, 0, 0); + Ref<StyleBoxFlat> graphsbcomment = make_flat_stylebox(Color(0, 0, 0, 0.3), 16, 24, 16, 5); + graphsbcomment->set_border_blend(false); + graphsbcomment->set_border_size(1); + graphsbcomment->set_light_color(Color(1, 1, 1, 0.6)); + graphsbcomment->set_dark_color(Color(1, 1, 1, 0.6)); + graphsbcomment = add_additional_border(graphsbcomment, 0, -22, 0, 0); + Ref<StyleBoxFlat> graphsbcommentselected = make_flat_stylebox(Color(0, 0, 0, 0.4), 16, 24, 16, 5); + graphsbcommentselected->set_border_blend(false); + graphsbcommentselected->set_border_size(1); + graphsbcommentselected->set_light_color(Color(1, 1, 1, 0.9)); + graphsbcommentselected->set_dark_color(Color(1, 1, 1, 0.9)); + graphsbcommentselected = add_additional_border(graphsbcommentselected, 0, -22, 0, 0); + theme->set_stylebox("frame", "GraphNode", graphsb); + theme->set_stylebox("selectedframe", "GraphNode", graphsbselected); + theme->set_stylebox("comment", "GraphNode", graphsbcomment); + theme->set_stylebox("commentfocus", "GraphNode", graphsbcommentselected); + + // FileDialog + Color disable_color = light_color_2; + disable_color.a = 0.7; + theme->set_color("files_disabled", "FileDialog", disable_color); return theme; } @@ -61,7 +459,7 @@ Ref<Theme> create_editor_theme() { Ref<Theme> create_custom_theme() { Ref<Theme> theme; - String custom_theme = EditorSettings::get_singleton()->get("interface/custom_theme"); + String custom_theme = EditorSettings::get_singleton()->get("interface/theme/custom_theme"); if (custom_theme != "") { theme = ResourceLoader::load(custom_theme); } diff --git a/editor/export_template_manager.cpp b/editor/export_template_manager.cpp index 83ada90144..e6f15d1712 100644 --- a/editor/export_template_manager.cpp +++ b/editor/export_template_manager.cpp @@ -1,11 +1,40 @@ +/*************************************************************************/ +/* export_template_manager.cpp */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #include "export_template_manager.h" + #include "editor_node.h" #include "editor_scale.h" +#include "io/zip_io.h" #include "os/dir_access.h" #include "version.h" -#include "io/zip_io.h" - void ExportTemplateManager::_update_template_list() { while (current_hb->get_child_count()) { diff --git a/editor/export_template_manager.h b/editor/export_template_manager.h index c3834ec643..480c73e123 100644 --- a/editor/export_template_manager.h +++ b/editor/export_template_manager.h @@ -1,3 +1,32 @@ +/*************************************************************************/ +/* export_template_manager.cpp */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #ifndef EXPORT_TEMPLATE_MANAGER_H #define EXPORT_TEMPLATE_MANAGER_H diff --git a/editor/filesystem_dock.cpp b/editor/filesystem_dock.cpp index 9d10117418..62fb241ade 100644 --- a/editor/filesystem_dock.cpp +++ b/editor/filesystem_dock.cpp @@ -415,8 +415,9 @@ void FileSystemDock::_update_files(bool p_keep_selection) { if (!has_icon("ResizedFolder", "EditorIcons")) { Ref<ImageTexture> folder = get_icon("FolderBig", "EditorIcons"); - Image img = folder->get_data(); - img.resize(thumbnail_size, thumbnail_size); + Ref<Image> img = folder->get_data(); + img = img->duplicate(); + img->resize(thumbnail_size, thumbnail_size); Ref<ImageTexture> resized_folder = Ref<ImageTexture>(memnew(ImageTexture)); resized_folder->create_from_image(img, 0); Theme::get_default()->set_icon("ResizedFolder", "EditorIcons", resized_folder); @@ -426,8 +427,8 @@ void FileSystemDock::_update_files(bool p_keep_selection) { if (!has_icon("ResizedFile", "EditorIcons")) { Ref<ImageTexture> file = get_icon("FileBig", "EditorIcons"); - Image img = file->get_data(); - img.resize(thumbnail_size, thumbnail_size); + Ref<Image> img = file->get_data(); + img->resize(thumbnail_size, thumbnail_size); Ref<ImageTexture> resized_file = Ref<ImageTexture>(memnew(ImageTexture)); resized_file->create_from_image(img, 0); Theme::get_default()->set_icon("ResizedFile", "EditorIcons", resized_file); @@ -1064,6 +1065,11 @@ void FileSystemDock::_folder_option(int p_option) { child = child->get_next(); } break; + case FOLDER_SHOW_IN_EXPLORER: + String path = item->get_metadata(tree->get_selected_column()); + String dir = GlobalConfig::get_singleton()->globalize_path(path); + OS::get_singleton()->shell_open(String("file://") + dir); + return; } } @@ -1102,6 +1108,9 @@ void FileSystemDock::_dir_rmb_pressed(const Vector2 &p_pos) { folder_options->add_item(TTR("Expand all"), FOLDER_EXPAND_ALL); folder_options->add_item(TTR("Collapse all"), FOLDER_COLLAPSE_ALL); + folder_options->add_separator(); + folder_options->add_item(TTR("Show In File Manager"), FOLDER_SHOW_IN_EXPLORER); + folder_options->set_position(tree->get_global_position() + p_pos); folder_options->popup(); } @@ -1728,6 +1737,7 @@ FileSystemDock::FileSystemDock(EditorNode *p_editor) { file_list_vb->set_v_size_flags(SIZE_EXPAND_FILL); path_hb = memnew(HBoxContainer); + path_hb->add_child(memnew(Control)); file_list_vb->add_child(path_hb); button_back = memnew(ToolButton); diff --git a/editor/filesystem_dock.h b/editor/filesystem_dock.h index 2b85cfa96d..77898aa6c2 100644 --- a/editor/filesystem_dock.h +++ b/editor/filesystem_dock.h @@ -76,7 +76,8 @@ private: enum FolderMenu { FOLDER_EXPAND_ALL, - FOLDER_COLLAPSE_ALL + FOLDER_COLLAPSE_ALL, + FOLDER_SHOW_IN_EXPLORER }; VBoxContainer *scanning_vb; diff --git a/editor/icons/2x/icon_2_d.png b/editor/icons/2x/icon_2_d.png Binary files differnew file mode 100644 index 0000000000..9b2ed64665 --- /dev/null +++ b/editor/icons/2x/icon_2_d.png diff --git a/editor/icons/2x/icon_3_d.png b/editor/icons/2x/icon_3_d.png Binary files differnew file mode 100644 index 0000000000..218c246870 --- /dev/null +++ b/editor/icons/2x/icon_3_d.png diff --git a/editor/icons/2x/icon_animation_player.png b/editor/icons/2x/icon_animation_player.png Binary files differindex 4a3209ab70..1a9373938b 100644 --- a/editor/icons/2x/icon_animation_player.png +++ b/editor/icons/2x/icon_animation_player.png diff --git a/editor/icons/2x/icon_animation_tree.png b/editor/icons/2x/icon_animation_tree.png Binary files differindex a213ab6e5e..a1dd4f137f 100644 --- a/editor/icons/2x/icon_animation_tree.png +++ b/editor/icons/2x/icon_animation_tree.png diff --git a/editor/icons/2x/icon_animation_tree_player.png b/editor/icons/2x/icon_animation_tree_player.png Binary files differindex a213ab6e5e..a1dd4f137f 100644 --- a/editor/icons/2x/icon_animation_tree_player.png +++ b/editor/icons/2x/icon_animation_tree_player.png diff --git a/editor/icons/2x/icon_arrow_left.png b/editor/icons/2x/icon_arrow_left.png Binary files differindex bc3995f70b..64bb9c81c0 100644 --- a/editor/icons/2x/icon_arrow_left.png +++ b/editor/icons/2x/icon_arrow_left.png diff --git a/editor/icons/2x/icon_arrow_right.png b/editor/icons/2x/icon_arrow_right.png Binary files differindex 045b390e0d..c3d6e66482 100644 --- a/editor/icons/2x/icon_arrow_right.png +++ b/editor/icons/2x/icon_arrow_right.png diff --git a/editor/icons/2x/icon_arrow_up.png b/editor/icons/2x/icon_arrow_up.png Binary files differindex 524ab934e2..008ef633ba 100644 --- a/editor/icons/2x/icon_arrow_up.png +++ b/editor/icons/2x/icon_arrow_up.png diff --git a/editor/icons/2x/icon_asset_lib.png b/editor/icons/2x/icon_asset_lib.png Binary files differnew file mode 100644 index 0000000000..22c31fb2d5 --- /dev/null +++ b/editor/icons/2x/icon_asset_lib.png diff --git a/editor/icons/2x/icon_audio_bus_bypass.png b/editor/icons/2x/icon_audio_bus_bypass.png Binary files differnew file mode 100644 index 0000000000..b44c40fb35 --- /dev/null +++ b/editor/icons/2x/icon_audio_bus_bypass.png diff --git a/editor/icons/2x/icon_audio_bus_layout.png b/editor/icons/2x/icon_audio_bus_layout.png Binary files differnew file mode 100644 index 0000000000..d6a5cba5c1 --- /dev/null +++ b/editor/icons/2x/icon_audio_bus_layout.png diff --git a/editor/icons/2x/icon_audio_bus_mute.png b/editor/icons/2x/icon_audio_bus_mute.png Binary files differnew file mode 100644 index 0000000000..4b334682f0 --- /dev/null +++ b/editor/icons/2x/icon_audio_bus_mute.png diff --git a/editor/icons/2x/icon_audio_bus_solo.png b/editor/icons/2x/icon_audio_bus_solo.png Binary files differnew file mode 100644 index 0000000000..b09a15351a --- /dev/null +++ b/editor/icons/2x/icon_audio_bus_solo.png diff --git a/editor/icons/2x/icon_audio_effect_amplify.png b/editor/icons/2x/icon_audio_effect_amplify.png Binary files differnew file mode 100644 index 0000000000..868bc6ddde --- /dev/null +++ b/editor/icons/2x/icon_audio_effect_amplify.png diff --git a/editor/icons/2x/icon_audio_player.png b/editor/icons/2x/icon_audio_player.png Binary files differnew file mode 100644 index 0000000000..799b93cc5d --- /dev/null +++ b/editor/icons/2x/icon_audio_player.png diff --git a/editor/icons/2x/icon_back.png b/editor/icons/2x/icon_back.png Binary files differindex 648c440928..b3c9b302b4 100644 --- a/editor/icons/2x/icon_back.png +++ b/editor/icons/2x/icon_back.png diff --git a/editor/icons/2x/icon_baked_light.png b/editor/icons/2x/icon_baked_light.png Binary files differindex 3c1cba5586..9b13ed8ff1 100644 --- a/editor/icons/2x/icon_baked_light.png +++ b/editor/icons/2x/icon_baked_light.png diff --git a/editor/icons/2x/icon_bool.png b/editor/icons/2x/icon_bool.png Binary files differindex 47103538bd..e2383809d8 100644 --- a/editor/icons/2x/icon_bool.png +++ b/editor/icons/2x/icon_bool.png diff --git a/editor/icons/2x/icon_bus_vu_db.png b/editor/icons/2x/icon_bus_vu_db.png Binary files differnew file mode 100644 index 0000000000..8856b026f0 --- /dev/null +++ b/editor/icons/2x/icon_bus_vu_db.png diff --git a/editor/icons/2x/icon_bus_vu_empty.png b/editor/icons/2x/icon_bus_vu_empty.png Binary files differnew file mode 100644 index 0000000000..dfa1536fb4 --- /dev/null +++ b/editor/icons/2x/icon_bus_vu_empty.png diff --git a/editor/icons/2x/icon_bus_vu_frozen.png b/editor/icons/2x/icon_bus_vu_frozen.png Binary files differnew file mode 100644 index 0000000000..367322b21c --- /dev/null +++ b/editor/icons/2x/icon_bus_vu_frozen.png diff --git a/editor/icons/2x/icon_bus_vu_full.png b/editor/icons/2x/icon_bus_vu_full.png Binary files differnew file mode 100644 index 0000000000..2c2f0bca06 --- /dev/null +++ b/editor/icons/2x/icon_bus_vu_full.png diff --git a/editor/icons/2x/icon_checked.png b/editor/icons/2x/icon_checked.png Binary files differnew file mode 100644 index 0000000000..6083540ffe --- /dev/null +++ b/editor/icons/2x/icon_checked.png diff --git a/editor/icons/2x/icon_copy_node_path.png b/editor/icons/2x/icon_copy_node_path.png Binary files differindex 056748d20b..29180d017c 100644 --- a/editor/icons/2x/icon_copy_node_path.png +++ b/editor/icons/2x/icon_copy_node_path.png diff --git a/editor/icons/2x/icon_curve_texture.png b/editor/icons/2x/icon_curve_texture.png Binary files differnew file mode 100644 index 0000000000..ccdebe89f5 --- /dev/null +++ b/editor/icons/2x/icon_curve_texture.png diff --git a/editor/icons/2x/icon_debug.png b/editor/icons/2x/icon_debug.png Binary files differnew file mode 100644 index 0000000000..9c581f340f --- /dev/null +++ b/editor/icons/2x/icon_debug.png diff --git a/editor/icons/2x/icon_dropdown.png b/editor/icons/2x/icon_dropdown.png Binary files differnew file mode 100644 index 0000000000..626dba79ec --- /dev/null +++ b/editor/icons/2x/icon_dropdown.png diff --git a/editor/icons/2x/icon_edit_resource.png b/editor/icons/2x/icon_edit_resource.png Binary files differindex 5ba9b36b0a..f0c7570160 100644 --- a/editor/icons/2x/icon_edit_resource.png +++ b/editor/icons/2x/icon_edit_resource.png diff --git a/editor/icons/2x/icon_error.png b/editor/icons/2x/icon_error.png Binary files differindex a6d79ab41b..c915da1d27 100644 --- a/editor/icons/2x/icon_error.png +++ b/editor/icons/2x/icon_error.png diff --git a/editor/icons/2x/icon_file.png b/editor/icons/2x/icon_file.png Binary files differindex 683f1141fd..a10fe2cc60 100644 --- a/editor/icons/2x/icon_file.png +++ b/editor/icons/2x/icon_file.png diff --git a/editor/icons/2x/icon_forward.png b/editor/icons/2x/icon_forward.png Binary files differindex 11fd444a04..6029449354 100644 --- a/editor/icons/2x/icon_forward.png +++ b/editor/icons/2x/icon_forward.png diff --git a/editor/icons/2x/icon_g_d_native_script.png b/editor/icons/2x/icon_g_d_native_script.png Binary files differnew file mode 100644 index 0000000000..31cc130867 --- /dev/null +++ b/editor/icons/2x/icon_g_d_native_script.png diff --git a/editor/icons/2x/icon_godot.png b/editor/icons/2x/icon_godot.png Binary files differdeleted file mode 100644 index 94d87e23cc..0000000000 --- a/editor/icons/2x/icon_godot.png +++ /dev/null diff --git a/editor/icons/2x/icon_godot_docs.png b/editor/icons/2x/icon_godot_docs.png Binary files differnew file mode 100644 index 0000000000..be30f092ef --- /dev/null +++ b/editor/icons/2x/icon_godot_docs.png diff --git a/editor/icons/2x/icon_gradient_texture.png b/editor/icons/2x/icon_gradient_texture.png Binary files differnew file mode 100644 index 0000000000..d002c8534c --- /dev/null +++ b/editor/icons/2x/icon_gradient_texture.png diff --git a/editor/icons/2x/icon_graph_scalars_to_vec.png b/editor/icons/2x/icon_graph_scalars_to_vec.png Binary files differindex 266c84e5ae..7363a47db3 100644 --- a/editor/icons/2x/icon_graph_scalars_to_vec.png +++ b/editor/icons/2x/icon_graph_scalars_to_vec.png diff --git a/editor/icons/2x/icon_graph_vec_to_scalars.png b/editor/icons/2x/icon_graph_vec_to_scalars.png Binary files differindex 1b8254b3c6..6d16ea72fe 100644 --- a/editor/icons/2x/icon_graph_vec_to_scalars.png +++ b/editor/icons/2x/icon_graph_vec_to_scalars.png diff --git a/editor/icons/2x/icon_graph_vecs_to_xform.png b/editor/icons/2x/icon_graph_vecs_to_xform.png Binary files differindex a9ed5052be..0f2ad7a83a 100644 --- a/editor/icons/2x/icon_graph_vecs_to_xform.png +++ b/editor/icons/2x/icon_graph_vecs_to_xform.png diff --git a/editor/icons/2x/icon_graph_xform_to_vecs.png b/editor/icons/2x/icon_graph_xform_to_vecs.png Binary files differindex 22125df573..d274ad99a6 100644 --- a/editor/icons/2x/icon_graph_xform_to_vecs.png +++ b/editor/icons/2x/icon_graph_xform_to_vecs.png diff --git a/editor/icons/2x/icon_hslider_bg.png b/editor/icons/2x/icon_hslider_bg.png Binary files differnew file mode 100644 index 0000000000..e3c61f25e0 --- /dev/null +++ b/editor/icons/2x/icon_hslider_bg.png diff --git a/editor/icons/2x/icon_key_hover.png b/editor/icons/2x/icon_key_hover.png Binary files differindex c9894ad8bf..5dd96e8dca 100644 --- a/editor/icons/2x/icon_key_hover.png +++ b/editor/icons/2x/icon_key_hover.png diff --git a/editor/icons/2x/icon_key_selected.png b/editor/icons/2x/icon_key_selected.png Binary files differindex 243dacb604..7fc9ffdeb4 100644 --- a/editor/icons/2x/icon_key_selected.png +++ b/editor/icons/2x/icon_key_selected.png diff --git a/editor/icons/2x/icon_key_value.png b/editor/icons/2x/icon_key_value.png Binary files differindex 3863403706..94921e2446 100644 --- a/editor/icons/2x/icon_key_value.png +++ b/editor/icons/2x/icon_key_value.png diff --git a/editor/icons/2x/icon_key_xform.png b/editor/icons/2x/icon_key_xform.png Binary files differindex 70c49b5b5f..5749aac8f4 100644 --- a/editor/icons/2x/icon_key_xform.png +++ b/editor/icons/2x/icon_key_xform.png diff --git a/editor/icons/2x/icon_line_2d.png b/editor/icons/2x/icon_line_2d.png Binary files differindex 27299a2b69..66e5bbc5ba 100644 --- a/editor/icons/2x/icon_line_2d.png +++ b/editor/icons/2x/icon_line_2d.png diff --git a/editor/icons/2x/icon_load.png b/editor/icons/2x/icon_load.png Binary files differindex 759381d636..2e797c448b 100644 --- a/editor/icons/2x/icon_load.png +++ b/editor/icons/2x/icon_load.png diff --git a/editor/icons/2x/icon_mini_basis.png b/editor/icons/2x/icon_mini_basis.png Binary files differnew file mode 100644 index 0000000000..276b48d722 --- /dev/null +++ b/editor/icons/2x/icon_mini_basis.png diff --git a/editor/icons/2x/icon_mini_matrix3.png b/editor/icons/2x/icon_mini_matrix3.png Binary files differindex 93783177e1..276b48d722 100644 --- a/editor/icons/2x/icon_mini_matrix3.png +++ b/editor/icons/2x/icon_mini_matrix3.png diff --git a/editor/icons/2x/icon_mini_transform2D.png b/editor/icons/2x/icon_mini_transform2D.png Binary files differnew file mode 100644 index 0000000000..4237eced18 --- /dev/null +++ b/editor/icons/2x/icon_mini_transform2D.png diff --git a/editor/icons/2x/icon_mirror_x.png b/editor/icons/2x/icon_mirror_x.png Binary files differindex 3b096dce88..b5a8867a16 100644 --- a/editor/icons/2x/icon_mirror_x.png +++ b/editor/icons/2x/icon_mirror_x.png diff --git a/editor/icons/2x/icon_mirror_y.png b/editor/icons/2x/icon_mirror_y.png Binary files differindex 4c89b167b5..4a0483eb70 100644 --- a/editor/icons/2x/icon_mirror_y.png +++ b/editor/icons/2x/icon_mirror_y.png diff --git a/editor/icons/2x/icon_move_down.png b/editor/icons/2x/icon_move_down.png Binary files differindex 97bbeea631..2a17aab204 100644 --- a/editor/icons/2x/icon_move_down.png +++ b/editor/icons/2x/icon_move_down.png diff --git a/editor/icons/2x/icon_move_up.png b/editor/icons/2x/icon_move_up.png Binary files differindex f8f31baeb1..d8d7f5a207 100644 --- a/editor/icons/2x/icon_move_up.png +++ b/editor/icons/2x/icon_move_up.png diff --git a/editor/icons/2x/icon_new.png b/editor/icons/2x/icon_new.png Binary files differindex 683f1141fd..a10fe2cc60 100644 --- a/editor/icons/2x/icon_new.png +++ b/editor/icons/2x/icon_new.png diff --git a/editor/icons/2x/icon_option_arrow.png b/editor/icons/2x/icon_option_arrow.png Binary files differnew file mode 100644 index 0000000000..ed177a4451 --- /dev/null +++ b/editor/icons/2x/icon_option_arrow.png diff --git a/editor/icons/2x/icon_particles_material.png b/editor/icons/2x/icon_particles_material.png Binary files differnew file mode 100644 index 0000000000..26ce8f6809 --- /dev/null +++ b/editor/icons/2x/icon_particles_material.png diff --git a/editor/icons/2x/icon_play_button_group.png b/editor/icons/2x/icon_play_button_group.png Binary files differnew file mode 100644 index 0000000000..e28cb52e64 --- /dev/null +++ b/editor/icons/2x/icon_play_button_group.png diff --git a/editor/icons/2x/icon_search.png b/editor/icons/2x/icon_search.png Binary files differnew file mode 100644 index 0000000000..0c4a6a8c84 --- /dev/null +++ b/editor/icons/2x/icon_search.png diff --git a/editor/icons/2x/icon_slider_grabber.png b/editor/icons/2x/icon_slider_grabber.png Binary files differnew file mode 100644 index 0000000000..64cf83270a --- /dev/null +++ b/editor/icons/2x/icon_slider_grabber.png diff --git a/editor/icons/2x/icon_slider_grabber_hl.png b/editor/icons/2x/icon_slider_grabber_hl.png Binary files differnew file mode 100644 index 0000000000..d68da0d12a --- /dev/null +++ b/editor/icons/2x/icon_slider_grabber_hl.png diff --git a/editor/icons/2x/icon_spatial_material.png b/editor/icons/2x/icon_spatial_material.png Binary files differnew file mode 100644 index 0000000000..68f6cf8dac --- /dev/null +++ b/editor/icons/2x/icon_spatial_material.png diff --git a/editor/icons/2x/icon_spinbox_updown.png b/editor/icons/2x/icon_spinbox_updown.png Binary files differnew file mode 100644 index 0000000000..e711fbf08b --- /dev/null +++ b/editor/icons/2x/icon_spinbox_updown.png diff --git a/editor/icons/2x/icon_stream_texture.png b/editor/icons/2x/icon_stream_texture.png Binary files differnew file mode 100644 index 0000000000..85cc3e7206 --- /dev/null +++ b/editor/icons/2x/icon_stream_texture.png diff --git a/editor/icons/2x/icon_tab_menu.png b/editor/icons/2x/icon_tab_menu.png Binary files differnew file mode 100644 index 0000000000..becad9db76 --- /dev/null +++ b/editor/icons/2x/icon_tab_menu.png diff --git a/editor/icons/2x/icon_tabs.png b/editor/icons/2x/icon_tabs.png Binary files differindex 6c317010c8..af61bc5ab1 100644 --- a/editor/icons/2x/icon_tabs.png +++ b/editor/icons/2x/icon_tabs.png diff --git a/editor/icons/2x/icon_tree_arrow_down.png b/editor/icons/2x/icon_tree_arrow_down.png Binary files differnew file mode 100644 index 0000000000..00012dea39 --- /dev/null +++ b/editor/icons/2x/icon_tree_arrow_down.png diff --git a/editor/icons/2x/icon_tree_arrow_right.png b/editor/icons/2x/icon_tree_arrow_right.png Binary files differnew file mode 100644 index 0000000000..baaf016784 --- /dev/null +++ b/editor/icons/2x/icon_tree_arrow_right.png diff --git a/editor/icons/2x/icon_tween.png b/editor/icons/2x/icon_tween.png Binary files differindex a13d955eb0..1f020a0e79 100644 --- a/editor/icons/2x/icon_tween.png +++ b/editor/icons/2x/icon_tween.png diff --git a/editor/icons/2x/icon_unchecked.png b/editor/icons/2x/icon_unchecked.png Binary files differnew file mode 100644 index 0000000000..cd8b781000 --- /dev/null +++ b/editor/icons/2x/icon_unchecked.png diff --git a/editor/icons/2x/icon_vslider_bg.png b/editor/icons/2x/icon_vslider_bg.png Binary files differnew file mode 100644 index 0000000000..a7e0e78564 --- /dev/null +++ b/editor/icons/2x/icon_vslider_bg.png diff --git a/editor/icons/2x/icon_warning.png b/editor/icons/2x/icon_warning.png Binary files differindex 5d807065e7..e953c02ce3 100644 --- a/editor/icons/2x/icon_warning.png +++ b/editor/icons/2x/icon_warning.png diff --git a/editor/icons/2x/icon_zoom.png b/editor/icons/2x/icon_zoom.png Binary files differindex 0c4a6a8c84..0de25b4db7 100644 --- a/editor/icons/2x/icon_zoom.png +++ b/editor/icons/2x/icon_zoom.png diff --git a/editor/icons/SCsub b/editor/icons/SCsub index 3fc8e5461f..20a381cc78 100644 --- a/editor/icons/SCsub +++ b/editor/icons/SCsub @@ -62,9 +62,9 @@ def make_editor_icons_action(target, source, env): s.write("static Ref<ImageTexture> make_icon(const uint8_t* p_png,const uint8_t* p_hidpi_png) {\n") s.write("\tRef<ImageTexture> texture( memnew( ImageTexture ) );\n") s.write("\tbool use_hidpi_image=(editor_get_scale()>1.0&&p_hidpi_png);\n") - s.write("\tImage img(use_hidpi_image?p_hidpi_png:p_png);\n") - s.write("\tif (editor_get_scale()>1.0 && !p_hidpi_png) { img.convert(Image::FORMAT_RGBA8); img.expand_x2_hq2x(); use_hidpi_image=true;}\n") - s.write("\timg.resize(img.get_width()*EDSCALE/(use_hidpi_image?2:1),img.get_height()*EDSCALE/(use_hidpi_image?2:1));\n") + s.write("\tRef<Image> img = memnew(Image(use_hidpi_image?p_hidpi_png:p_png));\n") + s.write("\tif (editor_get_scale()>1.0 && !p_hidpi_png) { img->convert(Image::FORMAT_RGBA8); img->expand_x2_hq2x(); use_hidpi_image=true;}\n") + s.write("\timg->resize(img->get_width()*EDSCALE/(use_hidpi_image?2:1),img->get_height()*EDSCALE/(use_hidpi_image?2:1));\n") s.write("\ttexture->create_from_image( img,ImageTexture::FLAG_FILTER );\n") s.write("\treturn texture;\n") s.write("}\n\n") diff --git a/editor/icons/icon_2_d.png b/editor/icons/icon_2_d.png Binary files differnew file mode 100644 index 0000000000..d8a77ee1c2 --- /dev/null +++ b/editor/icons/icon_2_d.png diff --git a/editor/icons/icon_3_d.png b/editor/icons/icon_3_d.png Binary files differnew file mode 100644 index 0000000000..e1daf1077b --- /dev/null +++ b/editor/icons/icon_3_d.png diff --git a/editor/icons/icon_animation_player.png b/editor/icons/icon_animation_player.png Binary files differindex 8a6f446e4e..474ec2e647 100644 --- a/editor/icons/icon_animation_player.png +++ b/editor/icons/icon_animation_player.png diff --git a/editor/icons/icon_animation_tree.png b/editor/icons/icon_animation_tree.png Binary files differindex 684edb876b..7a29f4d841 100644 --- a/editor/icons/icon_animation_tree.png +++ b/editor/icons/icon_animation_tree.png diff --git a/editor/icons/icon_animation_tree_player.png b/editor/icons/icon_animation_tree_player.png Binary files differindex 684edb876b..7a29f4d841 100644 --- a/editor/icons/icon_animation_tree_player.png +++ b/editor/icons/icon_animation_tree_player.png diff --git a/editor/icons/icon_arrow_left.png b/editor/icons/icon_arrow_left.png Binary files differindex 1e0d38b4b6..ad382516c2 100644 --- a/editor/icons/icon_arrow_left.png +++ b/editor/icons/icon_arrow_left.png diff --git a/editor/icons/icon_arrow_right.png b/editor/icons/icon_arrow_right.png Binary files differindex 09907755e1..6260d44fac 100644 --- a/editor/icons/icon_arrow_right.png +++ b/editor/icons/icon_arrow_right.png diff --git a/editor/icons/icon_arrow_up.png b/editor/icons/icon_arrow_up.png Binary files differindex f7ec666f69..2f02f48e18 100644 --- a/editor/icons/icon_arrow_up.png +++ b/editor/icons/icon_arrow_up.png diff --git a/editor/icons/icon_asset_lib.png b/editor/icons/icon_asset_lib.png Binary files differnew file mode 100644 index 0000000000..70d708a58c --- /dev/null +++ b/editor/icons/icon_asset_lib.png diff --git a/editor/icons/icon_audio_bus_bypass.png b/editor/icons/icon_audio_bus_bypass.png Binary files differnew file mode 100644 index 0000000000..95a3a0177a --- /dev/null +++ b/editor/icons/icon_audio_bus_bypass.png diff --git a/editor/icons/icon_audio_bus_layout.png b/editor/icons/icon_audio_bus_layout.png Binary files differnew file mode 100644 index 0000000000..bfa5e2c933 --- /dev/null +++ b/editor/icons/icon_audio_bus_layout.png diff --git a/editor/icons/icon_audio_bus_mute.png b/editor/icons/icon_audio_bus_mute.png Binary files differnew file mode 100644 index 0000000000..b074d848e0 --- /dev/null +++ b/editor/icons/icon_audio_bus_mute.png diff --git a/editor/icons/icon_audio_bus_solo.png b/editor/icons/icon_audio_bus_solo.png Binary files differnew file mode 100644 index 0000000000..085269f231 --- /dev/null +++ b/editor/icons/icon_audio_bus_solo.png diff --git a/editor/icons/icon_audio_effect_amplify.png b/editor/icons/icon_audio_effect_amplify.png Binary files differindex 9af3227d40..6588b90372 100644 --- a/editor/icons/icon_audio_effect_amplify.png +++ b/editor/icons/icon_audio_effect_amplify.png diff --git a/editor/icons/icon_audio_player.png b/editor/icons/icon_audio_player.png Binary files differnew file mode 100644 index 0000000000..c3e6d6cafa --- /dev/null +++ b/editor/icons/icon_audio_player.png diff --git a/editor/icons/icon_back.png b/editor/icons/icon_back.png Binary files differindex 52fbc8117a..8497d2cf4b 100644 --- a/editor/icons/icon_back.png +++ b/editor/icons/icon_back.png diff --git a/editor/icons/icon_baked_light.png b/editor/icons/icon_baked_light.png Binary files differindex 3b7fce5c9f..c667b542c1 100644 --- a/editor/icons/icon_baked_light.png +++ b/editor/icons/icon_baked_light.png diff --git a/editor/icons/icon_bool.png b/editor/icons/icon_bool.png Binary files differindex 822b5dd688..c680bc195a 100644 --- a/editor/icons/icon_bool.png +++ b/editor/icons/icon_bool.png diff --git a/editor/icons/icon_bus_vu_db.png b/editor/icons/icon_bus_vu_db.png Binary files differindex 52507cae52..2c51a2e559 100644 --- a/editor/icons/icon_bus_vu_db.png +++ b/editor/icons/icon_bus_vu_db.png diff --git a/editor/icons/icon_bus_vu_empty.png b/editor/icons/icon_bus_vu_empty.png Binary files differindex 6fc3143a55..32d886b1a2 100644 --- a/editor/icons/icon_bus_vu_empty.png +++ b/editor/icons/icon_bus_vu_empty.png diff --git a/editor/icons/icon_bus_vu_frozen.png b/editor/icons/icon_bus_vu_frozen.png Binary files differindex cf128afa91..1a6ca6e767 100644 --- a/editor/icons/icon_bus_vu_frozen.png +++ b/editor/icons/icon_bus_vu_frozen.png diff --git a/editor/icons/icon_bus_vu_full.png b/editor/icons/icon_bus_vu_full.png Binary files differindex 9e3d7a93e3..b47deea254 100644 --- a/editor/icons/icon_bus_vu_full.png +++ b/editor/icons/icon_bus_vu_full.png diff --git a/editor/icons/icon_checked.png b/editor/icons/icon_checked.png Binary files differnew file mode 100644 index 0000000000..d3442930bb --- /dev/null +++ b/editor/icons/icon_checked.png diff --git a/editor/icons/icon_copy_node_path.png b/editor/icons/icon_copy_node_path.png Binary files differindex d777f132d8..877bb81d81 100644 --- a/editor/icons/icon_copy_node_path.png +++ b/editor/icons/icon_copy_node_path.png diff --git a/editor/icons/icon_curve_texture.png b/editor/icons/icon_curve_texture.png Binary files differnew file mode 100644 index 0000000000..bc5c7f6bf1 --- /dev/null +++ b/editor/icons/icon_curve_texture.png diff --git a/editor/icons/icon_debug.png b/editor/icons/icon_debug.png Binary files differindex 03b98aa9e4..a4a4591e12 100644 --- a/editor/icons/icon_debug.png +++ b/editor/icons/icon_debug.png diff --git a/editor/icons/icon_default_project_icon.png b/editor/icons/icon_default_project_icon.png Binary files differindex e87a49bd28..4c31fe5cb2 100644 --- a/editor/icons/icon_default_project_icon.png +++ b/editor/icons/icon_default_project_icon.png diff --git a/editor/icons/icon_dropdown.png b/editor/icons/icon_dropdown.png Binary files differnew file mode 100644 index 0000000000..b9a324be7c --- /dev/null +++ b/editor/icons/icon_dropdown.png diff --git a/editor/icons/icon_edit_resource.png b/editor/icons/icon_edit_resource.png Binary files differindex 9f064fea3f..fca57f3e7e 100644 --- a/editor/icons/icon_edit_resource.png +++ b/editor/icons/icon_edit_resource.png diff --git a/editor/icons/icon_error.png b/editor/icons/icon_error.png Binary files differindex 7a9bed43aa..8a9130f70b 100644 --- a/editor/icons/icon_error.png +++ b/editor/icons/icon_error.png diff --git a/editor/icons/icon_file.png b/editor/icons/icon_file.png Binary files differindex 69c6c90dc7..b012e1f214 100644 --- a/editor/icons/icon_file.png +++ b/editor/icons/icon_file.png diff --git a/editor/icons/icon_forward.png b/editor/icons/icon_forward.png Binary files differindex 412ffa89d3..529964f49d 100644 --- a/editor/icons/icon_forward.png +++ b/editor/icons/icon_forward.png diff --git a/editor/icons/icon_g_d_native_script.png b/editor/icons/icon_g_d_native_script.png Binary files differnew file mode 100644 index 0000000000..ea4fe06704 --- /dev/null +++ b/editor/icons/icon_g_d_native_script.png diff --git a/editor/icons/icon_godot.png b/editor/icons/icon_godot.png Binary files differdeleted file mode 100644 index 0b72e6ecc7..0000000000 --- a/editor/icons/icon_godot.png +++ /dev/null diff --git a/editor/icons/icon_godot_docs.png b/editor/icons/icon_godot_docs.png Binary files differnew file mode 100644 index 0000000000..554280c5b4 --- /dev/null +++ b/editor/icons/icon_godot_docs.png diff --git a/editor/icons/icon_gradient_texture.png b/editor/icons/icon_gradient_texture.png Binary files differnew file mode 100644 index 0000000000..fedbf038a3 --- /dev/null +++ b/editor/icons/icon_gradient_texture.png diff --git a/editor/icons/icon_graph_scalars_to_vec.png b/editor/icons/icon_graph_scalars_to_vec.png Binary files differindex 231a25a02a..b8893e78ca 100644 --- a/editor/icons/icon_graph_scalars_to_vec.png +++ b/editor/icons/icon_graph_scalars_to_vec.png diff --git a/editor/icons/icon_graph_vec_to_scalars.png b/editor/icons/icon_graph_vec_to_scalars.png Binary files differindex 33f9fdf9bd..b0f2a9c4ae 100644 --- a/editor/icons/icon_graph_vec_to_scalars.png +++ b/editor/icons/icon_graph_vec_to_scalars.png diff --git a/editor/icons/icon_graph_vecs_to_xform.png b/editor/icons/icon_graph_vecs_to_xform.png Binary files differindex 82c32525dc..b5217badcf 100644 --- a/editor/icons/icon_graph_vecs_to_xform.png +++ b/editor/icons/icon_graph_vecs_to_xform.png diff --git a/editor/icons/icon_graph_xform_to_vecs.png b/editor/icons/icon_graph_xform_to_vecs.png Binary files differindex 3d59c7957d..9e2909969f 100644 --- a/editor/icons/icon_graph_xform_to_vecs.png +++ b/editor/icons/icon_graph_xform_to_vecs.png diff --git a/editor/icons/icon_h_button_array.png b/editor/icons/icon_h_button_array.png Binary files differdeleted file mode 100644 index baf3386801..0000000000 --- a/editor/icons/icon_h_button_array.png +++ /dev/null diff --git a/editor/icons/icon_hslider_bg.png b/editor/icons/icon_hslider_bg.png Binary files differnew file mode 100644 index 0000000000..e3c61f25e0 --- /dev/null +++ b/editor/icons/icon_hslider_bg.png diff --git a/editor/icons/icon_hsplit_bg.png b/editor/icons/icon_hsplit_bg.png Binary files differnew file mode 100644 index 0000000000..cfb76f7dc7 --- /dev/null +++ b/editor/icons/icon_hsplit_bg.png diff --git a/editor/icons/icon_hsplitter.png b/editor/icons/icon_hsplitter.png Binary files differnew file mode 100644 index 0000000000..3ac1dddf90 --- /dev/null +++ b/editor/icons/icon_hsplitter.png diff --git a/editor/icons/icon_key_hover.png b/editor/icons/icon_key_hover.png Binary files differindex 7ab405bb07..c8e59f0e87 100644 --- a/editor/icons/icon_key_hover.png +++ b/editor/icons/icon_key_hover.png diff --git a/editor/icons/icon_key_selected.png b/editor/icons/icon_key_selected.png Binary files differindex 1838dc95aa..e5f802db1c 100644 --- a/editor/icons/icon_key_selected.png +++ b/editor/icons/icon_key_selected.png diff --git a/editor/icons/icon_key_value.png b/editor/icons/icon_key_value.png Binary files differindex 5c0b25a264..1fa007f9e2 100644 --- a/editor/icons/icon_key_value.png +++ b/editor/icons/icon_key_value.png diff --git a/editor/icons/icon_key_xform.png b/editor/icons/icon_key_xform.png Binary files differindex 1171bd80db..bd87611d7a 100644 --- a/editor/icons/icon_key_xform.png +++ b/editor/icons/icon_key_xform.png diff --git a/editor/icons/icon_line_2d.png b/editor/icons/icon_line_2d.png Binary files differindex 4ebf46af04..8d2b176335 100644 --- a/editor/icons/icon_line_2d.png +++ b/editor/icons/icon_line_2d.png diff --git a/editor/icons/icon_load.png b/editor/icons/icon_load.png Binary files differindex 81835efa25..cc05e98ebb 100644 --- a/editor/icons/icon_load.png +++ b/editor/icons/icon_load.png diff --git a/editor/icons/icon_logo.png b/editor/icons/icon_logo.png Binary files differindex 9bbd7dc619..aed94cb87a 100644 --- a/editor/icons/icon_logo.png +++ b/editor/icons/icon_logo.png diff --git a/editor/icons/icon_logo_small.png b/editor/icons/icon_logo_small.png Binary files differindex 9c7c7fe365..809cf18541 100644 --- a/editor/icons/icon_logo_small.png +++ b/editor/icons/icon_logo_small.png diff --git a/editor/icons/icon_mini_basis.png b/editor/icons/icon_mini_basis.png Binary files differnew file mode 100644 index 0000000000..7a4ac9b137 --- /dev/null +++ b/editor/icons/icon_mini_basis.png diff --git a/editor/icons/icon_mini_matrix3.png b/editor/icons/icon_mini_matrix3.png Binary files differindex dd59d093cc..7a4ac9b137 100644 --- a/editor/icons/icon_mini_matrix3.png +++ b/editor/icons/icon_mini_matrix3.png diff --git a/editor/icons/icon_mini_transform2D.png b/editor/icons/icon_mini_transform2D.png Binary files differnew file mode 100644 index 0000000000..f4e1211bd7 --- /dev/null +++ b/editor/icons/icon_mini_transform2D.png diff --git a/editor/icons/icon_mirror_x.png b/editor/icons/icon_mirror_x.png Binary files differindex 7be48946b4..f2c9074b89 100644 --- a/editor/icons/icon_mirror_x.png +++ b/editor/icons/icon_mirror_x.png diff --git a/editor/icons/icon_mirror_y.png b/editor/icons/icon_mirror_y.png Binary files differindex ba924f7ae7..655f52d481 100644 --- a/editor/icons/icon_mirror_y.png +++ b/editor/icons/icon_mirror_y.png diff --git a/editor/icons/icon_move_down.png b/editor/icons/icon_move_down.png Binary files differindex 3934310964..7bb964675d 100644 --- a/editor/icons/icon_move_down.png +++ b/editor/icons/icon_move_down.png diff --git a/editor/icons/icon_move_up.png b/editor/icons/icon_move_up.png Binary files differindex 684013dc40..92614b8799 100644 --- a/editor/icons/icon_move_up.png +++ b/editor/icons/icon_move_up.png diff --git a/editor/icons/icon_new.png b/editor/icons/icon_new.png Binary files differindex 69c6c90dc7..b012e1f214 100644 --- a/editor/icons/icon_new.png +++ b/editor/icons/icon_new.png diff --git a/editor/icons/icon_option_arrow.png b/editor/icons/icon_option_arrow.png Binary files differnew file mode 100644 index 0000000000..b7bc38e03f --- /dev/null +++ b/editor/icons/icon_option_arrow.png diff --git a/editor/icons/icon_particles_material.png b/editor/icons/icon_particles_material.png Binary files differnew file mode 100644 index 0000000000..3b5c5644b2 --- /dev/null +++ b/editor/icons/icon_particles_material.png diff --git a/editor/icons/icon_play_button_group.png b/editor/icons/icon_play_button_group.png Binary files differnew file mode 100644 index 0000000000..83820c8e0c --- /dev/null +++ b/editor/icons/icon_play_button_group.png diff --git a/editor/icons/icon_scroll_bg.png b/editor/icons/icon_scroll_bg.png Binary files differnew file mode 100644 index 0000000000..1908fd8aee --- /dev/null +++ b/editor/icons/icon_scroll_bg.png diff --git a/editor/icons/icon_scroll_grabber.png b/editor/icons/icon_scroll_grabber.png Binary files differnew file mode 100644 index 0000000000..4be7f4e6cc --- /dev/null +++ b/editor/icons/icon_scroll_grabber.png diff --git a/editor/icons/icon_scroll_grabber_hl.png b/editor/icons/icon_scroll_grabber_hl.png Binary files differnew file mode 100644 index 0000000000..a81239b84b --- /dev/null +++ b/editor/icons/icon_scroll_grabber_hl.png diff --git a/editor/icons/icon_search.png b/editor/icons/icon_search.png Binary files differnew file mode 100644 index 0000000000..f3748803cf --- /dev/null +++ b/editor/icons/icon_search.png diff --git a/editor/icons/icon_slider_grabber.png b/editor/icons/icon_slider_grabber.png Binary files differnew file mode 100644 index 0000000000..6b6982e26c --- /dev/null +++ b/editor/icons/icon_slider_grabber.png diff --git a/editor/icons/icon_slider_grabber_hl.png b/editor/icons/icon_slider_grabber_hl.png Binary files differnew file mode 100644 index 0000000000..03d4b2bb99 --- /dev/null +++ b/editor/icons/icon_slider_grabber_hl.png diff --git a/editor/icons/icon_spatial_material.png b/editor/icons/icon_spatial_material.png Binary files differnew file mode 100644 index 0000000000..7608fc9036 --- /dev/null +++ b/editor/icons/icon_spatial_material.png diff --git a/editor/icons/icon_spinbox_updown.png b/editor/icons/icon_spinbox_updown.png Binary files differnew file mode 100644 index 0000000000..ff65df801b --- /dev/null +++ b/editor/icons/icon_spinbox_updown.png diff --git a/editor/icons/icon_stream_texture.png b/editor/icons/icon_stream_texture.png Binary files differnew file mode 100644 index 0000000000..1858a299d7 --- /dev/null +++ b/editor/icons/icon_stream_texture.png diff --git a/editor/icons/icon_tab_menu.png b/editor/icons/icon_tab_menu.png Binary files differindex 29edd02f01..ffc63f2d41 100644 --- a/editor/icons/icon_tab_menu.png +++ b/editor/icons/icon_tab_menu.png diff --git a/editor/icons/icon_tabs.png b/editor/icons/icon_tabs.png Binary files differindex bef0f60660..c17ab6fa1b 100644 --- a/editor/icons/icon_tabs.png +++ b/editor/icons/icon_tabs.png diff --git a/editor/icons/icon_tree_arrow_down.png b/editor/icons/icon_tree_arrow_down.png Binary files differnew file mode 100644 index 0000000000..4ef7b41de6 --- /dev/null +++ b/editor/icons/icon_tree_arrow_down.png diff --git a/editor/icons/icon_tree_arrow_right.png b/editor/icons/icon_tree_arrow_right.png Binary files differnew file mode 100644 index 0000000000..13a42f730d --- /dev/null +++ b/editor/icons/icon_tree_arrow_right.png diff --git a/editor/icons/icon_tween.png b/editor/icons/icon_tween.png Binary files differindex 36717c0922..3181e2cf63 100644 --- a/editor/icons/icon_tween.png +++ b/editor/icons/icon_tween.png diff --git a/editor/icons/icon_unchecked.png b/editor/icons/icon_unchecked.png Binary files differnew file mode 100644 index 0000000000..9d7d55aa46 --- /dev/null +++ b/editor/icons/icon_unchecked.png diff --git a/editor/icons/icon_v_button_array.png b/editor/icons/icon_v_button_array.png Binary files differdeleted file mode 100644 index d7ea9cc375..0000000000 --- a/editor/icons/icon_v_button_array.png +++ /dev/null diff --git a/editor/icons/icon_vslider_bg.png b/editor/icons/icon_vslider_bg.png Binary files differnew file mode 100644 index 0000000000..a7e0e78564 --- /dev/null +++ b/editor/icons/icon_vslider_bg.png diff --git a/editor/icons/icon_vsplit_bg.png b/editor/icons/icon_vsplit_bg.png Binary files differnew file mode 100644 index 0000000000..0c29b1e35c --- /dev/null +++ b/editor/icons/icon_vsplit_bg.png diff --git a/editor/icons/icon_vsplitter.png b/editor/icons/icon_vsplitter.png Binary files differnew file mode 100644 index 0000000000..56fb20bc3f --- /dev/null +++ b/editor/icons/icon_vsplitter.png diff --git a/editor/icons/icon_warning.png b/editor/icons/icon_warning.png Binary files differindex 451beba820..45b52542da 100644 --- a/editor/icons/icon_warning.png +++ b/editor/icons/icon_warning.png diff --git a/editor/icons/icon_zoom.png b/editor/icons/icon_zoom.png Binary files differindex f3748803cf..e95cf2bd78 100644 --- a/editor/icons/icon_zoom.png +++ b/editor/icons/icon_zoom.png diff --git a/editor/icons/source/icon_animation_player.svg b/editor/icons/source/icon_animation_player.svg index add4d5ac42..e6500ea249 100644 --- a/editor/icons/source/icon_animation_player.svg +++ b/editor/icons/source/icon_animation_player.svg @@ -14,11 +14,11 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_animation_player.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" - sodipodi:docname="icon_animation_player (copy).svg"> + sodipodi:docname="icon_animation_player.svg"> <defs id="defs4" /> <sodipodi:namedview @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="31.999998" - inkscape:cx="8.7610995" - inkscape:cy="9.3751685" + inkscape:cx="3.1985991" + inkscape:cy="7.9689184" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -69,7 +69,7 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="opacity:1;fill:#e1cb50;fill-opacity:0.98431373;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + style="opacity:1;fill:#fbe87a;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" d="m 1,1037.3622 0,14 1.1666666,0 0,-2 1.8333334,0 0,2 8,0 0,-2 2,0 0,2 1,0 0,-14 -1,0 0,2 -2,0 0,-2 -8,0 0,2 -1.8333334,0 0,-2 z m 1.1666666,4 1.8333334,0 0,2 -1.8333334,0 z m 9.8333334,0 2,0 0,2 -2,0 z m -9.8333334,4 1.8333334,0 0,2 -1.8333334,0 z m 9.8333334,0 2,0 0,2 -2,0 z" id="rect4136" inkscape:connector-curvature="0" diff --git a/editor/icons/source/icon_animation_tree_player.svg b/editor/icons/source/icon_animation_tree_player.svg index ab81cb226a..1c5c41e5f2 100644 --- a/editor/icons/source/icon_animation_tree_player.svg +++ b/editor/icons/source/icon_animation_tree_player.svg @@ -14,11 +14,11 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_animation_tree_player.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" - sodipodi:docname="icon_animation_tree_player (copy).svg"> + sodipodi:docname="icon_animation_tree_player.svg"> <defs id="defs4" /> <sodipodi:namedview @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="45.254831" - inkscape:cx="9.7184474" - inkscape:cy="8.2407739" + inkscape:zoom="22.627416" + inkscape:cx="-0.31764706" + inkscape:cy="5.3536612" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -69,8 +69,8 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="opacity:1;fill:#e1cb50;fill-opacity:0.98431373;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 1 1 L 1 15 L 2.1660156 15 L 2.1660156 13 L 4 13 L 4 15 L 12 15 L 12 13 L 14 13 L 14 15 L 15 15 L 15 1 L 14 1 L 14 3 L 12 3 L 12 1 L 4 1 L 4 3 L 2.1660156 3 L 2.1660156 1 L 1 1 z M 2.1660156 5 L 4 5 L 4 7 L 2.1660156 7 L 2.1660156 5 z M 8 5 A 1 1 0 0 1 9 6 A 1 1 0 0 1 8.8339844 6.5507812 L 10.060547 9.0039062 A 1 1 0 0 1 11 10 A 1 1 0 0 1 10 11 A 1 1 0 0 1 9 10 A 1 1 0 0 1 9.1660156 9.4492188 L 8 7.1171875 L 6.8339844 9.4492188 A 1 1 0 0 1 7 10 A 1 1 0 0 1 6 11 A 1 1 0 0 1 5 10 A 1 1 0 0 1 5.9414062 9.0019531 L 7.1660156 6.5507812 A 1 1 0 0 1 7 6 A 1 1 0 0 1 8 5 z M 12 5 L 14 5 L 14 7 L 12 7 L 12 5 z M 2.1660156 9 L 4 9 L 4 11 L 2.1660156 11 L 2.1660156 9 z M 12 9 L 14 9 L 14 11 L 12 11 L 12 9 z " + style="opacity:1;fill:#fbe87a;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="M 1 1 L 1 15 L 2.1660156 15 L 2.1660156 13 L 4 13 L 4 15 L 12 15 L 12 13 L 14 13 L 14 15 L 15 15 L 15 1 L 14 1 L 14 3 L 12 3 L 12 1 L 4 1 L 4 3 L 2.1660156 3 L 2.1660156 1 L 1 1 z M 5.984375 2.9863281 A 1.0001 1.0001 0 0 1 7 4 L 7 6.3828125 L 9.5527344 5.1054688 A 1.0001 1.0001 0 0 1 10.003906 4.9941406 A 1.0001 1.0001 0 0 1 10.447266 6.8945312 L 7 8.6171875 L 7 12 A 1.0001 1.0001 0 1 1 5 12 L 5 7.9921875 L 5 4 A 1.0001 1.0001 0 0 1 5.984375 2.9863281 z M 2.1660156 5 L 4 5 L 4 7 L 2.1660156 7 L 2.1660156 5 z M 12 5 L 14 5 L 14 7 L 12 7 L 12 5 z M 2.1660156 9 L 4 9 L 4 11 L 2.1660156 11 L 2.1660156 9 z M 12 9 L 14 9 L 14 11 L 12 11 L 12 9 z " transform="translate(0,1036.3622)" id="rect4136" /> </g> diff --git a/editor/icons/source/icon_arrow_left.svg b/editor/icons/source/icon_arrow_left.svg index 75a9ef0d68..a9be19b6d4 100644 --- a/editor/icons/source/icon_arrow_left.svg +++ b/editor/icons/source/icon_arrow_left.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_arrow_left.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="-0.2534386" - inkscape:cy="9.1352698" + inkscape:cx="7.4636822" + inkscape:cy="9.1396144" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -69,9 +69,16 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="M 6 4 L 3.5 6 L 1 8 L 3.5 10 L 6 12 L 6 9 L 15 9 L 15 7 L 6 7 L 6 4 z " - transform="translate(0,1036.3622)" - id="rect4352" /> + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 8,1048.3622 -4,-4 4,-4" + id="path814" + inkscape:connector-curvature="0" + sodipodi:nodetypes="ccc" /> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 4,1044.3622 h 7" + id="path816" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cc" /> </g> </svg> diff --git a/editor/icons/source/icon_arrow_right.svg b/editor/icons/source/icon_arrow_right.svg index a7600699f7..f6cbe3bc19 100644 --- a/editor/icons/source/icon_arrow_right.svg +++ b/editor/icons/source/icon_arrow_right.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_arrow_left.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="0.9028114" - inkscape:cy="9.2602698" + inkscape:cx="7.0981428" + inkscape:cy="9.8315212" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title /> + <dc:title></dc:title> </cc:Work> </rdf:RDF> </metadata> @@ -69,10 +69,16 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 10,1048.3622 5,-4 -5,-4 0,3 -9,0 0,2 9,0 z" - id="rect4352" + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 8.0142425,1048.3622 3.9999995,-4 -3.9999995,-4" + id="path814" inkscape:connector-curvature="0" - sodipodi:nodetypes="cccccccc" /> + sodipodi:nodetypes="ccc" /> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="M 12.014242,1044.3622 H 5.0142425" + id="path816" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cc" /> </g> </svg> diff --git a/editor/icons/source/icon_arrow_up.svg b/editor/icons/source/icon_arrow_up.svg index c1839cd69e..b24a167b8e 100644 --- a/editor/icons/source/icon_arrow_up.svg +++ b/editor/icons/source/icon_arrow_up.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_arrow_left.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="6.7465614" - inkscape:cy="9.3227698" + inkscape:cx="7.0981428" + inkscape:cy="9.8315212" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -69,9 +69,9 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 12,1042.3622 -2,-2.5 -2,-2.5 -2,2.5 -2,2.5 3,0 0,9 2,0 0,-9 3,0 z" - id="rect4352" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:0.99607843;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 2.9875012,1044.3838 a 1.0001,1.0001 0 0 0 1.7167968,0.6972 l 2.2929688,-2.2929 v 4.5859 a 1.0001,1.0001 0 1 0 2,0 v -4.5859 l 2.2929692,2.2929 a 1.0001,1.0001 0 1 0 1.414062,-1.414 l -3.9140624,-3.9141 a 1.0001,1.0001 0 0 0 -1.5859376,0 1.0001,1.0001 0 0 0 -0.00391,0.01 l -3.9101562,3.9102 a 1.0001,1.0001 0 0 0 -0.3027344,0.7168 z" + id="path814" inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_asset_lib.svg b/editor/icons/source/icon_asset_lib.svg new file mode 100644 index 0000000000..db9fcda6d4 --- /dev/null +++ b/editor/icons/source/icon_asset_lib.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_asset_lib.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254835" + inkscape:cx="8.3739682" + inkscape:cy="8.9121875" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-midpoints="true" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:1.87082875;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 8 1 A 3 3 0 0 0 5 4 L 5 6 L 1 6 L 1 10 L 1 13 C 1 14.10801 1.8919904 15 3 15 L 13 15 C 14.10801 15 15 14.10801 15 13 L 15 10 L 15 6 L 11 6 L 11 4 A 3 3 0 0 0 8 1 z M 8 2 A 2 2 0 0 0 7.84375 2.0078125 A 2.0000174 2.0000174 0 0 1 8 2 z M 8.15625 2.0078125 A 2.0000174 2.0000174 0 0 1 8.296875 2.0234375 A 2 2 0 0 0 8.15625 2.0078125 z M 7.703125 2.0234375 A 2 2 0 0 0 7.640625 2.0332031 A 2.0000174 2.0000174 0 0 1 7.703125 2.0234375 z M 8.359375 2.0332031 A 2.0000174 2.0000174 0 0 1 8.4648438 2.0566406 A 2 2 0 0 0 8.359375 2.0332031 z M 7.5351562 2.0566406 A 2 2 0 0 0 7.4296875 2.0839844 A 2.0000174 2.0000174 0 0 1 7.5351562 2.0566406 z M 8.5703125 2.0839844 A 2.0000174 2.0000174 0 0 1 8.6621094 2.1152344 A 2 2 0 0 0 8.5703125 2.0839844 z M 7.3378906 2.1152344 A 2 2 0 0 0 7.2558594 2.1464844 A 2.0000174 2.0000174 0 0 1 7.3378906 2.1152344 z M 8.7441406 2.1464844 A 2.0000174 2.0000174 0 0 1 8.8496094 2.1914062 A 2 2 0 0 0 8.7441406 2.1464844 z M 7.1503906 2.1914062 A 2 2 0 0 0 7.0722656 2.2304688 A 2.0000174 2.0000174 0 0 1 7.1503906 2.1914062 z M 8.9277344 2.2304688 A 2.0000174 2.0000174 0 0 1 9.0195312 2.28125 A 2 2 0 0 0 8.9277344 2.2304688 z M 6.9804688 2.28125 A 2 2 0 0 0 6.8886719 2.3378906 A 2.0000174 2.0000174 0 0 1 6.9804688 2.28125 z M 6.8320312 2.3789062 A 2 2 0 0 0 6.7304688 2.4550781 A 2.0000174 2.0000174 0 0 1 6.8320312 2.3789062 z M 9.2695312 2.4550781 A 2.0000174 2.0000174 0 0 1 9.3378906 2.515625 A 2 2 0 0 0 9.2695312 2.4550781 z M 6.6621094 2.515625 A 2 2 0 0 0 6.5859375 2.5859375 A 2.0000174 2.0000174 0 0 1 6.6621094 2.515625 z M 9.4140625 2.5859375 A 2.0000174 2.0000174 0 0 1 9.484375 2.6621094 A 2 2 0 0 0 9.4140625 2.5859375 z M 6.515625 2.6621094 A 2 2 0 0 0 6.4550781 2.7304688 A 2.0000174 2.0000174 0 0 1 6.515625 2.6621094 z M 9.5449219 2.7304688 A 2.0000174 2.0000174 0 0 1 9.6210938 2.8320312 A 2 2 0 0 0 9.5449219 2.7304688 z M 9.6621094 2.8886719 A 2.0000174 2.0000174 0 0 1 9.71875 2.9804688 A 2 2 0 0 0 9.6621094 2.8886719 z M 6.28125 2.9804688 A 2 2 0 0 0 6.2304688 3.0722656 A 2.0000174 2.0000174 0 0 1 6.28125 2.9804688 z M 8 3 A 1 1 0 0 1 9 4 L 9 6 L 7 6 L 7 4 A 1 1 0 0 1 8 3 z M 9.7695312 3.0722656 A 2.0000174 2.0000174 0 0 1 9.8085938 3.1503906 A 2 2 0 0 0 9.7695312 3.0722656 z M 6.1914062 3.1503906 A 2 2 0 0 0 6.1464844 3.2558594 A 2.0000174 2.0000174 0 0 1 6.1914062 3.1503906 z M 9.8535156 3.2558594 A 2.0000174 2.0000174 0 0 1 9.8847656 3.3378906 A 2 2 0 0 0 9.8535156 3.2558594 z M 6.1152344 3.3378906 A 2 2 0 0 0 6.0839844 3.4296875 A 2.0000174 2.0000174 0 0 1 6.1152344 3.3378906 z M 9.9160156 3.4296875 A 2.0000174 2.0000174 0 0 1 9.9433594 3.5351562 A 2 2 0 0 0 9.9160156 3.4296875 z M 6.0566406 3.5351562 A 2 2 0 0 0 6.0332031 3.640625 A 2.0000174 2.0000174 0 0 1 6.0566406 3.5351562 z M 9.9667969 3.640625 A 2.0000174 2.0000174 0 0 1 9.9765625 3.703125 A 2 2 0 0 0 9.9667969 3.640625 z M 6.0234375 3.703125 A 2 2 0 0 0 6.0078125 3.84375 A 2.0000174 2.0000174 0 0 1 6.0234375 3.703125 z M 9.9921875 3.84375 A 2.0000174 2.0000174 0 0 1 10 4 A 2 2 0 0 0 9.9921875 3.84375 z " + transform="translate(0,1036.3622)" + id="rect4503" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_bus_bypass.svg b/editor/icons/source/icon_audio_bus_bypass.svg new file mode 100644 index 0000000000..fe517d9ff7 --- /dev/null +++ b/editor/icons/source/icon_audio_bus_bypass.svg @@ -0,0 +1,295 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node_2d.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_audio_bus_bypass.svg"> + <defs + id="defs4"> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199"> + <path + inkscape:connector-curvature="0" + id="path4201" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5"> + <path + inkscape:connector-curvature="0" + id="path4201-6" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3"> + <path + inkscape:connector-curvature="0" + id="path4201-5" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-3"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-6" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-0"> + <path + inkscape:connector-curvature="0" + id="path4201-62" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-61" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-8" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-7"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-9" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3-0" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5-2"> + <path + inkscape:connector-curvature="0" + id="path4201-6-3" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2-7" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9-5" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5-8" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3-9"> + <path + inkscape:connector-curvature="0" + id="path4201-5-7" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6-3" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2-6" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1-2" + inkscape:connector-curvature="0" /> + </clipPath> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="31.999999" + inkscape:cx="13.750219" + inkscape:cy="8.7492163" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 6.9707031 2 C 6.7159676 2.01 6.4735547 2.1112156 6.2929688 2.2910156 L 3.5859375 4.9980469 L 2 4.9980469 C 1.4477381 4.9981469 1.0000552 5.4457469 1 5.9980469 L 1 9.9980469 C 1.0000552 10.550347 1.4477381 10.997947 2 10.998047 L 3.5859375 10.998047 L 6.2929688 13.705078 C 6.9229867 14.334678 7.9997118 13.888747 8 12.998047 L 8 2.9980469 C 7.9990576 2.4349469 7.5335846 1.9836 6.9707031 2 z M 10.984375 4.9863281 A 1.0001 1.0001 0 0 0 10 6 L 10 10 A 1.0001 1.0001 0 1 0 12 10 L 12 6 A 1.0001 1.0001 0 0 0 10.984375 4.9863281 z M 13.984375 4.9863281 A 1.0001 1.0001 0 0 0 13 6 L 13 10 A 1.0001 1.0001 0 1 0 15 10 L 15 6 A 1.0001 1.0001 0 0 0 13.984375 4.9863281 z " + transform="translate(0,1036.3622)" + id="path4158" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_bus_layout.svg b/editor/icons/source/icon_audio_bus_layout.svg new file mode 100644 index 0000000000..66dc37ecfc --- /dev/null +++ b/editor/icons/source/icon_audio_bus_layout.svg @@ -0,0 +1,107 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_audio_bus_layout.svg"> + <defs + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient959-5"> + <stop + id="stop957-3" + offset="0" + style="stop-color:#ff8484;stop-opacity:1" /> + <stop + style="stop-color:#e1dc7a;stop-opacity:1" + offset="0.5" + id="stop955-5" /> + <stop + id="stop953-6" + offset="1" + style="stop-color:#84ffb1;stop-opacity:1" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959-5" + id="linearGradient4542" + gradientUnits="userSpaceOnUse" + x1="8" + y1="1" + x2="8" + y2="15" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32.000001" + inkscape:cx="4.4869184" + inkscape:cy="8.3575292" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-midpoints="true" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="fill:url(#linearGradient4542);fill-opacity:1.0;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="M 3 1 C 1.8919904 1 1 1.8919904 1 3 L 1 13 C 1 14.10801 1.8919904 15 3 15 L 5 15 C 6.1080096 15 7 14.10801 7 13 L 7 3 C 7 1.8919904 6.1080096 1 5 1 L 3 1 z M 11 1 C 9.8919889 1 9 1.8919889 9 3 L 9 13 C 9 14.108011 9.8919889 15 11 15 L 13 15 C 14.108011 15 15 14.108011 15 13 L 15 3 C 15 1.8919889 14.108011 1 13 1 L 11 1 z M 3 2 L 5 2 C 5.5540096 2 6 2.4459904 6 3 L 6 13 C 6 13.55401 5.5540096 14 5 14 L 3 14 C 2.4459904 14 2 13.55401 2 13 L 2 3 C 2 2.4459904 2.4459904 2 3 2 z " + transform="translate(0,1036.3622)" + id="rect4505" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_bus_mute.svg b/editor/icons/source/icon_audio_bus_mute.svg new file mode 100644 index 0000000000..55a776dd97 --- /dev/null +++ b/editor/icons/source/icon_audio_bus_mute.svg @@ -0,0 +1,301 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node_2d.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_audio_bus_mute.svg"> + <defs + id="defs4"> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199"> + <path + inkscape:connector-curvature="0" + id="path4201" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5"> + <path + inkscape:connector-curvature="0" + id="path4201-6" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3"> + <path + inkscape:connector-curvature="0" + id="path4201-5" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-3"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-6" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-0"> + <path + inkscape:connector-curvature="0" + id="path4201-62" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-61" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-8" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-7"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-9" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3-0" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5-2"> + <path + inkscape:connector-curvature="0" + id="path4201-6-3" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2-7" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9-5" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5-8" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3-9"> + <path + inkscape:connector-curvature="0" + id="path4201-5-7" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6-3" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2-6" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1-2" + inkscape:connector-curvature="0" /> + </clipPath> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="31.999999" + inkscape:cx="11.636432" + inkscape:cy="7.916113" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 6.9707031,1038.3625 c -0.2547355,0.01 -0.4971483,0.1112 -0.6777343,0.291 l -2.7070313,2.707 H 2 c -0.5522619,10e-5 -0.9999448,0.4477 -1,1 v 4 c 5.52e-5,0.5523 0.4477381,0.9999 1,1 h 1.5859375 l 2.7070313,2.7071 c 0.630018,0.6296 1.706743,0.1836 1.7070312,-0.7071 v -10 c -9.424e-4,-0.5631 -0.4664154,-1.0144 -1.0292969,-0.998 z" + id="path4158" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccccccccccc" /> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 10.990234 4.9902344 A 1.0001 1.0001 0 0 0 10.292969 6.7070312 L 11.585938 8 L 10.292969 9.2929688 A 1.0001 1.0001 0 1 0 11.707031 10.707031 L 13 9.4140625 L 14.292969 10.707031 A 1.0001 1.0001 0 1 0 15.707031 9.2929688 L 14.414062 8 L 15.707031 6.7070312 A 1.0001 1.0001 0 0 0 14.980469 4.9921875 A 1.0001 1.0001 0 0 0 14.292969 5.2929688 L 13 6.5859375 L 11.707031 5.2929688 A 1.0001 1.0001 0 0 0 10.990234 4.9902344 z " + transform="translate(0,1036.3622)" + id="path1075" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_bus_solo.svg b/editor/icons/source/icon_audio_bus_solo.svg new file mode 100644 index 0000000000..fd06442da1 --- /dev/null +++ b/editor/icons/source/icon_audio_bus_solo.svg @@ -0,0 +1,315 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node_2d.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_audio_bus_solo.svg"> + <defs + id="defs4"> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199"> + <path + inkscape:connector-curvature="0" + id="path4201" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5"> + <path + inkscape:connector-curvature="0" + id="path4201-6" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3"> + <path + inkscape:connector-curvature="0" + id="path4201-5" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-3"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-6" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-0"> + <path + inkscape:connector-curvature="0" + id="path4201-62" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-61" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-8" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-7"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-9" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-75-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-3-0" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-5-2"> + <path + inkscape:connector-curvature="0" + id="path4201-6-3" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-2-7" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-9-5" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-1-9"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-2-2" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253-7-2"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255-5-8" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199-3-9"> + <path + inkscape:connector-curvature="0" + id="path4201-5-7" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4392-6-3" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4394-2-6" + d="m 8.072266,1041.3622 a 5,5 0 0 0 -3.607422,1.4648 5,5 0 0 0 0,7.0704 5,5 0 0 0 7.070312,0 l -1.416015,-1.4161 A 3,3 0 0 1 8,1049.3622 a 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 3,3 0 0 1 2.119141,0.8809 l 1.416015,-1.4161 a 5,5 0 0 0 -3.46289,-1.4648 z" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4196-9-1"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 8.0624999,1025.8622 a 3.375,2.9999997 0 0 0 -3.375,3 3.375,2.9999997 0 0 0 1.6875,2.5957 l 0,9.8115 a 3.375,2.9999997 0 0 0 -1.6875,2.5928 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.3750001,-3 3.375,2.9999997 0 0 0 -1.6875001,-2.5957 l 0,-8.7832 11.9311511,10.6054 a 3.375,2.9999997 0 0 0 -0.118651,0.7735 3.375,2.9999997 0 0 0 3.375,3 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -0.873413,0.1025 l -11.927857,-10.6025 9.884399,0 a 3.375,2.9999997 0 0 0 2.916871,1.5 3.375,2.9999997 0 0 0 3.375,-3 3.375,2.9999997 0 0 0 -3.375,-3 3.375,2.9999997 0 0 0 -2.920166,1.5 l -11.037964,0 a 3.375,2.9999997 0 0 0 -2.9168701,-1.5 z" + id="path4198-1-2" + inkscape:connector-curvature="0" /> + </clipPath> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627416" + inkscape:cx="9.3895072" + inkscape:cy="10.039347" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 6.9707031,1038.3625 c -0.2547355,0.01 -0.4971483,0.1112 -0.6777343,0.291 l -2.7070313,2.707 H 2 c -0.5522619,10e-5 -0.9999448,0.4477 -1,1 v 4 c 5.52e-5,0.5523 0.4477381,0.9999 1,1 h 1.5859375 l 2.7070313,2.7071 c 0.630018,0.6296 1.706743,0.1836 1.7070312,-0.7071 v -10 c -9.424e-4,-0.5631 -0.4664154,-1.0144 -1.0292969,-0.998 z" + id="path4158" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccccccccccc" /> + <path + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 15,1040.3622 a 3,3 0 0 0 -3,3 v 2 a 1.0000174,1.0000174 0 0 1 -1,1 v 2 a 3,3 0 0 0 3,-3 v -2 a 1.0000174,1.0000174 0 0 1 1,-1 z" + id="path4534" + inkscape:connector-curvature="0" /> + <rect + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4208" + width="1" + height="2" + x="10" + y="1046.3622" /> + <rect + y="1040.3622" + x="15" + height="2" + width="1" + id="rect4210" + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_effect_amplify.svg b/editor/icons/source/icon_audio_effect_amplify.svg new file mode 100644 index 0000000000..3c75d71791 --- /dev/null +++ b/editor/icons/source/icon_audio_effect_amplify.svg @@ -0,0 +1,110 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_audio_effect_amplify.svg"> + <defs + id="defs4"> + <linearGradient + id="linearGradient959-5" + inkscape:collect="always"> + <stop + style="stop-color:#ff8484;stop-opacity:1" + offset="0" + id="stop957-3" /> + <stop + id="stop955-5" + offset="0.5" + style="stop-color:#e1dc7a;stop-opacity:1" /> + <stop + style="stop-color:#84ffb1;stop-opacity:1" + offset="1" + id="stop953-6" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959-5" + id="linearGradient4521" + x1="9" + y1="1037.3622" + x2="9" + y2="1051.3622" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0,-1036.3622)" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627418" + inkscape:cx="11.634663" + inkscape:cy="5.7749201" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-midpoints="true" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="fill:url(#linearGradient4521);fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" + d="M 15,1 1,8 H 15 Z M 2,10 v 1 h 2 v -1 z m 2,1 v 1 H 2 V 11 H 1 v 4 h 1 v -2 h 2 v 2 h 1 v -4 z m 2,-1 v 1 4 h 1 v -4 h 1 v 4 h 1 v -4 h 1 v -1 z m 4,1 v 4 h 1 v -4 z m 2,-1 v 5 h 1 v -2 h 2 v -3 z m 1,1 h 1 v 1 h -1 z" + transform="translate(0,1036.3622)" + id="path4513" + inkscape:connector-curvature="0" + sodipodi:nodetypes="ccccccccccccccccccccccccccccccccccccccccccccccccccc" /> + </g> +</svg> diff --git a/editor/icons/source/icon_audio_player.svg b/editor/icons/source/icon_audio_player.svg new file mode 100644 index 0000000000..2d9c5f4e6c --- /dev/null +++ b/editor/icons/source/icon_audio_player.svg @@ -0,0 +1,113 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_audio_player.svg"> + <defs + id="defs4"> + <linearGradient + id="linearGradient959-5" + inkscape:collect="always"> + <stop + style="stop-color:#ff8484;stop-opacity:1" + offset="0" + id="stop957-3" /> + <stop + id="stop955-5" + offset="0.5" + style="stop-color:#e1dc7a;stop-opacity:1" /> + <stop + style="stop-color:#84ffb1;stop-opacity:1" + offset="1" + id="stop953-6" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959-5" + id="linearGradient4552" + x1="8" + y1="1" + x2="8" + y2="15" + gradientUnits="userSpaceOnUse" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="11.313709" + inkscape:cx="14.998333" + inkscape:cy="3.5679216" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-midpoints="true" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1.97227669;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 10.023235,1044.3625 c -0.5613918,-0.013 -1.0235345,0.4264 -1.0234377,0.9724 v 5.0542 c 6.911e-4,0.7482 0.8336124,1.2154 1.4999997,0.8414 l 4,-2.5262 c 0.666937,-0.3743 0.666937,-1.3104 0,-1.6847 l -4,-2.5261 c -0.145049,-0.082 -0.308928,-0.1269 -0.476562,-0.131 z" + id="path4507" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccccccc" /> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:url(#linearGradient4552);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 11.970703 1.0019531 A 1.0001 1.0001 0 0 0 11.724609 1.0390625 L 4.7246094 3.0390625 A 1.0001 1.0001 0 0 0 4 4 L 4 9.5507812 A 2.5 2.4999914 0 0 0 3.5 9.5 A 2.5 2.4999914 0 0 0 1 12 A 2.5 2.4999914 0 0 0 3.5 14.5 A 2.5 2.4999914 0 0 0 5.9960938 12.087891 A 1.0001 1.0001 0 0 0 6 12 L 6 4.7558594 L 11 3.328125 L 11 6.5 L 13 5.5 L 13 2 A 1.0001 1.0001 0 0 0 11.970703 1.0019531 z " + transform="translate(0,1036.3622)" + id="path4514" /> + </g> +</svg> diff --git a/editor/icons/source/icon_back.svg b/editor/icons/source/icon_back.svg index 597a1c3068..dfaf25de01 100644 --- a/editor/icons/source/icon_back.svg +++ b/editor/icons/source/icon_back.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_bone.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="4.4850647" - inkscape:cy="8.9717887" + inkscape:cx="8.1867174" + inkscape:cy="8.4650528" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -60,7 +60,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -70,10 +70,9 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#e0e0e0;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 5.9707031,1037.3633 c -0.3235485,0.01 -0.622658,0.1743 -0.8027343,0.4433 l -4,6 c -0.22390586,0.3359 -0.22390586,0.7735 0,1.1094 l 4,6 C 5.716941,1051.7388 6.999645,1051.3504 7,1050.3613 l 0,-12 c -9.424e-4,-0.5631 -0.4664154,-1.0144 -1.0292969,-0.998 z" - id="path4159" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cccccccc" /> + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none" + d="m 6,1038.3622 -4,6 4,6" + id="path814" + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_baked_light.svg b/editor/icons/source/icon_baked_light.svg index 98dc3135f6..e4d435254d 100644 --- a/editor/icons/source/icon_baked_light.svg +++ b/editor/icons/source/icon_baked_light.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_bone.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,7 +29,7 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="22.627417" - inkscape:cx="6.1801151" + inkscape:cx="-2.7913022" inkscape:cy="10.551189" inkscape:document-units="px" inkscape:current-layer="layer1" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -70,7 +70,7 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + style="opacity:1;fill:#fc9c9c;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" d="M 2 1 L 2 3 L 14 3 L 14 1 L 2 1 z M 1 4 L 1 13 A 2 2.0000174 0 0 0 3 15 L 13 15 A 2 2.0000174 0 0 0 15 13 L 15 4 L 1 4 z M 3 5 L 4 5 L 4 6 L 3 6 L 3 5 z M 6 5 L 7 5 L 7 6 L 6 6 L 6 5 z M 9 5 L 10 5 L 10 6 L 9 6 L 9 5 z M 12 5 L 13 5 L 13 6 L 12 6 L 12 5 z M 3 7 L 13 7 L 13 13 L 3 13 L 3 7 z M 6 8 L 6 9 L 10 9 L 10 8 L 6 8 z " transform="translate(0,1036.3622)" id="rect4155" /> diff --git a/editor/icons/source/icon_bool.svg b/editor/icons/source/icon_bool.svg index e471871adf..9f429376fd 100644 --- a/editor/icons/source/icon_bool.svg +++ b/editor/icons/source/icon_bool.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_bool.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="16" - inkscape:cx="-0.0405559" - inkscape:cy="11.453214" + inkscape:zoom="32" + inkscape:cx="3.5294581" + inkscape:cy="7.990409" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -68,10 +68,68 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1036.3622)"> - <path - style="opacity:1;fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 3 1 L 3 3 L 4 3 L 4 13 L 3 13 L 3 15 L 11 15 L 11 13 L 6 13 L 6 3 L 9 3 L 9 1 L 3 1 z M 9 3 L 9 8 L 11 8 L 11 3 L 9 3 z M 11 8 L 11 13 L 13 13 L 13 8 L 11 8 z " - transform="translate(0,1036.3622)" - id="rect4140" /> + <g + transform="translate(0,-2.0001)" + id="layer1-5" + inkscape:label="Layer 1" + style="fill:#cf68ea;fill-opacity:1"> + <rect + transform="scale(-1,1)" + y="1044.3622" + x="-2" + height="5.9999666" + width="2" + id="rect4364" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + transform="scale(-1,1)" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4368" + width="1" + height="2.0000174" + x="-2" + y="1044.3622" /> + <path + inkscape:connector-curvature="0" + id="path4370" + d="m 2,1044.3623 a 3,3 0 0 1 3,3 H 3 a 1.0000174,1.0000174 0 0 0 -1,-1 z" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4374" + width="2" + height="5" + x="13" + y="-1047.3622" + transform="scale(1,-1)" /> + <path + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 2,1050.3623 a 3,3 0 0 0 3,-3 H 3 a 1.0000174,1.0000174 0 0 1 -1,1 z" + id="path4378" + inkscape:connector-curvature="0" /> + <rect + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4384" + width="2" + height="3.9999492" + x="-2" + y="1042.3622" + transform="scale(-1,1)" /> + <path + inkscape:connector-curvature="0" + id="path4392" + d="m 16,1050.3623 a 3,3 0 0 1 -3,-3 h 2 a 1.0000174,1.0000174 0 0 0 1,1 z" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + inkscape:connector-curvature="0" + id="path4148" + d="m 7,1044.3622 a 3,3 0 0 0 -3,3 3,3 0 0 0 3,3 3,3 0 0 0 3,-3 3,3 0 0 0 -3,-3 z m 0,2 a 1.0000174,1.0000174 0 0 1 1,1 1.0000174,1.0000174 0 0 1 -1,1 1.0000174,1.0000174 0 0 1 -1,-1 1.0000174,1.0000174 0 0 1 1,-1 z" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + inkscape:connector-curvature="0" + id="path4174" + d="m 11,1044.3622 a 3,3 0 0 0 -3,3 3,3 0 0 0 3,3 3,3 0 0 0 3,-3 3,3 0 0 0 -3,-3 z m 0,2 a 1.0000174,1.0000174 0 0 1 1,1 1.0000174,1.0000174 0 0 1 -1,1 1.0000174,1.0000174 0 0 1 -1,-1 1.0000174,1.0000174 0 0 1 1,-1 z" + style="fill:#cf68ea;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </g> </g> </svg> diff --git a/editor/icons/source/icon_bus_vu_db.svg b/editor/icons/source/icon_bus_vu_db.svg new file mode 100644 index 0000000000..813990bb42 --- /dev/null +++ b/editor/icons/source/icon_bus_vu_db.svg @@ -0,0 +1,111 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="32" + height="128" + viewBox="0 0 32 128" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_vu_empty.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_bus_vu_db.svg"> + <defs + id="defs4"> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959-5" + id="linearGradient4736" + x1="16" + y1="0" + x2="16" + y2="128" + gradientUnits="userSpaceOnUse" /> + <linearGradient + inkscape:collect="always" + id="linearGradient959-5"> + <stop + id="stop957-3" + offset="0" + style="stop-color:#ff8484;stop-opacity:1" /> + <stop + style="stop-color:#e1dc7a;stop-opacity:1" + offset="0.5" + id="stop955-5" /> + <stop + id="stop953-6" + offset="1" + style="stop-color:#84ffb1;stop-opacity:1" /> + </linearGradient> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="4" + inkscape:cx="21.367149" + inkscape:cy="54.069367" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:object-nodes="true" + inkscape:snap-smooth-nodes="true" + inkscape:snap-midpoints="false" + showguides="false"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-924.3622)"> + <path + style="fill:url(#linearGradient4736);fill-opacity:1;stroke:none;stroke-width:2.68328929;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.49019608" + d="M 1.5 0 C 0.66899518 0 0 0.66899518 0 1.5 C 0 2.3310048 0.66899518 3 1.5 3 L 3.5 3 C 4.3310048 3 5 2.3310048 5 1.5 C 5 0.66899518 4.3310048 0 3.5 0 L 1.5 0 z M 1.5 7 C 0.669 7 0 7.669 0 8.5 C 0 9.331 0.669 10 1.5 10 C 2.331 10 3 9.331 3 8.5 C 3 7.669 2.331 7 1.5 7 z M 24 10.75 C 22.5 10.75 21 12.05555 21 14 A 1.0001 1.0001 0 1 0 23 14 C 23 12.94444 23.5 12.75 24 12.75 C 24.5 12.75 25 12.94444 25 14 C 25 14.59157 24.641069 15.156041 23.808594 15.863281 C 22.976118 16.570521 21.747003 17.315092 20.451172 18.164062 A 1.0001 1.0001 0 0 0 21 20 L 26 20 A 1.0001 1.0001 0 1 0 26 18 L 24.214844 18 C 24.498598 17.79333 24.845909 17.605569 25.103516 17.386719 C 26.133676 16.511529 27 15.40842 27 14 C 27 12.05555 25.5 10.75 24 10.75 z M 16.970703 11.001953 A 1.0001 1.0001 0 0 0 16.552734 11.105469 L 14.552734 12.105469 A 1.0001163 1.0001163 0 0 0 15.447266 13.894531 L 16 13.619141 L 16 19 A 1.0001 1.0001 0 1 0 18 19 L 18 12 A 1.0001 1.0001 0 0 0 16.970703 11.001953 z M 1.5 14 C 0.66899518 14 0 14.668995 0 15.5 C 0 16.331005 0.66899518 17 1.5 17 L 3.5 17 C 4.3310048 17 5 16.331005 5 15.5 C 5 14.668995 4.3310048 14 3.5 14 L 1.5 14 z M 1.5 21 C 0.669 21 0 21.669 0 22.5 C 0 23.331 0.669 24 1.5 24 C 2.331 24 3 23.331 3 22.5 C 3 21.669 2.331 21 1.5 21 z M 23 24 C 22.446 24 22 24.446 22 25 L 22 26 L 22 28 L 21.070312 28 A 1.0001 1.0001 0 0 0 21 28 C 19.929806 28 18.937441 28.57318 18.402344 29.5 C 17.867247 30.42681 17.867247 31.57318 18.402344 32.5 C 18.937441 33.42681 19.929806 34 21 34 L 23 34 C 23.554 34 24 33.554 24 33 L 24 25 C 24 24.446 23.554 24 23 24 z M 27 24 C 26.446 24 26 24.446 26 25 L 26 33 C 26 33.554 26.446 34 27 34 L 29 34 C 30.070194 34 31.062559 33.42681 31.597656 32.5 C 32.132753 31.57318 32.132753 30.42681 31.597656 29.5 C 31.492619 29.31807 31.365922 29.153017 31.228516 29 C 31.366318 28.846693 31.49237 28.682361 31.597656 28.5 C 32.132753 27.57318 32.132753 26.42681 31.597656 25.5 C 31.062559 24.57318 30.070194 24 29 24 L 27 24 z M 13 25 C 11.355297 25 10 26.3553 10 28 L 10 31 C 10 32.6447 11.355297 34 13 34 C 14.644703 34 16 32.6447 16 31 L 16 28 C 16 26.3553 14.644703 25 13 25 z M 28 26 L 29 26 C 29.358869 26 29.6858 26.18921 29.865234 26.5 C 30.044669 26.81079 30.044669 27.18921 29.865234 27.5 C 29.6858 27.81079 29.358869 28 29 28 L 28.929688 28 L 28 28 L 28 26 z M 13 27 C 13.571297 27 14 27.4287 14 28 L 14 31 C 14 31.5713 13.571297 32 13 32 C 12.428703 32 12 31.5713 12 31 L 12 28 C 12 27.4287 12.428703 27 13 27 z M 1.5 28 C 0.66899518 28 0 28.668995 0 29.5 C 0 30.331005 0.66899518 31 1.5 31 L 3.5 31 C 4.3310048 31 5 30.331005 5 29.5 C 5 28.668995 4.3310048 28 3.5 28 L 1.5 28 z M 21 30 L 22 30 L 22 32 L 21.070312 32 A 1.0001 1.0001 0 0 0 21 32 C 20.641131 32 20.3142 31.81079 20.134766 31.5 C 19.955331 31.18921 19.955331 30.81079 20.134766 30.5 C 20.3142 30.18921 20.641131 30 21 30 z M 28 30 L 29 30 C 29.358869 30 29.6858 30.18921 29.865234 30.5 C 30.044669 30.81079 30.044669 31.18921 29.865234 31.5 C 29.6858 31.81079 29.358869 32 29 32 L 28 32 L 28 30 z M 1.5 35 C 0.669 35 0 35.669 0 36.5 C 0 37.331 0.669 38 1.5 38 C 2.331 38 3 37.331 3 36.5 C 3 35.669 2.331 35 1.5 35 z M 24 37.75 C 22.5 37.75 21 39.05555 21 41 A 1.0001 1.0001 0 1 0 23 41 C 23 39.94444 23.5 39.75 24 39.75 C 24.5 39.75 25 39.94444 25 41 C 25 41.59157 24.641069 42.156041 23.808594 42.863281 C 22.976118 43.570521 21.747003 44.315092 20.451172 45.164062 A 1.0001 1.0001 0 0 0 21 47 L 26 47 A 1.0001 1.0001 0 1 0 26 45 L 24.214844 45 C 24.498598 44.79333 24.845909 44.605569 25.103516 44.386719 C 26.133676 43.511529 27 42.40842 27 41 C 27 39.05555 25.5 37.75 24 37.75 z M 16.970703 38.001953 A 1.0001 1.0001 0 0 0 16.552734 38.105469 L 14.552734 39.105469 A 1.0001163 1.0001163 0 0 0 15.447266 40.894531 L 16 40.619141 L 16 46 A 1.0001 1.0001 0 1 0 18 46 L 18 39 A 1.0001 1.0001 0 0 0 16.970703 38.001953 z M 1.5 42 C 0.66899518 42 0 42.668995 0 43.5 C 0 44.331005 0.66899518 45 1.5 45 L 3.5 45 C 4.3310048 45 5 44.331005 5 43.5 C 5 42.668995 4.3310048 42 3.5 42 L 1.5 42 z M 9 43 L 9 45 L 12 45 L 12 43 L 9 43 z M 2 49 C 1.169 49 0.5 49.669 0.5 50.5 C 0.5 51.331 1.169 52 2 52 C 2.831 52 3.5 51.331 3.5 50.5 C 3.5 49.669 2.831 49 2 49 z M 17.986328 52.75 C 16.486328 52.75 14.986328 54.05555 14.986328 56 A 1.0001 1.0001 0 1 0 16.986328 56 C 16.986328 54.94444 17.486328 54.75 17.986328 54.75 C 18.486328 54.75 18.986328 54.94444 18.986328 56 C 18.986328 56.59157 18.627397 57.156041 17.794922 57.863281 C 16.962447 58.570521 15.733331 59.315092 14.4375 60.164062 A 1.0001 1.0001 0 0 0 14.986328 62 L 19.986328 62 A 1.0001 1.0001 0 1 0 19.986328 60 L 18.199219 60 C 18.483315 59.79311 18.83195 59.605809 19.089844 59.386719 C 20.120004 58.511529 20.986328 57.40842 20.986328 56 C 20.986328 54.05555 19.486328 52.75 17.986328 52.75 z M 25.033203 52.988281 A 1.0001 1.0001 0 0 0 24.142578 53.486328 L 21.142578 58.486328 A 1.0001 1.0001 0 0 0 22 60 L 25 60 L 25 61 A 1.0001 1.0001 0 1 0 27 61 L 27 59 A 1.0001 1.0001 0 0 0 26 58 L 23.767578 58 L 25.857422 54.515625 A 1.0001 1.0001 0 0 0 25.033203 52.988281 z M 1.5 56 C 0.66899518 56 0 56.668995 0 57.5 C 0 58.331005 0.66899518 59 1.5 59 L 3.5 59 C 4.3310048 59 5 58.331005 5 57.5 C 5 56.668995 4.3310048 56 3.5 56 L 1.5 56 z M 9 58 L 9 60 L 12 60 L 12 58 L 9 58 z M 1.5 63 C 0.669 63 0 63.669 0 64.5 C 0 65.331 0.669 66 1.5 66 C 2.331 66 3 65.331 3 64.5 C 3 63.669 2.331 63 1.5 63 z M 26.046875 67.996094 A 1.0001 1.0001 0 0 0 25.683594 68.052734 C 25.683594 68.052734 24.700104 68.385829 23.792969 69.292969 C 22.885834 70.200139 22 71.75 22 74 A 1.0001 1.0001 0 0 0 22.021484 74.214844 C 22.135372 75.759296 23.42866 77 25 77 C 26.64501 77 28 75.64497 28 74 C 28 72.35499 26.64501 71 25 71 C 24.984666 71 24.970361 71.003672 24.955078 71.003906 C 25.03908 70.902917 25.122032 70.79203 25.207031 70.707031 C 25.799896 70.114161 26.316406 69.949219 26.316406 69.949219 A 1.0001 1.0001 0 0 0 26.046875 67.996094 z M 16.986328 68.001953 C 15.94567 68.009427 14.945809 68.560643 14.402344 69.501953 A 1.0001607 1.0001607 0 0 0 16.134766 70.501953 C 16.380733 70.075953 16.87953 69.892287 17.341797 70.060547 C 17.804064 70.228797 18.069795 70.689368 17.984375 71.173828 C 17.898952 71.658288 17.491934 72.001953 17 72.001953 A 1.0001 1.0001 0 0 0 16.916016 72.003906 A 1.0001 1.0001 0 0 0 16.751953 72.029297 A 1.0001 1.0001 0 0 0 16.722656 72.037109 A 1.0001 1.0001 0 0 0 16.634766 72.064453 A 1.0001 1.0001 0 0 0 16.574219 72.091797 A 1.0001 1.0001 0 0 0 16.527344 72.113281 A 1.0001 1.0001 0 0 0 16.486328 72.136719 A 1.0001 1.0001 0 0 0 16.453125 72.15625 A 1.0001 1.0001 0 0 0 16.3125 72.263672 A 1.0001 1.0001 0 0 0 16.287109 72.287109 A 1.0001 1.0001 0 0 0 16.269531 72.306641 A 1.0001 1.0001 0 0 0 16.21875 72.359375 A 1.0001 1.0001 0 0 0 16.1875 72.400391 A 1.0001 1.0001 0 0 0 16.162109 72.435547 A 1.0001 1.0001 0 0 0 16.142578 72.466797 A 1.0001 1.0001 0 0 0 16.064453 72.611328 A 1.0001 1.0001 0 0 0 16.041016 72.677734 A 1.0001 1.0001 0 0 0 16.033203 72.695312 A 1.0001 1.0001 0 0 0 15.996094 72.861328 A 1.0001 1.0001 0 0 0 15.990234 72.912109 A 1.0001 1.0001 0 0 0 15.990234 72.927734 A 1.0001 1.0001 0 0 0 15.986328 73 A 1.0001 1.0001 0 0 0 15.990234 73.074219 A 1.0001 1.0001 0 0 0 15.990234 73.089844 A 1.0001 1.0001 0 0 0 15.996094 73.140625 A 1.0001 1.0001 0 0 0 16.033203 73.304688 A 1.0001 1.0001 0 0 0 16.041016 73.324219 A 1.0001 1.0001 0 0 0 16.064453 73.390625 A 1.0001 1.0001 0 0 0 16.070312 73.404297 A 1.0001 1.0001 0 0 0 16.101562 73.466797 A 1.0001 1.0001 0 0 0 16.142578 73.535156 A 1.0001 1.0001 0 0 0 16.162109 73.566406 A 1.0001 1.0001 0 0 0 16.1875 73.601562 A 1.0001 1.0001 0 0 0 16.21875 73.642578 A 1.0001 1.0001 0 0 0 16.269531 73.695312 A 1.0001 1.0001 0 0 0 16.287109 73.714844 A 1.0001 1.0001 0 0 0 16.3125 73.738281 A 1.0001 1.0001 0 0 0 16.4375 73.835938 A 1.0001 1.0001 0 0 0 16.515625 73.882812 A 1.0001 1.0001 0 0 0 16.521484 73.886719 A 1.0001 1.0001 0 0 0 16.59375 73.919922 A 1.0001 1.0001 0 0 0 16.615234 73.929688 A 1.0001 1.0001 0 0 0 16.679688 73.953125 A 1.0001 1.0001 0 0 0 16.720703 73.964844 A 1.0001 1.0001 0 0 0 16.751953 73.972656 A 1.0001 1.0001 0 0 0 16.919922 73.998047 A 1.0001 1.0001 0 0 0 17 74.001953 C 17.491934 74.001953 17.898952 74.343665 17.984375 74.828125 C 18.069795 75.312585 17.804064 75.773206 17.341797 75.941406 C 16.87953 76.109706 16.380733 75.92637 16.134766 75.5 A 1.0001607 1.0001607 0 0 0 14.402344 76.5 C 15.126964 77.7551 16.66355 78.316013 18.025391 77.820312 C 19.387231 77.324714 20.206736 75.907669 19.955078 74.480469 C 19.854803 73.911777 19.590188 73.406592 19.222656 73 C 19.589698 72.593206 19.854887 72.089699 19.955078 71.521484 C 20.206736 70.094264 19.387231 68.677311 18.025391 68.181641 C 17.68493 68.057723 17.333214 67.999462 16.986328 68.001953 z M 1.5 70 C 0.66899518 70 0 70.668995 0 71.5 C 0 72.331005 0.66899518 73 1.5 73 L 3.5 73 C 4.3310048 73 5 72.331005 5 71.5 C 5 70.668995 4.3310048 70 3.5 70 L 1.5 70 z M 9 72 L 9 74 L 12 74 L 12 72 L 9 72 z M 25 73 C 25.564129 73 26 73.43587 26 74 C 26 74.56413 25.564129 75 25 75 C 24.435871 75 24 74.56413 24 74 C 24 73.43587 24.435871 73 25 73 z M 1.5 77 C 0.669 77 0 77.669 0 78.5 C 0 79.331 0.669 80 1.5 80 C 2.331 80 3 79.331 3 78.5 C 3 77.669 2.331 77 1.5 77 z M 18.033203 80.988281 A 1.0001 1.0001 0 0 0 17.142578 81.486328 L 14.142578 86.486328 A 1.0001 1.0001 0 0 0 15 88 L 18 88 L 18 89 A 1.0001 1.0001 0 1 0 20 89 L 20 87 A 1.0001 1.0001 0 0 0 19 86 L 16.767578 86 L 18.857422 82.515625 A 1.0001 1.0001 0 0 0 18.033203 80.988281 z M 25 81 C 23.35499 81 22 82.355 22 84 C 22 84.768995 22.303687 85.466552 22.787109 86 C 22.304287 86.533316 22 87.231542 22 88 C 22 89.645 23.35499 91 25 91 C 26.64501 91 28 89.645 28 88 C 28 87.231542 27.695713 86.533316 27.212891 86 C 27.696313 85.466552 28 84.768995 28 84 C 28 82.355 26.64501 81 25 81 z M 25 83 C 25.564129 83 26 83.4359 26 84 C 26 84.5642 25.564129 85 25 85 C 24.435871 85 24 84.5642 24 84 C 24 83.4359 24.435871 83 25 83 z M 1.5 84 C 0.66899518 84 0 84.668995 0 85.5 C 0 86.331005 0.66899518 87 1.5 87 L 3.5 87 C 4.3310048 87 5 86.331005 5 85.5 C 5 84.668995 4.3310048 84 3.5 84 L 1.5 84 z M 9 86 L 9 88 L 12 88 L 12 86 L 9 86 z M 25 87 C 25.564129 87 26 87.4359 26 88 C 26 88.5642 25.564129 89 25 89 C 24.435871 89 24 88.5642 24 88 C 24 87.4359 24.435871 87 25 87 z M 1.5 91 C 0.669 91 0 91.669 0 92.5 C 0 93.331 0.669 94 1.5 94 C 2.331 94 3 93.331 3 92.5 C 3 91.669 2.331 91 1.5 91 z M 17.947266 94.982422 A 1.0001 1.0001 0 0 0 17.683594 95.037109 C 17.683594 95.037109 16.700104 95.372197 15.792969 96.279297 C 14.885834 97.186097 14 98.736326 14 100.98633 A 1.0001 1.0001 0 0 0 14.021484 101.20117 C 14.135372 102.74565 15.42866 103.98633 17 103.98633 C 18.64501 103.98633 20 102.63133 20 100.98633 C 20 99.341226 18.64501 97.986328 17 97.986328 C 16.984666 97.986328 16.970361 97.99 16.955078 97.990234 C 17.03908 97.889241 17.122032 97.778363 17.207031 97.693359 C 17.799896 97.100459 18.316406 96.935547 18.316406 96.935547 A 1.0001 1.0001 0 0 0 18.046875 94.982422 A 1.0001 1.0001 0 0 0 17.947266 94.982422 z M 25 95 C 23.355297 95 22 96.3553 22 98 L 22 101 C 22 102.6447 23.355297 104 25 104 C 26.644703 104 28 102.6447 28 101 L 28 98 C 28 96.3553 26.644703 95 25 95 z M 25 97 C 25.571297 97 26 97.4287 26 98 L 26 101 C 26 101.5713 25.571297 102 25 102 C 24.428703 102 24 101.5713 24 101 L 24 98 C 24 97.4287 24.428703 97 25 97 z M 1.5 98 C 0.66899518 98 0 98.668995 0 99.5 C 0 100.331 0.66899518 101 1.5 101 L 3.5 101 C 4.3310048 101 5 100.331 5 99.5 C 5 98.668995 4.3310048 98 3.5 98 L 1.5 98 z M 17 99.986328 C 17.564129 99.986328 18 100.42213 18 100.98633 C 18 101.55043 17.564129 101.98633 17 101.98633 C 16.435871 101.98633 16 101.55043 16 100.98633 C 16 100.42213 16.435871 99.986328 17 99.986328 z M 9 100 L 9 102 L 12 102 L 12 100 L 9 100 z M 1.5 105 C 0.669 105 0 105.669 0 106.5 C 0 107.331 0.669 108 1.5 108 C 2.331 108 3 107.331 3 106.5 C 3 105.669 2.331 105 1.5 105 z M 24 108.75 C 22.5 108.75 21 110.0556 21 112 A 1.0001 1.0001 0 1 0 23 112 C 23 110.9445 23.5 110.75 24 110.75 C 24.5 110.75 25 110.9445 25 112 C 25 112.5916 24.641069 113.15608 23.808594 113.86328 C 22.976118 114.57048 21.747004 115.31506 20.451172 116.16406 A 1.0001 1.0001 0 0 0 21 118 L 26 118 A 1.0001 1.0001 0 1 0 26 116 L 24.214844 116 C 24.498598 115.7934 24.845909 115.60562 25.103516 115.38672 C 26.133676 114.51162 27 113.4085 27 112 C 27 110.0556 25.5 108.75 24 108.75 z M 14 109 A 1.0001 1.0001 0 1 0 14 111 L 17.382812 111 L 14.105469 117.55273 A 1.0001181 1.0001181 0 0 0 15.894531 118.44727 L 19.894531 110.44727 A 1.0001 1.0001 0 0 0 19 109 L 14 109 z M 1.5 112 C 0.66899518 112 0 112.669 0 113.5 C 0 114.331 0.66899518 115 1.5 115 L 3.5 115 C 4.3310048 115 5 114.331 5 113.5 C 5 112.669 4.3310048 112 3.5 112 L 1.5 112 z M 9 114 L 9 116 L 12 116 L 12 114 L 9 114 z M 1.5 119 C 0.669 119 0 119.669 0 120.5 C 0 121.331 0.669 122 1.5 122 C 2.331 122 3 121.331 3 120.5 C 3 119.669 2.331 119 1.5 119 z " + transform="translate(0,924.3622)" + id="rect4527" /> + </g> +</svg> diff --git a/editor/icons/source/icon_bus_vu_empty.svg b/editor/icons/source/icon_bus_vu_empty.svg new file mode 100644 index 0000000000..0755a2695b --- /dev/null +++ b/editor/icons/source/icon_bus_vu_empty.svg @@ -0,0 +1,115 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="128" + viewBox="0 0 16 128" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_vu_empty.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_bus_vu_empty.svg"> + <defs + id="defs4"> + <linearGradient + id="linearGradient959" + inkscape:collect="always"> + <stop + style="stop-color:#ff8484;stop-opacity:1" + offset="0" + id="stop957" /> + <stop + id="stop955" + offset="0.5" + style="stop-color:#e1dc7a;stop-opacity:1" /> + <stop + style="stop-color:#84ffb1;stop-opacity:1" + offset="1" + id="stop953" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959" + id="linearGradient951" + x1="8" + y1="2" + x2="8" + y2="126" + gradientUnits="userSpaceOnUse" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="5.6568543" + inkscape:cx="37.883117" + inkscape:cy="58.698878" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false" + inkscape:snap-midpoints="false"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-924.3622)"> + <path + style="fill:url(#linearGradient951);fill-opacity:1;stroke:none;stroke-width:1.28571427;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 3 2 C 2.4459952 2 2 2.4459952 2 3 C 2 3.5540048 2.4459952 4 3 4 L 13 4 C 13.554005 4 14 3.5540048 14 3 C 14 2.4459952 13.554005 2 13 2 L 3 2 z M 3 5 C 2.4459952 5 2 5.4459952 2 6 C 2 6.5540048 2.4459952 7 3 7 L 13 7 C 13.554005 7 14 6.5540048 14 6 C 14 5.4459952 13.554005 5 13 5 L 3 5 z M 3 8 C 2.4459952 8 2 8.4459952 2 9 C 2 9.5540048 2.4459952 10 3 10 L 13 10 C 13.554005 10 14 9.5540048 14 9 C 14 8.4459952 13.554005 8 13 8 L 3 8 z M 3 11 C 2.4459952 11 2 11.445995 2 12 C 2 12.554005 2.4459952 13 3 13 L 13 13 C 13.554005 13 14 12.554005 14 12 C 14 11.445995 13.554005 11 13 11 L 3 11 z M 3 14 C 2.4459952 14 2 14.445995 2 15 C 2 15.554005 2.4459952 16 3 16 L 13 16 C 13.554005 16 14 15.554005 14 15 C 14 14.445995 13.554005 14 13 14 L 3 14 z M 3 17 C 2.4459952 17 2 17.445995 2 18 C 2 18.554005 2.4459952 19 3 19 L 13 19 C 13.554005 19 14 18.554005 14 18 C 14 17.445995 13.554005 17 13 17 L 3 17 z M 3 20 C 2.4459952 20 2 20.445995 2 21 C 2 21.554005 2.4459952 22 3 22 L 13 22 C 13.554005 22 14 21.554005 14 21 C 14 20.445995 13.554005 20 13 20 L 3 20 z M 3 23 C 2.4459952 23 2 23.445995 2 24 C 2 24.554005 2.4459952 25 3 25 L 13 25 C 13.554005 25 14 24.554005 14 24 C 14 23.445995 13.554005 23 13 23 L 3 23 z M 3 26 C 2.4459952 26 2 26.445995 2 27 C 2 27.554005 2.4459952 28 3 28 L 13 28 C 13.554005 28 14 27.554005 14 27 C 14 26.445995 13.554005 26 13 26 L 3 26 z M 3 31 C 2.4459952 31 2 31.445995 2 32 C 2 32.554005 2.4459952 33 3 33 L 13 33 C 13.554005 33 14 32.554005 14 32 C 14 31.445995 13.554005 31 13 31 L 3 31 z M 3 34 C 2.4459952 34 2 34.445995 2 35 C 2 35.554005 2.4459952 36 3 36 L 13 36 C 13.554005 36 14 35.554005 14 35 C 14 34.445995 13.554005 34 13 34 L 3 34 z M 3 37 C 2.4459952 37 2 37.445995 2 38 C 2 38.554005 2.4459952 39 3 39 L 13 39 C 13.554005 39 14 38.554005 14 38 C 14 37.445995 13.554005 37 13 37 L 3 37 z M 3 40 C 2.4459952 40 2 40.445995 2 41 C 2 41.554005 2.4459952 42 3 42 L 13 42 C 13.554005 42 14 41.554005 14 41 C 14 40.445995 13.554005 40 13 40 L 3 40 z M 3 43 C 2.4459952 43 2 43.445995 2 44 C 2 44.554005 2.4459952 45 3 45 L 13 45 C 13.554005 45 14 44.554005 14 44 C 14 43.445995 13.554005 43 13 43 L 3 43 z M 3 46 C 2.4459952 46 2 46.445995 2 47 C 2 47.554005 2.4459952 48 3 48 L 13 48 C 13.554005 48 14 47.554005 14 47 C 14 46.445995 13.554005 46 13 46 L 3 46 z M 3 49 C 2.4459952 49 2 49.445995 2 50 C 2 50.554005 2.4459952 51 3 51 L 13 51 C 13.554005 51 14 50.554005 14 50 C 14 49.445995 13.554005 49 13 49 L 3 49 z M 3 52 C 2.4459952 52 2 52.445995 2 53 C 2 53.554005 2.4459952 54 3 54 L 13 54 C 13.554005 54 14 53.554005 14 53 C 14 52.445995 13.554005 52 13 52 L 3 52 z M 3 55 C 2.4459952 55 2 55.445995 2 56 C 2 56.554005 2.4459952 57 3 57 L 13 57 C 13.554005 57 14 56.554005 14 56 C 14 55.445995 13.554005 55 13 55 L 3 55 z M 3 58 C 2.4459952 58 2 58.445995 2 59 C 2 59.554005 2.4459952 60 3 60 L 13 60 C 13.554005 60 14 59.554005 14 59 C 14 58.445995 13.554005 58 13 58 L 3 58 z M 3 61 C 2.4459952 61 2 61.445995 2 62 C 2 62.554005 2.4459952 63 3 63 L 13 63 C 13.554005 63 14 62.554005 14 62 C 14 61.445995 13.554005 61 13 61 L 3 61 z M 3 64 C 2.4459952 64 2 64.445995 2 65 C 2 65.554005 2.4459952 66 3 66 L 13 66 C 13.554005 66 14 65.554005 14 65 C 14 64.445995 13.554005 64 13 64 L 3 64 z M 3 67 C 2.4459952 67 2 67.445995 2 68 C 2 68.554005 2.4459952 69 3 69 L 13 69 C 13.554005 69 14 68.554005 14 68 C 14 67.445995 13.554005 67 13 67 L 3 67 z M 3 70 C 2.4459952 70 2 70.445995 2 71 C 2 71.554005 2.4459952 72 3 72 L 13 72 C 13.554005 72 14 71.554005 14 71 C 14 70.445995 13.554005 70 13 70 L 3 70 z M 3 73 C 2.4459952 73 2 73.445995 2 74 C 2 74.554005 2.4459952 75 3 75 L 13 75 C 13.554005 75 14 74.554005 14 74 C 14 73.445995 13.554005 73 13 73 L 3 73 z M 3 76 C 2.4459952 76 2 76.445995 2 77 C 2 77.554005 2.4459952 78 3 78 L 13 78 C 13.554005 78 14 77.554005 14 77 C 14 76.445995 13.554005 76 13 76 L 3 76 z M 3 79 C 2.4459952 79 2 79.445995 2 80 C 2 80.554005 2.4459952 81 3 81 L 13 81 C 13.554005 81 14 80.554005 14 80 C 14 79.445995 13.554005 79 13 79 L 3 79 z M 3 82 C 2.4459952 82 2 82.445995 2 83 C 2 83.554005 2.4459952 84 3 84 L 13 84 C 13.554005 84 14 83.554005 14 83 C 14 82.445995 13.554005 82 13 82 L 3 82 z M 3 85 C 2.4459952 85 2 85.445995 2 86 C 2 86.554005 2.4459952 87 3 87 L 13 87 C 13.554005 87 14 86.554005 14 86 C 14 85.445995 13.554005 85 13 85 L 3 85 z M 3 88 C 2.4459952 88 2 88.445995 2 89 C 2 89.554005 2.4459952 90 3 90 L 13 90 C 13.554005 90 14 89.554005 14 89 C 14 88.445995 13.554005 88 13 88 L 3 88 z M 3 91 C 2.4459952 91 2 91.445995 2 92 C 2 92.554005 2.4459952 93 3 93 L 13 93 C 13.554005 93 14 92.554005 14 92 C 14 91.445995 13.554005 91 13 91 L 3 91 z M 3 94 C 2.4459952 94 2 94.445995 2 95 C 2 95.554005 2.4459952 96 3 96 L 13 96 C 13.554005 96 14 95.554005 14 95 C 14 94.445995 13.554005 94 13 94 L 3 94 z M 3 97 C 2.4459952 97 2 97.445995 2 98 C 2 98.554005 2.4459952 99 3 99 L 13 99 C 13.554005 99 14 98.554005 14 98 C 14 97.445995 13.554005 97 13 97 L 3 97 z M 3 100 C 2.4459952 100 2 100.446 2 101 C 2 101.554 2.4459952 102 3 102 L 13 102 C 13.554005 102 14 101.554 14 101 C 14 100.446 13.554005 100 13 100 L 3 100 z M 3 103 C 2.4459952 103 2 103.446 2 104 C 2 104.554 2.4459952 105 3 105 L 13 105 C 13.554005 105 14 104.554 14 104 C 14 103.446 13.554005 103 13 103 L 3 103 z M 3 106 C 2.4459952 106 2 106.446 2 107 C 2 107.554 2.4459952 108 3 108 L 13 108 C 13.554005 108 14 107.554 14 107 C 14 106.446 13.554005 106 13 106 L 3 106 z M 3 109 C 2.4459952 109 2 109.446 2 110 C 2 110.554 2.4459952 111 3 111 L 13 111 C 13.554005 111 14 110.554 14 110 C 14 109.446 13.554005 109 13 109 L 3 109 z M 3 112 C 2.4459952 112 2 112.446 2 113 C 2 113.554 2.4459952 114 3 114 L 13 114 C 13.554005 114 14 113.554 14 113 C 14 112.446 13.554005 112 13 112 L 3 112 z M 3 115 C 2.4459952 115 2 115.446 2 116 C 2 116.554 2.4459952 117 3 117 L 13 117 C 13.554005 117 14 116.554 14 116 C 14 115.446 13.554005 115 13 115 L 3 115 z M 3 118 C 2.4459952 118 2 118.446 2 119 C 2 119.554 2.4459952 120 3 120 L 13 120 C 13.554005 120 14 119.554 14 119 C 14 118.446 13.554005 118 13 118 L 3 118 z M 3 121 C 2.4459952 121 2 121.446 2 122 C 2 122.554 2.4459952 123 3 123 L 13 123 C 13.554005 123 14 122.554 14 122 C 14 121.446 13.554005 121 13 121 L 3 121 z M 3 124 C 2.4459952 124 2 124.446 2 125 C 2 125.554 2.4459952 126 3 126 L 13 126 C 13.554005 126 14 125.554 14 125 C 14 124.446 13.554005 124 13 124 L 3 124 z " + transform="translate(0,924.3622)" + id="rect852" /> + <path + id="path1006" + transform="translate(0,924.3622)" + d="M 3 2 C 2.4459952 2 2 2.4459952 2 3 C 2 3.5540048 2.4459952 4 3 4 L 13 4 C 13.554005 4 14 3.5540048 14 3 C 14 2.4459952 13.554005 2 13 2 L 3 2 z M 3 5 C 2.4459952 5 2 5.4459952 2 6 C 2 6.5540048 2.4459952 7 3 7 L 13 7 C 13.554005 7 14 6.5540048 14 6 C 14 5.4459952 13.554005 5 13 5 L 3 5 z M 3 8 C 2.4459952 8 2 8.4459952 2 9 C 2 9.5540048 2.4459952 10 3 10 L 13 10 C 13.554005 10 14 9.5540048 14 9 C 14 8.4459952 13.554005 8 13 8 L 3 8 z M 3 11 C 2.4459952 11 2 11.445995 2 12 C 2 12.554005 2.4459952 13 3 13 L 13 13 C 13.554005 13 14 12.554005 14 12 C 14 11.445995 13.554005 11 13 11 L 3 11 z M 3 14 C 2.4459952 14 2 14.445995 2 15 C 2 15.554005 2.4459952 16 3 16 L 13 16 C 13.554005 16 14 15.554005 14 15 C 14 14.445995 13.554005 14 13 14 L 3 14 z M 3 17 C 2.4459952 17 2 17.445995 2 18 C 2 18.554005 2.4459952 19 3 19 L 13 19 C 13.554005 19 14 18.554005 14 18 C 14 17.445995 13.554005 17 13 17 L 3 17 z M 3 20 C 2.4459952 20 2 20.445995 2 21 C 2 21.554005 2.4459952 22 3 22 L 13 22 C 13.554005 22 14 21.554005 14 21 C 14 20.445995 13.554005 20 13 20 L 3 20 z M 3 23 C 2.4459952 23 2 23.445995 2 24 C 2 24.554005 2.4459952 25 3 25 L 13 25 C 13.554005 25 14 24.554005 14 24 C 14 23.445995 13.554005 23 13 23 L 3 23 z M 3 26 C 2.4459952 26 2 26.445995 2 27 C 2 27.554005 2.4459952 28 3 28 L 13 28 C 13.554005 28 14 27.554005 14 27 C 14 26.445995 13.554005 26 13 26 L 3 26 z M 3 31 C 2.4459952 31 2 31.445995 2 32 C 2 32.554005 2.4459952 33 3 33 L 13 33 C 13.554005 33 14 32.554005 14 32 C 14 31.445995 13.554005 31 13 31 L 3 31 z M 3 34 C 2.4459952 34 2 34.445995 2 35 C 2 35.554005 2.4459952 36 3 36 L 13 36 C 13.554005 36 14 35.554005 14 35 C 14 34.445995 13.554005 34 13 34 L 3 34 z M 3 37 C 2.4459952 37 2 37.445995 2 38 C 2 38.554005 2.4459952 39 3 39 L 13 39 C 13.554005 39 14 38.554005 14 38 C 14 37.445995 13.554005 37 13 37 L 3 37 z M 3 40 C 2.4459952 40 2 40.445995 2 41 C 2 41.554005 2.4459952 42 3 42 L 13 42 C 13.554005 42 14 41.554005 14 41 C 14 40.445995 13.554005 40 13 40 L 3 40 z M 3 43 C 2.4459952 43 2 43.445995 2 44 C 2 44.554005 2.4459952 45 3 45 L 13 45 C 13.554005 45 14 44.554005 14 44 C 14 43.445995 13.554005 43 13 43 L 3 43 z M 3 46 C 2.4459952 46 2 46.445995 2 47 C 2 47.554005 2.4459952 48 3 48 L 13 48 C 13.554005 48 14 47.554005 14 47 C 14 46.445995 13.554005 46 13 46 L 3 46 z M 3 49 C 2.4459952 49 2 49.445995 2 50 C 2 50.554005 2.4459952 51 3 51 L 13 51 C 13.554005 51 14 50.554005 14 50 C 14 49.445995 13.554005 49 13 49 L 3 49 z M 3 52 C 2.4459952 52 2 52.445995 2 53 C 2 53.554005 2.4459952 54 3 54 L 13 54 C 13.554005 54 14 53.554005 14 53 C 14 52.445995 13.554005 52 13 52 L 3 52 z M 3 55 C 2.4459952 55 2 55.445995 2 56 C 2 56.554005 2.4459952 57 3 57 L 13 57 C 13.554005 57 14 56.554005 14 56 C 14 55.445995 13.554005 55 13 55 L 3 55 z M 3 58 C 2.4459952 58 2 58.445995 2 59 C 2 59.554005 2.4459952 60 3 60 L 13 60 C 13.554005 60 14 59.554005 14 59 C 14 58.445995 13.554005 58 13 58 L 3 58 z M 3 61 C 2.4459952 61 2 61.445995 2 62 C 2 62.554005 2.4459952 63 3 63 L 13 63 C 13.554005 63 14 62.554005 14 62 C 14 61.445995 13.554005 61 13 61 L 3 61 z M 3 64 C 2.4459952 64 2 64.445995 2 65 C 2 65.554005 2.4459952 66 3 66 L 13 66 C 13.554005 66 14 65.554005 14 65 C 14 64.445995 13.554005 64 13 64 L 3 64 z M 3 67 C 2.4459952 67 2 67.445995 2 68 C 2 68.554005 2.4459952 69 3 69 L 13 69 C 13.554005 69 14 68.554005 14 68 C 14 67.445995 13.554005 67 13 67 L 3 67 z M 3 70 C 2.4459952 70 2 70.445995 2 71 C 2 71.554005 2.4459952 72 3 72 L 13 72 C 13.554005 72 14 71.554005 14 71 C 14 70.445995 13.554005 70 13 70 L 3 70 z M 3 73 C 2.4459952 73 2 73.445995 2 74 C 2 74.554005 2.4459952 75 3 75 L 13 75 C 13.554005 75 14 74.554005 14 74 C 14 73.445995 13.554005 73 13 73 L 3 73 z M 3 76 C 2.4459952 76 2 76.445995 2 77 C 2 77.554005 2.4459952 78 3 78 L 13 78 C 13.554005 78 14 77.554005 14 77 C 14 76.445995 13.554005 76 13 76 L 3 76 z M 3 79 C 2.4459952 79 2 79.445995 2 80 C 2 80.554005 2.4459952 81 3 81 L 13 81 C 13.554005 81 14 80.554005 14 80 C 14 79.445995 13.554005 79 13 79 L 3 79 z M 3 82 C 2.4459952 82 2 82.445995 2 83 C 2 83.554005 2.4459952 84 3 84 L 13 84 C 13.554005 84 14 83.554005 14 83 C 14 82.445995 13.554005 82 13 82 L 3 82 z M 3 85 C 2.4459952 85 2 85.445995 2 86 C 2 86.554005 2.4459952 87 3 87 L 13 87 C 13.554005 87 14 86.554005 14 86 C 14 85.445995 13.554005 85 13 85 L 3 85 z M 3 88 C 2.4459952 88 2 88.445995 2 89 C 2 89.554005 2.4459952 90 3 90 L 13 90 C 13.554005 90 14 89.554005 14 89 C 14 88.445995 13.554005 88 13 88 L 3 88 z M 3 91 C 2.4459952 91 2 91.445995 2 92 C 2 92.554005 2.4459952 93 3 93 L 13 93 C 13.554005 93 14 92.554005 14 92 C 14 91.445995 13.554005 91 13 91 L 3 91 z M 3 94 C 2.4459952 94 2 94.445995 2 95 C 2 95.554005 2.4459952 96 3 96 L 13 96 C 13.554005 96 14 95.554005 14 95 C 14 94.445995 13.554005 94 13 94 L 3 94 z M 3 97 C 2.4459952 97 2 97.445995 2 98 C 2 98.554005 2.4459952 99 3 99 L 13 99 C 13.554005 99 14 98.554005 14 98 C 14 97.445995 13.554005 97 13 97 L 3 97 z M 3 100 C 2.4459952 100 2 100.446 2 101 C 2 101.554 2.4459952 102 3 102 L 13 102 C 13.554005 102 14 101.554 14 101 C 14 100.446 13.554005 100 13 100 L 3 100 z M 3 103 C 2.4459952 103 2 103.446 2 104 C 2 104.554 2.4459952 105 3 105 L 13 105 C 13.554005 105 14 104.554 14 104 C 14 103.446 13.554005 103 13 103 L 3 103 z M 3 106 C 2.4459952 106 2 106.446 2 107 C 2 107.554 2.4459952 108 3 108 L 13 108 C 13.554005 108 14 107.554 14 107 C 14 106.446 13.554005 106 13 106 L 3 106 z M 3 109 C 2.4459952 109 2 109.446 2 110 C 2 110.554 2.4459952 111 3 111 L 13 111 C 13.554005 111 14 110.554 14 110 C 14 109.446 13.554005 109 13 109 L 3 109 z M 3 112 C 2.4459952 112 2 112.446 2 113 C 2 113.554 2.4459952 114 3 114 L 13 114 C 13.554005 114 14 113.554 14 113 C 14 112.446 13.554005 112 13 112 L 3 112 z M 3 115 C 2.4459952 115 2 115.446 2 116 C 2 116.554 2.4459952 117 3 117 L 13 117 C 13.554005 117 14 116.554 14 116 C 14 115.446 13.554005 115 13 115 L 3 115 z M 3 118 C 2.4459952 118 2 118.446 2 119 C 2 119.554 2.4459952 120 3 120 L 13 120 C 13.554005 120 14 119.554 14 119 C 14 118.446 13.554005 118 13 118 L 3 118 z M 3 121 C 2.4459952 121 2 121.446 2 122 C 2 122.554 2.4459952 123 3 123 L 13 123 C 13.554005 123 14 122.554 14 122 C 14 121.446 13.554005 121 13 121 L 3 121 z M 3 124 C 2.4459952 124 2 124.446 2 125 C 2 125.554 2.4459952 126 3 126 L 13 126 C 13.554005 126 14 125.554 14 125 C 14 124.446 13.554005 124 13 124 L 3 124 z " + style="fill:#000000;fill-opacity:0.23529412;stroke:none;stroke-width:1.28571427;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </g> +</svg> diff --git a/editor/icons/source/icon_bus_vu_frozen.svg b/editor/icons/source/icon_bus_vu_frozen.svg new file mode 100644 index 0000000000..0324076402 --- /dev/null +++ b/editor/icons/source/icon_bus_vu_frozen.svg @@ -0,0 +1,110 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="128" + viewBox="0 0 16 128" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_vu_empty.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_bus_vu_frozen.svg"> + <defs + id="defs4"> + <linearGradient + id="linearGradient959" + inkscape:collect="always"> + <stop + style="stop-color:#62aeff;stop-opacity:1" + offset="0" + id="stop957" /> + <stop + id="stop955" + offset="0.5" + style="stop-color:#75d1e6;stop-opacity:1" /> + <stop + style="stop-color:#84ffee;stop-opacity:1" + offset="1" + id="stop953" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959" + id="linearGradient951" + x1="8" + y1="2" + x2="8" + y2="126" + gradientUnits="userSpaceOnUse" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="5.6568543" + inkscape:cx="9.4951314" + inkscape:cy="71.853257" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false" + inkscape:snap-midpoints="false"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-924.3622)"> + <path + style="fill:url(#linearGradient951);fill-opacity:1;stroke:none;stroke-width:1.28571427;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 3 2 C 2.4459952 2 2 2.4459952 2 3 C 2 3.5540048 2.4459952 4 3 4 L 13 4 C 13.554005 4 14 3.5540048 14 3 C 14 2.4459952 13.554005 2 13 2 L 3 2 z M 3 5 C 2.4459952 5 2 5.4459952 2 6 C 2 6.5540048 2.4459952 7 3 7 L 13 7 C 13.554005 7 14 6.5540048 14 6 C 14 5.4459952 13.554005 5 13 5 L 3 5 z M 3 8 C 2.4459952 8 2 8.4459952 2 9 C 2 9.5540048 2.4459952 10 3 10 L 13 10 C 13.554005 10 14 9.5540048 14 9 C 14 8.4459952 13.554005 8 13 8 L 3 8 z M 3 11 C 2.4459952 11 2 11.445995 2 12 C 2 12.554005 2.4459952 13 3 13 L 13 13 C 13.554005 13 14 12.554005 14 12 C 14 11.445995 13.554005 11 13 11 L 3 11 z M 3 14 C 2.4459952 14 2 14.445995 2 15 C 2 15.554005 2.4459952 16 3 16 L 13 16 C 13.554005 16 14 15.554005 14 15 C 14 14.445995 13.554005 14 13 14 L 3 14 z M 3 17 C 2.4459952 17 2 17.445995 2 18 C 2 18.554005 2.4459952 19 3 19 L 13 19 C 13.554005 19 14 18.554005 14 18 C 14 17.445995 13.554005 17 13 17 L 3 17 z M 3 20 C 2.4459952 20 2 20.445995 2 21 C 2 21.554005 2.4459952 22 3 22 L 13 22 C 13.554005 22 14 21.554005 14 21 C 14 20.445995 13.554005 20 13 20 L 3 20 z M 3 23 C 2.4459952 23 2 23.445995 2 24 C 2 24.554005 2.4459952 25 3 25 L 13 25 C 13.554005 25 14 24.554005 14 24 C 14 23.445995 13.554005 23 13 23 L 3 23 z M 3 26 C 2.4459952 26 2 26.445995 2 27 C 2 27.554005 2.4459952 28 3 28 L 13 28 C 13.554005 28 14 27.554005 14 27 C 14 26.445995 13.554005 26 13 26 L 3 26 z M 3 31 C 2.4459952 31 2 31.445995 2 32 C 2 32.554005 2.4459952 33 3 33 L 13 33 C 13.554005 33 14 32.554005 14 32 C 14 31.445995 13.554005 31 13 31 L 3 31 z M 3 34 C 2.4459952 34 2 34.445995 2 35 C 2 35.554005 2.4459952 36 3 36 L 13 36 C 13.554005 36 14 35.554005 14 35 C 14 34.445995 13.554005 34 13 34 L 3 34 z M 3 37 C 2.4459952 37 2 37.445995 2 38 C 2 38.554005 2.4459952 39 3 39 L 13 39 C 13.554005 39 14 38.554005 14 38 C 14 37.445995 13.554005 37 13 37 L 3 37 z M 3 40 C 2.4459952 40 2 40.445995 2 41 C 2 41.554005 2.4459952 42 3 42 L 13 42 C 13.554005 42 14 41.554005 14 41 C 14 40.445995 13.554005 40 13 40 L 3 40 z M 3 43 C 2.4459952 43 2 43.445995 2 44 C 2 44.554005 2.4459952 45 3 45 L 13 45 C 13.554005 45 14 44.554005 14 44 C 14 43.445995 13.554005 43 13 43 L 3 43 z M 3 46 C 2.4459952 46 2 46.445995 2 47 C 2 47.554005 2.4459952 48 3 48 L 13 48 C 13.554005 48 14 47.554005 14 47 C 14 46.445995 13.554005 46 13 46 L 3 46 z M 3 49 C 2.4459952 49 2 49.445995 2 50 C 2 50.554005 2.4459952 51 3 51 L 13 51 C 13.554005 51 14 50.554005 14 50 C 14 49.445995 13.554005 49 13 49 L 3 49 z M 3 52 C 2.4459952 52 2 52.445995 2 53 C 2 53.554005 2.4459952 54 3 54 L 13 54 C 13.554005 54 14 53.554005 14 53 C 14 52.445995 13.554005 52 13 52 L 3 52 z M 3 55 C 2.4459952 55 2 55.445995 2 56 C 2 56.554005 2.4459952 57 3 57 L 13 57 C 13.554005 57 14 56.554005 14 56 C 14 55.445995 13.554005 55 13 55 L 3 55 z M 3 58 C 2.4459952 58 2 58.445995 2 59 C 2 59.554005 2.4459952 60 3 60 L 13 60 C 13.554005 60 14 59.554005 14 59 C 14 58.445995 13.554005 58 13 58 L 3 58 z M 3 61 C 2.4459952 61 2 61.445995 2 62 C 2 62.554005 2.4459952 63 3 63 L 13 63 C 13.554005 63 14 62.554005 14 62 C 14 61.445995 13.554005 61 13 61 L 3 61 z M 3 64 C 2.4459952 64 2 64.445995 2 65 C 2 65.554005 2.4459952 66 3 66 L 13 66 C 13.554005 66 14 65.554005 14 65 C 14 64.445995 13.554005 64 13 64 L 3 64 z M 3 67 C 2.4459952 67 2 67.445995 2 68 C 2 68.554005 2.4459952 69 3 69 L 13 69 C 13.554005 69 14 68.554005 14 68 C 14 67.445995 13.554005 67 13 67 L 3 67 z M 3 70 C 2.4459952 70 2 70.445995 2 71 C 2 71.554005 2.4459952 72 3 72 L 13 72 C 13.554005 72 14 71.554005 14 71 C 14 70.445995 13.554005 70 13 70 L 3 70 z M 3 73 C 2.4459952 73 2 73.445995 2 74 C 2 74.554005 2.4459952 75 3 75 L 13 75 C 13.554005 75 14 74.554005 14 74 C 14 73.445995 13.554005 73 13 73 L 3 73 z M 3 76 C 2.4459952 76 2 76.445995 2 77 C 2 77.554005 2.4459952 78 3 78 L 13 78 C 13.554005 78 14 77.554005 14 77 C 14 76.445995 13.554005 76 13 76 L 3 76 z M 3 79 C 2.4459952 79 2 79.445995 2 80 C 2 80.554005 2.4459952 81 3 81 L 13 81 C 13.554005 81 14 80.554005 14 80 C 14 79.445995 13.554005 79 13 79 L 3 79 z M 3 82 C 2.4459952 82 2 82.445995 2 83 C 2 83.554005 2.4459952 84 3 84 L 13 84 C 13.554005 84 14 83.554005 14 83 C 14 82.445995 13.554005 82 13 82 L 3 82 z M 3 85 C 2.4459952 85 2 85.445995 2 86 C 2 86.554005 2.4459952 87 3 87 L 13 87 C 13.554005 87 14 86.554005 14 86 C 14 85.445995 13.554005 85 13 85 L 3 85 z M 3 88 C 2.4459952 88 2 88.445995 2 89 C 2 89.554005 2.4459952 90 3 90 L 13 90 C 13.554005 90 14 89.554005 14 89 C 14 88.445995 13.554005 88 13 88 L 3 88 z M 3 91 C 2.4459952 91 2 91.445995 2 92 C 2 92.554005 2.4459952 93 3 93 L 13 93 C 13.554005 93 14 92.554005 14 92 C 14 91.445995 13.554005 91 13 91 L 3 91 z M 3 94 C 2.4459952 94 2 94.445995 2 95 C 2 95.554005 2.4459952 96 3 96 L 13 96 C 13.554005 96 14 95.554005 14 95 C 14 94.445995 13.554005 94 13 94 L 3 94 z M 3 97 C 2.4459952 97 2 97.445995 2 98 C 2 98.554005 2.4459952 99 3 99 L 13 99 C 13.554005 99 14 98.554005 14 98 C 14 97.445995 13.554005 97 13 97 L 3 97 z M 3 100 C 2.4459952 100 2 100.446 2 101 C 2 101.554 2.4459952 102 3 102 L 13 102 C 13.554005 102 14 101.554 14 101 C 14 100.446 13.554005 100 13 100 L 3 100 z M 3 103 C 2.4459952 103 2 103.446 2 104 C 2 104.554 2.4459952 105 3 105 L 13 105 C 13.554005 105 14 104.554 14 104 C 14 103.446 13.554005 103 13 103 L 3 103 z M 3 106 C 2.4459952 106 2 106.446 2 107 C 2 107.554 2.4459952 108 3 108 L 13 108 C 13.554005 108 14 107.554 14 107 C 14 106.446 13.554005 106 13 106 L 3 106 z M 3 109 C 2.4459952 109 2 109.446 2 110 C 2 110.554 2.4459952 111 3 111 L 13 111 C 13.554005 111 14 110.554 14 110 C 14 109.446 13.554005 109 13 109 L 3 109 z M 3 112 C 2.4459952 112 2 112.446 2 113 C 2 113.554 2.4459952 114 3 114 L 13 114 C 13.554005 114 14 113.554 14 113 C 14 112.446 13.554005 112 13 112 L 3 112 z M 3 115 C 2.4459952 115 2 115.446 2 116 C 2 116.554 2.4459952 117 3 117 L 13 117 C 13.554005 117 14 116.554 14 116 C 14 115.446 13.554005 115 13 115 L 3 115 z M 3 118 C 2.4459952 118 2 118.446 2 119 C 2 119.554 2.4459952 120 3 120 L 13 120 C 13.554005 120 14 119.554 14 119 C 14 118.446 13.554005 118 13 118 L 3 118 z M 3 121 C 2.4459952 121 2 121.446 2 122 C 2 122.554 2.4459952 123 3 123 L 13 123 C 13.554005 123 14 122.554 14 122 C 14 121.446 13.554005 121 13 121 L 3 121 z M 3 124 C 2.4459952 124 2 124.446 2 125 C 2 125.554 2.4459952 126 3 126 L 13 126 C 13.554005 126 14 125.554 14 125 C 14 124.446 13.554005 124 13 124 L 3 124 z " + id="rect852" + transform="translate(0,924.3622)" /> + </g> +</svg> diff --git a/editor/icons/source/icon_bus_vu_full.svg b/editor/icons/source/icon_bus_vu_full.svg new file mode 100644 index 0000000000..7f2fd22560 --- /dev/null +++ b/editor/icons/source/icon_bus_vu_full.svg @@ -0,0 +1,110 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="128" + viewBox="0 0 16 128" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_vu_empty.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_bus_vu_full.svg"> + <defs + id="defs4"> + <linearGradient + id="linearGradient959" + inkscape:collect="always"> + <stop + style="stop-color:#ff8484;stop-opacity:1" + offset="0" + id="stop957" /> + <stop + id="stop955" + offset="0.5" + style="stop-color:#e1dc7a;stop-opacity:1" /> + <stop + style="stop-color:#84ffb1;stop-opacity:1" + offset="1" + id="stop953" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient959" + id="linearGradient951" + x1="8" + y1="2" + x2="8" + y2="126" + gradientUnits="userSpaceOnUse" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="5.6568543" + inkscape:cx="1.8206711" + inkscape:cy="73.901674" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false" + inkscape:snap-midpoints="false"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-924.3622)"> + <path + style="fill:url(#linearGradient951);fill-opacity:1;stroke:none;stroke-width:1.28571427;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 3 2 C 2.4459952 2 2 2.4459952 2 3 C 2 3.5540048 2.4459952 4 3 4 L 13 4 C 13.554005 4 14 3.5540048 14 3 C 14 2.4459952 13.554005 2 13 2 L 3 2 z M 3 5 C 2.4459952 5 2 5.4459952 2 6 C 2 6.5540048 2.4459952 7 3 7 L 13 7 C 13.554005 7 14 6.5540048 14 6 C 14 5.4459952 13.554005 5 13 5 L 3 5 z M 3 8 C 2.4459952 8 2 8.4459952 2 9 C 2 9.5540048 2.4459952 10 3 10 L 13 10 C 13.554005 10 14 9.5540048 14 9 C 14 8.4459952 13.554005 8 13 8 L 3 8 z M 3 11 C 2.4459952 11 2 11.445995 2 12 C 2 12.554005 2.4459952 13 3 13 L 13 13 C 13.554005 13 14 12.554005 14 12 C 14 11.445995 13.554005 11 13 11 L 3 11 z M 3 14 C 2.4459952 14 2 14.445995 2 15 C 2 15.554005 2.4459952 16 3 16 L 13 16 C 13.554005 16 14 15.554005 14 15 C 14 14.445995 13.554005 14 13 14 L 3 14 z M 3 17 C 2.4459952 17 2 17.445995 2 18 C 2 18.554005 2.4459952 19 3 19 L 13 19 C 13.554005 19 14 18.554005 14 18 C 14 17.445995 13.554005 17 13 17 L 3 17 z M 3 20 C 2.4459952 20 2 20.445995 2 21 C 2 21.554005 2.4459952 22 3 22 L 13 22 C 13.554005 22 14 21.554005 14 21 C 14 20.445995 13.554005 20 13 20 L 3 20 z M 3 23 C 2.4459952 23 2 23.445995 2 24 C 2 24.554005 2.4459952 25 3 25 L 13 25 C 13.554005 25 14 24.554005 14 24 C 14 23.445995 13.554005 23 13 23 L 3 23 z M 3 26 C 2.4459952 26 2 26.445995 2 27 C 2 27.554005 2.4459952 28 3 28 L 13 28 C 13.554005 28 14 27.554005 14 27 C 14 26.445995 13.554005 26 13 26 L 3 26 z M 3 31 C 2.4459952 31 2 31.445995 2 32 C 2 32.554005 2.4459952 33 3 33 L 13 33 C 13.554005 33 14 32.554005 14 32 C 14 31.445995 13.554005 31 13 31 L 3 31 z M 3 34 C 2.4459952 34 2 34.445995 2 35 C 2 35.554005 2.4459952 36 3 36 L 13 36 C 13.554005 36 14 35.554005 14 35 C 14 34.445995 13.554005 34 13 34 L 3 34 z M 3 37 C 2.4459952 37 2 37.445995 2 38 C 2 38.554005 2.4459952 39 3 39 L 13 39 C 13.554005 39 14 38.554005 14 38 C 14 37.445995 13.554005 37 13 37 L 3 37 z M 3 40 C 2.4459952 40 2 40.445995 2 41 C 2 41.554005 2.4459952 42 3 42 L 13 42 C 13.554005 42 14 41.554005 14 41 C 14 40.445995 13.554005 40 13 40 L 3 40 z M 3 43 C 2.4459952 43 2 43.445995 2 44 C 2 44.554005 2.4459952 45 3 45 L 13 45 C 13.554005 45 14 44.554005 14 44 C 14 43.445995 13.554005 43 13 43 L 3 43 z M 3 46 C 2.4459952 46 2 46.445995 2 47 C 2 47.554005 2.4459952 48 3 48 L 13 48 C 13.554005 48 14 47.554005 14 47 C 14 46.445995 13.554005 46 13 46 L 3 46 z M 3 49 C 2.4459952 49 2 49.445995 2 50 C 2 50.554005 2.4459952 51 3 51 L 13 51 C 13.554005 51 14 50.554005 14 50 C 14 49.445995 13.554005 49 13 49 L 3 49 z M 3 52 C 2.4459952 52 2 52.445995 2 53 C 2 53.554005 2.4459952 54 3 54 L 13 54 C 13.554005 54 14 53.554005 14 53 C 14 52.445995 13.554005 52 13 52 L 3 52 z M 3 55 C 2.4459952 55 2 55.445995 2 56 C 2 56.554005 2.4459952 57 3 57 L 13 57 C 13.554005 57 14 56.554005 14 56 C 14 55.445995 13.554005 55 13 55 L 3 55 z M 3 58 C 2.4459952 58 2 58.445995 2 59 C 2 59.554005 2.4459952 60 3 60 L 13 60 C 13.554005 60 14 59.554005 14 59 C 14 58.445995 13.554005 58 13 58 L 3 58 z M 3 61 C 2.4459952 61 2 61.445995 2 62 C 2 62.554005 2.4459952 63 3 63 L 13 63 C 13.554005 63 14 62.554005 14 62 C 14 61.445995 13.554005 61 13 61 L 3 61 z M 3 64 C 2.4459952 64 2 64.445995 2 65 C 2 65.554005 2.4459952 66 3 66 L 13 66 C 13.554005 66 14 65.554005 14 65 C 14 64.445995 13.554005 64 13 64 L 3 64 z M 3 67 C 2.4459952 67 2 67.445995 2 68 C 2 68.554005 2.4459952 69 3 69 L 13 69 C 13.554005 69 14 68.554005 14 68 C 14 67.445995 13.554005 67 13 67 L 3 67 z M 3 70 C 2.4459952 70 2 70.445995 2 71 C 2 71.554005 2.4459952 72 3 72 L 13 72 C 13.554005 72 14 71.554005 14 71 C 14 70.445995 13.554005 70 13 70 L 3 70 z M 3 73 C 2.4459952 73 2 73.445995 2 74 C 2 74.554005 2.4459952 75 3 75 L 13 75 C 13.554005 75 14 74.554005 14 74 C 14 73.445995 13.554005 73 13 73 L 3 73 z M 3 76 C 2.4459952 76 2 76.445995 2 77 C 2 77.554005 2.4459952 78 3 78 L 13 78 C 13.554005 78 14 77.554005 14 77 C 14 76.445995 13.554005 76 13 76 L 3 76 z M 3 79 C 2.4459952 79 2 79.445995 2 80 C 2 80.554005 2.4459952 81 3 81 L 13 81 C 13.554005 81 14 80.554005 14 80 C 14 79.445995 13.554005 79 13 79 L 3 79 z M 3 82 C 2.4459952 82 2 82.445995 2 83 C 2 83.554005 2.4459952 84 3 84 L 13 84 C 13.554005 84 14 83.554005 14 83 C 14 82.445995 13.554005 82 13 82 L 3 82 z M 3 85 C 2.4459952 85 2 85.445995 2 86 C 2 86.554005 2.4459952 87 3 87 L 13 87 C 13.554005 87 14 86.554005 14 86 C 14 85.445995 13.554005 85 13 85 L 3 85 z M 3 88 C 2.4459952 88 2 88.445995 2 89 C 2 89.554005 2.4459952 90 3 90 L 13 90 C 13.554005 90 14 89.554005 14 89 C 14 88.445995 13.554005 88 13 88 L 3 88 z M 3 91 C 2.4459952 91 2 91.445995 2 92 C 2 92.554005 2.4459952 93 3 93 L 13 93 C 13.554005 93 14 92.554005 14 92 C 14 91.445995 13.554005 91 13 91 L 3 91 z M 3 94 C 2.4459952 94 2 94.445995 2 95 C 2 95.554005 2.4459952 96 3 96 L 13 96 C 13.554005 96 14 95.554005 14 95 C 14 94.445995 13.554005 94 13 94 L 3 94 z M 3 97 C 2.4459952 97 2 97.445995 2 98 C 2 98.554005 2.4459952 99 3 99 L 13 99 C 13.554005 99 14 98.554005 14 98 C 14 97.445995 13.554005 97 13 97 L 3 97 z M 3 100 C 2.4459952 100 2 100.446 2 101 C 2 101.554 2.4459952 102 3 102 L 13 102 C 13.554005 102 14 101.554 14 101 C 14 100.446 13.554005 100 13 100 L 3 100 z M 3 103 C 2.4459952 103 2 103.446 2 104 C 2 104.554 2.4459952 105 3 105 L 13 105 C 13.554005 105 14 104.554 14 104 C 14 103.446 13.554005 103 13 103 L 3 103 z M 3 106 C 2.4459952 106 2 106.446 2 107 C 2 107.554 2.4459952 108 3 108 L 13 108 C 13.554005 108 14 107.554 14 107 C 14 106.446 13.554005 106 13 106 L 3 106 z M 3 109 C 2.4459952 109 2 109.446 2 110 C 2 110.554 2.4459952 111 3 111 L 13 111 C 13.554005 111 14 110.554 14 110 C 14 109.446 13.554005 109 13 109 L 3 109 z M 3 112 C 2.4459952 112 2 112.446 2 113 C 2 113.554 2.4459952 114 3 114 L 13 114 C 13.554005 114 14 113.554 14 113 C 14 112.446 13.554005 112 13 112 L 3 112 z M 3 115 C 2.4459952 115 2 115.446 2 116 C 2 116.554 2.4459952 117 3 117 L 13 117 C 13.554005 117 14 116.554 14 116 C 14 115.446 13.554005 115 13 115 L 3 115 z M 3 118 C 2.4459952 118 2 118.446 2 119 C 2 119.554 2.4459952 120 3 120 L 13 120 C 13.554005 120 14 119.554 14 119 C 14 118.446 13.554005 118 13 118 L 3 118 z M 3 121 C 2.4459952 121 2 121.446 2 122 C 2 122.554 2.4459952 123 3 123 L 13 123 C 13.554005 123 14 122.554 14 122 C 14 121.446 13.554005 121 13 121 L 3 121 z M 3 124 C 2.4459952 124 2 124.446 2 125 C 2 125.554 2.4459952 126 3 126 L 13 126 C 13.554005 126 14 125.554 14 125 C 14 124.446 13.554005 124 13 124 L 3 124 z " + transform="translate(0,924.3622)" + id="rect852" /> + </g> +</svg> diff --git a/editor/icons/source/icon_checked.svg b/editor/icons/source/icon_checked.svg new file mode 100644 index 0000000000..6d2c03f4c5 --- /dev/null +++ b/editor/icons/source/icon_checked.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="checked.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/checked.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="8.555527" + inkscape:cy="7.1886752" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:0.78431374;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="M 4 2 C 2.8954305 2 2 2.8954305 2 4 L 2 12 C 2 13.104569 2.8954305 14 4 14 L 12 14 C 13.104569 14 14 13.104569 14 12 L 14 4 C 14 2.8954305 13.104569 2 12 2 L 4 2 z M 11.292969 4.2929688 L 12.707031 5.7070312 L 6 12.414062 L 3.2929688 9.7070312 L 4.7070312 8.2929688 L 6 9.5859375 L 11.292969 4.2929688 z " + transform="translate(0,1036.3623)" + id="circle4178" /> + </g> +</svg> diff --git a/editor/icons/source/icon_copy_node_path.svg b/editor/icons/source/icon_copy_node_path.svg index 9f33c5e54d..abc93eb003 100644 --- a/editor/icons/source/icon_copy_node_path.svg +++ b/editor/icons/source/icon_copy_node_path.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/godotengine/godot/tools/editor/icons/con_script_create.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -39,8 +39,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="21.189633" - inkscape:cx="12.640765" - inkscape:cy="9.6848443" + inkscape:cx="-1.3283302" + inkscape:cy="8.1746718" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -52,8 +52,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -73,7 +73,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -90,7 +90,7 @@ ry="1.0000174" rx="1" /> <path - style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + style="opacity:1;fill:#e0e0e0;fill-opacity:0.78431374;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" d="M 2 1 C 1.4477381 1.0001 1.0000552 1.4477 1 2 L 1 14 C 1.0000552 14.5523 1.4477381 14.9999 2 15 L 14 15 C 14.552262 14.9999 14.999945 14.5523 15 14 L 15 6 L 10 1 L 2 1 z M 3 3 L 9 3 L 9 6 C 9 6.554 9.4459905 7 10 7 L 13 7 L 13 13 L 3 13 L 3 3 z M 6 8 L 4 12 L 6 12 L 8 8 L 6 8 z M 10 8 L 8 12 L 10 12 L 12 8 L 10 8 z " transform="translate(0,1036.3622)" id="rect4178" /> diff --git a/editor/icons/source/icon_curve_texture.svg b/editor/icons/source/icon_curve_texture.svg new file mode 100644 index 0000000000..b1cb456608 --- /dev/null +++ b/editor/icons/source/icon_curve_texture.svg @@ -0,0 +1,81 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_key.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_curve_texture.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="5.2803314" + inkscape:cy="6.7903753" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:object-nodes="true" + inkscape:snap-smooth-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + d="M 2 1 C 1.4477153 1 1 1.4477153 1 2 L 1 11.160156 C 1.3218501 11.050492 1.6599997 10.996335 2 11 C 2.3311746 11 2.665754 10.992098 3 10.986328 L 3 3 L 13 3 L 13 4.1347656 C 13.290071 4.0308316 13.594421 3.9722014 13.902344 3.9609375 C 14.275493 3.9481411 14.647753 4.0051061 15 4.1289062 L 15 2 C 15 1.4477153 14.552285 1 14 1 L 2 1 z M 9 5 L 9 6 L 8 6 L 8 7 L 6 7 L 6 8 L 5 8 L 5 9 L 4 9 L 4 10 L 6 10 L 8 10 L 8.390625 10 C 9.5025431 9.4332285 10.358388 8.54624 11 6.5273438 L 11 6 L 10 6 L 10 5 L 9 5 z M 13.966797 5.9882812 A 1.0001 1.0001 0 0 0 13.039062 6.7265625 C 12.111631 9.9725625 10.403509 11.409059 8.3867188 12.193359 C 6.369928 12.977659 4 13 2 13 A 1.0001 1.0001 0 1 0 2 15 C 4 15 6.6300719 15.023994 9.1132812 14.058594 C 11.596491 13.092894 13.888369 11.029391 14.960938 7.2753906 A 1.0001 1.0001 0 0 0 13.966797 5.9882812 z " + transform="translate(0,1036.3622)" + id="rect4156" /> + </g> +</svg> diff --git a/editor/icons/source/icon_debug.svg b/editor/icons/source/icon_debug.svg new file mode 100644 index 0000000000..1b3e748668 --- /dev/null +++ b/editor/icons/source/icon_debug.svg @@ -0,0 +1,93 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_debug.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="8.8380296" + inkscape:cy="8.0475262" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-midpoints="true" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 3 3.9863281 A 1.0001 1.0001 0 0 0 2.015625 5.1816406 C 2.2178415 6.2802406 2.7057331 7.1756813 3.390625 7.8007812 C 3.6768866 8.0620519 3.9944862 8.2637767 4.3242188 8.4375 A 4 4 0 0 0 4.1289062 9 L 2 9 A 1.0001 1.0001 0 1 0 2 11 L 4.1328125 11 A 4 4 0 0 0 4.3652344 11.658203 C 4.2801416 11.696657 4.2143084 11.719391 4.1210938 11.765625 C 3.5374123 12.055025 2.8673634 12.538772 2.2089844 13.388672 A 1.0003084 1.0003084 0 1 0 3.7910156 14.613281 C 4.2919543 13.966681 4.6296764 13.745141 5.0097656 13.556641 C 5.205099 13.459768 5.4352695 13.372568 5.6953125 13.263672 A 4 4 0 0 0 8 14 A 4 4 0 0 0 10.332031 13.244141 C 11.496007 13.78538 11.98739 14.238118 12.128906 14.490234 A 1.0001 1.0001 0 1 0 13.871094 13.511719 C 13.471096 12.799229 12.778174 12.20655 11.644531 11.634766 A 4 4 0 0 0 11.869141 11 L 14 11 A 1.0001 1.0001 0 1 0 14 9 L 11.867188 9 A 4 4 0 0 0 11.685547 8.4550781 C 12.182886 8.1889169 12.596375 7.860606 12.908203 7.4804688 C 13.491193 6.7697687 13.74859 5.9803156 13.957031 5.2910156 A 1.0001 1.0001 0 0 0 12.982422 3.9882812 A 1.0001 1.0001 0 0 0 12.042969 4.7109375 C 11.850379 5.3477375 11.656068 5.8559906 11.363281 6.2128906 C 11.080302 6.5578365 10.697905 6.8305531 9.8867188 7 L 6.1503906 7 C 5.5504757 6.8482606 5.0764053 6.630863 4.7382812 6.3222656 C 4.3835001 5.9984656 4.1227361 5.5721125 3.984375 4.8203125 A 1.0001 1.0001 0 0 0 3 3.9863281 z M 8.046875 4 A 2 2 0 0 0 7 4.2675781 A 2 2 0 0 0 6 6 L 10 6 A 2 2 0 0 0 9 4.2675781 A 2 2 0 0 0 8.046875 4 z " + id="path4507" + transform="translate(0,1036.3622)" /> + <path + style="fill:none;fill-opacity:1;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.78431373" + id="path4548" + sodipodi:type="arc" + sodipodi:cx="8" + sodipodi:cy="-1041.3622" + sodipodi:rx="4" + sodipodi:ry="4" + sodipodi:start="0.78539816" + sodipodi:end="2.3561945" + d="M 10.828427,-1038.5338 A 4,4 0 0 1 8,-1037.3622 a 4,4 0 0 1 -2.8284272,-1.1716" + transform="scale(1,-1)" + sodipodi:open="true" /> + </g> +</svg> diff --git a/editor/icons/source/icon_dropdown.svg b/editor/icons/source/icon_dropdown.svg new file mode 100644 index 0000000000..5963e74007 --- /dev/null +++ b/editor/icons/source/icon_dropdown.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="8" + height="8" + viewBox="0 0 8 8" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="dropdown.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="64" + inkscape:cx="3.5701039" + inkscape:cy="3.3945836" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1044.3622)"> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.78431374" + d="m 1,1047.3622 3,3 3,-3" + id="path4503" + inkscape:connector-curvature="0" /> + </g> +</svg> diff --git a/editor/icons/source/icon_edit_resource.svg b/editor/icons/source/icon_edit_resource.svg index 1950988ca2..7f6516eb58 100644 --- a/editor/icons/source/icon_edit_resource.svg +++ b/editor/icons/source/icon_edit_resource.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="63.999997" - inkscape:cx="1.8775976" - inkscape:cy="5.2018914" + inkscape:cx="2.7141614" + inkscape:cy="4.341677" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -73,9 +73,9 @@ id="layer1" transform="translate(0,-1044.3622)"> <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#e0e0e0;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 1.9472656,1044.3555 a 1.0001,1.0001 0 0 0 -0.546875,1.8066 l 2.9335938,2.2012 -2.9335938,2.1992 a 1.0001,1.0001 0 1 0 1.1992188,1.5996 l 4,-3 a 1.0001,1.0001 0 0 0 0,-1.5996 l -4,-3 a 1.0001,1.0001 0 0 0 -0.6523438,-0.207 z" - id="path4137" - inkscape:connector-curvature="0" /> + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:0.78431373;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 3.9902344 -0.009765625 A 1.0001 1.0001 0 0 0 3.2929688 1.7070312 L 4.5859375 3 L 1 3 L 1 5 L 4.5859375 5 L 3.2929688 6.2929688 A 1.0001 1.0001 0 1 0 4.7070312 7.7070312 L 7.7070312 4.7070312 A 1.0001 1.0001 0 0 0 7.7070312 3.2929688 L 4.7070312 0.29296875 A 1.0001 1.0001 0 0 0 3.9902344 -0.009765625 z " + transform="translate(0,1044.3622)" + id="path814" /> </g> </svg> diff --git a/editor/icons/source/icon_error.svg b/editor/icons/source/icon_error.svg index a0b04a98cb..013f1c7ba9 100644 --- a/editor/icons/source/icon_error.svg +++ b/editor/icons/source/icon_error.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="22.627416" - inkscape:cx="5.542036" - inkscape:cy="14.568715" + inkscape:zoom="45.254832" + inkscape:cx="0.9455546" + inkscape:cy="4.9546755" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -76,6 +76,6 @@ height="8" x="2.220446e-16" y="1044.3622" - ry="1.0000174" /> + ry="4" /> </g> </svg> diff --git a/editor/icons/source/icon_forward.svg b/editor/icons/source/icon_forward.svg index f6cb351cc1..392e2bda8e 100644 --- a/editor/icons/source/icon_forward.svg +++ b/editor/icons/source/icon_forward.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_bone.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,7 +29,7 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="4.4850647" + inkscape:cx="-1.8586853" inkscape:cy="8.9717887" inkscape:document-units="px" inkscape:current-layer="layer1" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -60,7 +60,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -70,10 +70,9 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#e0e0e0;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 2.0293363,1037.3633 c 0.3235485,0.01 0.622658,0.1743 0.8027343,0.4433 l 4,6 c 0.2239059,0.3359 0.2239059,0.7735 0,1.1094 l -4,6 c -0.5489722,0.8228 -1.8316762,0.4344 -1.8320312,-0.5547 l 0,-12 c 9.424e-4,-0.5631 0.4664154,-1.0144 1.0292969,-0.998 z" - id="path4159" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cccccccc" /> + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 2,1038.3622 4,6 -4,6" + id="path814" + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_g_d_native_script.svg b/editor/icons/source/icon_g_d_native_script.svg new file mode 100644 index 0000000000..33a8e52a5d --- /dev/null +++ b/editor/icons/source/icon_g_d_native_script.svg @@ -0,0 +1,77 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_g_d_script.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_g_d_native.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627417" + inkscape:cx="6.4177687" + inkscape:cy="8.8552476" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="M 7 1 L 6.4355469 3.2578125 A 5.0000172 5.0000172 0 0 0 5.7460938 3.5371094 L 3.7578125 2.34375 L 2.34375 3.7578125 L 3.5390625 5.7519531 A 5.0000172 5.0000172 0 0 0 3.2539062 6.4375 L 1 7 L 4 7 L 4 8 L 4 9 L 6 9 L 6 8.0488281 A 2.0000174 2.0000174 0 0 1 6 8 A 2.0000174 2.0000174 0 0 1 8 6 A 2.0000174 2.0000174 0 0 1 10 8 L 10 9 L 15 9 L 15 7 L 12.742188 6.4355469 A 5.0000172 5.0000172 0 0 0 12.462891 5.7480469 L 13.65625 3.7578125 L 12.242188 2.34375 L 10.248047 3.5390625 A 5.0000172 5.0000172 0 0 0 9.5625 3.2539062 L 9 1 L 7 1 z M 1 8 L 1 12 L 1 16 L 3 16 A 3 3 0 0 0 6 13 A 3 3 0 0 0 3 10 L 3 8 L 1 8 z M 7 8 L 7 10 L 9 10 L 9 8 L 7 8 z M 10 10 L 10 16 L 12 16 L 12 12 A 1.0000174 1.0000174 0 0 1 13 13 L 13 16 L 15 16 L 15 13 A 3 3 0 0 0 12 10 L 10 10 z M 3 12 A 1.0000174 1.0000174 0 0 1 4 13 A 1.0000174 1.0000174 0 0 1 3 14 L 3 12 z M 7 12 L 7 16 L 9 16 L 9 12 L 7 12 z " + transform="translate(0,1036.3622)" + id="path4176" /> + </g> +</svg> diff --git a/editor/icons/source/icon_godot.svg b/editor/icons/source/icon_godot.svg deleted file mode 100644 index 419f23125b..0000000000 --- a/editor/icons/source/icon_godot.svg +++ /dev/null @@ -1,168 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" standalone="no"?> -<!-- Created with Inkscape (http://www.inkscape.org/) --> - -<svg - xmlns:dc="http://purl.org/dc/elements/1.1/" - xmlns:cc="http://creativecommons.org/ns#" - xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" - xmlns:svg="http://www.w3.org/2000/svg" - xmlns="http://www.w3.org/2000/svg" - xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" - xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" - width="16" - height="16" - viewBox="0 0 16 16" - id="svg2" - version="1.1" - inkscape:version="0.91 r13725" - inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collision_shape_2d.png" - inkscape:export-xdpi="90" - inkscape:export-ydpi="90" - sodipodi:docname="icon_godot.svg"> - <defs - id="defs4" /> - <sodipodi:namedview - id="base" - pagecolor="#ffffff" - bordercolor="#666666" - borderopacity="1.0" - inkscape:pageopacity="0.0" - inkscape:pageshadow="2" - inkscape:zoom="32" - inkscape:cx="9.8470361" - inkscape:cy="9.8599985" - inkscape:document-units="px" - inkscape:current-layer="layer1" - showgrid="false" - units="px" - inkscape:snap-bbox="true" - inkscape:bbox-paths="true" - inkscape:bbox-nodes="true" - inkscape:snap-bbox-edge-midpoints="true" - inkscape:snap-bbox-midpoints="true" - inkscape:snap-object-midpoints="true" - inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" - inkscape:window-x="0" - inkscape:window-y="27" - inkscape:window-maximized="1"> - <inkscape:grid - type="xygrid" - id="grid3336" /> - </sodipodi:namedview> - <metadata - id="metadata7"> - <rdf:RDF> - <cc:Work - rdf:about=""> - <dc:format>image/svg+xml</dc:format> - <dc:type - rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title /> - </cc:Work> - </rdf:RDF> - </metadata> - <g - inkscape:label="Layer 1" - inkscape:groupmode="layer" - id="layer1" - transform="translate(0,-1036.3622)"> - <g - transform="matrix(0.01724138,0,0,0.01724138,-0.82758647,1035.0456)" - id="layer1-5" - inkscape:label="Layer 1"> - <g - transform="matrix(1.0688992,0,0,1.1334985,-45.061194,-81.689066)" - id="g4149"> - <path - style="fill:#ffffff;fill-opacity:1;stroke:none" - d="m 116.99388,715.36604 43.13957,-74.51381 75.99672,-171.42666 271.088,-13.63746 282.06373,14.1696 138.45065,255.56931 -25.0756,66.96734 -376.12685,53.39482 -367.70391,-40.32222 z" - id="path3239" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cccccccccc" /> - <g - id="g3412" - transform="matrix(12.995388,0,0,-12.995388,898.37246,704.73082)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 0,-3.942 c 0,-0.39 -0.25,-0.734 -0.621,-0.852 L -6.835,-6.8 c -0.273,-0.091 -0.57,-0.042 -0.8,0.128 -0.232,0.168 -0.37,0.437 -0.37,0.721 l 0,4.305 -5.818,-1.108 0,-4.381 c 0,-0.447 -0.332,-0.824 -0.775,-0.885 l -8.41,-1.152 c -0.039,-0.003 -0.081,-0.008 -0.121,-0.008 -0.214,0 -0.424,0.078 -0.588,0.22 -0.195,0.172 -0.306,0.416 -0.306,0.676 l 0,4.638 -4.341,-0.018 0,-10e-4 -0.318,10e-4 -0.319,-10e-4 0,10e-4 -4.34,0.018 0,-4.638 c 0,-0.26 -0.112,-0.504 -0.307,-0.676 -0.164,-0.142 -0.374,-0.22 -0.587,-0.22 -0.041,0 -0.082,0.005 -0.123,0.008 l -8.41,1.152 c -0.442,0.061 -0.774,0.438 -0.774,0.885 l 0,4.381 -5.819,1.108 0,-4.305 c 0,-0.284 -0.137,-0.553 -0.368,-0.721 -0.232,-0.17 -0.529,-0.219 -0.802,-0.128 l -6.215,2.006 c -0.369,0.118 -0.619,0.462 -0.619,0.852 l 0,3.942 -3.837,1.29 c -0.19,-0.811 -0.295,-1.642 -0.295,-2.481 0,-10.301 14.512,-18.252 32.448,-18.309 l 0.022,0 0.023,0 c 17.936,0.057 32.448,8.008 32.448,18.309 0,0.766 -0.088,1.521 -0.247,2.266 L 0,0 Z" - style="fill:#478cbf;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3414" /> - </g> - <g - id="g3416" - transform="matrix(12.995388,0,0,-12.995388,140.10982,467.34929)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 0,-16.047 2.163,-0.729 c 0.364,-0.122 0.61,-0.462 0.61,-0.847 l 0,-3.936 4.426,-1.428 0,4.154 c 0,0.27 0.118,0.52 0.323,0.689 0.206,0.172 0.474,0.241 0.739,0.192 l 7.608,-1.452 c 0.422,-0.079 0.728,-0.448 0.728,-0.877 l 0,-4.338 6.62,-0.904 0,4.509 c 0,0.241 0.096,0.467 0.264,0.635 0.167,0.166 0.394,0.259 0.633,0.259 l 0.002,0 5.551,-0.022 5.549,0.022 c 0.245,-10e-4 0.468,-0.093 0.635,-0.259 0.169,-0.168 0.264,-0.394 0.264,-0.635 l 0,-4.509 6.621,0.904 0,4.338 c 0,0.429 0.304,0.798 0.726,0.877 l 7.609,1.452 c 0.262,0.049 0.533,-0.02 0.738,-0.192 0.205,-0.169 0.325,-0.419 0.325,-0.689 l 0,-4.154 4.425,1.428 0,3.936 c 0,0.385 0.245,0.725 0.609,0.847 l 1.475,0.497 0,16.279 0.04,0 c 1.437,1.834 2.767,3.767 4.042,5.828 -1.694,2.883 -3.768,5.459 -5.986,7.846 -2.057,-1.035 -4.055,-2.208 -5.942,-3.456 -0.944,0.938 -2.008,1.706 -3.052,2.509 -1.027,0.824 -2.183,1.428 -3.281,2.132 0.327,2.433 0.489,4.828 0.554,7.327 -2.831,1.424 -5.85,2.369 -8.903,3.047 -1.219,-2.048 -2.334,-4.267 -3.304,-6.436 -1.152,0.192 -2.309,0.264 -3.467,0.277 l 0,0.002 c -0.008,0 -0.015,-0.002 -0.022,-0.002 -0.008,0 -0.015,0.002 -0.022,0.002 l 0,-0.002 c -1.16,-0.013 -2.316,-0.085 -3.468,-0.277 -0.97,2.169 -2.084,4.388 -3.305,6.436 C 19.475,24.555 16.456,23.61 13.626,22.186 13.69,19.687 13.852,17.292 14.18,14.859 13.081,14.155 11.925,13.551 10.898,12.727 9.855,11.924 8.79,11.156 7.846,10.218 5.958,11.466 3.961,12.639 1.904,13.674 -0.314,11.287 -2.388,8.711 -4.082,5.828 -2.807,3.767 -1.477,1.834 -0.04,0 L 0,0 Z" - style="fill:#478cbf;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3418" /> - </g> - <g - id="g3420" - transform="matrix(12.995388,0,0,-12.995388,411.4457,567.42812)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 c 0,-3.611 -2.926,-6.537 -6.537,-6.537 -3.608,0 -6.535,2.926 -6.535,6.537 0,3.609 2.927,6.533 6.535,6.533 C -2.926,6.533 0,3.609 0,0" - style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3422" /> - </g> - <g - id="g3424" - transform="matrix(12.995388,0,0,-12.995388,391.00655,572.46636)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 c 0,-2.396 -1.941,-4.337 -4.339,-4.337 -2.396,0 -4.339,1.941 -4.339,4.337 0,2.396 1.943,4.339 4.339,4.339 C -1.941,4.339 0,2.396 0,0" - style="fill:#414042;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3426" /> - </g> - <g - id="g3428" - transform="matrix(12.995388,0,0,-12.995388,526.30933,660.10985)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 c -1.162,0 -2.104,0.856 -2.104,1.912 l 0,6.018 c 0,1.054 0.942,1.912 2.104,1.912 1.162,0 2.106,-0.858 2.106,-1.912 l 0,-6.018 C 2.106,0.856 1.162,0 0,0" - style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3430" /> - </g> - <g - id="g3432" - transform="matrix(12.995388,0,0,-12.995388,641.18731,567.42812)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 c 0,-3.611 2.926,-6.537 6.537,-6.537 3.609,0 6.535,2.926 6.535,6.537 0,3.609 -2.926,6.533 -6.535,6.533 C 2.926,6.533 0,3.609 0,0" - style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3434" /> - </g> - <g - id="g3436" - transform="matrix(12.995388,0,0,-12.995388,661.63165,572.46636)"> - <path - inkscape:connector-curvature="0" - d="m 0,0 c 0,-2.396 1.941,-4.337 4.336,-4.337 2.398,0 4.339,1.941 4.339,4.337 0,2.396 -1.941,4.339 -4.339,4.339 C 1.941,4.339 0,2.396 0,0" - style="fill:#414042;fill-opacity:1;fill-rule:nonzero;stroke:none" - id="path3438" /> - </g> - </g> - </g> - <path - style="opacity:1;fill:#000000;fill-opacity:1;stroke:none;stroke-width:6;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.44162436" - d="m 4,1041.3622 a 3,3 0 0 0 -3,3 3,3 0 0 0 3,3 3,3 0 0 0 3,-3 3,3 0 0 0 -3,-3 z m 0,1 a 2.0000174,2.0000174 0 0 1 2,2 2.0000174,2.0000174 0 0 1 -2,2 2.0000174,2.0000174 0 0 1 -2,-2 2.0000174,2.0000174 0 0 1 2,-2 z" - id="path4151" - inkscape:connector-curvature="0" /> - <path - inkscape:connector-curvature="0" - id="path4156" - d="m 12,1041.3622 a 3,3 0 0 0 -3,3 3,3 0 0 0 3,3 3,3 0 0 0 3,-3 3,3 0 0 0 -3,-3 z m 0,1 a 2.0000174,2.0000174 0 0 1 2,2 2.0000174,2.0000174 0 0 1 -2,2 2.0000174,2.0000174 0 0 1 -2,-2 2.0000174,2.0000174 0 0 1 2,-2 z" - style="opacity:1;fill:#000000;fill-opacity:1;stroke:none;stroke-width:6;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.44162436" /> - <rect - style="opacity:1;fill:#000000;fill-opacity:1;stroke:none;stroke-width:6;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.44162436" - id="rect4160" - width="4" - height="1" - x="6" - y="1043.3622" - ry="0" /> - </g> -</svg> diff --git a/editor/icons/source/icon_godot_docs.svg b/editor/icons/source/icon_godot_docs.svg new file mode 100644 index 0000000000..77aa92b31f --- /dev/null +++ b/editor/icons/source/icon_godot_docs.svg @@ -0,0 +1,173 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 15 15" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r15371" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collision_shape_2d.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_godot_docs.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627417" + inkscape:cx="-14.305844" + inkscape:cy="5.1981046" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="false" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1920" + inkscape:window-height="1011" + inkscape:window-x="0" + inkscape:window-y="0" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" + originx="0" + originy="0" + spacingx="1" + spacingy="1" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1037.3622)"> + <g + id="g78" + transform="matrix(0.06307836,0,0,-0.06307664,13.671143,1047.293)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c 0,0 -0.325,1.994 -0.515,1.976 l -36.182,-3.491 c -2.879,-0.278 -5.115,-2.574 -5.317,-5.459 l -0.994,-14.247 -27.992,-1.997 -1.904,12.912 c -0.424,2.872 -2.932,5.037 -5.835,5.037 h -38.188 c -2.902,0 -5.41,-2.165 -5.834,-5.037 l -1.905,-12.912 -27.992,1.997 -0.994,14.247 c -0.202,2.886 -2.438,5.182 -5.317,5.46 l -36.2,3.49 c -0.187,0.018 -0.324,-1.978 -0.511,-1.978 l -0.049,-7.83 30.658,-4.944 1.004,-14.374 c 0.203,-2.91 2.551,-5.263 5.463,-5.472 l 38.551,-2.75 c 0.146,-0.01 0.29,-0.016 0.434,-0.016 2.897,0 5.401,2.166 5.825,5.038 l 1.959,13.286 h 28.005 l 1.959,-13.286 c 0.423,-2.871 2.93,-5.037 5.831,-5.037 0.142,0 0.284,0.005 0.423,0.015 l 38.556,2.75 c 2.911,0.209 5.26,2.562 5.463,5.472 l 1.003,14.374 30.645,4.966 z" + style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path80" + inkscape:connector-curvature="0" /> + </g> + <g + id="g82-3" + transform="matrix(0.06307836,0,0,-0.06307664,1.3279404,1043.5689)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 v -47.514 -6.035 -5.492 c 0.108,-0.001 0.216,-0.005 0.323,-0.015 l 36.196,-3.49 c 1.896,-0.183 3.382,-1.709 3.514,-3.609 l 1.116,-15.978 31.574,-2.253 2.175,14.747 c 0.282,1.912 1.922,3.329 3.856,3.329 h 38.188 c 1.933,0 3.573,-1.417 3.855,-3.329 l 2.175,-14.747 31.575,2.253 1.115,15.978 c 0.133,1.9 1.618,3.425 3.514,3.609 l 36.182,3.49 c 0.107,0.01 0.214,0.014 0.322,0.015 v 4.711 l 0.015,0.005 V 0 h 0.134 c 4.795,6.12 9.232,12.569 13.487,19.449 -5.651,9.62 -12.575,18.217 -19.976,26.182 -6.864,-3.455 -13.531,-7.369 -19.828,-11.534 -3.151,3.132 -6.7,5.694 -10.186,8.372 -3.425,2.751 -7.285,4.768 -10.946,7.118 1.09,8.117 1.629,16.108 1.846,24.448 -9.446,4.754 -19.519,7.906 -29.708,10.17 -4.068,-6.837 -7.788,-14.241 -11.028,-21.479 -3.842,0.642 -7.702,0.88 -11.567,0.926 v 0.006 c -0.027,0 -0.052,-0.006 -0.075,-0.006 -0.024,0 -0.049,0.006 -0.073,0.006 V 63.652 C 93.903,63.606 90.046,63.368 86.203,62.726 82.965,69.964 79.247,77.368 75.173,84.205 64.989,81.941 54.915,78.789 45.47,74.035 45.686,65.695 46.225,57.704 47.318,49.587 43.65,47.237 39.795,45.22 36.369,42.469 32.888,39.791 29.333,37.229 26.181,34.097 19.884,38.262 13.219,42.176 6.353,45.631 -1.048,37.666 -7.968,29.069 -13.621,19.449 -9.368,12.569 -4.928,6.12 -0.134,0 Z" + style="fill:#478cbf;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path84-6" + inkscape:connector-curvature="0" /> + </g> + <g + id="g86-7" + transform="matrix(0.06307836,0,0,-0.06307664,11.62285,1047.9836)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 -1.121,-16.063 c -0.135,-1.936 -1.675,-3.477 -3.611,-3.616 l -38.555,-2.751 c -0.094,-0.007 -0.188,-0.01 -0.281,-0.01 -1.916,0 -3.569,1.406 -3.852,3.33 l -2.211,14.994 H -81.09 l -2.211,-14.994 c -0.297,-2.018 -2.101,-3.469 -4.133,-3.32 l -38.555,2.751 c -1.936,0.139 -3.476,1.68 -3.611,3.616 L -130.721,0 -163.268,3.138 c 0.015,-3.498 0.06,-7.33 0.06,-8.093 0,-34.374 43.605,-50.896 97.781,-51.086 h 0.066 0.067 c 54.176,0.19 97.766,16.712 97.766,51.086 0,0.777 0.047,4.593 0.063,8.093 z" + style="fill:#478cbf;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path88-5" + inkscape:connector-curvature="0" /> + </g> + <g + id="g90-3" + transform="matrix(0.06307836,0,0,-0.06307664,5.6393685,1045.0806)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c 0,-12.052 -9.765,-21.815 -21.813,-21.815 -12.042,0 -21.81,9.763 -21.81,21.815 0,12.044 9.768,21.802 21.81,21.802 C -9.765,21.802 0,12.044 0,0" + style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path92-5" + inkscape:connector-curvature="0" /> + </g> + <g + id="g94-6" + transform="matrix(0.06307836,0,0,-0.06307664,5.3082938,1045.1623)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c 0,-7.994 -6.479,-14.473 -14.479,-14.473 -7.996,0 -14.479,6.479 -14.479,14.473 0,7.994 6.483,14.479 14.479,14.479 C -6.479,14.479 0,7.994 0,0" + style="fill:#414042;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path96-2" + inkscape:connector-curvature="0" /> + </g> + <g + id="g98-9" + transform="matrix(0.06307836,0,0,-0.06307664,7.4998997,1046.5818)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c -3.878,0 -7.021,2.858 -7.021,6.381 v 20.081 c 0,3.52 3.143,6.381 7.021,6.381 3.878,0 7.028,-2.861 7.028,-6.381 V 6.381 C 7.028,2.858 3.878,0 0,0" + style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path100-1" + inkscape:connector-curvature="0" /> + </g> + <g + id="g102-2" + transform="matrix(0.06307836,0,0,-0.06307664,9.3606615,1045.0806)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c 0,-12.052 9.765,-21.815 21.815,-21.815 12.041,0 21.808,9.763 21.808,21.815 0,12.044 -9.767,21.802 -21.808,21.802 C 9.765,21.802 0,12.044 0,0" + style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path104-7" + inkscape:connector-curvature="0" /> + </g> + <g + id="g106-0" + transform="matrix(0.06307836,0,0,-0.06307664,9.6918191,1045.1623)" + style="stroke-width:19.8168869"> + <path + d="m 0,0 c 0,-7.994 6.477,-14.473 14.471,-14.473 8.002,0 14.479,6.479 14.479,14.473 0,7.994 -6.477,14.479 -14.479,14.479 C 6.477,14.479 0,7.994 0,0" + style="fill:#414042;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:19.8168869" + id="path108-9" + inkscape:connector-curvature="0" /> + </g> + <path + inkscape:connector-curvature="0" + id="path4392" + d="m 4.3227149,1042.5597 a 2.5297459,2.5296773 0 0 0 -2.5297461,2.5297 2.5297459,2.5296773 0 0 0 2.5297461,2.5297 2.5297459,2.5296773 0 0 0 2.5297463,-2.5297 2.5297459,2.5296773 0 0 0 -2.5297463,-2.5297 z m 0,0.5084 a 2.0213759,2.021321 0 0 1 2.0213758,2.0213 2.0213759,2.021321 0 0 1 -2.0213758,2.0213 2.0213759,2.021321 0 0 1 -2.0213757,-2.0213 2.0213759,2.021321 0 0 1 2.0213757,-2.0213 z" + style="opacity:1;fill:#414042;fill-opacity:1;stroke:none;stroke-width:1.94780529;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter4200);enable-background:new" /> + <path + style="opacity:1;fill:#414042;fill-opacity:1;stroke:none;stroke-width:1.94780529;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;filter:url(#filter4200);enable-background:new" + d="m 10.679126,1042.5597 a 2.5297459,2.5296773 0 0 0 -2.5297472,2.5297 2.5297459,2.5296773 0 0 0 2.5297472,2.5297 2.5297459,2.5296773 0 0 0 2.529744,-2.5297 2.5297459,2.5296773 0 0 0 -2.529744,-2.5297 z m 0,0.5084 a 2.0213759,2.021321 0 0 1 2.021373,2.0213 2.0213759,2.021321 0 0 1 -2.021373,2.0213 2.0213759,2.021321 0 0 1 -2.0213767,-2.0213 2.0213759,2.021321 0 0 1 2.0213767,-2.0213 z" + id="path4403" + inkscape:connector-curvature="0" /> + <rect + style="opacity:1;fill:#414042;fill-opacity:1;stroke:none;stroke-width:5.625;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.44162436" + id="rect4160" + width="2.3136585" + height="0.53352129" + x="6.3440895" + y="1043.9767" /> + </g> +</svg> diff --git a/editor/icons/source/icon_gradient_texture.svg b/editor/icons/source/icon_gradient_texture.svg new file mode 100644 index 0000000000..efc48bb778 --- /dev/null +++ b/editor/icons/source/icon_gradient_texture.svg @@ -0,0 +1,160 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_key.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_gradient_texture.svg"> + <defs + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient848"> + <stop + style="stop-color:#e0e0e0;stop-opacity:1;" + offset="0" + id="stop844" /> + <stop + style="stop-color:#e0e0e0;stop-opacity:0;" + offset="1" + id="stop846" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient848" + id="linearGradient850" + x1="10" + y1="1" + x2="10" + y2="15" + gradientUnits="userSpaceOnUse" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="3.5928314" + inkscape:cy="6.4466253" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="opacity:1;fill:url(#linearGradient850);fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + d="M 2 1 A 1 1 0 0 0 1 2 L 1 14 A 1 1 0 0 0 2 15 L 14 15 A 1 1 0 0 0 15 14 L 15 2 A 1 1 0 0 0 14 1 L 2 1 z M 3 3 L 13 3 L 13 11 L 3 11 L 3 3 z " + transform="translate(0,1036.3622)" + id="rect4156" /> + <rect + y="1043.3622" + x="6" + height="1" + width="2" + id="rect4197" + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" /> + <rect + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + id="rect4199" + width="2" + height="2.0000174" + x="6" + y="1044.3622" /> + <rect + y="1045.3622" + x="4" + height="1" + width="2" + id="rect4201" + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" /> + <rect + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + id="rect4203" + width="2" + height="2.0000174" + x="8" + y="1044.3622" /> + <rect + y="1044.3622" + x="10" + height="2.0000174" + width="2" + id="rect4205" + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" /> + <rect + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + id="rect4207" + width="3" + height="2.0000174" + x="8" + y="1042.3622" /> + <rect + y="1041.3622" + x="9" + height="1" + width="1" + id="rect4217" + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" /> + <rect + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + id="rect4219" + width="1" + height="1" + x="5" + y="1044.3622" /> + </g> +</svg> diff --git a/editor/icons/source/icon_graph_scalars_to_vec.svg b/editor/icons/source/icon_graph_scalars_to_vec.svg index 0f2994a606..d951a41832 100644 --- a/editor/icons/source/icon_graph_scalars_to_vec.svg +++ b/editor/icons/source/icon_graph_scalars_to_vec.svg @@ -7,6 +7,7 @@ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="14" @@ -14,13 +15,35 @@ viewBox="0 0 14 14" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot-design/assets/icons/svg/icon_graph_scalar_uniform.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" sodipodi:docname="icon_graph_scalars_to_vec.svg"> <defs - id="defs4" /> + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient834"> + <stop + id="stop832" + offset="0" + style="stop-color:#cf68ea;stop-opacity:1" /> + <stop + id="stop830" + offset="1" + style="stop-color:#b8ea68;stop-opacity:1;" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient834" + id="linearGradient836" + x1="1" + y1="7" + x2="13.014242" + y2="7" + gradientUnits="userSpaceOnUse" /> + </defs> <sodipodi:namedview id="base" pagecolor="#ffffff" @@ -29,8 +52,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="4.4222736" - inkscape:cy="8.4198974" + inkscape:cx="6.5785236" + inkscape:cy="9.2011474" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +65,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -63,7 +86,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -73,22 +96,9 @@ id="layer1" transform="translate(0,-1038.3622)"> <path - style="fill:none;fill-rule:evenodd;stroke:#b8ea68;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 7,1045.3622 5,0" - id="path4154" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cc" /> - <path - style="fill:none;fill-rule:evenodd;stroke:#cf68ea;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 2,1040.3622 5,0 0,10 -5,0" - id="path4155" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cccc" /> - <path - style="fill:none;fill-rule:evenodd;stroke:#cf68ea;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 7,1045.3622 -5,0" - id="path4157" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cc" /> + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:url(#linearGradient836);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 1.9902344 0.99023438 A 1.0001 1.0001 0 0 0 1.2929688 2.7070312 L 4.5859375 6 L 2 6 A 1.0001 1.0001 0 1 0 2 8 L 4.5859375 8 L 1.2929688 11.292969 A 1.0001 1.0001 0 1 0 2.7070312 12.707031 L 7.4140625 8 L 12 8 A 1.0001 1.0001 0 1 0 12 6 L 7.4140625 6 L 2.7070312 1.2929688 A 1.0001 1.0001 0 0 0 1.9902344 0.99023438 z " + transform="translate(0,1038.3622)" + id="path4154" /> </g> </svg> diff --git a/editor/icons/source/icon_graph_vec_to_scalars.svg b/editor/icons/source/icon_graph_vec_to_scalars.svg index fb58db9d78..8bddf89b2d 100644 --- a/editor/icons/source/icon_graph_vec_to_scalars.svg +++ b/editor/icons/source/icon_graph_vec_to_scalars.svg @@ -7,6 +7,7 @@ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="14" @@ -14,13 +15,36 @@ viewBox="0 0 14 14" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot-design/assets/icons/svg/icon_graph_scalar_uniform.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" sodipodi:docname="icon_graph_vec_to_scalars.svg"> <defs - id="defs4" /> + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient834"> + <stop + id="stop832" + offset="0" + style="stop-color:#cf68ea;stop-opacity:1" /> + <stop + id="stop830" + offset="1" + style="stop-color:#b8ea68;stop-opacity:1;" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient834" + id="linearGradient836" + x1="1" + y1="7" + x2="13.014242" + y2="7" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,13.999754,1038.3622)" /> + </defs> <sodipodi:namedview id="base" pagecolor="#ffffff" @@ -29,8 +53,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="4.4222736" - inkscape:cy="8.4198974" + inkscape:cx="6.5785236" + inkscape:cy="9.2011474" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +66,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -73,22 +97,9 @@ id="layer1" transform="translate(0,-1038.3622)"> <path - style="fill:none;fill-rule:evenodd;stroke:#b8ea68;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 7,1045.3622 -5,0" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:url(#linearGradient836);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 12.00952,1039.3524 a 1.0001,1.0001 0 0 1 0.697265,1.7168 l -3.2929685,3.293 h 2.5859375 a 1.0001,1.0001 0 1 1 0,2 H 9.4138165 l 3.2929685,3.293 a 1.0001,1.0001 0 1 1 -1.414062,1.414 l -4.7070315,-4.707 H 1.999754 a 1.0001,1.0001 0 1 1 0,-2 h 4.5859375 l 4.7070315,-4.707 a 1.0001,1.0001 0 0 1 0.716797,-0.3028 z" id="path4154" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cc" /> - <path - style="fill:none;fill-rule:evenodd;stroke:#cf68ea;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 12,1040.3622 -5,0 0,10 5,0" - id="path4155" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cccc" /> - <path - style="fill:none;fill-rule:evenodd;stroke:#cf68ea;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 7,1045.3622 5,0" - id="path4157" - inkscape:connector-curvature="0" - sodipodi:nodetypes="cc" /> + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_graph_vecs_to_xform.svg b/editor/icons/source/icon_graph_vecs_to_xform.svg index f8ba3eb4b8..1321766117 100644 --- a/editor/icons/source/icon_graph_vecs_to_xform.svg +++ b/editor/icons/source/icon_graph_vecs_to_xform.svg @@ -7,6 +7,7 @@ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="14" @@ -14,13 +15,36 @@ viewBox="0 0 14 14" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot-design/assets/icons/svg/icon_graph_scalar_uniform.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" sodipodi:docname="icon_graph_vecs_to_xform.svg"> <defs - id="defs4" /> + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient834"> + <stop + style="stop-color:#b8ea68;stop-opacity:1;" + offset="0" + id="stop830" /> + <stop + style="stop-color:#ea686c;stop-opacity:1" + offset="1" + id="stop832" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient834" + id="linearGradient836" + x1="1" + y1="7" + x2="13.014242" + y2="7" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(7.4681641e-4,1038.3622)" /> + </defs> <sodipodi:namedview id="base" pagecolor="#ffffff" @@ -29,8 +53,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="2.8910236" - inkscape:cy="10.294897" + inkscape:cx="3.3597736" + inkscape:cy="10.326147" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +66,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -73,14 +97,9 @@ id="layer1" transform="translate(0,-1038.3622)"> <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#ea686c;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 7,1044.3613 a 1.0001,1.0001 0 1 0 0,2 l 5,0 a 1.0001,1.0001 0 1 0 0,-2 l -5,0 z" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:url(#linearGradient836);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 1.9909808,1039.3524 a 1.0001,1.0001 0 0 0 -0.697265,1.7168 l 3.2929683,3.293 H 2.0007468 a 1.0001,1.0001 0 1 0 0,2 h 2.5859373 l -3.2929683,3.293 a 1.0001,1.0001 0 1 0 1.414062,1.414 l 4.7070313,-4.707 h 4.5859379 a 1.0001,1.0001 0 1 0 0,-2 H 7.4148091 l -4.7070313,-4.707 a 1.0001,1.0001 0 0 0 -0.716797,-0.3028 z" id="path4154" inkscape:connector-curvature="0" /> - <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#b8ea68;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="M 2 1 A 1.0001 1.0001 0 1 0 2 3 L 6 3 L 6 6 L 2 6 A 1.0001 1.0001 0 1 0 2 8 L 6 8 L 6 11 L 2 11 A 1.0001 1.0001 0 1 0 2 13 L 7 13 A 1.0001 1.0001 0 0 0 8 12 L 8 7.1679688 A 1.0001 1.0001 0 0 0 8 6.8398438 L 8 2 A 1.0001 1.0001 0 0 0 7 1 L 2 1 z " - transform="translate(0,1038.3622)" - id="path4155" /> </g> </svg> diff --git a/editor/icons/source/icon_graph_xform_to_vecs.svg b/editor/icons/source/icon_graph_xform_to_vecs.svg index cc113e72fd..45754c8a44 100644 --- a/editor/icons/source/icon_graph_xform_to_vecs.svg +++ b/editor/icons/source/icon_graph_xform_to_vecs.svg @@ -7,6 +7,7 @@ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" + xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" width="14" @@ -14,13 +15,36 @@ viewBox="0 0 14 14" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot-design/assets/icons/svg/icon_graph_scalar_uniform.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" sodipodi:docname="icon_graph_xform_to_vecs.svg"> <defs - id="defs4" /> + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient834"> + <stop + style="stop-color:#b8ea68;stop-opacity:1;" + offset="0" + id="stop830" /> + <stop + style="stop-color:#ea686c;stop-opacity:1" + offset="1" + id="stop832" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient834" + id="linearGradient836" + x1="1" + y1="7" + x2="13.014242" + y2="7" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,13.999754,1038.3622)" /> + </defs> <sodipodi:namedview id="base" pagecolor="#ffffff" @@ -29,8 +53,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="-2.5152264" - inkscape:cy="10.232397" + inkscape:cx="3.3597736" + inkscape:cy="10.326147" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +66,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -73,14 +97,9 @@ id="layer1" transform="translate(0,-1038.3622)"> <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#ea686c;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 7,1044.3613 a 1.0001,1.0001 0 1 1 0,2 l -5,0 a 1.0001,1.0001 0 1 1 0,-2 l 5,0 z" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:url(#linearGradient836);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 12.00952,1039.3524 a 1.0001,1.0001 0 0 1 0.697265,1.7168 l -3.2929683,3.293 h 2.5859373 a 1.0001,1.0001 0 1 1 0,2 H 9.4138167 l 3.2929683,3.293 a 1.0001,1.0001 0 1 1 -1.414062,1.414 l -4.7070313,-4.707 H 1.999754 a 1.0001,1.0001 0 1 1 0,-2 h 4.5859377 l 4.7070313,-4.707 a 1.0001,1.0001 0 0 1 0.716797,-0.3028 z" id="path4154" inkscape:connector-curvature="0" /> - <path - style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#b8ea68;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" - d="m 12,1039.3622 a 1.0001,1.0001 0 1 1 0,2 l -4,0 0,3 4,0 a 1.0001,1.0001 0 1 1 0,2 l -4,0 0,3 4,0 a 1.0001,1.0001 0 1 1 0,2 l -5,0 a 1.0001,1.0001 0 0 1 -1,-1 l 0,-4.832 a 1.0001,1.0001 0 0 1 0,-0.3282 l 0,-4.8398 a 1.0001,1.0001 0 0 1 1,-1 l 5,0 z" - id="path4155" - inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_hslider_bg.svg b/editor/icons/source/icon_hslider_bg.svg new file mode 100644 index 0000000000..10bea12ab8 --- /dev/null +++ b/editor/icons/source/icon_hslider_bg.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 unknown" + sodipodi:docname="icon_hslider_bg.svg" + inkscape:export-filename="/mnt/2TB/Development/godot_dev/editor/icons/2x/icon_hslider_bg.png" + inkscape:export-xdpi="96" + inkscape:export-ydpi="96"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="4.166346" + inkscape:cy="6.5721301" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="929" + inkscape:window-height="897" + inkscape:window-x="436" + inkscape:window-y="155" + inkscape:window-maximized="0" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <path + style="fill:#000000;fill-opacity:0.19607843;stroke:none;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 4 5 A 3 3 0 0 0 1 8 A 3 3 0 0 0 4 11 L 12 11 A 3 3 0 0 0 15 8 A 3 3 0 0 0 12 5 L 4 5 z " + transform="translate(0,1036.3623)" + id="path814" /> + </g> +</svg> diff --git a/editor/icons/source/icon_hsplitter.svg b/editor/icons/source/icon_hsplitter.svg new file mode 100644 index 0000000000..01c893fc56 --- /dev/null +++ b/editor/icons/source/icon_hsplitter.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="8" + height="64" + viewBox="0 0 8 64" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="hsplitter.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="11.313709" + inkscape:cx="-2.0338296" + inkscape:cy="39.22669" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-988.3622)"> + <path + style="fill:none;stroke:#ffffff;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:0.39215687;stroke-miterlimit:4;stroke-dasharray:none" + d="m 4,990.3622 v 60" + id="path814" + inkscape:connector-curvature="0" /> + </g> +</svg> diff --git a/editor/icons/source/icon_key_hover.svg b/editor/icons/source/icon_key_hover.svg index c3f34a781b..10caa81968 100644 --- a/editor/icons/source/icon_key_hover.svg +++ b/editor/icons/source/icon_key_hover.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_dependency_changed_hl.png" inkscape:export-xdpi="45" inkscape:export-ydpi="45" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="43.417341" - inkscape:cx="0.40602789" - inkscape:cy="4.9542089" + inkscape:zoom="61.401392" + inkscape:cx="1.5457638" + inkscape:cy="2.7778126" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -68,10 +68,14 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1044.3622)"> - <path - style="opacity:1;fill:#8fdeef;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 4 0 A 4 3.9999914 0 0 0 0 4 A 4 3.9999914 0 0 0 4 8 A 4 3.9999914 0 0 0 8 4 A 4 3.9999914 0 0 0 4 0 z " - transform="translate(0,1044.3622)" - id="path4137" /> + <rect + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.76284212;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect814" + width="6.1027369" + height="6.1027369" + x="-741.52698" + y="741.08105" + ry="0.76285541" + transform="rotate(-45)" /> </g> </svg> diff --git a/editor/icons/source/icon_key_selected.svg b/editor/icons/source/icon_key_selected.svg index c3f01dbec8..62180cca5b 100644 --- a/editor/icons/source/icon_key_selected.svg +++ b/editor/icons/source/icon_key_selected.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_dependency_changed_hl.png" inkscape:export-xdpi="45" inkscape:export-ydpi="45" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="43.417341" - inkscape:cx="3.4232555" - inkscape:cy="4.5626603" + inkscape:cx="-0.88377936" + inkscape:cy="3.8025953" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -68,10 +68,14 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1044.3622)"> - <path - style="opacity:1;fill:#e7e7e7;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 4 0 A 4 3.9999914 0 0 0 0 4 A 4 3.9999914 0 0 0 4 8 A 4 3.9999914 0 0 0 8 4 A 4 3.9999914 0 0 0 4 0 z " - transform="translate(0,1044.3622)" - id="path4137" /> + <rect + style="fill:#84c2ff;fill-opacity:1;stroke:none;stroke-width:0.76284212;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect814" + width="6.1027369" + height="6.1027369" + x="-741.52698" + y="741.08112" + ry="0.76285541" + transform="rotate(-45)" /> </g> </svg> diff --git a/editor/icons/source/icon_key_value.svg b/editor/icons/source/icon_key_value.svg index 5e6333e54b..21780cc695 100644 --- a/editor/icons/source/icon_key_value.svg +++ b/editor/icons/source/icon_key_value.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_dependency_changed_hl.png" inkscape:export-xdpi="45" inkscape:export-ydpi="45" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="43.417341" - inkscape:cx="3.2850619" - inkscape:cy="5.046338" + inkscape:cx="3.6075137" + inkscape:cy="3.8486599" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -68,10 +68,14 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1044.3622)"> - <path - style="opacity:1;fill:#3da9bf;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 4 0 A 4 3.9999914 0 0 0 0 4 A 4 3.9999914 0 0 0 4 8 A 4 3.9999914 0 0 0 8 4 A 4 3.9999914 0 0 0 4 0 z " - transform="translate(0,1044.3622)" - id="path4137" /> + <rect + style="fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:0.76284212;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect814" + width="6.1027369" + height="6.1027369" + x="-741.52698" + y="741.08105" + ry="0.76285541" + transform="rotate(-45)" /> </g> </svg> diff --git a/editor/icons/source/icon_key_xform.svg b/editor/icons/source/icon_key_xform.svg index 06a282f705..37de107284 100644 --- a/editor/icons/source/icon_key_xform.svg +++ b/editor/icons/source/icon_key_xform.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_dependency_changed_hl.png" inkscape:export-xdpi="45" inkscape:export-ydpi="45" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="43.417341" - inkscape:cx="3.2850619" - inkscape:cy="5.046338" + inkscape:cx="4.6209337" + inkscape:cy="3.8256276" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -68,10 +68,14 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1044.3622)"> - <path - style="opacity:1;fill:#bf523c;fill-opacity:1;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="M 4 0 A 4 3.9999914 0 0 0 0 4 A 4 3.9999914 0 0 0 4 8 A 4 3.9999914 0 0 0 8 4 A 4 3.9999914 0 0 0 4 0 z " - transform="translate(0,1044.3622)" - id="path4137" /> + <rect + style="fill:#ea686c;fill-opacity:1;stroke:none;stroke-width:0.76284212;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect814" + width="6.1027369" + height="6.1027369" + x="-741.52698" + y="741.08112" + ry="0.76285541" + transform="rotate(-45)" /> </g> </svg> diff --git a/editor/icons/source/icon_mini_basis.svg b/editor/icons/source/icon_mini_basis.svg new file mode 100644 index 0000000000..a9d3be82ea --- /dev/null +++ b/editor/icons/source/icon_mini_basis.svg @@ -0,0 +1,204 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="12" + viewBox="0 0 16 12" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_mini_basis.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627418" + inkscape:cx="13.930099" + inkscape:cy="4.8789967" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-nodes="true" + inkscape:snap-smooth-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3622)"> + <rect + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4364" + width="2" + height="5.9999666" + x="-2" + y="1044.3621" + transform="scale(-1,1)" /> + <rect + y="1044.3621" + x="-2" + height="2.0000174" + width="1" + id="rect4368" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + transform="scale(-1,1)" /> + <path + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 2,1044.3622 a 3,3 0 0 1 3,3 H 3 a 1.0000174,1.0000174 0 0 0 -1,-1 z" + id="path4370" + inkscape:connector-curvature="0" /> + <path + inkscape:connector-curvature="0" + id="path4378" + d="m 2,1050.3622 a 3,3 0 0 0 3,-3 H 3 a 1.0000174,1.0000174 0 0 1 -1,1 z" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + transform="scale(-1,1)" + y="1042.3621" + x="-2" + height="3.9999492" + width="2" + id="rect4384" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect857" + width="2" + height="2.0000174" + x="-9" + y="1044.3622" + transform="scale(-1,1)" /> + <path + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path859" + sodipodi:type="arc" + sodipodi:cx="7" + sodipodi:cy="1046.3622" + sodipodi:rx="2" + sodipodi:ry="2" + sodipodi:start="1.5707963" + sodipodi:end="4.712389" + sodipodi:open="true" + d="m 7.0000001,1048.3622 a 2,2 0 0 1 -1.7320509,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.7320508,-1" /> + <path + d="m -6.9999999,1050.3622 a 2,2 0 0 1 -1.7320509,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.7320508,-1" + sodipodi:open="true" + sodipodi:end="4.712389" + sodipodi:start="1.5707963" + sodipodi:ry="2" + sodipodi:rx="2" + sodipodi:cy="1048.3622" + sodipodi:cx="-7" + sodipodi:type="arc" + id="path861" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + transform="scale(-1,1)" /> + <rect + transform="scale(-1,1)" + y="1048.3622" + x="-7" + height="2.0000174" + width="2" + id="rect863" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#eef39f;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4412" + width="2" + height="3.9999492" + x="10" + y="1046.3622" /> + <rect + y="1042.3622" + x="10" + height="1.9999928" + width="2" + id="rect4432" + style="fill:#eef39f;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + transform="scale(-1,1)" + y="1044.3622" + x="-16" + height="2.0000174" + width="2" + id="rect902" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + d="m 14,1048.3622 a 2,2 0 0 1 -1.732051,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.732051,-1" + sodipodi:open="true" + sodipodi:end="4.712389" + sodipodi:start="1.5707963" + sodipodi:ry="2" + sodipodi:rx="2" + sodipodi:cy="1046.3622" + sodipodi:cx="14" + sodipodi:type="arc" + id="path904" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + transform="scale(-1,1)" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path906" + sodipodi:type="arc" + sodipodi:cx="-14" + sodipodi:cy="1048.3622" + sodipodi:rx="2" + sodipodi:ry="2" + sodipodi:start="1.5707963" + sodipodi:end="4.712389" + sodipodi:open="true" + d="m -14,1050.3622 a 2,2 0 0 1 -1.732051,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.732051,-1" /> + <rect + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect908" + width="2" + height="2.0000174" + x="-14" + y="1048.3622" + transform="scale(-1,1)" /> + </g> +</svg> diff --git a/editor/icons/source/icon_mini_matrix3.svg b/editor/icons/source/icon_mini_matrix3.svg index 592230d13c..27adb40b17 100644 --- a/editor/icons/source/icon_mini_matrix3.svg +++ b/editor/icons/source/icon_mini_matrix3.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 12" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" inkscape:export-xdpi="45" inkscape:export-ydpi="45" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="32.000001" - inkscape:cx="4.071303" - inkscape:cy="4.582959" + inkscape:zoom="22.627418" + inkscape:cx="13.930099" + inkscape:cy="4.8789967" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -70,71 +70,135 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1040.3622)"> + <rect + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4364" + width="2" + height="5.9999666" + x="-2" + y="1044.3621" + transform="scale(-1,1)" /> + <rect + y="1044.3621" + x="-2" + height="2.0000174" + width="1" + id="rect4368" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + transform="scale(-1,1)" /> <path style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 12.00042,1044.3622 a 1,1 0 0 1 1,1 1,1 0 0 1 -1,1 l 0,2 a 3,3 0 0 0 2.597656,-1.5 3,3 0 0 0 0.226563,-2.5 l -2.824219,0 z" - id="path4753" + d="m 2,1044.3622 a 3,3 0 0 1 3,3 H 3 a 1.0000174,1.0000174 0 0 0 -1,-1 z" + id="path4370" inkscape:connector-curvature="0" /> <path inkscape:connector-curvature="0" - id="path4757" - d="m 12.00042,1046.3622 0,2 a 1,1 0 0 1 1,1 1,1 0 0 1 -1,1 l 0,2 a 3,3 0 0 0 2.597656,-1.5 3,3 0 0 0 0,-3 3,3 0 0 0 -2.597656,-1.5 z" + id="path4378" + d="m 2,1050.3622 a 3,3 0 0 0 3,-3 H 3 a 1.0000174,1.0000174 0 0 1 -1,1 z" style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> - <path - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 3,1044.3622 a 3,3 0 0 1 3,3 l -2,0 a 1.0000174,1.0000174 0 0 0 -1,-1 l 0,-2 z" - id="path4771" - inkscape:connector-curvature="0" /> <rect - y="-1050.3622" - x="4" - height="3" + transform="scale(-1,1)" + y="1042.3621" + x="-2" + height="3.9999492" width="2" - id="rect4773" - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - transform="scale(1,-1)" /> + id="rect4384" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> <rect - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - id="rect4775" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect857" + width="2" + height="2.0000174" + x="-9" + y="1044.3622" + transform="scale(-1,1)" /> + <path + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path859" + sodipodi:type="arc" + sodipodi:cx="7" + sodipodi:cy="1046.3622" + sodipodi:rx="2" + sodipodi:ry="2" + sodipodi:start="1.5707963" + sodipodi:end="4.712389" + sodipodi:open="true" + d="m 7.0000001,1048.3622 a 2,2 0 0 1 -1.7320509,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.7320508,-1" /> + <path + d="m -6.9999999,1050.3622 a 2,2 0 0 1 -1.7320509,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.7320508,-1" + sodipodi:open="true" + sodipodi:end="4.712389" + sodipodi:start="1.5707963" + sodipodi:ry="2" + sodipodi:rx="2" + sodipodi:cy="1048.3622" + sodipodi:cx="-7" + sodipodi:type="arc" + id="path861" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + transform="scale(-1,1)" /> + <rect + transform="scale(-1,1)" + y="1048.3622" + x="-7" + height="2.0000174" width="2" - height="5.9999828" - x="1" - y="-1050.3622" - transform="scale(1,-1)" /> + id="rect863" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> <rect - transform="scale(1,-1)" - y="-1050.3622" - x="4" - height="5.9999828" + style="fill:#eef39f;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4412" width="2" - id="rect4777" - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> - <path - inkscape:connector-curvature="0" - id="path4779" - d="m 6,1044.3622 a 3,3 0 0 1 3,3 l -2,0 a 1.0000174,1.0000174 0 0 0 -1,-1 l 0,-2 z" - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + height="3.9999492" + x="10" + y="1046.3622" /> <rect - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - id="rect4781" + y="1042.3622" + x="10" + height="1.9999928" width="2" - height="3.0000002" - x="7" - y="-1050.3622" - transform="scale(1,-1)" /> + id="rect4432" + style="fill:#eef39f;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> <rect - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - id="rect4783" - width="4.0004196" - height="2" - x="11" - y="1043.3622" /> + transform="scale(-1,1)" + y="1044.3622" + x="-16" + height="2.0000174" + width="2" + id="rect902" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + d="m 14,1048.3622 a 2,2 0 0 1 -1.732051,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.732051,-1" + sodipodi:open="true" + sodipodi:end="4.712389" + sodipodi:start="1.5707963" + sodipodi:ry="2" + sodipodi:rx="2" + sodipodi:cy="1046.3622" + sodipodi:cx="14" + sodipodi:type="arc" + id="path904" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + transform="scale(-1,1)" + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path906" + sodipodi:type="arc" + sodipodi:cx="-14" + sodipodi:cy="1048.3622" + sodipodi:rx="2" + sodipodi:ry="2" + sodipodi:start="1.5707963" + sodipodi:end="4.712389" + sodipodi:open="true" + d="m -14,1050.3622 a 2,2 0 0 1 -1.732051,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.732051,-1" /> <rect - y="1050.3622" - x="11" - height="2" - width="1" - id="rect4173" - style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + style="fill:#e3ec69;fill-opacity:1;stroke:none;stroke-width:1.41422868;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect908" + width="2" + height="2.0000174" + x="-14" + y="1048.3622" + transform="scale(-1,1)" /> </g> </svg> diff --git a/editor/icons/source/icon_mini_transform2D.svg b/editor/icons/source/icon_mini_transform2D.svg new file mode 100644 index 0000000000..e8e38f1256 --- /dev/null +++ b/editor/icons/source/icon_mini_transform2D.svg @@ -0,0 +1,117 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="12" + viewBox="0 0 16 12" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_add_track.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="icon_mini_transform2D.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627418" + inkscape:cx="6.4108823" + inkscape:cy="5.363647" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-nodes="true" + inkscape:snap-smooth-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3622)"> + <rect + y="1048.3622" + x="5" + height="2" + width="5" + id="rect4763" + style="fill:#ddf4aa;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + sodipodi:open="true" + d="m 7.0000001,1050.3622 a 2,2 0 0 1 -1.7320509,-1 2,2 0 0 1 0,-2 2,2 0 0 1 1.7320508,-1" + sodipodi:end="4.712389" + sodipodi:start="1.5707963" + sodipodi:ry="2" + sodipodi:rx="2" + sodipodi:cy="1048.3622" + sodipodi:cx="7" + sodipodi:type="arc" + id="path4765" + style="fill:#ddf4aa;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + inkscape:connector-curvature="0" + id="path4767" + d="m 7,1042.3622 v 2 a 1,1 0 0 1 1,1 1,1 0 0 1 -1,1 v 2 a 3,3 0 0 0 2.597656,-1.5 3,3 0 0 0 0,-3 A 3,3 0 0 0 7,1042.3622 Z" + style="fill:#ddf4aa;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#c4ec69;fill-opacity:1;stroke:none;stroke-width:1.85164022;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect823" + width="6" + height="2" + x="0" + y="1042.3622" /> + <rect + y="1043.3622" + x="2" + height="7.0000172" + width="2" + id="rect825" + style="fill:#c4ec69;fill-opacity:1;stroke:none;stroke-width:2.00000238;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <path + style="fill:#c4ec69;fill-opacity:1;stroke:none;stroke-width:2.1380899;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 10 2 L 10 10 L 12 10 A 4 4 0 0 0 15.464844 8 A 4 4 0 0 0 15.464844 4 A 4 4 0 0 0 12 2 L 10 2 z M 12 4 A 2.0000174 2.0000174 0 0 1 13.732422 5 A 2.0000174 2.0000174 0 0 1 13.732422 7 A 2.0000174 2.0000174 0 0 1 12 8 L 12 4 z " + transform="translate(0,1040.3622)" + id="rect827" /> + </g> +</svg> diff --git a/editor/icons/source/icon_mirror_x.svg b/editor/icons/source/icon_mirror_x.svg index f24a630770..ca28fec4f8 100644 --- a/editor/icons/source/icon_mirror_x.svg +++ b/editor/icons/source/icon_mirror_x.svg @@ -14,11 +14,11 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_tool_move.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" - sodipodi:docname="icon_h_size.svg"> + sodipodi:docname="icon_mirror_x.svg"> <defs id="defs4" /> <sodipodi:namedview @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="7.1680801" - inkscape:cy="7.9718121" + inkscape:cx="2.7305801" + inkscape:cy="8.1905621" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -69,11 +69,21 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="m 4,7 0,-2 -3,3 3,3 0,-2 8,0 0,2 3,-3 -3,-3 0,2 z" - transform="translate(0,1036.3622)" - id="rect4140" + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 4,1042.3622 -2,2 2,2" + id="path816" inkscape:connector-curvature="0" - sodipodi:nodetypes="ccccccccccc" /> + sodipodi:nodetypes="ccc" /> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.99607843;stroke-miterlimit:4;stroke-dasharray:none" + d="M 2,1044.3622 H 13" + id="path818" + inkscape:connector-curvature="0" /> + <path + inkscape:connector-curvature="0" + id="path820" + d="m 12,1042.3622 2,2 -2,2" + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + sodipodi:nodetypes="ccc" /> </g> </svg> diff --git a/editor/icons/source/icon_mirror_y.svg b/editor/icons/source/icon_mirror_y.svg index bb913b84af..922caf6efc 100644 --- a/editor/icons/source/icon_mirror_y.svg +++ b/editor/icons/source/icon_mirror_y.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_tool_move.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="1.7618301" - inkscape:cy="7.9093121" + inkscape:cx="2.7305801" + inkscape:cy="8.1905621" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title /> + <dc:title></dc:title> </cc:Work> </rdf:RDF> </metadata> @@ -69,10 +69,9 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="m 7,1048.3622 -2,0 3,3 3,-3 -2,0 0,-8 2,0 -3,-3 -3,3 2,0 z" - id="rect4140" - inkscape:connector-curvature="0" - sodipodi:nodetypes="ccccccccccc" /> + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:0.99607843;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 11.012128,1048.3548 a 1.0001,1.0001 0 0 0 -1.7167967,-0.6973 l -0.2929688,0.293 v -7.1719 l 0.2929688,0.293 a 1.0001,1.0001 0 0 0 1.7148437,-0.7266 1.0001,1.0001 0 0 0 -0.300781,-0.6875 l -2.0000003,-2 a 1.0001,1.0001 0 0 0 -1.4140624,0 l -1.9999998,2 a 1.0001,1.0001 0 1 0 1.4140622,1.4141 l 0.2929688,-0.293 v 7.1719 l -0.2929688,-0.293 a 1.0001,1.0001 0 1 0 -1.4140622,1.4141 l 1.9999998,2 a 1.0001,1.0001 0 0 0 1.4140624,0 l 2.0000003,-2 a 1.0001,1.0001 0 0 0 0.302734,-0.7168 z" + id="path816" + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_move_down.svg b/editor/icons/source/icon_move_down.svg index e83a69ad50..911def98b8 100644 --- a/editor/icons/source/icon_move_down.svg +++ b/editor/icons/source/icon_move_down.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_arrow_left.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="22.627417" - inkscape:cx="4.2997855" - inkscape:cy="8.3620593" + inkscape:zoom="32" + inkscape:cx="-0.21847599" + inkscape:cy="8.1503711" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -62,7 +62,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -72,9 +72,14 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:#e0e0e0;fill-opacity:0.99607843;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" - d="m 8,1051.3622 -6,-7 4,0 0,-7 4,0 0,7 4,0 -6,7 z" - id="path4135" + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 4,1045.348 4,5 4,-5" + id="path814" + inkscape:connector-curvature="0" /> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" + d="m 8,1038.348 v 11" + id="path816" inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_move_up.svg b/editor/icons/source/icon_move_up.svg index 8f671a0d72..4e24791efb 100644 --- a/editor/icons/source/icon_move_up.svg +++ b/editor/icons/source/icon_move_up.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_arrow_left.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="22.627417" - inkscape:cx="4.2997855" - inkscape:cy="8.3620593" + inkscape:zoom="32" + inkscape:cx="5.8620142" + inkscape:cy="9.0057643" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -62,7 +62,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -72,9 +72,14 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:#e0e0e0;fill-opacity:0.99607843;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.99607843" - d="M 8 1 L 2 8 L 6 8 L 6 15 L 10 15 L 10 8 L 14 8 L 8 1 z " - transform="translate(0,1036.3622)" - id="path4135" /> + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:0.99607843;stroke-miterlimit:4;stroke-dasharray:none" + d="m 4,1043.3622 4,-5 4,5" + id="path814" + inkscape:connector-curvature="0" /> + <path + style="fill:none;stroke:#e0e0e0;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:0.99607843;stroke-miterlimit:4;stroke-dasharray:none" + d="m 8,1050.3622 v -11" + id="path816" + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_new.svg b/editor/icons/source/icon_new.svg index a37ba1be3f..d59dd3513a 100644 --- a/editor/icons/source/icon_new.svg +++ b/editor/icons/source/icon_new.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_new.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="16" - inkscape:cx="0.22745062" - inkscape:cy="11.330333" + inkscape:zoom="22.627417" + inkscape:cx="20.922744" + inkscape:cy="2.4022924" inkscape:document-units="px" inkscape:current-layer="layer1-8" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -76,11 +76,17 @@ inkscape:label="Layer 1" transform="translate(0,-1.6949463e-5)"> <path - sodipodi:nodetypes="ccccccccccc" - inkscape:connector-curvature="0" + style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 2,1 v 14 h 8 V 14 H 8 v -4 h 2 V 8 h 4 V 6 H 9 V 1 Z m 8,0 v 4 h 4 z" + transform="translate(0,1036.3622)" id="rect4158" - d="m 2,1037.3622 0,14 12,0 0,-9 -5,0 0,-5 z m 8,0 0,4 4,0 z" - style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + inkscape:connector-curvature="0" + sodipodi:nodetypes="ccccccccccccccccc" /> + <path + style="fill:#84ffb1;fill-opacity:1;stroke:none;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 11,1045.3622 v 2 H 9 v 2 h 2 v 2 h 2 v -2 h 2 v -2 h -2 v -2 z" + id="rect4485" + inkscape:connector-curvature="0" /> </g> </g> </svg> diff --git a/editor/icons/source/icon_option_arrow.svg b/editor/icons/source/icon_option_arrow.svg new file mode 100644 index 0000000000..5cd943e9e3 --- /dev/null +++ b/editor/icons/source/icon_option_arrow.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 12" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="option_arrow.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254834" + inkscape:cx="3.1667338" + inkscape:cy="5.9875884" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3622)"> + <path + inkscape:connector-curvature="0" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#ffffff;fill-opacity:0.78431374;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 9.9999996,1043.3583 c -0.2637796,0.01 -0.5144012,0.1165 -0.697265,0.3067 l -3.292969,3.2929 -3.2929688,-3.2929 C 2.5285367,1043.4714 2.2700113,1043.3622 2,1043.3622 c -0.8974208,2e-4 -1.34038281,1.0909 -0.6972656,1.7168 l 4,4 c 0.3905299,0.3904 1.0235325,0.3904 1.4140624,0 l 4.0000002,-4 c 0.657344,-0.6321 0.194906,-1.7422 -0.7167974,-1.7207 z" + id="path4484" + sodipodi:nodetypes="cccccccccc" /> + </g> +</svg> diff --git a/editor/icons/source/icon_particles_material.svg b/editor/icons/source/icon_particles_material.svg new file mode 100644 index 0000000000..b4c2ef7ccd --- /dev/null +++ b/editor/icons/source/icon_particles_material.svg @@ -0,0 +1,159 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.91 r13725" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node_2d.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_particles_shader.svg"> + <defs + id="defs4"> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4253"> + <path + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + id="path4255" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4199"> + <path + inkscape:connector-curvature="0" + id="path4201" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4208"> + <path + style="opacity:1;fill:#a5b7f5;fill-opacity:0.98823529;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + d="M 8,1037.3622 A 4.4999948,4.9999847 0 0 0 3.5859375,1041.3934 3,3 0 0 0 1,1044.3622 a 3,3 0 0 0 3,3 l 8,0 a 3,3 0 0 0 3,-3 3,3 0 0 0 -2.589844,-2.9668 A 4.4999948,4.9999847 0 0 0 8,1037.3622 Z m -4,11 a 1,1 0 0 0 -1,1 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 1,1 0 0 0 -1,-1 z m 8,0 a 1,1 0 0 0 -1,1 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 1,1 0 0 0 -1,-1 z m -4,1 a 1,1 0 0 0 -1,1 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 1,1 0 0 0 -1,-1 z" + id="path4210" + inkscape:connector-curvature="0" /> + </clipPath> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="15.999999" + inkscape:cx="8.2922739" + inkscape:cy="6.6952763" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1920" + inkscape:window-height="1016" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:object-nodes="true" + inkscape:snap-smooth-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <g + id="g4271" + clip-path="url(#clipPath4208)" + transform="translate(0,1.8694115e-5)"> + <rect + y="1037.3622" + x="0" + height="2.0000031" + width="16" + id="rect4159" + style="fill:#ff7070;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#ffeb70;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4161" + width="16" + height="2.0000029" + x="0" + y="1039.3622" /> + <rect + style="fill:#9dff70;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4163" + width="16" + height="1.9999999" + x="0" + y="1041.3622" /> + <rect + y="1043.3622" + x="0" + height="2.0000024" + width="16" + id="rect4165" + style="fill:#70ffb9;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + y="1045.3622" + x="0" + height="2.0000021" + width="16" + id="rect4167" + style="fill:#70deff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#ff70ac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4169" + width="16" + height="1.9999987" + x="0" + y="1049.3622" /> + <rect + style="fill:#9f70ff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4146" + width="16" + height="2.0000021" + x="0" + y="1047.3622" /> + </g> + </g> +</svg> diff --git a/editor/icons/source/icon_play_button_group.svg b/editor/icons/source/icon_play_button_group.svg new file mode 100644 index 0000000000..84bdb00505 --- /dev/null +++ b/editor/icons/source/icon_play_button_group.svg @@ -0,0 +1,78 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="32" + height="32" + viewBox="0 0 32 31.999998" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="button_group.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/button_disabled.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="16" + inkscape:cx="15.144473" + inkscape:cy="14.499068" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1020.3623)"> + <circle + style="fill:#000000;fill-opacity:0.19607843;stroke:none;stroke-width:2.54545379;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path4503" + cx="16" + cy="1036.3623" + r="13.999995" /> + </g> +</svg> diff --git a/editor/icons/source/icon_scroll_bg.svg b/editor/icons/source/icon_scroll_bg.svg new file mode 100644 index 0000000000..29604b9e14 --- /dev/null +++ b/editor/icons/source/icon_scroll_bg.svg @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 11.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="scroll_bg.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/panel_bg.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254836" + inkscape:cx="4.4464273" + inkscape:cy="6.9717582" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3623)" /> +</svg> diff --git a/editor/icons/source/icon_scroll_grabber.svg b/editor/icons/source/icon_scroll_grabber.svg new file mode 100644 index 0000000000..b9d2bbbec0 --- /dev/null +++ b/editor/icons/source/icon_scroll_grabber.svg @@ -0,0 +1,78 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 11.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="scroll_grabber.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/panel_bg.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254836" + inkscape:cx="1.3086411" + inkscape:cy="6.9275641" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3623)"> + <circle + style="opacity:1;fill:#ffffff;fill-opacity:0.27450982;stroke:none;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path4239" + cx="6" + cy="1046.3623" + r="2" /> + </g> +</svg> diff --git a/editor/icons/source/icon_scroll_grabber_hl.svg b/editor/icons/source/icon_scroll_grabber_hl.svg new file mode 100644 index 0000000000..ce9a66c5bc --- /dev/null +++ b/editor/icons/source/icon_scroll_grabber_hl.svg @@ -0,0 +1,82 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 11.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 unknown" + sodipodi:docname="icon_scroll_grabber_hl.svg" + inkscape:export-filename="/mnt/2TB/Development/godot_dev/editor/icons/icon_scroll_grabber_hl.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254836" + inkscape:cx="3.0874565" + inkscape:cy="5.7564185" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1097" + inkscape:window-height="1076" + inkscape:window-x="161" + inkscape:window-y="200" + inkscape:window-maximized="0" + inkscape:snap-nodes="false"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3623)"> + <circle + style="opacity:1;fill:#f9f9f9;fill-opacity:0.73000002;stroke:none;stroke-width:2.24999642;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="path4239" + cx="6" + cy="1046.3623" + r="2.9999952" + inkscape:export-filename="/mnt/2TB/Development/godot_dev/editor/icons/icon_scroll_grabber_hl.png" + inkscape:export-xdpi="96" + inkscape:export-ydpi="96" /> + </g> +</svg> diff --git a/editor/icons/source/icon_search.svg b/editor/icons/source/icon_search.svg new file mode 100644 index 0000000000..bcd2ecca46 --- /dev/null +++ b/editor/icons/source/icon_search.svg @@ -0,0 +1,87 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_zoom.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_search.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="5.8093316" + inkscape:cy="11.467722" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 6,1037.3622 a 5,5 0 0 0 -5,5 5,5 0 0 0 5,5 5,5 0 0 0 5,-5 5,5 0 0 0 -5,-5 z m 0,2 a 3,3 0 0 1 3,3 3,3 0 0 1 -3,3 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 z" + id="path4135" + inkscape:connector-curvature="0" /> + <rect + style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + id="rect4140" + width="2" + height="7.0000172" + x="-733.81873" + y="745.30402" + inkscape:transform-center-y="5.3032921" + transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)" + inkscape:transform-center-x="-5.3033134" /> + </g> +</svg> diff --git a/editor/icons/source/icon_slider_grabber.svg b/editor/icons/source/icon_slider_grabber.svg new file mode 100644 index 0000000000..b13ca5d1a9 --- /dev/null +++ b/editor/icons/source/icon_slider_grabber.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 unknown" + sodipodi:docname="icon_slider_grabber.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/checked.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="3.7828436" + inkscape:cy="7.4986644" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1195" + inkscape:window-height="722" + inkscape:window-x="91" + inkscape:window-y="633" + inkscape:window-maximized="0" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <circle + r="6.9999943" + cy="1044.3623" + cx="8.0000057" + id="circle4262" + style="fill:#d3d3d3;fill-opacity:1;stroke:none;stroke-width:20;stroke-linecap:square;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </g> +</svg> diff --git a/editor/icons/source/icon_slider_grabber_hl.svg b/editor/icons/source/icon_slider_grabber_hl.svg new file mode 100644 index 0000000000..5d53811c55 --- /dev/null +++ b/editor/icons/source/icon_slider_grabber_hl.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 unknown" + sodipodi:docname="icon_slider_grabber_hl.svg" + inkscape:export-filename="/mnt/2TB/Development/godot_dev/editor/icons/2x/icon_slider_grabber_hl.png" + inkscape:export-xdpi="192" + inkscape:export-ydpi="192"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="7.6841863" + inkscape:cy="6.0120089" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1092" + inkscape:window-height="880" + inkscape:window-x="92" + inkscape:window-y="49" + inkscape:window-maximized="0" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <circle + r="6.9999943" + cy="1044.3623" + cx="8.0000057" + id="circle4262" + style="fill:#f9f9f9;fill-opacity:1;stroke:none;stroke-width:20;stroke-linecap:square;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </g> +</svg> diff --git a/editor/icons/source/icon_spatial_material.svg b/editor/icons/source/icon_spatial_material.svg new file mode 100644 index 0000000000..329354b716 --- /dev/null +++ b/editor/icons/source/icon_spatial_material.svg @@ -0,0 +1,165 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.91 r13725" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collision_shape.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_spatial_shader.svg"> + <defs + id="defs4"> + <clipPath + id="clipPath4253" + clipPathUnits="userSpaceOnUse"> + <path + inkscape:connector-curvature="0" + id="path4255" + d="m 16.458984,1024.37 a 12.000027,12.000027 0 0 0 -3.564453,0.4004 12.000027,12.000027 0 0 0 -8.4863279,14.6973 12.000027,12.000027 0 0 0 14.6972659,8.4863 12.000027,12.000027 0 0 0 8.486328,-14.6973 12.000027,12.000027 0 0 0 -11.132813,-8.8867 z M 16.25,1029.8212 a 6.5451717,6.5451717 0 0 1 6.072266,4.8476 6.5451717,6.5451717 0 0 1 -4.628907,8.0157 6.5451717,6.5451717 0 0 1 -8.0156246,-4.6289 6.5451717,6.5451717 0 0 1 4.6289066,-8.0157 6.5451717,6.5451717 0 0 1 1.943359,-0.2187 z" + style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + </clipPath> + <clipPath + id="clipPath4199" + clipPathUnits="userSpaceOnUse"> + <path + style="opacity:1;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="m 16.5,1025.8622 a 11.8125,10.499999 0 0 0 -11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125001,10.5 11.8125,10.499999 0 0 0 11.8125,-10.5 11.8125,10.499999 0 0 0 -11.8125,-10.5 z m -3.375,3 a 3.375,2.9999997 0 0 1 3.375,3 3.375,2.9999997 0 0 1 -3.375,3 3.375,2.9999997 0 0 1 -3.3750001,-3 3.375,2.9999997 0 0 1 3.3750001,-3 z" + id="path4201" + inkscape:connector-curvature="0" /> + </clipPath> + <clipPath + clipPathUnits="userSpaceOnUse" + id="clipPath4280"> + <g + id="g4282" + inkscape:label="Layer 1" + transform="translate(0,1.1802001e-5)" + style="stroke:#fc9c9c;stroke-opacity:0.99607843"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;baseline-shift:baseline;text-anchor:start;white-space:normal;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#fc9c9c;fill-opacity:0.99607843;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 7.9628906,1.0019531 A 1.0001,1.0001 0 0 0 7.5527344,1.1054688 l -6,3 A 1.0001,1.0001 0 0 0 1,5 l 0,6 a 1.0001,1.0001 0 0 0 0.5527344,0.894531 l 6,3 a 1.0001,1.0001 0 0 0 0.8945312,0 l 6.0000004,-3 A 1.0001,1.0001 0 0 0 15,11 L 15,5 A 1.0001,1.0001 0 0 0 14.447266,4.1054688 l -6.0000004,-3 A 1.0001,1.0001 0 0 0 7.9628906,1.0019531 Z M 8,3.1191406 11.763672,5 8,6.8828125 4.2363281,5 8,3.1191406 Z m -5,3.5 4,2 0,3.7636714 -4,-2 0,-3.7636714 z m 10,0 0,3.7636714 -4,2 0,-3.7636714 4,-2 z" + transform="translate(0,1036.3622)" + id="path4284" + inkscape:connector-curvature="0" /> + </g> + </clipPath> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627417" + inkscape:cx="7.8442401" + inkscape:cy="13.929239" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="true" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1920" + inkscape:window-height="1016" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false" + inkscape:snap-midpoints="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <g + id="g4271" + clip-path="url(#clipPath4280)"> + <rect + y="1037.3622" + x="0" + height="2.0000031" + width="16" + id="rect4159" + style="fill:#ff7070;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#ffeb70;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4161" + width="16" + height="2.0000029" + x="0" + y="1039.3622" /> + <rect + style="fill:#9dff70;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4163" + width="16" + height="1.9999999" + x="0" + y="1041.3622" /> + <rect + y="1043.3622" + x="0" + height="2.0000024" + width="16" + id="rect4165" + style="fill:#70ffb9;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + y="1045.3622" + x="0" + height="2.0000021" + width="16" + id="rect4167" + style="fill:#70deff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + <rect + style="fill:#ff70ac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4169" + width="16" + height="1.9999987" + x="0" + y="1049.3622" /> + <rect + style="fill:#9f70ff;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4146" + width="16" + height="2.0000021" + x="0" + y="1047.3622" /> + </g> + </g> +</svg> diff --git a/editor/icons/source/icon_spinbox_updown.svg b/editor/icons/source/icon_spinbox_updown.svg new file mode 100644 index 0000000000..e29d7fe0d2 --- /dev/null +++ b/editor/icons/source/icon_spinbox_updown.svg @@ -0,0 +1,83 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="spinbox_updown.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="16" + inkscape:cx="-1.901723" + inkscape:cy="9.1326297" + inkscape:document-units="px" + inkscape:current-layer="layer1-5" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#e0e0e0;fill-opacity:0.78431374;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="M 7.984375 1.0019531 A 1.0001 1.0001 0 0 0 7.2929688 1.2929688 L 3.2929688 5.2929688 A 1.0001 1.0001 0 1 0 4.7070312 6.7070312 L 8 3.4140625 L 11.292969 6.7070312 A 1.0001 1.0001 0 1 0 12.707031 5.2929688 L 8.7070312 1.2929688 A 1.0001 1.0001 0 0 0 7.984375 1.0019531 z M 11.990234 8.9863281 A 1.0001 1.0001 0 0 0 11.292969 9.2929688 L 8 12.585938 L 4.7070312 9.2929688 A 1.0001 1.0001 0 0 0 3.9902344 8.9902344 A 1.0001 1.0001 0 0 0 3.2929688 10.707031 L 7.2929688 14.707031 A 1.0001 1.0001 0 0 0 8.7070312 14.707031 L 12.707031 10.707031 A 1.0001 1.0001 0 0 0 11.990234 8.9863281 z " + transform="translate(0,1036.3622)" + id="path4484" /> + <g + id="layer1-5" + inkscape:label="Layer 1" + transform="translate(14.210182,-5.3664)" /> + </g> +</svg> diff --git a/editor/icons/source/icon_stream_texture.svg b/editor/icons/source/icon_stream_texture.svg new file mode 100644 index 0000000000..6ec701adff --- /dev/null +++ b/editor/icons/source/icon_stream_texture.svg @@ -0,0 +1,81 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_key.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90" + sodipodi:docname="icon_stream_texture.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="11.200084" + inkscape:cy="6.7708068" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:object-nodes="false" + inkscape:snap-smooth-nodes="false"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title></dc:title> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.99607843" + d="M 2 1 A 1 1 0 0 0 1 2 L 1 14 A 1 1 0 0 0 2 15 L 8 15 L 8 13 L 10 13 L 10 11 L 8 11 L 3 11 L 3 3 L 8 3 L 8 1 L 2 1 z M 8 3 L 8 5 L 10 5 L 10 3 L 8 3 z M 10 3 L 12 3 L 12 1 L 10 1 L 10 3 z M 12 3 L 12 5 L 14 5 L 14 3 L 12 3 z M 12 5 L 10 5 L 10 7 L 12 7 L 12 5 z M 12 7 L 12 9 L 14 9 L 14 7 L 12 7 z M 12 9 L 10 9 L 10 11 L 12 11 L 12 9 z M 12 11 L 12 13 L 14 13 L 14 11 L 12 11 z M 12 13 L 10 13 L 10 15 L 12 15 L 12 13 z M 10 9 L 10 7 L 8 7 L 8 6 L 7 6 L 7 7 L 6 7 L 6 8 L 5 8 L 5 9 L 4 9 L 4 10 L 6 10 L 8 10 L 8 9 L 10 9 z " + transform="translate(0,1036.3622)" + id="rect4156" /> + </g> +</svg> diff --git a/editor/icons/source/icon_tab_menu.svg b/editor/icons/source/icon_tab_menu.svg new file mode 100644 index 0000000000..39e0d1f261 --- /dev/null +++ b/editor/icons/source/icon_tab_menu.svg @@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 16" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="tab_menu.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32.000001" + inkscape:cx="4.0814179" + inkscape:cy="8.4695645" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3622)"> + <circle + style="fill:#ffffff;fill-opacity:0.39215687;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.35294118" + id="path819" + cx="8" + cy="1038.3622" + r="2" /> + <circle + r="2" + cy="1044.3622" + cx="8" + id="circle821" + style="fill:#ffffff;fill-opacity:0.39215687;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.35294118" /> + <circle + style="fill:#ffffff;fill-opacity:0.39215687;stroke:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.35294118" + id="circle823" + cx="8" + cy="1050.3622" + r="2" /> + </g> +</svg> diff --git a/editor/icons/source/icon_tabs.svg b/editor/icons/source/icon_tabs.svg index 79ed1e5910..c09a042033 100644 --- a/editor/icons/source/icon_tabs.svg +++ b/editor/icons/source/icon_tabs.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_center_container.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="22.627417" - inkscape:cx="11.687421" - inkscape:cy="9.3335226" + inkscape:zoom="32" + inkscape:cx="6.9623805" + inkscape:cy="8.3399158" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -71,73 +71,10 @@ inkscape:groupmode="layer" id="layer1" transform="translate(0,-1036.3622)"> - <rect - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="rect4156" - width="1" - height="9.0000172" - x="1" - y="1040.3622" /> - <rect - y="-8" - x="1039.3622" - height="6" - width="1" - id="rect4159" - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - transform="matrix(0,1,-1,0,0,0)" /> - <rect - y="1040.3622" - x="7" - height="3.0000174" - width="1" - id="rect4161" - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> <path - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="path4163" - sodipodi:type="arc" - sodipodi:cx="2" - sodipodi:cy="1040.3622" - sodipodi:rx="1" - sodipodi:ry="1" - sodipodi:start="1.5707963" - sodipodi:end="0" - d="m 2,1041.3622 a 1,1 0 0 1 -0.9238795,-0.6173 1,1 0 0 1 0.2167727,-1.0898 1,1 0 0 1 1.0897902,-0.2168 A 1,1 0 0 1 3,1040.3622 l -1,0 z" /> - <rect - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="rect4167" - width="1" - height="9.0000172" - x="14" - y="1040.3622" /> - <rect - transform="matrix(0,1,-1,0,0,0)" - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="rect4169" - width="1" - height="6" - x="1039.3622" - y="-14" /> - <path - transform="scale(-1,1)" - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="path4171" - sodipodi:type="arc" - sodipodi:cx="-14" - sodipodi:cy="1040.3622" - sodipodi:rx="1" - sodipodi:ry="1" - sodipodi:start="1.5707963" - sodipodi:end="0" - d="m -14,1041.3622 a 1,1 0 0 1 -0.92388,-0.6173 1,1 0 0 1 0.216773,-1.0898 1,1 0 0 1 1.08979,-0.2168 1,1 0 0 1 0.617317,0.9239 l -1,0 z" /> - <rect - transform="matrix(0,1,-1,0,0,0)" - style="opacity:1;fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="rect4173" - width="1" - height="13" - x="1042.3622" - y="-15" /> + style="fill:#a5efac;fill-opacity:1;stroke:none;stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="M 5 4 C 3.8919904 4 3.1821539 4.9071 3 6 L 2 12 L 1 12 L 1 14 L 5 14 L 11 14 L 15 14 L 15 12 L 13 12 L 12 6 C 11.817843 4.9071 11.108009 4 10 4 L 5 4 z " + transform="translate(0,1036.3622)" + id="rect821" /> </g> </svg> diff --git a/editor/icons/source/icon_tree_arrow_down.svg b/editor/icons/source/icon_tree_arrow_down.svg new file mode 100644 index 0000000000..1dd209720f --- /dev/null +++ b/editor/icons/source/icon_tree_arrow_down.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 12" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="arrow_down.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627417" + inkscape:cx="1.7981958" + inkscape:cy="7.5815407" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3622)"> + <path + style="fill:none;stroke:#ffffff;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.39215687" + d="m 3,1045.3622 3,3 3,-3" + id="path814" + inkscape:connector-curvature="0" + sodipodi:nodetypes="ccc" /> + </g> +</svg> diff --git a/editor/icons/source/icon_tree_arrow_right.svg b/editor/icons/source/icon_tree_arrow_right.svg new file mode 100644 index 0000000000..43134ba1b1 --- /dev/null +++ b/editor/icons/source/icon_tree_arrow_right.svg @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="12" + height="12" + viewBox="0 0 12 12" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="arrow_right.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="45.254836" + inkscape:cx="4.0845752" + inkscape:cy="5.8802612" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1040.3622)"> + <path + style="fill:none;stroke:#ffffff;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.39215687" + d="m 4,1049.3622 3.0000202,-3 -3.0000202,-3" + id="path814" + inkscape:connector-curvature="0" + sodipodi:nodetypes="ccc" /> + </g> +</svg> diff --git a/editor/icons/source/icon_tween.svg b/editor/icons/source/icon_tween.svg index 5cb5cad227..7857c5f187 100644 --- a/editor/icons/source/icon_tween.svg +++ b/editor/icons/source/icon_tween.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_tween.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,8 +29,8 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="32" - inkscape:cx="6.0670176" - inkscape:cy="10.041334" + inkscape:cx="4.9605895" + inkscape:cy="8.5201258" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1" @@ -71,28 +71,25 @@ id="layer1" transform="translate(0,-1036.3622)"> <path - style="fill:none;fill-rule:evenodd;stroke:#e0e0e0;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - d="m 9,1050.3622 -7,0 0,-7" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#fbe87a;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 1,1043.3613 v 8 h 8 v -2 H 3 v -6 z" id="path4138" - inkscape:connector-curvature="0" - sodipodi:nodetypes="ccc" /> + inkscape:connector-curvature="0" /> <path - sodipodi:nodetypes="ccc" - inkscape:connector-curvature="0" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#fbe87a;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 7,1037.3613 v 2 h 6 v 6 h 2 v -8 z" id="path4140" - d="m 7,1038.3622 7,0 0,7" - style="fill:none;fill-rule:evenodd;stroke:#e0e0e0;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + inkscape:connector-curvature="0" /> <path sodipodi:nodetypes="cccc" inkscape:connector-curvature="0" id="path4142" d="m 6.0000002,1041.3622 4.9999998,0 0,5 z" - style="opacity:1;fill:#e0e0e0;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + style="opacity:1;fill:#fbe87a;fill-opacity:1;stroke:none;stroke-width:4;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> <path - inkscape:connector-curvature="0" + style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#fbe87a;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" + d="m 8.2929688,1042.6543 -7,7 1.4140624,1.4141 7,-7 z" id="path4144" - d="m 2,1050.3622 7,-7" - style="fill:none;fill-rule:evenodd;stroke:#e0e0e0;stroke-width:2;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" - sodipodi:nodetypes="cc" /> + inkscape:connector-curvature="0" /> </g> </svg> diff --git a/editor/icons/source/icon_unchecked.svg b/editor/icons/source/icon_unchecked.svg new file mode 100644 index 0000000000..053cbe6de5 --- /dev/null +++ b/editor/icons/source/icon_unchecked.svg @@ -0,0 +1,77 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="unchecked.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/unchecked.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32" + inkscape:cx="4.8224661" + inkscape:cy="8.2065809" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <path + style="opacity:1;fill:#e0e0e0;fill-opacity:0.78431374;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="M 4 2 A 2 2 0 0 0 2 4 L 2 12 A 2 2 0 0 0 4 14 L 12 14 A 2 2 0 0 0 14 12 L 14 4 A 2 2 0 0 0 12 2 L 4 2 z M 4.8007812 4 L 11.199219 4 A 0.8000012 0.8000012 0 0 1 12 4.8007812 L 12 11.199219 A 0.8000012 0.8000012 0 0 1 11.199219 12 L 4.8007812 12 A 0.8000012 0.8000012 0 0 1 4 11.199219 L 4 4.8007812 A 0.8000012 0.8000012 0 0 1 4.8007812 4 z " + transform="translate(0,1036.3623)" + id="circle4178" /> + </g> +</svg> diff --git a/editor/icons/source/icon_vslider_bg.svg b/editor/icons/source/icon_vslider_bg.svg new file mode 100644 index 0000000000..b34dddc2d0 --- /dev/null +++ b/editor/icons/source/icon_vslider_bg.svg @@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="16" + height="16" + viewBox="0 0 16 15.999999" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + sodipodi:docname="vslider_bg.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/checked.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="22.627417" + inkscape:cx="10.537518" + inkscape:cy="7.6498812" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="false" + inkscape:snap-intersection-paths="false" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1036.3623)"> + <g + id="layer1-5" + inkscape:label="Layer 1" + transform="rotate(90,8,1044.3623)"> + <path + id="path814" + transform="translate(0,1036.3623)" + d="m 4,5 a 3,3 0 0 0 -3,3 3,3 0 0 0 3,3 h 8 A 3,3 0 0 0 15,8 3,3 0 0 0 12,5 Z" + style="fill:#000000;fill-opacity:0.19607843;stroke:none;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + inkscape:connector-curvature="0" /> + </g> + </g> +</svg> diff --git a/editor/icons/source/icon_vsplit_bg.svg b/editor/icons/source/icon_vsplit_bg.svg new file mode 100644 index 0000000000..e11940cf53 --- /dev/null +++ b/editor/icons/source/icon_vsplit_bg.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="8" + height="8" + viewBox="0 0 8 7.9999995" + id="svg2" + version="1.1" + inkscape:version="0.91 r13725" + sodipodi:docname="vsplit_bg.svg" + inkscape:export-filename="/home/djrm/Projects/godot/scene/resources/default_theme/panel_bg.png" + inkscape:export-xdpi="90" + inkscape:export-ydpi="90"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="64.000003" + inkscape:cx="-1.1524794" + inkscape:cy="3.8847002" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:object-paths="true" + inkscape:snap-intersection-paths="true" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:window-width="1920" + inkscape:window-height="1016" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1"> + <inkscape:grid + type="xygrid" + id="grid4136" + empspacing="4" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1044.3623)"> + <rect + style="opacity:1;fill:#000000;fill-opacity:0.09803922;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + id="rect4213" + width="8" + height="7.999999" + x="0" + y="1044.3623" /> + </g> +</svg> diff --git a/editor/icons/source/icon_vsplitter.svg b/editor/icons/source/icon_vsplitter.svg new file mode 100644 index 0000000000..80f7c2ce12 --- /dev/null +++ b/editor/icons/source/icon_vsplitter.svg @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + xmlns:dc="http://purl.org/dc/elements/1.1/" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns="http://www.w3.org/2000/svg" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="64" + height="8" + viewBox="0 0 64 8" + id="svg2" + version="1.1" + inkscape:version="0.92.1 r" + inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_collapse.png" + inkscape:export-xdpi="45" + inkscape:export-ydpi="45" + sodipodi:docname="vsplitter.svg"> + <defs + id="defs4" /> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="32.000001" + inkscape:cx="59.744611" + inkscape:cy="0.46378871" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + units="px" + inkscape:snap-bbox="true" + inkscape:bbox-paths="true" + inkscape:bbox-nodes="true" + inkscape:snap-bbox-edge-midpoints="true" + inkscape:snap-bbox-midpoints="false" + inkscape:snap-object-midpoints="true" + inkscape:snap-center="true" + inkscape:window-width="1600" + inkscape:window-height="836" + inkscape:window-x="0" + inkscape:window-y="27" + inkscape:window-maximized="1" + inkscape:snap-smooth-nodes="true" + inkscape:object-nodes="true"> + <inkscape:grid + type="xygrid" + id="grid3336" /> + </sodipodi:namedview> + <metadata + id="metadata7"> + <rdf:RDF> + <cc:Work + rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> + <dc:title /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1" + transform="translate(0,-1044.3622)"> + <path + style="fill:none;stroke:#ffffff;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:0.39215687;stroke-miterlimit:4;stroke-dasharray:none" + d="M 2,1048.3622 H 62" + id="path814" + inkscape:connector-curvature="0" /> + </g> +</svg> diff --git a/editor/icons/source/icon_warning.svg b/editor/icons/source/icon_warning.svg index 4d39141a58..d886fbdaed 100644 --- a/editor/icons/source/icon_warning.svg +++ b/editor/icons/source/icon_warning.svg @@ -14,7 +14,7 @@ viewBox="0 0 8 8" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_node.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -29,7 +29,7 @@ inkscape:pageopacity="0.0" inkscape:pageshadow="2" inkscape:zoom="45.254832" - inkscape:cx="2.2320862" + inkscape:cx="-2.2536226" inkscape:cy="6.41947" inkscape:document-units="px" inkscape:current-layer="layer1" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="true" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -76,6 +76,6 @@ height="8" x="0" y="1044.3622" - ry="1" /> + ry="4" /> </g> </svg> diff --git a/editor/icons/source/icon_zoom.svg b/editor/icons/source/icon_zoom.svg index 811036b370..de94ed9614 100644 --- a/editor/icons/source/icon_zoom.svg +++ b/editor/icons/source/icon_zoom.svg @@ -14,7 +14,7 @@ viewBox="0 0 16 16" id="svg2" version="1.1" - inkscape:version="0.91 r13725" + inkscape:version="0.92.1 r" inkscape:export-filename="/home/djrm/Projects/godot/tools/editor/icons/icon_zoom.png" inkscape:export-xdpi="90" inkscape:export-ydpi="90" @@ -28,9 +28,9 @@ borderopacity="1.0" inkscape:pageopacity="0.0" inkscape:pageshadow="2" - inkscape:zoom="22.627417" - inkscape:cx="3.7772222" - inkscape:cy="11.922647" + inkscape:zoom="32" + inkscape:cx="9.872627" + inkscape:cy="8.8162049" inkscape:document-units="px" inkscape:current-layer="layer1" showgrid="true" @@ -42,8 +42,8 @@ inkscape:snap-bbox-midpoints="false" inkscape:snap-object-midpoints="true" inkscape:snap-center="true" - inkscape:window-width="1920" - inkscape:window-height="1016" + inkscape:window-width="1600" + inkscape:window-height="836" inkscape:window-x="0" inkscape:window-y="27" inkscape:window-maximized="1"> @@ -59,7 +59,7 @@ <dc:format>image/svg+xml</dc:format> <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage" /> - <dc:title></dc:title> + <dc:title /> </cc:Work> </rdf:RDF> </metadata> @@ -70,18 +70,8 @@ transform="translate(0,-1036.3622)"> <path style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - d="m 6,1037.3622 a 5,5 0 0 0 -5,5 5,5 0 0 0 5,5 5,5 0 0 0 5,-5 5,5 0 0 0 -5,-5 z m 0,2 a 3,3 0 0 1 3,3 3,3 0 0 1 -3,3 3,3 0 0 1 -3,-3 3,3 0 0 1 3,-3 z" - id="path4135" - inkscape:connector-curvature="0" /> - <rect - style="opacity:1;fill:#e0e0e0;fill-opacity:0.99607843;stroke:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" - id="rect4140" - width="2" - height="7.0000172" - x="-733.81873" - y="745.30402" - inkscape:transform-center-y="5.3032921" - transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)" - inkscape:transform-center-x="-5.3033134" /> + d="M 6 1 A 5 5 0 0 0 1 6 A 5 5 0 0 0 6 11 A 5 5 0 0 0 8.7519531 10.166016 L 13.070312 14.484375 L 14.484375 13.070312 L 10.166016 8.7519531 A 5 5 0 0 0 10.576172 8 L 10 8 L 10 6 L 9 6 A 3 3 0 0 1 6 9 A 3 3 0 0 1 3 6 A 3 3 0 0 1 6 3 A 3 3 0 0 1 8 3.7675781 L 8 2 L 8.9902344 2 A 5 5 0 0 0 6 1 z M 11 1 L 11 3 L 9 3 L 9 5 L 11 5 L 11 7 L 13 7 L 13 5 L 15 5 L 15 3 L 13 3 L 13 1 L 11 1 z " + transform="translate(0,1036.3622)" + id="path4135" /> </g> </svg> diff --git a/editor/import/editor_import_collada.cpp b/editor/import/editor_import_collada.cpp index dcbc509865..e0a2ea624e 100644 --- a/editor/import/editor_import_collada.cpp +++ b/editor/import/editor_import_collada.cpp @@ -72,7 +72,7 @@ struct ColladaImport { Map<String, NodeMap> node_map; //map from collada node to engine node Map<String, String> node_name_map; //map from collada node to engine node - Map<String, Ref<Mesh> > mesh_cache; + Map<String, Ref<ArrayMesh> > mesh_cache; Map<String, Ref<Curve3D> > curve_cache; Map<String, Ref<Material> > material_cache; Map<Collada::Node *, Skeleton *> skeleton_map; @@ -88,7 +88,7 @@ struct ColladaImport { Error _create_scene(Collada::Node *p_node, Spatial *p_parent); Error _create_resources(Collada::Node *p_node); Error _create_material(const String &p_material); - Error _create_mesh_surfaces(bool p_optimize, Ref<Mesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_data, const Collada::MorphControllerData *p_morph_data, Vector<Ref<Mesh> > p_morph_meshes = Vector<Ref<Mesh> >(), bool p_for_morph = false, bool p_use_mesh_material = false); + Error _create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_data, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh> > p_morph_meshes = Vector<Ref<ArrayMesh> >(), bool p_for_morph = false, bool p_use_mesh_material = false); Error load(const String &p_path, int p_flags, bool p_force_make_tangents = false); void _fix_param_animation_tracks(); void create_animation(int p_clip, bool p_make_tracks_in_all_bones, bool p_import_value_tracks); @@ -402,8 +402,8 @@ Error ColladaImport::_create_material(const String &p_target) { Ref<Texture> texture = ResourceLoader::load(texfile, "Texture"); if (texture.is_valid()) { - material->set_texture(SpatialMaterial::TEXTURE_SPECULAR, texture); - material->set_specular(Color(1, 1, 1, 1)); + material->set_texture(SpatialMaterial::TEXTURE_METALLIC, texture); + material->set_specular(1.0); //material->set_texture(SpatialMaterial::PARAM_SPECULAR,texture); //material->set_parameter(SpatialMaterial::PARAM_SPECULAR,Color(1,1,1,1)); @@ -411,8 +411,9 @@ Error ColladaImport::_create_material(const String &p_target) { missing_textures.push_back(texfile.get_file()); } } + } else { - material->set_metalness(effect.specular.color.get_v()); + material->set_metallic(effect.specular.color.get_v()); } // EMISSION @@ -553,10 +554,10 @@ static void _generate_tangents_and_binormals(const PoolVector<int> &p_indices, c tangent = Vector3(); } else { tangent = Vector3((t2 * x1 - t1 * x2) * r, (t2 * y1 - t1 * y2) * r, - (t2 * z1 - t1 * z2) * r) + (t2 * z1 - t1 * z2) * r) .normalized(); binormal = Vector3((s1 * x2 - s2 * x1) * r, (s1 * y2 - s2 * y1) * r, - (s1 * z2 - s2 * z1) * r) + (s1 * z2 - s2 * z1) * r) .normalized(); } @@ -590,7 +591,7 @@ static void _generate_tangents_and_binormals(const PoolVector<int> &p_indices, c } } -Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<Mesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<Mesh> > p_morph_meshes, bool p_for_morph, bool p_use_mesh_material) { +Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh> > p_morph_meshes, bool p_for_morph, bool p_use_mesh_material) { bool local_xform_mirror = p_local_xform.basis.determinant() < 0; @@ -1529,7 +1530,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node) { String meshid; Transform apply_xform; Vector<int> bone_remap; - Vector<Ref<Mesh> > morphs; + Vector<Ref<ArrayMesh> > morphs; print_line("mesh: " + String(mi->get_name())); @@ -1620,9 +1621,9 @@ Error ColladaImport::_create_resources(Collada::Node *p_node) { String meshid = names[i]; if (collada.state.mesh_data_map.has(meshid)) { - Ref<Mesh> mesh = Ref<Mesh>(memnew(Mesh)); + Ref<ArrayMesh> mesh = Ref<ArrayMesh>(memnew(ArrayMesh)); const Collada::MeshData &meshdata = collada.state.mesh_data_map[meshid]; - Error err = _create_mesh_surfaces(false, mesh, ng->material_map, meshdata, apply_xform, bone_remap, skin, NULL, Vector<Ref<Mesh> >(), true); + Error err = _create_mesh_surfaces(false, mesh, ng->material_map, meshdata, apply_xform, bone_remap, skin, NULL, Vector<Ref<ArrayMesh> >(), true); ERR_FAIL_COND_V(err, err); morphs.push_back(mesh); @@ -1647,7 +1648,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node) { meshid = ng->source; } - Ref<Mesh> mesh; + Ref<ArrayMesh> mesh; if (mesh_cache.has(meshid)) { mesh = mesh_cache[meshid]; } else { @@ -1655,7 +1656,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node) { //bleh, must ignore invalid ERR_FAIL_COND_V(!collada.state.mesh_data_map.has(meshid), ERR_INVALID_DATA); - mesh = Ref<Mesh>(memnew(Mesh)); + mesh = Ref<ArrayMesh>(memnew(ArrayMesh)); const Collada::MeshData &meshdata = collada.state.mesh_data_map[meshid]; mesh->set_name(meshdata.name); Error err = _create_mesh_surfaces(morphs.size() == 0, mesh, ng->material_map, meshdata, apply_xform, bone_remap, skin, morph, morphs, false, use_mesh_builtin_materials); @@ -1863,7 +1864,7 @@ void ColladaImport::create_animations(bool p_make_tracks_in_all_bones, bool p_im node = node_name_map[at.target]; } else { - print_line("Coudlnt find node: " + at.target); + print_line("Couldnt find node: " + at.target); continue; } } else { diff --git a/editor/import/editor_import_plugin.cpp b/editor/import/editor_import_plugin.cpp new file mode 100644 index 0000000000..6dee5da538 --- /dev/null +++ b/editor/import/editor_import_plugin.cpp @@ -0,0 +1,152 @@ +/*************************************************************************/ +/* editor_import_plugin.cpp */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ +#include "editor_import_plugin.h" +#include "core/script_language.h" + +EditorImportPlugin::EditorImportPlugin() { +} + +String EditorImportPlugin::get_importer_name() const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_importer_name")), ""); + return get_script_instance()->call("get_importer_name"); +} + +String EditorImportPlugin::get_visible_name() const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_visible_name")), ""); + return get_script_instance()->call("get_visible_name"); +} + +void EditorImportPlugin::get_recognized_extensions(List<String> *p_extensions) const { + ERR_FAIL_COND(!(get_script_instance() && get_script_instance()->has_method("get_recognized_extensions"))); + Array extensions = get_script_instance()->call("get_recognized_extensions"); + for (int i = 0; i < extensions.size(); i++) { + p_extensions->push_back(extensions[i]); + } +} + +String EditorImportPlugin::get_preset_name(int p_idx) const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_preset_name")), ""); + return get_script_instance()->call("get_preset_name", p_idx); +} + +int EditorImportPlugin::get_preset_count() { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_preset_count")), 0); + return get_script_instance()->call("get_preset_count"); +} + +String EditorImportPlugin::get_save_extension() const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_save_extension")), ""); + return get_script_instance()->call("get_save_extension"); +} + +String EditorImportPlugin::get_resource_type() const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_resource_type")), ""); + return get_script_instance()->call("get_resource_type"); +} + +void EditorImportPlugin::get_import_options(List<ResourceImporter::ImportOption> *r_options, int p_preset) const { + + ERR_FAIL_COND(!(get_script_instance() && get_script_instance()->has_method("get_import_options"))); + Array needed; + needed.push_back("name"); + needed.push_back("default_value"); + Array options = get_script_instance()->call("get_import_options", p_preset); + for (int i = 0; i < options.size(); i++) { + Dictionary d = options[i]; + ERR_FAIL_COND(!d.has_all(needed)); + String name = d["name"]; + Variant default_value = d["default_value"]; + + PropertyHint hint = PROPERTY_HINT_NONE; + if (d.has("property_hint")) { + hint = (PropertyHint)d["property_hint"].operator int64_t(); + } + + String hint_string; + if (d.has("hint_string")) { + hint_string = d["hint_string"]; + } + + uint32_t usage = PROPERTY_USAGE_DEFAULT; + if (d.has("usage")) { + usage = d["usage"]; + } + + ImportOption option(PropertyInfo(default_value.get_type(), name, hint, hint_string, usage), default_value); + r_options->push_back(option); + } +} + +bool EditorImportPlugin::get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const { + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("get_option_visibility")), true); + Dictionary d; + Map<StringName, Variant>::Element *E = p_options.front(); + while (E) { + d[E->key()] = E->get(); + E = E->next(); + } + return get_script_instance()->call("get_option_visibility", p_option, d); +} + +Error EditorImportPlugin::import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files) { + + ERR_FAIL_COND_V(!(get_script_instance() && get_script_instance()->has_method("import")), ERR_UNAVAILABLE); + Dictionary options; + Array platform_variants, gen_files; + + Map<StringName, Variant>::Element *E = p_options.front(); + while (E) { + options[E->key()] = E->get(); + E = E->next(); + } + Error err = (Error)get_script_instance()->call("import", p_source_file, p_save_path, options, platform_variants, gen_files).operator int64_t(); + + for (int i = 0; i < platform_variants.size(); i++) { + r_platform_variants->push_back(platform_variants[i]); + } + for (int i = 0; i < gen_files.size(); i++) { + r_gen_files->push_back(gen_files[i]); + } + return err; +} + +void EditorImportPlugin::_bind_methods() { + + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::STRING, "get_importer_name")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::STRING, "get_visible_name")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::INT, "get_preset_count")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::STRING, "get_preset_name", PropertyInfo(Variant::INT, "preset"))); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::ARRAY, "get_recognized_extensions")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::ARRAY, "get_import_options", PropertyInfo(Variant::INT, "preset"))); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::STRING, "get_save_extension")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::STRING, "get_resource_type")); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::BOOL, "get_option_visibility", PropertyInfo(Variant::STRING, "option"), PropertyInfo(Variant::DICTIONARY, "options"))); + ClassDB::add_virtual_method(get_class_static(), MethodInfo(Variant::INT, "import", PropertyInfo(Variant::STRING, "source_file"), PropertyInfo(Variant::STRING, "save_path"), PropertyInfo(Variant::DICTIONARY, "options"), PropertyInfo(Variant::ARRAY, "r_platform_variants"), PropertyInfo(Variant::ARRAY, "r_gen_files"))); +} diff --git a/editor/import/editor_import_plugin.h b/editor/import/editor_import_plugin.h new file mode 100644 index 0000000000..3c16b79713 --- /dev/null +++ b/editor/import/editor_import_plugin.h @@ -0,0 +1,54 @@ +/*************************************************************************/ +/* editor_import_plugin.h */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ +#ifndef EDITOR_IMPORT_PLUGIN_H +#define EDITOR_IMPORT_PLUGIN_H + +#include "io/resource_import.h" + +class EditorImportPlugin : public ResourceImporter { + GDCLASS(EditorImportPlugin, Reference) +protected: + static void _bind_methods(); + +public: + EditorImportPlugin(); + virtual String get_importer_name() const; + virtual String get_visible_name() const; + virtual void get_recognized_extensions(List<String> *p_extensions) const; + virtual String get_preset_name(int p_idx) const; + virtual int get_preset_count(); + virtual String get_save_extension() const; + virtual String get_resource_type() const; + virtual void get_import_options(List<ImportOption> *r_options, int p_preset) const; + virtual bool get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const; + virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files); +}; + +#endif //EDITOR_IMPORT_PLUGIN_H diff --git a/editor/import/resource_importer_csv_translation.cpp b/editor/import/resource_importer_csv_translation.cpp index ea43477dc3..9214b8f45e 100644 --- a/editor/import/resource_importer_csv_translation.cpp +++ b/editor/import/resource_importer_csv_translation.cpp @@ -54,7 +54,7 @@ String ResourceImporterCSVTranslation::get_save_extension() const { String ResourceImporterCSVTranslation::get_resource_type() const { - return "StreamCSVTranslation"; + return "Translation"; } bool ResourceImporterCSVTranslation::get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const { @@ -128,7 +128,7 @@ Error ResourceImporterCSVTranslation::import(const String &p_source_file, const xlt = cxl; } - String save_path = p_source_file.get_basename() + "." + translations[i]->get_locale() + ".xl"; + String save_path = p_source_file.get_basename() + "." + translations[i]->get_locale() + ".translation"; ResourceSaver::save(save_path, xlt); if (r_gen_files) { diff --git a/editor/import/resource_importer_obj.cpp b/editor/import/resource_importer_obj.cpp index 19fd1208b9..1c5aa95ff1 100644 --- a/editor/import/resource_importer_obj.cpp +++ b/editor/import/resource_importer_obj.cpp @@ -33,7 +33,6 @@ #include "os/file_access.h" #include "scene/resources/mesh.h" #include "scene/resources/surface_tool.h" -#include "scene/resources/surface_tool.h" String ResourceImporterOBJ::get_importer_name() const { @@ -49,12 +48,12 @@ void ResourceImporterOBJ::get_recognized_extensions(List<String> *p_extensions) p_extensions->push_back("obj"); } String ResourceImporterOBJ::get_save_extension() const { - return "msh"; + return "mesh"; } String ResourceImporterOBJ::get_resource_type() const { - return "Mesh"; + return "ArrayMesh"; } bool ResourceImporterOBJ::get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const { @@ -89,7 +88,7 @@ Error ResourceImporterOBJ::import(const String &p_source_file, const String &p_s FileAccessRef f = FileAccess::open(p_source_file, FileAccess::READ); ERR_FAIL_COND_V(!f, ERR_CANT_OPEN); - Ref<Mesh> mesh = Ref<Mesh>(memnew(Mesh)); + Ref<ArrayMesh> mesh = Ref<ArrayMesh>(memnew(ArrayMesh)); Map<String, Ref<Material> > name_map; bool generate_normals = p_options["generate/normals"]; @@ -168,18 +167,23 @@ Error ResourceImporterOBJ::import(const String &p_source_file, const String &p_s if (face[idx].size() == 3) { int norm = face[idx][2].to_int() - 1; + if (norm < 0) + norm += normals.size() + 1; ERR_FAIL_INDEX_V(norm, normals.size(), ERR_PARSE_ERROR); surf_tool->add_normal(normals[norm]); } if (face[idx].size() >= 2 && face[idx][1] != String()) { - int uv = face[idx][1].to_int() - 1; + if (uv < 0) + uv += uvs.size() + 1; ERR_FAIL_INDEX_V(uv, uvs.size(), ERR_PARSE_ERROR); surf_tool->add_uv(uvs[uv]); } int vtx = face[idx][0].to_int() - 1; + if (vtx < 0) + vtx += vertices.size() + 1; ERR_FAIL_INDEX_V(vtx, vertices.size(), ERR_PARSE_ERROR); Vector3 vertex = vertices[vtx]; @@ -239,7 +243,7 @@ Error ResourceImporterOBJ::import(const String &p_source_file, const String &p_s } */ - Error err = ResourceSaver::save(p_save_path + ".msh", mesh); + Error err = ResourceSaver::save(p_save_path + ".mesh", mesh); return err; } diff --git a/editor/import/resource_importer_scene.cpp b/editor/import/resource_importer_scene.cpp index 755f4eb219..2409f6707d 100644 --- a/editor/import/resource_importer_scene.cpp +++ b/editor/import/resource_importer_scene.cpp @@ -137,7 +137,7 @@ static String _fixstr(const String &p_what, const String &p_str) { return p_what; } -Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, Ref<Shape> > &collision_map) { +Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<ArrayMesh>, Ref<Shape> > &collision_map) { // children first.. for (int i = 0; i < p_node->get_child_count(); i++) { @@ -175,7 +175,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> mi->set_flag(GeometryInstance::FLAG_BILLBOARD, true); if (mi->get_mesh().is_valid()) { - Ref<Mesh> m = mi->get_mesh(); + Ref<ArrayMesh> m = mi->get_mesh(); for (int i = 0; i < m->get_surface_count(); i++) { Ref<SpatialMaterial> fm = m->surface_get_material(i); @@ -194,7 +194,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> MeshInstance *mi = p_node->cast_to<MeshInstance>(); - Ref<Mesh> m = mi->get_mesh(); + Ref<ArrayMesh> m = mi->get_mesh(); if (m.is_valid()) { @@ -275,7 +275,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> if (mi->get_mesh().is_valid()) { - Ref<Mesh> m = mi->get_mesh(); + Ref<ArrayMesh> m = mi->get_mesh(); for (int i = 0; i < m->get_surface_count(); i++) { Ref<SpatialMaterial> fm = m->surface_get_material(i); @@ -325,7 +325,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> /*if (mi->get_mesh().is_valid()) { - Ref<Mesh> m = mi->get_mesh(); + Ref<ArrayMesh> m = mi->get_mesh(); for(int i=0;i<m->get_surface_count();i++) { Ref<SpatialMaterial> fm = m->surface_get_material(i); @@ -477,7 +477,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> MeshInstance *mi = p_node->cast_to<MeshInstance>(); - Ref<Mesh> mesh = mi->get_mesh(); + Ref<ArrayMesh> mesh = mi->get_mesh(); ERR_FAIL_COND_V(mesh.is_null(), NULL); NavigationMeshInstance *nmi = memnew(NavigationMeshInstance); @@ -655,7 +655,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh> MeshInstance *mi = p_node->cast_to<MeshInstance>(); - Ref<Mesh> mesh = mi->get_mesh(); + Ref<ArrayMesh> mesh = mi->get_mesh(); if (!mesh.is_null()) { if (_teststr(mesh->get_name(), "col")) { @@ -972,7 +972,7 @@ static String _make_extname(const String &p_str) { return ext_name; } -void ResourceImporterScene::_make_external_resources(Node *p_node, const String &p_base_path, bool p_make_materials, bool p_make_meshes, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<Mesh>, Ref<Mesh> > &p_meshes) { +void ResourceImporterScene::_make_external_resources(Node *p_node, const String &p_base_path, bool p_make_materials, bool p_make_meshes, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh> > &p_meshes) { List<PropertyInfo> pi; @@ -987,7 +987,7 @@ void ResourceImporterScene::_make_external_resources(Node *p_node, const String if (!p_materials.has(mat)) { - String ext_name = p_base_path + "." + _make_extname(mat->get_name()) + ".mtl"; + String ext_name = p_base_path + "." + _make_extname(mat->get_name()) + ".material"; if (FileAccess::exists(ext_name)) { //if exists, use it Ref<Material> existing = ResourceLoader::load(ext_name); @@ -1005,7 +1005,7 @@ void ResourceImporterScene::_make_external_resources(Node *p_node, const String } } else { - Ref<Mesh> mesh = p_node->get(E->get().name); + Ref<ArrayMesh> mesh = p_node->get(E->get().name); if (mesh.is_valid()) { @@ -1015,10 +1015,10 @@ void ResourceImporterScene::_make_external_resources(Node *p_node, const String if (!p_meshes.has(mesh)) { - String ext_name = p_base_path + "." + _make_extname(mesh->get_name()) + ".msh"; + String ext_name = p_base_path + "." + _make_extname(mesh->get_name()) + ".mesh"; if (FileAccess::exists(ext_name)) { //if exists, use it - Ref<Mesh> existing = ResourceLoader::load(ext_name); + Ref<ArrayMesh> existing = ResourceLoader::load(ext_name); p_meshes[mesh] = existing; } else { @@ -1040,7 +1040,7 @@ void ResourceImporterScene::_make_external_resources(Node *p_node, const String if (!p_materials.has(mat)) { - String ext_name = p_base_path + "." + _make_extname(mat->get_name()) + ".mtl"; + String ext_name = p_base_path + "." + _make_extname(mat->get_name()) + ".material"; if (FileAccess::exists(ext_name)) { //if exists, use it Ref<Material> existing = ResourceLoader::load(ext_name); @@ -1059,7 +1059,7 @@ void ResourceImporterScene::_make_external_resources(Node *p_node, const String } if (!p_make_meshes) { - p_meshes[mesh] = Ref<Mesh>(); //save it anyway, so it won't be checked again + p_meshes[mesh] = Ref<ArrayMesh>(); //save it anyway, so it won't be checked again } } } @@ -1192,7 +1192,7 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p float anim_optimizer_angerr = p_options["animation/optimizer/max_angular_error"]; float anim_optimizer_maxang = p_options["animation/optimizer/max_angle"]; - Map<Ref<Mesh>, Ref<Shape> > collision_map; + Map<Ref<ArrayMesh>, Ref<Shape> > collision_map; scene = _fix_node(scene, scene, collision_map); @@ -1230,7 +1230,7 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p if (external_materials || external_meshes) { Map<Ref<Material>, Ref<Material> > mat_map; - Map<Ref<Mesh>, Ref<Mesh> > mesh_map; + Map<Ref<ArrayMesh>, Ref<ArrayMesh> > mesh_map; _make_external_resources(scene, p_source_file.get_basename(), external_materials, external_meshes, mat_map, mesh_map); } diff --git a/editor/import/resource_importer_scene.h b/editor/import/resource_importer_scene.h index 9f7b1a84e6..ede3028b29 100644 --- a/editor/import/resource_importer_scene.h +++ b/editor/import/resource_importer_scene.h @@ -32,6 +32,7 @@ #include "io/resource_import.h" #include "scene/resources/animation.h" +#include "scene/resources/mesh.h" #include "scene/resources/shape.h" class Material; @@ -100,9 +101,9 @@ public: virtual void get_import_options(List<ImportOption> *r_options, int p_preset = 0) const; virtual bool get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const; - void _make_external_resources(Node *p_node, const String &p_base_path, bool p_make_materials, bool p_make_meshes, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<Mesh>, Ref<Mesh> > &p_meshes); + void _make_external_resources(Node *p_node, const String &p_base_path, bool p_make_materials, bool p_make_meshes, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh> > &p_meshes); - Node *_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, Ref<Shape> > &collision_map); + Node *_fix_node(Node *p_node, Node *p_root, Map<Ref<ArrayMesh>, Ref<Shape> > &collision_map); void _create_clips(Node *scene, const Array &p_clips, bool p_bake_all); void _filter_anim_tracks(Ref<Animation> anim, Set<String> &keep); diff --git a/editor/import/resource_importer_texture.cpp b/editor/import/resource_importer_texture.cpp index f0dcc4a298..41b2353ed3 100644 --- a/editor/import/resource_importer_texture.cpp +++ b/editor/import/resource_importer_texture.cpp @@ -66,6 +66,22 @@ void ResourceImporterTexture::_texture_reimport_3d(const Ref<StreamTexture> &p_t singleton->mutex->unlock(); } +void ResourceImporterTexture::_texture_reimport_normal(const Ref<StreamTexture> &p_tex) { + + singleton->mutex->lock(); + StringName path = p_tex->get_path(); + + if (!singleton->make_flags.has(path)) { + singleton->make_flags[path] = 0; + } + + singleton->make_flags[path] |= MAKE_NORMAL_FLAG; + + print_line("requesting normalfor " + String(path)); + + singleton->mutex->unlock(); +} + void ResourceImporterTexture::update_imports() { if (EditorFileSystem::get_singleton()->is_scanning() || EditorFileSystem::get_singleton()->is_importing()) { @@ -96,6 +112,11 @@ void ResourceImporterTexture::update_imports() { changed = true; } + if (E->get() & MAKE_NORMAL_FLAG && int(cf->get_value("params", "compress/normal_map")) == 0) { + cf->set_value("params", "compress/normal_map", 1); + changed = true; + } + if (E->get() & MAKE_3D_FLAG && bool(cf->get_value("params", "detect_3d"))) { cf->set_value("params", "detect_3d", false); cf->set_value("params", "compress/mode", 2); @@ -144,8 +165,12 @@ String ResourceImporterTexture::get_resource_type() const { bool ResourceImporterTexture::get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const { - if (p_option == "compress/lossy_quality" && int(p_options["compress/mode"]) != COMPRESS_LOSSY) - return false; + if (p_option == "compress/lossy_quality") { + int compress_mode = int(p_options["compress/mode"]); + if (compress_mode != COMPRESS_LOSSY && compress_mode != COMPRESS_VIDEO_RAM) { + return false; + } + } return true; } @@ -169,6 +194,8 @@ void ResourceImporterTexture::get_import_options(List<ImportOption> *r_options, r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "compress/mode", PROPERTY_HINT_ENUM, "Lossless,Lossy,Video RAM,Uncompressed", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_UPDATE_ALL_IF_MODIFIED), p_preset == PRESET_3D ? 2 : 0)); r_options->push_back(ImportOption(PropertyInfo(Variant::REAL, "compress/lossy_quality", PROPERTY_HINT_RANGE, "0,1,0.01"), 0.7)); + r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "compress/hdr_mode", PROPERTY_HINT_ENUM, "Compress,Force RGBE"), 0)); + r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "compress/normal_map", PROPERTY_HINT_ENUM, "Detect,Enable,Disabled"), 0)); r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "flags/repeat", PROPERTY_HINT_ENUM, "Disabled,Enabled,Mirrored"), p_preset == PRESET_3D ? 1 : 0)); r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "flags/filter"), p_preset == PRESET_2D_PIXEL ? false : true)); r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "flags/mipmaps"), p_preset == PRESET_3D ? true : false)); @@ -176,21 +203,23 @@ void ResourceImporterTexture::get_import_options(List<ImportOption> *r_options, r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "flags/srgb", PROPERTY_HINT_ENUM, "Disable,Enable,Detect"), 2)); r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "process/fix_alpha_border"), p_preset != PRESET_3D ? true : false)); r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "process/premult_alpha"), true)); + r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "process/HDR_as_SRGB"), false)); r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "stream"), false)); r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "size_limit", PROPERTY_HINT_RANGE, "0,4096,1"), 0)); r_options->push_back(ImportOption(PropertyInfo(Variant::BOOL, "detect_3d"), p_preset == PRESET_DETECT)); } -void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_to_path, int p_compress_mode, float p_lossy_quality, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags, bool p_streamable, bool p_detect_3d, bool p_detect_srgb) { +void ResourceImporterTexture::_save_stex(const Ref<Image> &p_image, const String &p_to_path, int p_compress_mode, float p_lossy_quality, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags, bool p_streamable, bool p_detect_3d, bool p_detect_srgb, bool p_force_rgbe, bool p_detect_normal, bool p_force_normal) { + print_line("saving: " + p_to_path); FileAccess *f = FileAccess::open(p_to_path, FileAccess::WRITE); f->store_8('G'); f->store_8('D'); f->store_8('S'); f->store_8('T'); //godot streamable texture - f->store_32(p_image.get_width()); - f->store_32(p_image.get_height()); + f->store_32(p_image->get_width()); + f->store_32(p_image->get_height()); f->store_32(p_texture_flags); uint32_t format = 0; @@ -203,18 +232,24 @@ void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_t format |= StreamTexture::FORMAT_BIT_DETECT_3D; if (p_detect_srgb) format |= StreamTexture::FORMAT_BIT_DETECT_SRGB; + if (p_detect_normal) + format |= StreamTexture::FORMAT_BIT_DETECT_NORMAL; + + if ((p_compress_mode == COMPRESS_LOSSLESS || p_compress_mode == COMPRESS_LOSSY) && p_image->get_format() > Image::FORMAT_RGBA8) { + p_compress_mode == COMPRESS_UNCOMPRESSED; //these can't go as lossy + } switch (p_compress_mode) { case COMPRESS_LOSSLESS: { - Image image = p_image; + Ref<Image> image = p_image->duplicate(); if (p_mipmaps) { - image.generate_mipmaps(); + image->generate_mipmaps(); } else { - image.clear_mipmaps(); + image->clear_mipmaps(); } - int mmc = image.get_mipmap_count() + 1; + int mmc = image->get_mipmap_count() + 1; format |= StreamTexture::FORMAT_BIT_LOSSLESS; f->store_32(format); @@ -223,7 +258,7 @@ void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_t for (int i = 0; i < mmc; i++) { if (i > 0) { - image.shrink_x2(); + image->shrink_x2(); } PoolVector<uint8_t> data = Image::lossless_packer(image); @@ -236,14 +271,14 @@ void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_t } break; case COMPRESS_LOSSY: { - Image image = p_image; + Ref<Image> image = p_image->duplicate(); if (p_mipmaps) { - image.generate_mipmaps(); + image->generate_mipmaps(); } else { - image.clear_mipmaps(); + image->clear_mipmaps(); } - int mmc = image.get_mipmap_count() + 1; + int mmc = image->get_mipmap_count() + 1; format |= StreamTexture::FORMAT_BIT_LOSSY; f->store_32(format); @@ -252,7 +287,7 @@ void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_t for (int i = 0; i < mmc; i++) { if (i > 0) { - image.shrink_x2(); + image->shrink_x2(); } PoolVector<uint8_t> data = Image::lossy_packer(image, p_lossy_quality); @@ -265,33 +300,44 @@ void ResourceImporterTexture::_save_stex(const Image &p_image, const String &p_t } break; case COMPRESS_VIDEO_RAM: { - Image image = p_image; - image.generate_mipmaps(); - image.compress(p_vram_compression); + Ref<Image> image = p_image->duplicate(); + image->generate_mipmaps(); - format |= image.get_format(); + if (p_force_rgbe && image->get_format() >= Image::FORMAT_R8 && image->get_format() <= Image::FORMAT_RGBE9995) { + image->convert(Image::FORMAT_RGBE9995); + } else { + Image::CompressSource csource = Image::COMPRESS_SOURCE_GENERIC; + if (p_force_normal) { + csource = Image::COMPRESS_SOURCE_NORMAL; + } else if (p_texture_flags & VS::TEXTURE_FLAG_CONVERT_TO_LINEAR) { + csource = Image::COMPRESS_SOURCE_SRGB; + } + + image->compress(p_vram_compression, csource, p_lossy_quality); + } + + format |= image->get_format(); f->store_32(format); - PoolVector<uint8_t> data = image.get_data(); + PoolVector<uint8_t> data = image->get_data(); int dl = data.size(); PoolVector<uint8_t>::Read r = data.read(); f->store_buffer(r.ptr(), dl); - } break; case COMPRESS_UNCOMPRESSED: { - Image image = p_image; + Ref<Image> image = p_image->duplicate(); if (p_mipmaps) { - image.generate_mipmaps(); + image->generate_mipmaps(); } else { - image.clear_mipmaps(); + image->clear_mipmaps(); } - format |= image.get_format(); + format |= image->get_format(); f->store_32(format); - PoolVector<uint8_t> data = image.get_data(); + PoolVector<uint8_t> data = image->get_data(); int dl = data.size(); PoolVector<uint8_t>::Read r = data.read(); @@ -316,9 +362,13 @@ Error ResourceImporterTexture::import(const String &p_source_file, const String bool premult_alpha = p_options["process/premult_alpha"]; bool stream = p_options["stream"]; int size_limit = p_options["size_limit"]; + bool force_rgbe = int(p_options["compress/hdr_mode"]) == 1; + bool hdr_as_srgb = p_options["process/HDR_as_SRGB"]; + int normal = p_options["compress/normal_map"]; - Image image; - Error err = ImageLoader::load_image(p_source_file, &image); + Ref<Image> image; + image.instance(); + Error err = ImageLoader::load_image(p_source_file, image, NULL, hdr_as_srgb); if (err != OK) return err; @@ -336,46 +386,64 @@ Error ResourceImporterTexture::import(const String &p_source_file, const String if (srgb == 1) tex_flags |= Texture::FLAG_CONVERT_TO_LINEAR; - if (size_limit > 0 && (image.get_width() > size_limit || image.get_height() > size_limit)) { + if (size_limit > 0 && (image->get_width() > size_limit || image->get_height() > size_limit)) { //limit size - if (image.get_width() >= image.get_height()) { + if (image->get_width() >= image->get_height()) { int new_width = size_limit; - int new_height = image.get_height() * new_width / image.get_width(); + int new_height = image->get_height() * new_width / image->get_width(); - image.resize(new_width, new_height, Image::INTERPOLATE_CUBIC); + image->resize(new_width, new_height, Image::INTERPOLATE_CUBIC); } else { int new_height = size_limit; - int new_width = image.get_width() * new_height / image.get_height(); + int new_width = image->get_width() * new_height / image->get_height(); - image.resize(new_width, new_height, Image::INTERPOLATE_CUBIC); + image->resize(new_width, new_height, Image::INTERPOLATE_CUBIC); } } if (fix_alpha_border) { - image.fix_alpha_edges(); + image->fix_alpha_edges(); } if (premult_alpha) { - image.premultiply_alpha(); + image->premultiply_alpha(); } bool detect_3d = p_options["detect_3d"]; bool detect_srgb = srgb == 2; + bool detect_normal = normal == 0; + bool force_normal = normal == 1; if (compress_mode == COMPRESS_VIDEO_RAM) { //must import in all formats //Android, GLES 2.x - _save_stex(image, p_save_path + ".etc.stex", compress_mode, lossy, Image::COMPRESS_ETC, mipmaps, tex_flags, stream, detect_3d, detect_srgb); - r_platform_variants->push_back("etc"); - //_save_stex(image,p_save_path+".etc2.stex",compress_mode,lossy,Image::COMPRESS_ETC2,mipmaps,tex_flags,stream); - //r_platform_variants->push_back("etc2"); - _save_stex(image, p_save_path + ".s3tc.stex", compress_mode, lossy, Image::COMPRESS_S3TC, mipmaps, tex_flags, stream, detect_3d, detect_srgb); - r_platform_variants->push_back("s3tc"); + if (GlobalConfig::get_singleton()->get("rendering/vram_formats/use_s3tc")) { + + _save_stex(image, p_save_path + ".s3tc.stex", compress_mode, lossy, Image::COMPRESS_S3TC, mipmaps, tex_flags, stream, detect_3d, detect_srgb, force_rgbe, detect_normal, force_normal); + r_platform_variants->push_back("s3tc"); + } + + if (GlobalConfig::get_singleton()->get("rendering/vram_formats/use_etc")) { + _save_stex(image, p_save_path + ".etc.stex", compress_mode, lossy, Image::COMPRESS_ETC, mipmaps, tex_flags, stream, detect_3d, detect_srgb, force_rgbe, detect_normal, force_normal); + r_platform_variants->push_back("etc"); + } + + if (GlobalConfig::get_singleton()->get("rendering/vram_formats/use_etc2")) { + + _save_stex(image, p_save_path + ".etc2.stex", compress_mode, lossy, Image::COMPRESS_ETC2, mipmaps, tex_flags, stream, detect_3d, detect_srgb, force_rgbe, detect_normal, force_normal); + r_platform_variants->push_back("etc2"); + } + + if (GlobalConfig::get_singleton()->get("rendering/vram_formats/use_pvrtc")) { + + _save_stex(image, p_save_path + ".pvrtc.stex", compress_mode, lossy, Image::COMPRESS_PVRTC4, mipmaps, tex_flags, stream, detect_3d, detect_srgb, force_rgbe, detect_normal, force_normal); + r_platform_variants->push_back("pvrtc"); + } } else { //import normally - _save_stex(image, p_save_path + ".stex", compress_mode, lossy, Image::COMPRESS_16BIT /*this is ignored */, mipmaps, tex_flags, stream, detect_3d, detect_srgb); + _save_stex(image, p_save_path + ".stex", compress_mode, lossy, Image::COMPRESS_S3TC /*this is ignored */, mipmaps, tex_flags, stream, detect_3d, detect_srgb, force_rgbe, detect_normal, force_normal); } return OK; @@ -388,6 +456,7 @@ ResourceImporterTexture::ResourceImporterTexture() { singleton = this; StreamTexture::request_3d_callback = _texture_reimport_3d; StreamTexture::request_srgb_callback = _texture_reimport_srgb; + StreamTexture::request_normal_callback = _texture_reimport_normal; mutex = Mutex::create(); } diff --git a/editor/import/resource_importer_texture.h b/editor/import/resource_importer_texture.h index 196eb48469..31bd0f29b0 100644 --- a/editor/import/resource_importer_texture.h +++ b/editor/import/resource_importer_texture.h @@ -30,7 +30,9 @@ #ifndef RESOURCEIMPORTTEXTURE_H #define RESOURCEIMPORTTEXTURE_H +#include "image.h" #include "io/resource_import.h" + class StreamTexture; class ResourceImporterTexture : public ResourceImporter { @@ -39,7 +41,8 @@ class ResourceImporterTexture : public ResourceImporter { protected: enum { MAKE_3D_FLAG = 1, - MAKE_SRGB_FLAG = 2 + MAKE_SRGB_FLAG = 2, + MAKE_NORMAL_FLAG = 4 }; Mutex *mutex; @@ -47,6 +50,7 @@ protected: static void _texture_reimport_srgb(const Ref<StreamTexture> &p_tex); static void _texture_reimport_3d(const Ref<StreamTexture> &p_tex); + static void _texture_reimport_normal(const Ref<StreamTexture> &p_tex); static ResourceImporterTexture *singleton; @@ -78,7 +82,7 @@ public: virtual void get_import_options(List<ImportOption> *r_options, int p_preset = 0) const; virtual bool get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const; - void _save_stex(const Image &p_image, const String &p_to_path, int p_compress_mode, float p_lossy_quality, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags, bool p_streamable, bool p_detect_3d, bool p_detect_srgb); + void _save_stex(const Ref<Image> &p_image, const String &p_to_path, int p_compress_mode, float p_lossy_quality, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags, bool p_streamable, bool p_detect_3d, bool p_detect_srgb, bool p_force_rgbe, bool p_detect_normal, bool p_force_normal); virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files = NULL); diff --git a/editor/import/resource_importer_wav.cpp b/editor/import/resource_importer_wav.cpp index 92c1aa47db..7841baa02e 100644 --- a/editor/import/resource_importer_wav.cpp +++ b/editor/import/resource_importer_wav.cpp @@ -48,7 +48,7 @@ void ResourceImporterWAV::get_recognized_extensions(List<String> *p_extensions) p_extensions->push_back("wav"); } String ResourceImporterWAV::get_save_extension() const { - return "smp"; + return "sample"; } String ResourceImporterWAV::get_resource_type() const { @@ -485,7 +485,7 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s sample->set_loop_end(loop_end); sample->set_stereo(format_channels == 2); - ResourceSaver::save(p_save_path + ".smp", sample); + ResourceSaver::save(p_save_path + ".sample", sample); return OK; } diff --git a/editor/io_plugins/editor_font_import_plugin.cpp b/editor/io_plugins/editor_font_import_plugin.cpp index fa66328887..9831e08cf1 100644 --- a/editor/io_plugins/editor_font_import_plugin.cpp +++ b/editor/io_plugins/editor_font_import_plugin.cpp @@ -533,16 +533,16 @@ class EditorFontImportDialog : public ConfirmationDialog { return; } - if (dest->get_line_edit()->get_text().get_file()==".fnt") { - dest->get_line_edit()->set_text(dest->get_line_edit()->get_text().get_base_dir() + "/" + source->get_line_edit()->get_text().get_file().get_basename() + ".fnt" ); + if (dest->get_line_edit()->get_text().get_file()==".font") { + dest->get_line_edit()->set_text(dest->get_line_edit()->get_text().get_base_dir() + "/" + source->get_line_edit()->get_text().get_file().get_basename() + ".font" ); } if (dest->get_line_edit()->get_text().get_extension() == dest->get_line_edit()->get_text()) { - dest->get_line_edit()->set_text(dest->get_line_edit()->get_text() + ".fnt"); + dest->get_line_edit()->set_text(dest->get_line_edit()->get_text() + ".font"); } - if (dest->get_line_edit()->get_text().get_extension().to_lower() != "fnt") { - error_dialog->set_text(TTR("Invalid file extension.\nPlease use .fnt.")); + if (dest->get_line_edit()->get_text().get_extension().to_lower() != "font") { + error_dialog->set_text(TTR("Invalid file extension.\nPlease use .font.")); error_dialog->popup_centered(Size2(200,100)); return; } @@ -665,7 +665,7 @@ public: // List<String> fl; Ref<BitmapFont> font= memnew(BitmapFont); - dest->get_file_dialog()->add_filter("*.fnt ; Font" ); + dest->get_file_dialog()->add_filter("*.font ; Font" ); /* ResourceSaver::get_recognized_extensions(font,&fl); for(List<String>::Element *E=fl.front();E;E=E->next()) { @@ -1690,7 +1690,7 @@ void EditorFontImportPlugin::import_from_drop(const Vector<String>& p_drop, cons if (ext=="ttf" || ext=="otf" || ext=="fnt") { import_dialog(); - dialog->set_source_and_dest(p_drop[i],p_dest_path.plus_file(file.get_basename()+".fnt")); + dialog->set_source_and_dest(p_drop[i],p_dest_path.plus_file(file.get_basename()+".font")); break; } } diff --git a/editor/io_plugins/editor_mesh_import_plugin.cpp b/editor/io_plugins/editor_mesh_import_plugin.cpp index a8ecc2f10e..0c9f3a3f37 100644 --- a/editor/io_plugins/editor_mesh_import_plugin.cpp +++ b/editor/io_plugins/editor_mesh_import_plugin.cpp @@ -262,7 +262,7 @@ public: imd->add_source(EditorImportPlugin::validate_source_path(meshes[i])); - String file_path = dst.plus_file(meshes[i].get_file().get_basename()+".msh"); + String file_path = dst.plus_file(meshes[i].get_file().get_basename()+".mesh"); plugin->import(file_path,imd); } diff --git a/editor/io_plugins/editor_sample_import_plugin.cpp b/editor/io_plugins/editor_sample_import_plugin.cpp index 7836b60fde..0909b96cdc 100644 --- a/editor/io_plugins/editor_sample_import_plugin.cpp +++ b/editor/io_plugins/editor_sample_import_plugin.cpp @@ -299,7 +299,7 @@ public: error_dialog->popup_centered(Size2(200,100)*EDSCALE); } - dst = dst.plus_file(samples[i].get_file().get_basename()+".smp"); + dst = dst.plus_file(samples[i].get_file().get_basename()+".sample"); plugin->import(dst,imd); } @@ -910,13 +910,13 @@ Vector<uint8_t> EditorSampleExportPlugin::custom_export(String& p_path,const Ref imd->set_option("edit/loop",false); imd->set_option("compress/mode",1); - String savepath = EditorSettings::get_singleton()->get_settings_path().plus_file("tmp/smpconv.smp"); + String savepath = EditorSettings::get_singleton()->get_settings_path().plus_file("tmp/smpconv.sample"); Error err = EditorSampleImportPlugin::singleton->import(savepath,imd); ERR_FAIL_COND_V(err!=OK,Vector<uint8_t>()); - p_path=p_path.get_basename()+".converted.smp"; + p_path=p_path.get_basename()+".converted.sample"; return FileAccess::get_file_as_array(savepath); } diff --git a/editor/io_plugins/editor_scene_import_plugin.cpp b/editor/io_plugins/editor_scene_import_plugin.cpp index cd6acbb374..fed02b0e72 100644 --- a/editor/io_plugins/editor_scene_import_plugin.cpp +++ b/editor/io_plugins/editor_scene_import_plugin.cpp @@ -1093,7 +1093,7 @@ const EditorSceneImportDialog::FlagInfo EditorSceneImportDialog::scene_flag_name {EditorSceneImportPlugin::SCENE_FLAG_MERGE_KEEP_EXTRA_ANIM_TRACKS,("Merge"),"Keep user-added Animation tracks.",true}, {EditorSceneImportPlugin::SCENE_FLAG_DETECT_ALPHA,("Materials"),"Set Alpha in Materials (-alpha)",true}, {EditorSceneImportPlugin::SCENE_FLAG_DETECT_VCOLOR,("Materials"),"Set Vert. Color in Materials (-vcol)",true}, - {EditorSceneImportPlugin::SCENE_FLAG_CREATE_COLLISIONS,("Create"),"Create Collisions and/or Rigid Bodies (-col,-colonly,-rigid)",true}, + {EditorSceneImportPlugin::SCENE_FLAG_CREATE_COLLISIONS,("Create"),"Create Collisions and/or Rigid Bodies (-col,-colonly,-rigid,-rigidonly)",true}, {EditorSceneImportPlugin::SCENE_FLAG_CREATE_PORTALS,("Create"),"Create Portals (-portal)",true}, {EditorSceneImportPlugin::SCENE_FLAG_CREATE_ROOMS,("Create"),"Create Rooms (-room)",true}, {EditorSceneImportPlugin::SCENE_FLAG_SIMPLIFY_ROOMS,("Create"),"Simplify Rooms",false}, @@ -1714,12 +1714,14 @@ Node* EditorSceneImportPlugin::_fix_node(Node *p_node,Node *p_root,Map<Ref<Mesh> //mi->set_baked_light_texture_id(layer); } - if (p_flags&SCENE_FLAG_CREATE_COLLISIONS && _teststr(name,"colonly")) { + bool is_rigid = _teststr(name, "rigidonly"); + + if (p_flags & SCENE_FLAG_CREATE_COLLISIONS && (_teststr(name, "colonly") || is_rigid)) { if (isroot) return p_node; - - if (p_node->cast_to<MeshInstance>()) { + + if (p_node->cast_to<MeshInstance>() && !is_rigid) { MeshInstance *mi = p_node->cast_to<MeshInstance>(); Node * col = mi->create_trimesh_collision_node(); ERR_FAIL_COND_V(!col,NULL); @@ -1739,10 +1741,16 @@ Node* EditorSceneImportPlugin::_fix_node(Node *p_node,Node *p_root,Map<Ref<Mesh> } else if (p_node->has_meta("empty_draw_type")) { String empty_draw_type = String(p_node->get_meta("empty_draw_type")); print_line(empty_draw_type); - StaticBody *sb = memnew( StaticBody); - sb->set_name(_fixstr(name,"colonly")); - sb->cast_to<Spatial>()->set_transform(p_node->cast_to<Spatial>()->get_transform()); - p_node->replace_by(sb); + PhysicsBody *pb; + if (is_rigid) { + pb = memnew(RigidBody); + pb->set_name(_fixstr(name, "rigidonly")); + } else { + pb = memnew(StaticBody); + pb->set_name(_fixstr(name, "colonly")); + } + pb->cast_to<Spatial>()->set_transform(p_node->cast_to<Spatial>()->get_transform()); + p_node->replace_by(pb); memdelete(p_node); CollisionShape *colshape = memnew( CollisionShape); if (empty_draw_type == "CUBE") { @@ -1755,7 +1763,7 @@ Node* EditorSceneImportPlugin::_fix_node(Node *p_node,Node *p_root,Map<Ref<Mesh> rayShape->set_length(1); colshape->set_shape(rayShape); colshape->set_name("RayShape"); - sb->cast_to<Spatial>()->rotate_x(Math_PI / 2); + pb->cast_to<Spatial>()->rotate_x(Math_PI / 2); } else if (empty_draw_type == "IMAGE") { PlaneShape *planeShape = memnew( PlaneShape); colshape->set_shape(planeShape); @@ -1766,8 +1774,8 @@ Node* EditorSceneImportPlugin::_fix_node(Node *p_node,Node *p_root,Map<Ref<Mesh> colshape->set_shape(sphereShape); colshape->set_name("SphereShape"); } - sb->add_child(colshape); - colshape->set_owner(sb->get_owner()); + pb->add_child(colshape); + colshape->set_owner(pb->get_owner()); } } else if (p_flags&SCENE_FLAG_CREATE_COLLISIONS && _teststr(name,"rigid") && p_node->cast_to<MeshInstance>()) { diff --git a/editor/io_plugins/editor_texture_import_plugin.cpp b/editor/io_plugins/editor_texture_import_plugin.cpp index a2f0ecaf7b..d48675fa30 100644 --- a/editor/io_plugins/editor_texture_import_plugin.cpp +++ b/editor/io_plugins/editor_texture_import_plugin.cpp @@ -28,6 +28,7 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ #include "editor_texture_import_plugin.h" + #if 0 #include "editor/editor_node.h" #include "editor/editor_settings.h" @@ -35,13 +36,14 @@ #include "global_config.h" #include "io/image_loader.h" #include "io/marshalls.h" -#include "io/md5.h" #include "io/resource_saver.h" #include "scene/gui/button_group.h" #include "scene/gui/check_button.h" #include "scene/gui/margin_container.h" #include "scene/io/resource_format_image.h" +#include "thirdparty/misc/md5.h" + static const char *flag_names[]={ ("Streaming Format"), ("Fix Border Alpha"), @@ -594,7 +596,7 @@ void EditorTextureImportDialog::_mode_changed(int p_mode) { size->show(); file_select->set_mode(EditorFileDialog::MODE_OPEN_FILE); - save_file_select->add_filter("*.ltex;"+TTR("Large Texture")); + save_file_select->add_filter("*.largetex;"+TTR("Large Texture")); texture_options->set_flags(EditorTextureImportPlugin::IMAGE_FLAG_FIX_BORDER_ALPHA|EditorTextureImportPlugin::IMAGE_FLAG_NO_MIPMAPS|EditorTextureImportPlugin::IMAGE_FLAG_FILTER); texture_options->set_quality(0.7); @@ -1095,7 +1097,7 @@ Error EditorTextureImportPlugin::import2(const String& p_path, const Ref<Resourc int cell_size=from->get_option("large_cell_size"); ERR_FAIL_COND_V(cell_size<128 || cell_size>16384,ERR_CANT_OPEN); - EditorProgress pg("ltex",TTR("Import Large Texture"),3); + EditorProgress pg("largetex",TTR("Import Large Texture"),3); pg.step(TTR("Load Source Image"),0); Image img; @@ -1315,9 +1317,9 @@ Error EditorTextureImportPlugin::import2(const String& p_path, const Ref<Resourc String spath = from->get_source_path(E->get()).get_file(); if (p_external) { - apath = p_path.get_base_dir().plus_file(spath.get_basename()+"."+from->get_source_path(E->get()).md5_text()+".atex"); + apath = p_path.get_base_dir().plus_file(spath.get_basename()+"."+from->get_source_path(E->get()).md5_text()+".atlastex"); } else { - apath = p_path.get_base_dir().plus_file(spath.get_basename()+".atex"); + apath = p_path.get_base_dir().plus_file(spath.get_basename()+".atlastex"); } Ref<AtlasTexture> at; diff --git a/editor/io_plugins/editor_translation_import_plugin.cpp b/editor/io_plugins/editor_translation_import_plugin.cpp index 8fba33f787..5b15b94006 100644 --- a/editor/io_plugins/editor_translation_import_plugin.cpp +++ b/editor/io_plugins/editor_translation_import_plugin.cpp @@ -258,7 +258,7 @@ public: imd->set_option("skip_first",ignore_first->is_pressed()); imd->set_option("compress",compress->is_pressed()); - String savefile = save_path->get_text().plus_file(import_path->get_text().get_file().get_basename()+"."+locale+".xl"); + String savefile = save_path->get_text().plus_file(import_path->get_text().get_file().get_basename()+"."+locale+".translation"); Error err = plugin->import(savefile,imd); if (err!=OK) { error_dialog->set_text(TTR("Couldn't import!")); @@ -347,7 +347,7 @@ public: add_to_project = memnew( CheckButton); add_to_project->set_pressed(true); - add_to_project->set_text(TTR("Add to Project (godot.cfg)")); + add_to_project->set_text(TTR("Add to Project (project.godot)")); tcomp->add_child(add_to_project); file_select = memnew(EditorFileDialog); diff --git a/editor/pane_drag.cpp b/editor/pane_drag.cpp index 69a1f07fba..22b306f941 100644 --- a/editor/pane_drag.cpp +++ b/editor/pane_drag.cpp @@ -29,11 +29,12 @@ /*************************************************************************/ #include "pane_drag.h" -void PaneDrag::_gui_input(const InputEvent &p_input) { +void PaneDrag::_gui_input(const Ref<InputEvent> &p_input) { - if (p_input.type == InputEvent::MOUSE_MOTION && p_input.mouse_motion.button_mask & BUTTON_MASK_LEFT) { + Ref<InputEventMouseMotion> mm = p_input; + if (mm.is_valid() && mm->get_button_mask() & BUTTON_MASK_LEFT) { - emit_signal("dragged", Point2(p_input.mouse_motion.relative_x, p_input.mouse_motion.relative_y)); + emit_signal("dragged", Point2(mm->get_relative().x, mm->get_relative().y)); } } diff --git a/editor/pane_drag.h b/editor/pane_drag.h index bd26621c83..0be017b8f7 100644 --- a/editor/pane_drag.h +++ b/editor/pane_drag.h @@ -34,12 +34,12 @@ class PaneDrag : public Control { - GDCLASS(PaneDrag, Control); + GDCLASS(PaneDrag, Control) bool mouse_over; protected: - void _gui_input(const InputEvent &p_input); + void _gui_input(const Ref<InputEvent> &p_input); void _notification(int p_what); virtual Size2 get_minimum_size() const; static void _bind_methods(); diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp index 0be7b202a8..28c5b89741 100644 --- a/editor/plugins/animation_player_editor_plugin.cpp +++ b/editor/plugins/animation_player_editor_plugin.cpp @@ -51,7 +51,7 @@ void AnimationPlayerEditor::_node_removed(Node *p_node) { } } -void AnimationPlayerEditor::_gui_input(InputEvent p_event) { +void AnimationPlayerEditor::_gui_input(Ref<InputEvent> p_event) { } void AnimationPlayerEditor::_notification(int p_what) { @@ -118,8 +118,6 @@ void AnimationPlayerEditor::_notification(int p_what) { blend_editor.next->connect("item_selected", this, "_blend_editor_next_changed"); - nodename->set_icon(get_icon("AnimationPlayer", "EditorIcons")); - /* anim_editor_load->set_normal_texture( get_icon("AnimGet","EditorIcons")); anim_editor_store->set_normal_texture( get_icon("AnimSet","EditorIcons")); @@ -790,10 +788,6 @@ void AnimationPlayerEditor::_update_player() { player->get_animation_list(&animlist); animation->clear(); - if (player) - nodename->set_text(player->get_name()); - else - nodename->set_text("<empty>"); add_anim->set_disabled(player == NULL); load_anim->set_disabled(player == NULL); @@ -1166,14 +1160,15 @@ void AnimationPlayerEditor::_animation_save_menu(int p_option) { } } -void AnimationPlayerEditor::_unhandled_key_input(const InputEvent &p_ev) { +void AnimationPlayerEditor::_unhandled_key_input(const Ref<InputEvent> &p_ev) { - if (is_visible_in_tree() && p_ev.type == InputEvent::KEY && p_ev.key.pressed && !p_ev.key.echo && !p_ev.key.mod.alt && !p_ev.key.mod.control && !p_ev.key.mod.meta) { + Ref<InputEventKey> k = p_ev; + if (is_visible_in_tree() && k.is_valid() && k->is_pressed() && !k->is_echo() && !k->get_alt() && !k->get_control() && !k->get_metakey()) { - switch (p_ev.key.scancode) { + switch (k->get_scancode()) { case KEY_A: { - if (!p_ev.key.mod.shift) + if (!k->get_shift()) _play_bw_from_pressed(); else _play_bw_pressed(); @@ -1182,7 +1177,7 @@ void AnimationPlayerEditor::_unhandled_key_input(const InputEvent &p_ev) { _stop_pressed(); } break; case KEY_D: { - if (!p_ev.key.mod.shift) + if (!k->get_shift()) _play_from_pressed(); else _play_pressed(); @@ -1367,8 +1362,6 @@ AnimationPlayerEditor::AnimationPlayerEditor(EditorNode *p_editor) { //tool_anim->get_popup()->add_item("Edit Anim Resource",TOOL_PASTE_ANIM); hb->add_child(tool_anim); - nodename = memnew(Button); - hb->add_child(nodename); pin = memnew(ToolButton); pin->set_toggle_mode(true); hb->add_child(pin); @@ -1384,19 +1377,18 @@ AnimationPlayerEditor::AnimationPlayerEditor(EditorNode *p_editor) { name_dialog->set_title(TTR("Create New Animation")); name_dialog->set_hide_on_ok(false); add_child(name_dialog); - name = memnew(LineEdit); - name_dialog->add_child(name); - name->set_position(Point2(18, 30)); - name->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 10); - name_dialog->register_text_enter(name); + VBoxContainer *vb = memnew(VBoxContainer); + name_dialog->add_child(vb); l = memnew(Label); l->set_text(TTR("Animation Name:")); - l->set_position(Point2(10, 10)); - - name_dialog->add_child(l); + vb->add_child(l); name_title = l; + name = memnew(LineEdit); + vb->add_child(name); + name_dialog->register_text_enter(name); + error_dialog = memnew(ConfirmationDialog); error_dialog->get_ok()->set_text(TTR("Close")); //error_dialog->get_cancel()->set_text("Close"); diff --git a/editor/plugins/animation_player_editor_plugin.h b/editor/plugins/animation_player_editor_plugin.h index a042da14df..ceaa73569a 100644 --- a/editor/plugins/animation_player_editor_plugin.h +++ b/editor/plugins/animation_player_editor_plugin.h @@ -85,7 +85,6 @@ class AnimationPlayerEditor : public VBoxContainer { Button *remove_anim; MenuButton *tool_anim; ToolButton *pin; - Button *nodename; SpinBox *frame; LineEdit *scale; LineEdit *name; @@ -159,7 +158,7 @@ class AnimationPlayerEditor : public VBoxContainer { void _animation_key_editor_anim_len_changed(float p_new); void _animation_key_editor_anim_step_changed(float p_len); - void _unhandled_key_input(const InputEvent &p_ev); + void _unhandled_key_input(const Ref<InputEvent> &p_ev); void _animation_tool_menu(int p_option); void _animation_save_menu(int p_option); @@ -167,7 +166,7 @@ class AnimationPlayerEditor : public VBoxContainer { protected: void _notification(int p_what); - void _gui_input(InputEvent p_event); + void _gui_input(Ref<InputEvent> p_event); void _node_removed(Node *p_node); static void _bind_methods(); diff --git a/editor/plugins/animation_tree_editor_plugin.cpp b/editor/plugins/animation_tree_editor_plugin.cpp index e126cdf40f..d67832e10b 100644 --- a/editor/plugins/animation_tree_editor_plugin.cpp +++ b/editor/plugins/animation_tree_editor_plugin.cpp @@ -735,139 +735,139 @@ void AnimationTreeEditor::_node_edit_property(const StringName& p_node) { } #endif -void AnimationTreeEditor::_gui_input(InputEvent p_event) { +void AnimationTreeEditor::_gui_input(Ref<InputEvent> p_event) { - switch (p_event.type) { + Ref<InputEventMouseButton> mb = p_event; - case InputEvent::MOUSE_BUTTON: { + if (mb.is_valid()) { - if (p_event.mouse_button.pressed) { + if (mb->is_pressed()) { - if (p_event.mouse_button.button_index == 1) { - click_pos = Point2(p_event.mouse_button.x, p_event.mouse_button.y); - click_motion = click_pos; - click_type = _locate_click(click_pos, &click_node, &click_slot); - if (click_type != CLICK_NONE) { + if (mb->get_button_index() == 1) { + click_pos = Point2(mb->get_position().x, mb->get_position().y); + click_motion = click_pos; + click_type = _locate_click(click_pos, &click_node, &click_slot); + if (click_type != CLICK_NONE) { - order.erase(click_node); - order.push_back(click_node); - update(); - } + order.erase(click_node); + order.push_back(click_node); + update(); + } - switch (click_type) { - case CLICK_INPUT_SLOT: { - click_pos = _get_slot_pos(click_node, true, click_slot); - } break; - case CLICK_OUTPUT_SLOT: { - click_pos = _get_slot_pos(click_node, false, click_slot); - } break; - case CLICK_PARAMETER: { - - edited_node = click_node; - renaming_edit = false; - _popup_edit_dialog(); - //open editor - //_node_edit_property(click_node); - } break; - default: {} - } + switch (click_type) { + case CLICK_INPUT_SLOT: { + click_pos = _get_slot_pos(click_node, true, click_slot); + } break; + case CLICK_OUTPUT_SLOT: { + click_pos = _get_slot_pos(click_node, false, click_slot); + } break; + case CLICK_PARAMETER: { + + edited_node = click_node; + renaming_edit = false; + _popup_edit_dialog(); + //open editor + //_node_edit_property(click_node); + } break; + default: {} } - if (p_event.mouse_button.button_index == 2) { - - if (click_type != CLICK_NONE) { - click_type = CLICK_NONE; - update(); - } else { - // try to disconnect/remove - - Point2 rclick_pos = Point2(p_event.mouse_button.x, p_event.mouse_button.y); - rclick_type = _locate_click(rclick_pos, &rclick_node, &rclick_slot); - if (rclick_type == CLICK_INPUT_SLOT || rclick_type == CLICK_OUTPUT_SLOT) { - - node_popup->clear(); - node_popup->add_item(TTR("Disconnect"), NODE_DISCONNECT); - if (anim_tree->node_get_type(rclick_node) == AnimationTreePlayer::NODE_TRANSITION) { - node_popup->add_item(TTR("Add Input"), NODE_ADD_INPUT); - if (rclick_type == CLICK_INPUT_SLOT) { - if (anim_tree->transition_node_has_input_auto_advance(rclick_node, rclick_slot)) - node_popup->add_item(TTR("Clear Auto-Advance"), NODE_CLEAR_AUTOADVANCE); - else - node_popup->add_item(TTR("Set Auto-Advance"), NODE_SET_AUTOADVANCE); - node_popup->add_item(TTR("Delete Input"), NODE_DELETE_INPUT); - } - } + } + if (mb->get_button_index() == 2) { - node_popup->set_position(rclick_pos + get_global_position()); - node_popup->popup(); + if (click_type != CLICK_NONE) { + click_type = CLICK_NONE; + update(); + } else { + // try to disconnect/remove + + Point2 rclick_pos = Point2(mb->get_position().x, mb->get_position().y); + rclick_type = _locate_click(rclick_pos, &rclick_node, &rclick_slot); + if (rclick_type == CLICK_INPUT_SLOT || rclick_type == CLICK_OUTPUT_SLOT) { + + node_popup->clear(); + node_popup->add_item(TTR("Disconnect"), NODE_DISCONNECT); + if (anim_tree->node_get_type(rclick_node) == AnimationTreePlayer::NODE_TRANSITION) { + node_popup->add_item(TTR("Add Input"), NODE_ADD_INPUT); + if (rclick_type == CLICK_INPUT_SLOT) { + if (anim_tree->transition_node_has_input_auto_advance(rclick_node, rclick_slot)) + node_popup->add_item(TTR("Clear Auto-Advance"), NODE_CLEAR_AUTOADVANCE); + else + node_popup->add_item(TTR("Set Auto-Advance"), NODE_SET_AUTOADVANCE); + node_popup->add_item(TTR("Delete Input"), NODE_DELETE_INPUT); + } } - if (rclick_type == CLICK_NODE) { - node_popup->clear(); - node_popup->add_item(TTR("Rename"), NODE_RENAME); - node_popup->add_item(TTR("Remove"), NODE_ERASE); - if (anim_tree->node_get_type(rclick_node) == AnimationTreePlayer::NODE_TRANSITION) - node_popup->add_item(TTR("Add Input"), NODE_ADD_INPUT); - node_popup->set_position(rclick_pos + get_global_position()); - node_popup->popup(); - } + node_popup->set_position(rclick_pos + get_global_position()); + node_popup->popup(); } - } - } else { - if (p_event.mouse_button.button_index == 1 && click_type != CLICK_NONE) { + if (rclick_type == CLICK_NODE) { + node_popup->clear(); + node_popup->add_item(TTR("Rename"), NODE_RENAME); + node_popup->add_item(TTR("Remove"), NODE_ERASE); + if (anim_tree->node_get_type(rclick_node) == AnimationTreePlayer::NODE_TRANSITION) + node_popup->add_item(TTR("Add Input"), NODE_ADD_INPUT); + node_popup->set_position(rclick_pos + get_global_position()); + node_popup->popup(); + } + } + } + } else { - switch (click_type) { - case CLICK_INPUT_SLOT: - case CLICK_OUTPUT_SLOT: { + if (mb->get_button_index() == 1 && click_type != CLICK_NONE) { - Point2 dst_click_pos = Point2(p_event.mouse_button.x, p_event.mouse_button.y); - StringName id; - int slot; - ClickType dst_click_type = _locate_click(dst_click_pos, &id, &slot); + switch (click_type) { + case CLICK_INPUT_SLOT: + case CLICK_OUTPUT_SLOT: { - if (dst_click_type == CLICK_INPUT_SLOT && click_type == CLICK_OUTPUT_SLOT) { + Point2 dst_click_pos = Point2(mb->get_position().x, mb->get_position().y); + StringName id; + int slot; + ClickType dst_click_type = _locate_click(dst_click_pos, &id, &slot); - anim_tree->connect_nodes(click_node, id, slot); - } - if (click_type == CLICK_INPUT_SLOT && dst_click_type == CLICK_OUTPUT_SLOT) { + if (dst_click_type == CLICK_INPUT_SLOT && click_type == CLICK_OUTPUT_SLOT) { - anim_tree->connect_nodes(id, click_node, click_slot); - } + anim_tree->connect_nodes(click_node, id, slot); + } + if (click_type == CLICK_INPUT_SLOT && dst_click_type == CLICK_OUTPUT_SLOT) { - } break; - case CLICK_NODE: { - Point2 new_pos = anim_tree->node_get_pos(click_node) + (click_motion - click_pos); - if (new_pos.x < 5) - new_pos.x = 5; - if (new_pos.y < 5) - new_pos.y = 5; - anim_tree->node_set_pos(click_node, new_pos); - - } break; - default: {} - } + anim_tree->connect_nodes(id, click_node, click_slot); + } - click_type = CLICK_NONE; - update(); + } break; + case CLICK_NODE: { + Point2 new_pos = anim_tree->node_get_pos(click_node) + (click_motion - click_pos); + if (new_pos.x < 5) + new_pos.x = 5; + if (new_pos.y < 5) + new_pos.y = 5; + anim_tree->node_set_pos(click_node, new_pos); + + } break; + default: {} } + + click_type = CLICK_NONE; + update(); } } + } - case InputEvent::MOUSE_MOTION: { + Ref<InputEventMouseMotion> mm = p_event; - if (p_event.mouse_motion.button_mask & 1 && click_type != CLICK_NONE) { + if (mm.is_valid()) { - click_motion = Point2(p_event.mouse_button.x, p_event.mouse_button.y); - update(); - } - if ((p_event.mouse_motion.button_mask & 4 || Input::get_singleton()->is_key_pressed(KEY_SPACE))) { + if (mm->get_button_mask() & 1 && click_type != CLICK_NONE) { - h_scroll->set_value(h_scroll->get_value() - p_event.mouse_motion.relative_x); - v_scroll->set_value(v_scroll->get_value() - p_event.mouse_motion.relative_y); - update(); - } + click_motion = Point2(mm->get_position().x, mm->get_position().y); + update(); + } + if ((mm->get_button_mask() & 4 || Input::get_singleton()->is_key_pressed(KEY_SPACE))) { - } break; + h_scroll->set_value(h_scroll->get_value() - mm->get_relative().x); + v_scroll->set_value(v_scroll->get_value() - mm->get_relative().y); + update(); + } } } @@ -876,7 +876,7 @@ void AnimationTreeEditor::_draw_cos_line(const Vector2 &p_from, const Vector2 &p static const int steps = 20; Rect2 r; - r.pos = p_from; + r.position = p_from; r.expand_to(p_to); Vector2 sign = Vector2((p_from.x < p_to.x) ? 1 : -1, (p_from.y < p_to.y) ? 1 : -1); bool flip = sign.x * sign.y < 0; @@ -888,7 +888,7 @@ void AnimationTreeEditor::_draw_cos_line(const Vector2 &p_from, const Vector2 &p float c = -Math::cos(d * Math_PI) * 0.5 + 0.5; if (flip) c = 1.0 - c; - Vector2 p = r.pos + Vector2(d * r.size.width, c * r.size.height); + Vector2 p = r.position + Vector2(d * r.size.width, c * r.size.height); if (i > 0) { diff --git a/editor/plugins/animation_tree_editor_plugin.h b/editor/plugins/animation_tree_editor_plugin.h index 8bbe22387b..785f042dd9 100644 --- a/editor/plugins/animation_tree_editor_plugin.h +++ b/editor/plugins/animation_tree_editor_plugin.h @@ -155,7 +155,7 @@ class AnimationTreeEditor : public Control { protected: void _notification(int p_what); - void _gui_input(InputEvent p_event); + void _gui_input(Ref<InputEvent> p_event); static void _bind_methods(); public: diff --git a/editor/plugins/baked_light_baker.h b/editor/plugins/baked_light_baker.h index 5f32e236c0..123812fc07 100644 --- a/editor/plugins/baked_light_baker.h +++ b/editor/plugins/baked_light_baker.h @@ -31,7 +31,7 @@ #define BAKED_LIGHT_BAKER_H #include "os/thread.h" -#include "scene/3d/baked_light_instance.h" + #include "scene/3d/light.h" #include "scene/3d/mesh_instance.h" diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index 08e09dd629..4313c1a91b 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -204,17 +204,19 @@ void CanvasItemEditor::_edit_set_pivot(const Vector2 &mouse_pos) { undo_redo->commit_action(); } -void CanvasItemEditor::_unhandled_key_input(const InputEvent &p_ev) { +void CanvasItemEditor::_unhandled_key_input(const Ref<InputEvent> &p_ev) { + + Ref<InputEventKey> k = p_ev; if (!is_visible_in_tree() || get_viewport()->gui_has_modal_stack()) return; - if (p_ev.key.mod.control) + if (k->get_control()) return; - if (p_ev.key.pressed && !p_ev.key.echo && p_ev.key.scancode == KEY_V && drag == DRAG_NONE && can_move_pivot) { + if (k->is_pressed() && !k->is_echo() && k->get_scancode() == KEY_V && drag == DRAG_NONE && can_move_pivot) { - if (p_ev.key.mod.shift) { + if (k->get_shift()) { //move drag pivot drag = DRAG_PIVOT; } else if (!Input::get_singleton()->is_mouse_button_pressed(0)) { @@ -534,10 +536,10 @@ void CanvasItemEditor::_find_canvas_items_at_rect(const Rect2 &p_rect, Node *p_n Rect2 rect = c->get_item_rect(); Transform2D xform = p_parent_xform * p_canvas_xform * c->get_transform(); - if (p_rect.has_point(xform.xform(rect.pos)) && - p_rect.has_point(xform.xform(rect.pos + Vector2(rect.size.x, 0))) && - p_rect.has_point(xform.xform(rect.pos + Vector2(rect.size.x, rect.size.y))) && - p_rect.has_point(xform.xform(rect.pos + Vector2(0, rect.size.y)))) { + if (p_rect.has_point(xform.xform(rect.position)) && + p_rect.has_point(xform.xform(rect.position + Vector2(rect.size.x, 0))) && + p_rect.has_point(xform.xform(rect.position + Vector2(rect.size.x, rect.size.y))) && + p_rect.has_point(xform.xform(rect.position + Vector2(0, rect.size.y)))) { r_items->push_back(c); } @@ -650,7 +652,7 @@ void CanvasItemEditor::_key_move(const Vector2 &p_dir, bool p_snap, KeyMoveMODE // drag = transform.affine_inverse().basis_xform(p_dir); // zoom sensitive drag = canvas_item->get_global_transform_with_canvas().affine_inverse().basis_xform(drag); Rect2 local_rect = canvas_item->get_item_rect(); - local_rect.pos += drag; + local_rect.position += drag; undo_redo->add_do_method(canvas_item, "edit_set_rect", local_rect); } else { // p_move_mode==MOVE_LOCAL_BASE || p_move_mode==MOVE_LOCAL_WITH_ROT @@ -678,7 +680,7 @@ Point2 CanvasItemEditor::_find_topleftmost_point() { Vector2 tl = Point2(1e10, 1e10); Rect2 r2; - r2.pos = tl; + r2.position = tl; List<Node *> &selection = editor_selection->get_selected_node_list(); @@ -693,13 +695,13 @@ Point2 CanvasItemEditor::_find_topleftmost_point() { Rect2 rect = canvas_item->get_item_rect(); Transform2D xform = canvas_item->get_global_transform_with_canvas(); - r2.expand_to(xform.xform(rect.pos)); - r2.expand_to(xform.xform(rect.pos + Vector2(rect.size.x, 0))); - r2.expand_to(xform.xform(rect.pos + rect.size)); - r2.expand_to(xform.xform(rect.pos + Vector2(0, rect.size.y))); + r2.expand_to(xform.xform(rect.position)); + r2.expand_to(xform.xform(rect.position + Vector2(rect.size.x, 0))); + r2.expand_to(xform.xform(rect.position + rect.size)); + r2.expand_to(xform.xform(rect.position + Vector2(0, rect.size.y))); } - return r2.pos; + return r2.position; } int CanvasItemEditor::get_item_count() { @@ -757,18 +759,18 @@ CanvasItemEditor::DragType CanvasItemEditor::_find_drag_type(const Transform2D & Vector2 endpoints[4] = { - xform.xform(rect.pos), - xform.xform(rect.pos + Vector2(rect.size.x, 0)), - xform.xform(rect.pos + rect.size), - xform.xform(rect.pos + Vector2(0, rect.size.y)) + xform.xform(rect.position), + xform.xform(rect.position + Vector2(rect.size.x, 0)), + xform.xform(rect.position + rect.size), + xform.xform(rect.position + Vector2(0, rect.size.y)) }; Vector2 endpointsl[4] = { - xforml.xform(rect.pos), - xforml.xform(rect.pos + Vector2(rect.size.x, 0)), - xforml.xform(rect.pos + rect.size), - xforml.xform(rect.pos + Vector2(0, rect.size.y)) + xforml.xform(rect.position), + xforml.xform(rect.position + Vector2(rect.size.x, 0)), + xforml.xform(rect.position + rect.size), + xforml.xform(rect.position + Vector2(0, rect.size.y)) }; DragType dragger[] = { @@ -958,9 +960,9 @@ bool CanvasItemEditor::get_remove_list(List<Node *> *p_list) { return false; //!p_list->empty(); } -void CanvasItemEditor::_list_select(const InputEventMouseButton &b) { +void CanvasItemEditor::_list_select(const Ref<InputEventMouseButton> &b) { - Point2 click = Point2(b.x, b.y); + Point2 click = b->get_position(); Node *scene = editor->get_edited_scene(); if (!scene) @@ -982,7 +984,7 @@ void CanvasItemEditor::_list_select(const InputEventMouseButton &b) { CanvasItem *item = selection_results[0].item; selection_results.clear(); - additive_selection = b.mod.shift; + additive_selection = b->get_shift(); if (!_select(item, click, additive_selection, false)) return; @@ -1008,13 +1010,12 @@ void CanvasItemEditor::_list_select(const InputEventMouseButton &b) { selection_menu->add_item(item->get_name()); selection_menu->set_item_icon(i, icon); selection_menu->set_item_metadata(i, node_path); - selection_menu->set_item_tooltip(i, String(item->get_name()) + - "\nType: " + item->get_class() + "\nPath: " + node_path); + selection_menu->set_item_tooltip(i, String(item->get_name()) + "\nType: " + item->get_class() + "\nPath: " + node_path); } - additive_selection = b.mod.shift; + additive_selection = b->get_shift(); - selection_menu->set_global_position(Vector2(b.global_x, b.global_y)); + selection_menu->set_global_position(b->get_global_position()); selection_menu->popup(); selection_menu->call_deferred("grab_click_focus"); selection_menu->set_invalidate_click_until_motion(); @@ -1023,7 +1024,7 @@ void CanvasItemEditor::_list_select(const InputEventMouseButton &b) { } } -void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { +void CanvasItemEditor::_viewport_gui_input(const Ref<InputEvent> &p_event) { { @@ -1039,40 +1040,53 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { } } - if (p_event.type == InputEvent::MOUSE_BUTTON) { + Ref<InputEventMouseButton> b = p_event; - const InputEventMouseButton &b = p_event.mouse_button; + if (b.is_valid()) { - if (b.button_index == BUTTON_WHEEL_DOWN) { + if (b->get_button_index() == BUTTON_WHEEL_DOWN) { - if (zoom < MIN_ZOOM) - return; + if (bool(EditorSettings::get_singleton()->get("editors/2d/scroll_to_pan"))) { + + v_scroll->set_value(v_scroll->get_value() + int(EditorSettings::get_singleton()->get("editors/2d/pan_speed")) / zoom * b->get_factor()); + + } else { + + if (zoom < MIN_ZOOM) + return; - float prev_zoom = zoom; - zoom = zoom * 0.95; - { - Point2 ofs(b.x, b.y); - ofs = ofs / prev_zoom - ofs / zoom; - h_scroll->set_value(h_scroll->get_value() + ofs.x); - v_scroll->set_value(v_scroll->get_value() + ofs.y); + float prev_zoom = zoom; + zoom = zoom * (1 - (0.05 * b->get_factor())); + { + Point2 ofs = b->get_position(); + ofs = ofs / prev_zoom - ofs / zoom; + h_scroll->set_value(h_scroll->get_value() + ofs.x); + v_scroll->set_value(v_scroll->get_value() + ofs.y); + } } + _update_scroll(0); viewport->update(); return; } - if (b.button_index == BUTTON_WHEEL_UP) { + if (b->get_button_index() == BUTTON_WHEEL_UP) { - if (zoom > MAX_ZOOM) - return; + if (bool(EditorSettings::get_singleton()->get("editors/2d/scroll_to_pan"))) { + + v_scroll->set_value(v_scroll->get_value() - int(EditorSettings::get_singleton()->get("editors/2d/pan_speed")) / zoom * b->get_factor()); - float prev_zoom = zoom; - zoom = zoom * (1.0 / 0.95); - { - Point2 ofs(b.x, b.y); - ofs = ofs / prev_zoom - ofs / zoom; - h_scroll->set_value(h_scroll->get_value() + ofs.x); - v_scroll->set_value(v_scroll->get_value() + ofs.y); + } else { + if (zoom > MAX_ZOOM) return; + + float prev_zoom = zoom; + zoom = zoom * ((0.95 + (0.05 * b->get_factor())) / 0.95); + { + Point2 ofs = b->get_position(); + ofs = ofs / prev_zoom - ofs / zoom; + h_scroll->set_value(h_scroll->get_value() + ofs.x); + v_scroll->set_value(v_scroll->get_value() + ofs.y); + } } _update_scroll(0); @@ -1080,9 +1094,25 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { return; } - if (b.button_index == BUTTON_RIGHT) { + if (b->get_button_index() == BUTTON_WHEEL_LEFT) { + + if (bool(EditorSettings::get_singleton()->get("editors/2d/scroll_to_pan"))) { + + h_scroll->set_value(h_scroll->get_value() - int(EditorSettings::get_singleton()->get("editors/2d/pan_speed")) / zoom * b->get_factor()); + } + } + + if (b->get_button_index() == BUTTON_WHEEL_RIGHT) { + + if (bool(EditorSettings::get_singleton()->get("editors/2d/scroll_to_pan"))) { - if (b.pressed && (tool == TOOL_SELECT && b.mod.alt)) { + h_scroll->set_value(h_scroll->get_value() + int(EditorSettings::get_singleton()->get("editors/2d/pan_speed")) / zoom * b->get_factor()); + } + } + + if (b->get_button_index() == BUTTON_RIGHT) { + + if (b->is_pressed() && (tool == TOOL_SELECT && b->get_alt())) { _list_select(b); return; @@ -1129,7 +1159,7 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { } else if (box_selecting) { box_selecting = false; viewport->update(); - } else if (b.pressed) { + } else if (b->is_pressed()) { #if 0 ref_item = NULL; Node* scene = get_scene()->get_root_node()->cast_to<EditorNode>()->get_edited_scene(); @@ -1145,16 +1175,16 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { return; */ - if (b.button_index == BUTTON_LEFT && tool == TOOL_LIST_SELECT) { - if (b.pressed) + if (b->get_button_index() == BUTTON_LEFT && tool == TOOL_LIST_SELECT) { + if (b->is_pressed()) _list_select(b); return; } - if (b.button_index == BUTTON_LEFT && tool == TOOL_EDIT_PIVOT) { - if (b.pressed) { + if (b->get_button_index() == BUTTON_LEFT && tool == TOOL_EDIT_PIVOT) { + if (b->is_pressed()) { - Point2 mouse_pos(b.x, b.y); + Point2 mouse_pos = b->get_position(); mouse_pos = transform.affine_inverse().xform(mouse_pos); mouse_pos = snap_point(mouse_pos); _edit_set_pivot(mouse_pos); @@ -1162,10 +1192,10 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { return; } - if (tool == TOOL_PAN || b.button_index != BUTTON_LEFT || Input::get_singleton()->is_key_pressed(KEY_SPACE)) + if (tool == TOOL_PAN || b->get_button_index() != BUTTON_LEFT || Input::get_singleton()->is_key_pressed(KEY_SPACE)) return; - if (!b.pressed) { + if (!b->is_pressed()) { if (drag != DRAG_NONE) { @@ -1227,7 +1257,7 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { if (box_selecting) { #if 0 - if ( ! b.mod.shift ) _clear_canvas_items(); + if ( ! b->get_shift() ) _clear_canvas_items(); if ( box_selection_end() ) return; #endif @@ -1272,8 +1302,8 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { E->get().to }; - Vector2 p = Geometry::get_closest_point_to_segment_2d(Vector2(b.x, b.y), s); - float d = p.distance_to(Vector2(b.x, b.y)); + Vector2 p = Geometry::get_closest_point_to_segment_2d(b->get_position(), s); + float d = p.distance_to(b->get_position()); if (d < bone_width && d < closest_dist) { Cbone = E; closest_dist = d; @@ -1340,9 +1370,9 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { CanvasItemEditorSelectedItem *se = editor_selection->get_node_editor_data<CanvasItemEditorSelectedItem>(canvas_item); ERR_FAIL_COND(!se); - Point2 click(b.x, b.y); + Point2 click = b->get_position(); - if ((b.mod.control && tool == TOOL_SELECT) || tool == TOOL_ROTATE) { + if ((b->get_control() && tool == TOOL_SELECT) || tool == TOOL_ROTATE) { drag = DRAG_ROTATE; drag_from = transform.affine_inverse().xform(click); @@ -1361,7 +1391,7 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { if (tool == TOOL_SELECT) { drag = _find_drag_type(xform, rect, click, drag_point_from); - if (b.doubleclick) { + if (b->is_doubleclick()) { if (canvas_item->get_filename() != "" && canvas_item != editor->get_edited_scene()) { @@ -1386,9 +1416,9 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { //multi canvas_item edit - Point2 click = Point2(b.x, b.y); + Point2 click = b->get_position(); - if ((b.mod.alt || tool == TOOL_MOVE) && get_item_count()) { + if ((b->get_alt() || tool == TOOL_MOVE) && get_item_count()) { _prepare_drag(click); viewport->update(); return; @@ -1433,37 +1463,36 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { }; c = n->cast_to<CanvasItem>(); #if 0 - if ( b.pressed ) box_selection_start( click ); + if ( b->is_pressed() ) box_selection_start( click ); #endif - additive_selection = b.mod.shift; + additive_selection = b->get_shift(); if (!_select(c, click, additive_selection)) return; } - if (p_event.type == InputEvent::MOUSE_MOTION) { + Ref<InputEventMouseMotion> m = p_event; + if (m.is_valid()) { if (!viewport->has_focus() && (!get_focus_owner() || !get_focus_owner()->is_text_field())) viewport->call_deferred("grab_focus"); - const InputEventMouseMotion &m = p_event.mouse_motion; - if (box_selecting) { - box_selecting_to = transform.affine_inverse().xform(Point2(m.x, m.y)); + box_selecting_to = transform.affine_inverse().xform(m->get_position()); viewport->update(); return; } if (drag == DRAG_NONE) { - if ((m.button_mask & BUTTON_MASK_LEFT && tool == TOOL_PAN) || m.button_mask & BUTTON_MASK_MIDDLE || (m.button_mask & BUTTON_MASK_LEFT && Input::get_singleton()->is_key_pressed(KEY_SPACE))) { + if ((m->get_button_mask() & BUTTON_MASK_LEFT && tool == TOOL_PAN) || m->get_button_mask() & BUTTON_MASK_MIDDLE || (m->get_button_mask() & BUTTON_MASK_LEFT && Input::get_singleton()->is_key_pressed(KEY_SPACE))) { Point2i relative; if (bool(EditorSettings::get_singleton()->get("editors/2d/warped_mouse_panning"))) { relative = Input::get_singleton()->warp_mouse_motion(m, viewport->get_global_rect()); } else { - relative = Point2i(m.relative_x, m.relative_y); + relative = m->get_relative(); } h_scroll->set_value(h_scroll->get_value() - relative.x / zoom); @@ -1496,7 +1525,7 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { } Vector2 dfrom = drag_from; - Vector2 dto = transform.affine_inverse().xform(Point2(m.x, m.y)); + Vector2 dto = transform.affine_inverse().xform(m->get_position()); if (canvas_item->has_meta("_edit_lock_")) continue; @@ -1530,8 +1559,8 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { continue; } - bool uniform = m.mod.shift; - bool symmetric = m.mod.alt; + bool uniform = m->get_shift(); + bool symmetric = m->get_alt(); dto = dto - (drag == DRAG_ALL || drag == DRAG_NODE_2D ? drag_from - drag_point_from : Vector2(0, 0)); @@ -1551,8 +1580,8 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { canvas_item->get_global_transform_with_canvas().affine_inverse().xform(dfrom); Rect2 local_rect = canvas_item->get_item_rect(); - Vector2 begin = local_rect.pos; - Vector2 end = local_rect.pos + local_rect.size; + Vector2 begin = local_rect.position; + Vector2 end = local_rect.position + local_rect.size; Vector2 minsize = canvas_item->edit_get_minimum_size(); if (uniform) { @@ -1644,7 +1673,7 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { if (!dragging_bone) { - local_rect.pos = begin; + local_rect.position = begin; local_rect.size = end - begin; canvas_item->edit_set_rect(local_rect); @@ -1765,25 +1794,25 @@ void CanvasItemEditor::_viewport_gui_input(const InputEvent &p_event) { } } - if (p_event.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_event; - const InputEventKey &k = p_event.key; + if (k.is_valid()) { - if (k.pressed && drag == DRAG_NONE) { + if (k->is_pressed() && drag == DRAG_NONE) { KeyMoveMODE move_mode = MOVE_VIEW_BASE; - if (k.mod.alt) move_mode = MOVE_LOCAL_BASE; - if (k.mod.control || k.mod.meta) move_mode = MOVE_LOCAL_WITH_ROT; - - if (k.scancode == KEY_UP) - _key_move(Vector2(0, -1), k.mod.shift, move_mode); - else if (k.scancode == KEY_DOWN) - _key_move(Vector2(0, 1), k.mod.shift, move_mode); - else if (k.scancode == KEY_LEFT) - _key_move(Vector2(-1, 0), k.mod.shift, move_mode); - else if (k.scancode == KEY_RIGHT) - _key_move(Vector2(1, 0), k.mod.shift, move_mode); - else if (k.scancode == KEY_ESCAPE) { + if (k->get_alt()) move_mode = MOVE_LOCAL_BASE; + if (k->get_control() || k->get_metakey()) move_mode = MOVE_LOCAL_WITH_ROT; + + if (k->get_scancode() == KEY_UP) + _key_move(Vector2(0, -1), k->get_shift(), move_mode); + else if (k->get_scancode() == KEY_DOWN) + _key_move(Vector2(0, 1), k->get_shift(), move_mode); + else if (k->get_scancode() == KEY_LEFT) + _key_move(Vector2(-1, 0), k->get_shift(), move_mode); + else if (k->get_scancode() == KEY_RIGHT) + _key_move(Vector2(1, 0), k->get_shift(), move_mode); + else if (k->get_scancode() == KEY_ESCAPE) { editor_selection->clear(); viewport->update(); } else @@ -1837,7 +1866,7 @@ void CanvasItemEditor::_viewport_draw() { if (h_scroll->is_visible_in_tree()) size.height -= h_scroll->get_size().height; - get_stylebox("EditorFocus", "EditorStyles")->draw(ci, Rect2(Point2(), size)); + get_stylebox("Focus", "EditorStyles")->draw(ci, Rect2(Point2(), size)); } Ref<Texture> lock = get_icon("Lock", "EditorIcons"); @@ -1867,10 +1896,10 @@ void CanvasItemEditor::_viewport_draw() { Vector2 endpoints[4] = { - xform.xform(rect.pos), - xform.xform(rect.pos + Vector2(rect.size.x, 0)), - xform.xform(rect.pos + rect.size), - xform.xform(rect.pos + Vector2(0, rect.size.y)) + xform.xform(rect.position), + xform.xform(rect.position + Vector2(rect.size.x, 0)), + xform.xform(rect.position + rect.size), + xform.xform(rect.position + Vector2(0, rect.size.y)) }; Color c = Color(1, 0.6, 0.4, 0.7); @@ -2211,7 +2240,7 @@ void CanvasItemEditor::_find_canvas_items_span(Node *p_node, Rect2 &r_rect, cons lock.group = c->has_meta("_edit_group_"); if (lock.group || lock.lock) { - lock.pos = xform.xform(rect.pos); + lock.pos = xform.xform(rect.position); lock_list.push_back(lock); } @@ -2227,10 +2256,10 @@ void CanvasItemEditor::_find_canvas_items_span(Node *p_node, Rect2 &r_rect, cons bone_list[id].last_pass = bone_last_frame; } - r_rect.expand_to(xform.xform(rect.pos)); - r_rect.expand_to(xform.xform(rect.pos + Point2(rect.size.x, 0))); - r_rect.expand_to(xform.xform(rect.pos + Point2(0, rect.size.y))); - r_rect.expand_to(xform.xform(rect.pos + rect.size)); + r_rect.expand_to(xform.xform(rect.position)); + r_rect.expand_to(xform.xform(rect.position + Point2(rect.size.x, 0))); + r_rect.expand_to(xform.xform(rect.position + Point2(0, rect.size.y))); + r_rect.expand_to(xform.xform(rect.position + rect.size)); } } @@ -2276,19 +2305,19 @@ void CanvasItemEditor::_update_scrollbars() { //expand area so it's easier to do animations and stuff at 0,0 canvas_item_rect.size += screen_rect * 2; - canvas_item_rect.pos -= screen_rect; + canvas_item_rect.position -= screen_rect; Point2 ofs; if (canvas_item_rect.size.height <= (local_rect.size.y / zoom)) { v_scroll->hide(); - ofs.y = canvas_item_rect.pos.y; + ofs.y = canvas_item_rect.position.y; } else { v_scroll->show(); - v_scroll->set_min(canvas_item_rect.pos.y); - v_scroll->set_max(canvas_item_rect.pos.y + canvas_item_rect.size.y); + v_scroll->set_min(canvas_item_rect.position.y); + v_scroll->set_max(canvas_item_rect.position.y + canvas_item_rect.size.y); v_scroll->set_page(local_rect.size.y / zoom); if (first_update) { //so 0,0 is visible @@ -2303,12 +2332,12 @@ void CanvasItemEditor::_update_scrollbars() { if (canvas_item_rect.size.width <= (local_rect.size.x / zoom)) { h_scroll->hide(); - ofs.x = canvas_item_rect.pos.x; + ofs.x = canvas_item_rect.position.x; } else { h_scroll->show(); - h_scroll->set_min(canvas_item_rect.pos.x); - h_scroll->set_max(canvas_item_rect.pos.x + canvas_item_rect.size.x); + h_scroll->set_min(canvas_item_rect.position.x); + h_scroll->set_max(canvas_item_rect.position.x + canvas_item_rect.size.x); h_scroll->set_page(local_rect.size.x / zoom); ofs.x = h_scroll->get_value(); } @@ -2976,7 +3005,7 @@ void CanvasItemEditor::_focus_selection(int p_op) { Transform2D t(angle, Vector2(0.f, 0.f)); item_rect = t.xform(item_rect); - Rect2 canvas_item_rect(pos + scale * item_rect.pos, scale * item_rect.size); + Rect2 canvas_item_rect(pos + scale * item_rect.position, scale * item_rect.size); if (count == 1) { rect = canvas_item_rect; } else { @@ -2987,7 +3016,7 @@ void CanvasItemEditor::_focus_selection(int p_op) { if (p_op == VIEW_CENTER_TO_SELECTION) { - center = rect.pos + rect.size / 2; + center = rect.position + rect.size / 2; Vector2 offset = viewport->get_size() / 2 - editor->get_scene_root()->get_global_canvas_transform().xform(center); h_scroll->set_value(h_scroll->get_value() - offset.x / zoom); v_scroll->set_value(v_scroll->get_value() - offset.y / zoom); diff --git a/editor/plugins/canvas_item_editor_plugin.h b/editor/plugins/canvas_item_editor_plugin.h index 7f09b92f4c..22fa5b5db8 100644 --- a/editor/plugins/canvas_item_editor_plugin.h +++ b/editor/plugins/canvas_item_editor_plugin.h @@ -322,7 +322,7 @@ class CanvasItemEditor : public VBoxContainer { void _clear_canvas_items(); void _visibility_changed(ObjectID p_canvas_item); void _key_move(const Vector2 &p_dir, bool p_snap, KeyMoveMODE p_move_mode); - void _list_select(const InputEventMouseButton &b); + void _list_select(const Ref<InputEventMouseButton> &b); DragType _find_drag_type(const Transform2D &p_xform, const Rect2 &p_local_rect, const Point2 &p_click, Vector2 &r_point); void _prepare_drag(const Point2 &p_click_pos); @@ -352,9 +352,9 @@ class CanvasItemEditor : public VBoxContainer { int get_item_count(); void _keying_changed(); - void _unhandled_key_input(const InputEvent &p_ev); + void _unhandled_key_input(const Ref<InputEvent> &p_ev); - void _viewport_gui_input(const InputEvent &p_event); + void _viewport_gui_input(const Ref<InputEvent> &p_event); void _viewport_draw(); void _focus_selection(int p_op); diff --git a/editor/plugins/collision_polygon_2d_editor_plugin.cpp b/editor/plugins/collision_polygon_2d_editor_plugin.cpp index ae426ba29e..43abea0131 100644 --- a/editor/plugins/collision_polygon_2d_editor_plugin.cpp +++ b/editor/plugins/collision_polygon_2d_editor_plugin.cpp @@ -94,213 +94,208 @@ void CollisionPolygon2DEditor::_wip_close() { edited_point = -1; } -bool CollisionPolygon2DEditor::forward_gui_input(const InputEvent &p_event) { +bool CollisionPolygon2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) return false; - switch (p_event.type) { + Ref<InputEventMouseButton> mb; - case InputEvent::MOUSE_BUTTON: { + if (mb.is_valid()) { + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - const InputEventMouseButton &mb = p_event.mouse_button; + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + cpoint = node->get_global_transform().affine_inverse().xform(cpoint); - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Vector<Vector2> poly = node->get_polygon(); - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - cpoint = node->get_global_transform().affine_inverse().xform(cpoint); + //first check if a point is to be added (segment split) + real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); - Vector<Vector2> poly = node->get_polygon(); + switch (mode) { - //first check if a point is to be added (segment split) - real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); + case MODE_CREATE: { - switch (mode) { + if (mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) { - case MODE_CREATE: { + if (!wip_active) { - if (mb.button_index == BUTTON_LEFT && mb.pressed) { + wip.clear(); + wip.push_back(cpoint); + wip_active = true; + edited_point_pos = cpoint; + canvas_item_editor->get_viewport_control()->update(); + edited_point = 1; + return true; + } else { - if (!wip_active) { + if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { + //wip closed + _wip_close(); - wip.clear(); - wip.push_back(cpoint); - wip_active = true; - edited_point_pos = cpoint; - canvas_item_editor->get_viewport_control()->update(); - edited_point = 1; return true; } else { - if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { - //wip closed - _wip_close(); - - return true; - } else { - - wip.push_back(cpoint); - edited_point = wip.size(); - canvas_item_editor->get_viewport_control()->update(); - return true; + wip.push_back(cpoint); + edited_point = wip.size(); + canvas_item_editor->get_viewport_control()->update(); + return true; - //add wip point - } + //add wip point } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && wip_active) { - _wip_close(); } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && wip_active) { + _wip_close(); + } - } break; - - case MODE_EDIT: { + } break; - if (mb.button_index == BUTTON_LEFT) { - if (mb.pressed) { + case MODE_EDIT: { - if (mb.mod.control) { + if (mb->get_button_index() == BUTTON_LEFT) { + if (mb->is_pressed()) { - if (poly.size() < 3) { + if (mb->get_control()) { - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_undo_method(node, "set_polygon", poly); - poly.push_back(cpoint); - undo_redo->add_do_method(node, "set_polygon", poly); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - return true; - } - - //search edges - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { - - Vector2 points[2] = { xform.xform(poly[i]), - xform.xform(poly[(i + 1) % poly.size()]) }; - - Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); - if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) - continue; //not valid to reuse point - - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } - } - - if (closest_idx >= 0) { + if (poly.size() < 3) { - pre_move_edit = poly; - poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); - edited_point = closest_idx + 1; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - node->set_polygon(poly); - canvas_item_editor->get_viewport_control()->update(); - return true; - } - } else { + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_undo_method(node, "set_polygon", poly); + poly.push_back(cpoint); + undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } - //look for points to move + //search edges + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { + Vector2 points[2] = { xform.xform(poly[i]), + xform.xform(poly[(i + 1) % poly.size()]) }; - Vector2 cp = xform.xform(poly[i]); + Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); + if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) + continue; //not valid to reuse point - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; } + } - if (closest_idx >= 0) { + if (closest_idx >= 0) { - pre_move_edit = poly; - edited_point = closest_idx; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - canvas_item_editor->get_viewport_control()->update(); - return true; - } + pre_move_edit = poly; + poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); + edited_point = closest_idx + 1; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + node->set_polygon(poly); + canvas_item_editor->get_viewport_control()->update(); + return true; } } else { - if (edited_point != -1) { + //look for points to move - //apply + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - ERR_FAIL_INDEX_V(edited_point, poly.size(), false); - poly[edited_point] = edited_point_pos; - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_do_method(node, "set_polygon", poly); - undo_redo->add_undo_method(node, "set_polygon", pre_move_edit); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + Vector2 cp = xform.xform(poly[i]); - edited_point = -1; - return true; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } } - } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && edited_point == -1) { - - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { - Vector2 cp = xform.xform(poly[i]); + if (closest_idx >= 0) { - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; + pre_move_edit = poly; + edited_point = closest_idx; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + canvas_item_editor->get_viewport_control()->update(); + return true; } } + } else { + + if (edited_point != -1) { - if (closest_idx >= 0) { + //apply - undo_redo->create_action(TTR("Edit Poly (Remove Point)")); - undo_redo->add_undo_method(node, "set_polygon", poly); - poly.remove(closest_idx); + ERR_FAIL_INDEX_V(edited_point, poly.size(), false); + poly[edited_point] = edited_point_pos; + undo_redo->create_action(TTR("Edit Poly")); undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_undo_method(node, "set_polygon", pre_move_edit); undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->commit_action(); + + edited_point = -1; return true; } } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && edited_point == -1) { - } break; - } + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - } break; - case InputEvent::MOUSE_MOTION: { + Vector2 cp = xform.xform(poly[i]); - const InputEventMouseMotion &mm = p_event.mouse_motion; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } + } - if (edited_point != -1 && (wip_active || mm.button_mask & BUTTON_MASK_LEFT)) { + if (closest_idx >= 0) { - Vector2 gpoint = Point2(mm.x, mm.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + undo_redo->create_action(TTR("Edit Poly (Remove Point)")); + undo_redo->add_undo_method(node, "set_polygon", poly); + poly.remove(closest_idx); + undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } + } - canvas_item_editor->get_viewport_control()->update(); - } + } break; + } + } - } break; + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid()) { + + if (edited_point != -1 && (wip_active || mm->get_button_mask() & BUTTON_MASK_LEFT)) { + + Vector2 gpoint = mm->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + + canvas_item_editor->get_viewport_control()->update(); + } } return false; diff --git a/editor/plugins/collision_polygon_2d_editor_plugin.h b/editor/plugins/collision_polygon_2d_editor_plugin.h index babe653581..382c0d6c37 100644 --- a/editor/plugins/collision_polygon_2d_editor_plugin.h +++ b/editor/plugins/collision_polygon_2d_editor_plugin.h @@ -80,7 +80,7 @@ protected: static void _bind_methods(); public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_collision_polygon); CollisionPolygon2DEditor(EditorNode *p_editor); }; @@ -93,7 +93,7 @@ class CollisionPolygon2DEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } virtual String get_name() const { return "CollisionPolygon2D"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/collision_polygon_editor_plugin.cpp b/editor/plugins/collision_polygon_editor_plugin.cpp index fdb1bf984e..c89e6f59a4 100644 --- a/editor/plugins/collision_polygon_editor_plugin.cpp +++ b/editor/plugins/collision_polygon_editor_plugin.cpp @@ -131,7 +131,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In - Vector2 gpoint=Point2(mb.x,mb.y); + Vector2 gpoint=Point2(mb->get_pos().x,mb->get_pos().y); Vector3 ray_from = p_camera->project_ray_origin(gpoint); Vector3 ray_dir = p_camera->project_ray_normal(gpoint); @@ -156,7 +156,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In case MODE_CREATE: { - if (mb.button_index==BUTTON_LEFT && mb.pressed) { + if (mb->get_button_index()==BUTTON_LEFT && mb->is_pressed()) { if (!wip_active) { @@ -186,7 +186,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In //add wip point } } - } else if (mb.button_index==BUTTON_RIGHT && mb.pressed && wip_active) { + } else if (mb->get_button_index()==BUTTON_RIGHT && mb->is_pressed() && wip_active) { _wip_close(); } @@ -196,10 +196,10 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In case MODE_EDIT: { - if (mb.button_index==BUTTON_LEFT) { - if (mb.pressed) { + if (mb->get_button_index()==BUTTON_LEFT) { + if (mb->is_pressed()) { - if (mb.mod.control) { + if (mb->get_control()) { if (poly.size() < 3) { @@ -297,7 +297,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In return true; } } - } if (mb.button_index==BUTTON_RIGHT && mb.pressed && edited_point==-1) { + } if (mb->get_button_index()==BUTTON_RIGHT && mb->is_pressed() && edited_point==-1) { @@ -344,7 +344,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera* p_camera,const In const InputEventMouseMotion &mm=p_event.mouse_motion; - if (edited_point!=-1 && (wip_active || mm.button_mask&BUTTON_MASK_LEFT)) { + if (edited_point!=-1 && (wip_active || mm->get_button_mask()&BUTTON_MASK_LEFT)) { Vector2 gpoint = Point2(mm.x,mm.y); diff --git a/editor/plugins/collision_shape_2d_editor_plugin.cpp b/editor/plugins/collision_shape_2d_editor_plugin.cpp index 70cc81efb0..9a6ee8153e 100644 --- a/editor/plugins/collision_shape_2d_editor_plugin.cpp +++ b/editor/plugins/collision_shape_2d_editor_plugin.cpp @@ -302,7 +302,7 @@ void CollisionShape2DEditor::commit_handle(int idx, Variant &p_org) { undo_redo->commit_action(); } -bool CollisionShape2DEditor::forward_gui_input(const InputEvent &p_event) { +bool CollisionShape2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) { return false; @@ -316,68 +316,66 @@ bool CollisionShape2DEditor::forward_gui_input(const InputEvent &p_event) { return false; } - switch (p_event.type) { - case InputEvent::MOUSE_BUTTON: { - const InputEventMouseButton &mb = p_event.mouse_button; + Ref<InputEventMouseButton> mb = p_event; - Transform2D gt = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + if (mb.is_valid()) { - Point2 gpoint(mb.x, mb.y); + Transform2D gt = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - if (mb.button_index == BUTTON_LEFT) { - if (mb.pressed) { - for (int i = 0; i < handles.size(); i++) { - if (gt.xform(handles[i]).distance_to(gpoint) < 8) { - edit_handle = i; + Point2 gpoint(mb->get_position().x, mb->get_position().y); - break; - } + if (mb->get_button_index() == BUTTON_LEFT) { + if (mb->is_pressed()) { + for (int i = 0; i < handles.size(); i++) { + if (gt.xform(handles[i]).distance_to(gpoint) < 8) { + edit_handle = i; + + break; } + } - if (edit_handle == -1) { - pressed = false; + if (edit_handle == -1) { + pressed = false; - return false; - } + return false; + } - original = get_handle_value(edit_handle); - pressed = true; + original = get_handle_value(edit_handle); + pressed = true; - return true; + return true; - } else { - if (pressed) { - commit_handle(edit_handle, original); + } else { + if (pressed) { + commit_handle(edit_handle, original); - edit_handle = -1; - pressed = false; + edit_handle = -1; + pressed = false; - return true; - } + return true; } } + } - return false; - - } break; + return false; + } - case InputEvent::MOUSE_MOTION: { - const InputEventMouseMotion &mm = p_event.mouse_motion; + Ref<InputEventMouseMotion> mm = p_event; - if (edit_handle == -1 || !pressed) { - return false; - } + if (mm.is_valid()) { - Point2 gpoint = Point2(mm.x, mm.y); - Point2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - cpoint = node->get_global_transform().affine_inverse().xform(cpoint); + if (edit_handle == -1 || !pressed) { + return false; + } - set_handle(edit_handle, cpoint); + Point2 gpoint = mm->get_position(); + Point2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + cpoint = node->get_global_transform().affine_inverse().xform(cpoint); - return true; + set_handle(edit_handle, cpoint); - } break; + return true; } return false; diff --git a/editor/plugins/collision_shape_2d_editor_plugin.h b/editor/plugins/collision_shape_2d_editor_plugin.h index bbd94516a8..09aefc65c0 100644 --- a/editor/plugins/collision_shape_2d_editor_plugin.h +++ b/editor/plugins/collision_shape_2d_editor_plugin.h @@ -74,7 +74,7 @@ protected: static void _bind_methods(); public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_node); CollisionShape2DEditor(EditorNode *p_editor); @@ -87,7 +87,7 @@ class CollisionShape2DEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return collision_shape_2d_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return collision_shape_2d_editor->forward_gui_input(p_event); } virtual String get_name() const { return "CollisionShape2D"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/curve_editor_plugin.cpp b/editor/plugins/curve_editor_plugin.cpp index 52edc75bc0..d869d703f1 100644 --- a/editor/plugins/curve_editor_plugin.cpp +++ b/editor/plugins/curve_editor_plugin.cpp @@ -1,11 +1,42 @@ +/*************************************************************************/ +/* curve_editor_plugin.cpp */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #include "curve_editor_plugin.h" #include "canvas_item_editor_plugin.h" #include "os/keyboard.h" #include "spatial_editor_plugin.h" -void CurveTextureEdit::_gui_input(const InputEvent &p_event) { - if (p_event.type == InputEvent::KEY && p_event.key.pressed && p_event.key.scancode == KEY_DELETE && grabbed != -1) { +void CurveTextureEdit::_gui_input(const Ref<InputEvent> &p_event) { + + Ref<InputEventKey> k = p_event; + if (k.is_valid() && k->is_pressed() && k->get_scancode() == KEY_DELETE && grabbed != -1) { points.remove(grabbed); grabbed = -1; @@ -14,7 +45,9 @@ void CurveTextureEdit::_gui_input(const InputEvent &p_event) { accept_event(); } - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.pressed) { + Ref<InputEventMouseButton> mb = p_event; + + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed()) { update(); Ref<Font> font = get_font("font", "Label"); @@ -24,7 +57,7 @@ void CurveTextureEdit::_gui_input(const InputEvent &p_event) { Vector2 size = get_size(); size.y -= font_h; - Point2 p = Vector2(p_event.mouse_button.x, p_event.mouse_button.y) / size; + Point2 p = Vector2(mb->get_position().x, mb->get_position().y) / size; p.y = CLAMP(1.0 - p.y, 0, 1) * (max - min) + min; grabbed = -1; grabbing = true; @@ -60,7 +93,7 @@ void CurveTextureEdit::_gui_input(const InputEvent &p_event) { emit_signal("curve_changed"); } - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && !p_event.mouse_button.pressed) { + if (mb.is_valid() && mb->get_button_index() == 1 && !mb->is_pressed()) { if (grabbing) { grabbing = false; @@ -69,14 +102,16 @@ void CurveTextureEdit::_gui_input(const InputEvent &p_event) { update(); } - if (p_event.type == InputEvent::MOUSE_MOTION && grabbing && grabbed != -1) { + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid() && grabbing && grabbed != -1) { Ref<Font> font = get_font("font", "Label"); int font_h = font->get_height(); Vector2 size = get_size(); size.y -= font_h; - Point2 p = Vector2(p_event.mouse_motion.x, p_event.mouse_motion.y) / size; + Point2 p = mm->get_position() / size; p.y = CLAMP(1.0 - p.y, 0, 1) * (max - min) + min; p.x = CLAMP(p.x, 0.0, 1.0); diff --git a/editor/plugins/curve_editor_plugin.h b/editor/plugins/curve_editor_plugin.h index e98cec2727..4e75ba407c 100644 --- a/editor/plugins/curve_editor_plugin.h +++ b/editor/plugins/curve_editor_plugin.h @@ -1,3 +1,32 @@ +/*************************************************************************/ +/* curve_editor_plugin.h */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #ifndef CURVE_EDITOR_PLUGIN_H #define CURVE_EDITOR_PLUGIN_H @@ -25,7 +54,7 @@ class CurveTextureEdit : public Control { void _plot_curve(const Vector2 &p_a, const Vector2 &p_b, const Vector2 &p_c, const Vector2 &p_d); protected: - void _gui_input(const InputEvent &p_event); + void _gui_input(const Ref<InputEvent> &p_event); void _notification(int p_what); static void _bind_methods(); diff --git a/editor/plugins/editor_preview_plugins.cpp b/editor/plugins/editor_preview_plugins.cpp index db8060d591..11d804422a 100644 --- a/editor/plugins/editor_preview_plugins.cpp +++ b/editor/plugins/editor_preview_plugins.cpp @@ -39,239 +39,226 @@ #include "scene/resources/bit_mask.h" #include "scene/resources/mesh.h" -#if 0 -bool EditorTexturePreviewPlugin::handles(const String& p_type) const { +bool EditorTexturePreviewPlugin::handles(const String &p_type) const { - return (ClassDB::is_type(p_type,"ImageTexture") || ClassDB::is_type(p_type, "AtlasTexture")); + return ClassDB::is_parent_class(p_type, "Texture"); } -Ref<Texture> EditorTexturePreviewPlugin::generate(const RES& p_from) { +Ref<Texture> EditorTexturePreviewPlugin::generate(const RES &p_from) { - Image img; + Ref<Image> img; Ref<AtlasTexture> atex = p_from; if (atex.is_valid()) { - Ref<ImageTexture> tex = atex->get_atlas(); + Ref<Texture> tex = atex->get_atlas(); if (!tex.is_valid()) { return Ref<Texture>(); } - Image atlas = tex->get_data(); - img = atlas.get_rect(atex->get_region()); - } - else { - Ref<ImageTexture> tex = p_from; + Ref<Image> atlas = tex->get_data(); + img = atlas->get_rect(atex->get_region()); + } else { + Ref<Texture> tex = p_from; img = tex->get_data(); } - if (img.empty()) + if (img.is_null() || img->empty()) return Ref<Texture>(); - img.clear_mipmaps(); + img->clear_mipmaps(); int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - thumbnail_size*=EDSCALE; - if (img.is_compressed()) { - if (img.decompress()!=OK) + thumbnail_size *= EDSCALE; + if (img->is_compressed()) { + if (img->decompress() != OK) return Ref<Texture>(); - } else if (img.get_format()!=Image::FORMAT_RGB8 && img.get_format()!=Image::FORMAT_RGBA8) { - img.convert(Image::FORMAT_RGBA8); + } else if (img->get_format() != Image::FORMAT_RGB8 && img->get_format() != Image::FORMAT_RGBA8) { + img->convert(Image::FORMAT_RGBA8); } - int width,height; - if (img.get_width() > thumbnail_size && img.get_width() >= img.get_height()) { + int width, height; + if (img->get_width() > thumbnail_size && img->get_width() >= img->get_height()) { - width=thumbnail_size; - height = img.get_height() * thumbnail_size / img.get_width(); - } else if (img.get_height() > thumbnail_size && img.get_height() >= img.get_width()) { + width = thumbnail_size; + height = img->get_height() * thumbnail_size / img->get_width(); + } else if (img->get_height() > thumbnail_size && img->get_height() >= img->get_width()) { - height=thumbnail_size; - width = img.get_width() * thumbnail_size / img.get_height(); - } else { + height = thumbnail_size; + width = img->get_width() * thumbnail_size / img->get_height(); + } else { - width=img.get_width(); - height=img.get_height(); + width = img->get_width(); + height = img->get_height(); } - img.resize(width,height); + img->resize(width, height); - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture )); + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); - ptex->create_from_image(img,0); + ptex->create_from_image(img, 0); return ptex; - } EditorTexturePreviewPlugin::EditorTexturePreviewPlugin() { - - } //////////////////////////////////////////////////////////////////////////// -bool EditorBitmapPreviewPlugin::handles(const String& p_type) const { +bool EditorBitmapPreviewPlugin::handles(const String &p_type) const { - return ClassDB::is_type(p_type,"BitMap"); + return ClassDB::is_parent_class(p_type, "BitMap"); } -Ref<Texture> EditorBitmapPreviewPlugin::generate(const RES& p_from) { +Ref<Texture> EditorBitmapPreviewPlugin::generate(const RES &p_from) { - Ref<BitMap> bm =p_from; + Ref<BitMap> bm = p_from; - if (bm->get_size()==Size2()) { + if (bm->get_size() == Size2()) { return Ref<Texture>(); } PoolVector<uint8_t> data; - data.resize(bm->get_size().width*bm->get_size().height); + data.resize(bm->get_size().width * bm->get_size().height); { - PoolVector<uint8_t>::Write w=data.write(); + PoolVector<uint8_t>::Write w = data.write(); - for(int i=0;i<bm->get_size().width;i++) { - for(int j=0;j<bm->get_size().height;j++) { - if (bm->get_bit(Point2i(i,j))) { - w[j*bm->get_size().width+i]=255; + for (int i = 0; i < bm->get_size().width; i++) { + for (int j = 0; j < bm->get_size().height; j++) { + if (bm->get_bit(Point2i(i, j))) { + w[j * bm->get_size().width + i] = 255; } else { - w[j*bm->get_size().width+i]=0; - + w[j * bm->get_size().width + i] = 0; } } - } } - - Image img(bm->get_size().width,bm->get_size().height,0,Image::FORMAT_L8,data); + Ref<Image> img; + img.instance(); + img->create(bm->get_size().width, bm->get_size().height, 0, Image::FORMAT_L8, data); int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - thumbnail_size*=EDSCALE; - if (img.is_compressed()) { - if (img.decompress()!=OK) + thumbnail_size *= EDSCALE; + if (img->is_compressed()) { + if (img->decompress() != OK) return Ref<Texture>(); - } else if (img.get_format()!=Image::FORMAT_RGB8 && img.get_format()!=Image::FORMAT_RGBA8) { - img.convert(Image::FORMAT_RGBA8); + } else if (img->get_format() != Image::FORMAT_RGB8 && img->get_format() != Image::FORMAT_RGBA8) { + img->convert(Image::FORMAT_RGBA8); } - int width,height; - if (img.get_width() > thumbnail_size && img.get_width() >= img.get_height()) { + int width, height; + if (img->get_width() > thumbnail_size && img->get_width() >= img->get_height()) { - width=thumbnail_size; - height = img.get_height() * thumbnail_size / img.get_width(); - } else if (img.get_height() > thumbnail_size && img.get_height() >= img.get_width()) { + width = thumbnail_size; + height = img->get_height() * thumbnail_size / img->get_width(); + } else if (img->get_height() > thumbnail_size && img->get_height() >= img->get_width()) { - height=thumbnail_size; - width = img.get_width() * thumbnail_size / img.get_height(); - } else { + height = thumbnail_size; + width = img->get_width() * thumbnail_size / img->get_height(); + } else { - width=img.get_width(); - height=img.get_height(); + width = img->get_width(); + height = img->get_height(); } - img.resize(width,height); + img->resize(width, height); - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture )); + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); - ptex->create_from_image(img,0); + ptex->create_from_image(img, 0); return ptex; - } EditorBitmapPreviewPlugin::EditorBitmapPreviewPlugin() { - - } /////////////////////////////////////////////////////////////////////////// +bool EditorPackedScenePreviewPlugin::handles(const String &p_type) const { -Ref<Texture> EditorPackedScenePreviewPlugin::_gen_from_imd(Ref<ResourceImportMetadata> p_imd) { - - if (p_imd.is_null()) { - return Ref<Texture>(); - } + return ClassDB::is_parent_class(p_type, "PackedScene"); +} +Ref<Texture> EditorPackedScenePreviewPlugin::generate(const RES &p_from) { - if (!p_imd->has_option("thumbnail")) - return Ref<Texture>(); + return generate_from_path(p_from->get_path()); +} - Variant tn = p_imd->get_option("thumbnail"); - //print_line(Variant::get_type_name(tn.get_type())); - PoolVector<uint8_t> thumbnail = tn; +Ref<Texture> EditorPackedScenePreviewPlugin::generate_from_path(const String &p_path) { - int len = thumbnail.size(); - if (len==0) - return Ref<Texture>(); + String temp_path = EditorSettings::get_singleton()->get_settings_path().plus_file("tmp"); + String cache_base = GlobalConfig::get_singleton()->globalize_path(p_path).md5_text(); + cache_base = temp_path.plus_file("resthumb-" + cache_base); + //does not have it, try to load a cached thumbnail - PoolVector<uint8_t>::Read r = thumbnail.read(); + String path = cache_base + ".png"; - Image img(r.ptr(),len); - if (img.empty()) + if (!FileAccess::exists(path)) return Ref<Texture>(); - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture )); - ptex->create_from_image(img,0); - return ptex; + Ref<Image> img; + img.instance(); + Error err = img->load(path); + if (err == OK) { -} + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); -bool EditorPackedScenePreviewPlugin::handles(const String& p_type) const { + ptex->create_from_image(img, 0); + return ptex; - return ClassDB::is_type(p_type,"PackedScene"); + } else { + return Ref<Texture>(); + } } -Ref<Texture> EditorPackedScenePreviewPlugin::generate(const RES& p_from) { - Ref<ResourceImportMetadata> imd = p_from->get_import_metadata(); - return _gen_from_imd(imd); +EditorPackedScenePreviewPlugin::EditorPackedScenePreviewPlugin() { } -Ref<Texture> EditorPackedScenePreviewPlugin::generate_from_path(const String& p_path) { +////////////////////////////////////////////////////////////////// + +void EditorMaterialPreviewPlugin::_preview_done(const Variant &p_udata) { - Ref<ResourceImportMetadata> imd = ResourceLoader::load_import_metadata(p_path); - return _gen_from_imd(imd); + preview_done = true; } -EditorPackedScenePreviewPlugin::EditorPackedScenePreviewPlugin() { +void EditorMaterialPreviewPlugin::_bind_methods() { + ClassDB::bind_method("_preview_done", &EditorMaterialPreviewPlugin::_preview_done); } -////////////////////////////////////////////////////////////////// +bool EditorMaterialPreviewPlugin::handles(const String &p_type) const { -bool EditorMaterialPreviewPlugin::handles(const String& p_type) const { - - return ClassDB::is_type(p_type,"Material"); //any material + return ClassDB::is_parent_class(p_type, "Material"); //any material } -Ref<Texture> EditorMaterialPreviewPlugin::generate(const RES& p_from) { +Ref<Texture> EditorMaterialPreviewPlugin::generate(const RES &p_from) { Ref<Material> material = p_from; - ERR_FAIL_COND_V(material.is_null(),Ref<Texture>()); + ERR_FAIL_COND_V(material.is_null(), Ref<Texture>()); - VS::get_singleton()->mesh_surface_set_material(sphere,0,material->get_rid()); + VS::get_singleton()->mesh_surface_set_material(sphere, 0, material->get_rid()); - VS::get_singleton()->viewport_queue_screen_capture(viewport); - VS::get_singleton()->viewport_set_render_target_update_mode(viewport,VS::RENDER_TARGET_UPDATE_ONCE); //once used for capture + VS::get_singleton()->viewport_set_update_mode(viewport, VS::VIEWPORT_UPDATE_ONCE); //once used for capture //print_line("queue capture!"); - Image img; - int timeout=1000; - while(timeout) { - //print_line("try capture?"); + preview_done = false; + VS::get_singleton()->request_frame_drawn_callback(this, "_preview_done", Variant()); + + while (!preview_done) { OS::get_singleton()->delay_usec(10); - img = VS::get_singleton()->viewport_get_screen_capture(viewport); - if (!img.empty()) - break; - timeout--; } - //print_line("captured!"); - VS::get_singleton()->mesh_surface_set_material(sphere,0,RID()); + Ref<Image> img = VS::get_singleton()->VS::get_singleton()->texture_get_data(viewport_texture); + VS::get_singleton()->mesh_surface_set_material(sphere, 0, RID()); - int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - thumbnail_size*=EDSCALE; - img.resize(thumbnail_size,thumbnail_size); + ERR_FAIL_COND_V(!img.is_valid(), Ref<ImageTexture>()); - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture )); - ptex->create_from_image(img,0); + int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); + thumbnail_size *= EDSCALE; + img->convert(Image::FORMAT_RGBA8); + img->resize(thumbnail_size, thumbnail_size); + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); + ptex->create_from_image(img, 0); return ptex; } @@ -280,70 +267,68 @@ EditorMaterialPreviewPlugin::EditorMaterialPreviewPlugin() { scenario = VS::get_singleton()->scenario_create(); viewport = VS::get_singleton()->viewport_create(); - VS::get_singleton()->viewport_set_as_render_target(viewport,true); - VS::get_singleton()->viewport_set_render_target_update_mode(viewport,VS::RENDER_TARGET_UPDATE_DISABLED); - VS::get_singleton()->viewport_set_scenario(viewport,scenario); - VS::ViewportRect vr; - vr.x=0; - vr.y=0; - vr.width=128; - vr.height=128; - VS::get_singleton()->viewport_set_rect(viewport,vr); + VS::get_singleton()->viewport_set_update_mode(viewport, VS::VIEWPORT_UPDATE_DISABLED); + VS::get_singleton()->viewport_set_scenario(viewport, scenario); + VS::get_singleton()->viewport_set_size(viewport, 128, 128); + VS::get_singleton()->viewport_set_transparent_background(viewport, true); + VS::get_singleton()->viewport_set_active(viewport, true); + VS::get_singleton()->viewport_set_vflip(viewport, true); + viewport_texture = VS::get_singleton()->viewport_get_texture(viewport); camera = VS::get_singleton()->camera_create(); - VS::get_singleton()->viewport_attach_camera(viewport,camera); - VS::get_singleton()->camera_set_transform(camera,Transform(Matrix3(),Vector3(0,0,3))); - VS::get_singleton()->camera_set_perspective(camera,45,0.1,10); + VS::get_singleton()->viewport_attach_camera(viewport, camera); + VS::get_singleton()->camera_set_transform(camera, Transform(Basis(), Vector3(0, 0, 3))); + VS::get_singleton()->camera_set_perspective(camera, 45, 0.1, 10); light = VS::get_singleton()->light_create(VS::LIGHT_DIRECTIONAL); - light_instance = VS::get_singleton()->instance_create2(light,scenario); - VS::get_singleton()->instance_set_transform(light_instance,Transform().looking_at(Vector3(-1,-1,-1),Vector3(0,1,0))); + light_instance = VS::get_singleton()->instance_create2(light, scenario); + VS::get_singleton()->instance_set_transform(light_instance, Transform().looking_at(Vector3(-1, -1, -1), Vector3(0, 1, 0))); light2 = VS::get_singleton()->light_create(VS::LIGHT_DIRECTIONAL); - VS::get_singleton()->light_set_color(light2,VS::LIGHT_COLOR_DIFFUSE,Color(0.7,0.7,0.7)); - VS::get_singleton()->light_set_color(light2,VS::LIGHT_COLOR_SPECULAR,Color(0.0,0.0,0.0)); - light_instance2 = VS::get_singleton()->instance_create2(light2,scenario); + VS::get_singleton()->light_set_color(light2, Color(0.7, 0.7, 0.7)); + //VS::get_singleton()->light_set_color(light2, Color(0.7, 0.7, 0.7)); + + light_instance2 = VS::get_singleton()->instance_create2(light2, scenario); - VS::get_singleton()->instance_set_transform(light_instance2,Transform().looking_at(Vector3(0,1,0),Vector3(0,0,1))); + VS::get_singleton()->instance_set_transform(light_instance2, Transform().looking_at(Vector3(0, 1, 0), Vector3(0, 0, 1))); sphere = VS::get_singleton()->mesh_create(); - sphere_instance = VS::get_singleton()->instance_create2(sphere,scenario); + sphere_instance = VS::get_singleton()->instance_create2(sphere, scenario); - int lats=32; - int lons=32; - float radius=1.0; + int lats = 32; + int lons = 32; + float radius = 1.0; PoolVector<Vector3> vertices; PoolVector<Vector3> normals; PoolVector<Vector2> uvs; PoolVector<float> tangents; - Matrix3 tt = Matrix3(Vector3(0,1,0),Math_PI*0.5); + Basis tt = Basis(Vector3(0, 1, 0), Math_PI * 0.5); - for(int i = 1; i <= lats; i++) { - double lat0 = Math_PI * (-0.5 + (double) (i - 1) / lats); - double z0 = Math::sin(lat0); - double zr0 = Math::cos(lat0); + for (int i = 1; i <= lats; i++) { + double lat0 = Math_PI * (-0.5 + (double)(i - 1) / lats); + double z0 = Math::sin(lat0); + double zr0 = Math::cos(lat0); - double lat1 = Math_PI * (-0.5 + (double) i / lats); + double lat1 = Math_PI * (-0.5 + (double)i / lats); double z1 = Math::sin(lat1); double zr1 = Math::cos(lat1); - for(int j = lons; j >= 1; j--) { + for (int j = lons; j >= 1; j--) { - double lng0 = 2 * Math_PI * (double) (j - 1) / lons; + double lng0 = 2 * Math_PI * (double)(j - 1) / lons; double x0 = Math::cos(lng0); double y0 = Math::sin(lng0); - double lng1 = 2 * Math_PI * (double) (j) / lons; + double lng1 = 2 * Math_PI * (double)(j) / lons; double x1 = Math::cos(lng1); double y1 = Math::sin(lng1); - - Vector3 v[4]={ - Vector3(x1 * zr0, z0, y1 *zr0), - Vector3(x1 * zr1, z1, y1 *zr1), - Vector3(x0 * zr1, z1, y0 *zr1), - Vector3(x0 * zr0, z0, y0 *zr0) + Vector3 v[4] = { + Vector3(x1 * zr0, z0, y1 * zr0), + Vector3(x1 * zr1, z1, y1 * zr1), + Vector3(x0 * zr1, z1, y0 * zr1), + Vector3(x0 * zr0, z0, y0 * zr0) }; #define ADD_POINT(m_idx) \ @@ -364,8 +349,6 @@ EditorMaterialPreviewPlugin::EditorMaterialPreviewPlugin() { tangents.push_back(1.0); \ } - - ADD_POINT(0); ADD_POINT(1); ADD_POINT(2); @@ -378,12 +361,11 @@ EditorMaterialPreviewPlugin::EditorMaterialPreviewPlugin() { Array arr; arr.resize(VS::ARRAY_MAX); - arr[VS::ARRAY_VERTEX]=vertices; - arr[VS::ARRAY_NORMAL]=normals; - arr[VS::ARRAY_TANGENT]=tangents; - arr[VS::ARRAY_TEX_UV]=uvs; - VS::get_singleton()->mesh_add_surface(sphere,VS::PRIMITIVE_TRIANGLES,arr); - + arr[VS::ARRAY_VERTEX] = vertices; + arr[VS::ARRAY_NORMAL] = normals; + arr[VS::ARRAY_TANGENT] = tangents; + arr[VS::ARRAY_TEX_UV] = uvs; + VS::get_singleton()->mesh_add_surface_from_arrays(sphere, VS::PRIMITIVE_TRIANGLES, arr); } EditorMaterialPreviewPlugin::~EditorMaterialPreviewPlugin() { @@ -397,30 +379,28 @@ EditorMaterialPreviewPlugin::~EditorMaterialPreviewPlugin() { VS::get_singleton()->free(light_instance2); VS::get_singleton()->free(camera); VS::get_singleton()->free(scenario); - } /////////////////////////////////////////////////////////////////////////// static bool _is_text_char(CharType c) { - return (c>='a' && c<='z') || (c>='A' && c<='Z') || (c>='0' && c<='9') || c=='_'; + return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9') || c == '_'; } -bool EditorScriptPreviewPlugin::handles(const String& p_type) const { +bool EditorScriptPreviewPlugin::handles(const String &p_type) const { - return ClassDB::is_type(p_type,"Script"); + return ClassDB::is_parent_class(p_type, "Script"); } -Ref<Texture> EditorScriptPreviewPlugin::generate(const RES& p_from) { - +Ref<Texture> EditorScriptPreviewPlugin::generate(const RES &p_from) { Ref<Script> scr = p_from; if (scr.is_null()) return Ref<Texture>(); String code = scr->get_source_code().strip_edges(); - if (code=="") + if (code == "") return Ref<Texture>(); List<String> kwors; @@ -428,107 +408,104 @@ Ref<Texture> EditorScriptPreviewPlugin::generate(const RES& p_from) { Set<String> keywords; - for(List<String>::Element *E=kwors.front();E;E=E->next()) { + for (List<String>::Element *E = kwors.front(); E; E = E->next()) { keywords.insert(E->get()); - } - int line = 0; - int col=0; + int col = 0; int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - thumbnail_size*=EDSCALE; - Image img(thumbnail_size,thumbnail_size,0,Image::FORMAT_RGBA8); - - + thumbnail_size *= EDSCALE; + Ref<Image> img; + img.instance(); + img->create(thumbnail_size, thumbnail_size, 0, Image::FORMAT_RGBA8); Color bg_color = EditorSettings::get_singleton()->get("text_editor/highlighting/background_color"); - bg_color.a=1.0; + bg_color.a = 1.0; Color keyword_color = EditorSettings::get_singleton()->get("text_editor/highlighting/keyword_color"); Color text_color = EditorSettings::get_singleton()->get("text_editor/highlighting/text_color"); Color symbol_color = EditorSettings::get_singleton()->get("text_editor/highlighting/symbol_color"); + img->lock(); - for(int i=0;i<thumbnail_size;i++) { - for(int j=0;j<thumbnail_size;j++) { - img.put_pixel(i,j,bg_color); + for (int i = 0; i < thumbnail_size; i++) { + for (int j = 0; j < thumbnail_size; j++) { + img->put_pixel(i, j, bg_color); } - } - bool prev_is_text=false; - bool in_keyword=false; - for(int i=0;i<code.length();i++) { + bool prev_is_text = false; + bool in_keyword = false; + for (int i = 0; i < code.length(); i++) { CharType c = code[i]; - if (c>32) { - if (col<thumbnail_size) { + if (c > 32) { + if (col < thumbnail_size) { Color color = text_color; - if (c!='_' && ((c>='!' && c<='/') || (c>=':' && c<='@') || (c>='[' && c<='`') || (c>='{' && c<='~') || c=='\t')) { + if (c != '_' && ((c >= '!' && c <= '/') || (c >= ':' && c <= '@') || (c >= '[' && c <= '`') || (c >= '{' && c <= '~') || c == '\t')) { //make symbol a little visible - color=symbol_color; - in_keyword=false; + color = symbol_color; + in_keyword = false; } else if (!prev_is_text && _is_text_char(c)) { int pos = i; - while(_is_text_char(code[pos])) { + while (_is_text_char(code[pos])) { pos++; } ///print_line("from "+itos(i)+" to "+itos(pos)); - String word = code.substr(i,pos-i); + String word = code.substr(i, pos - i); //print_line("found word: "+word); if (keywords.has(word)) - in_keyword=true; + in_keyword = true; } else if (!_is_text_char(c)) { - in_keyword=false; + in_keyword = false; } if (in_keyword) - color=keyword_color; + color = keyword_color; - Color ul=color; - ul.a*=0.5; - img.put_pixel(col,line*2,bg_color.blend(ul)); - img.put_pixel(col,line*2+1,color); + Color ul = color; + ul.a *= 0.5; + img->put_pixel(col, line * 2, bg_color.blend(ul)); + img->put_pixel(col, line * 2 + 1, color); - prev_is_text=_is_text_char(c); + prev_is_text = _is_text_char(c); } } else { - prev_is_text=false; - in_keyword=false; + prev_is_text = false; + in_keyword = false; - if (c=='\n') { - col=0; + if (c == '\n') { + col = 0; line++; - if (line>=thumbnail_size/2) + if (line >= thumbnail_size / 2) break; - } else if (c=='\t') { - col+=3; + } else if (c == '\t') { + col += 3; } } col++; } - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture)); + img->unlock(); - ptex->create_from_image(img,0); - return ptex; + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); + ptex->create_from_image(img, 0); + return ptex; } EditorScriptPreviewPlugin::EditorScriptPreviewPlugin() { - - } /////////////////////////////////////////////////////////////////// #if 0 bool EditorSamplePreviewPlugin::handles(const String& p_type) const { - return ClassDB::is_type(p_type,"Sample"); + return ClassDB::is_parent_class(p_type,"Sample"); } Ref<Texture> EditorSamplePreviewPlugin::generate(const RES& p_from) { @@ -795,105 +772,108 @@ EditorSamplePreviewPlugin::EditorSamplePreviewPlugin() { #endif /////////////////////////////////////////////////////////////////////////// -bool EditorMeshPreviewPlugin::handles(const String& p_type) const { +void EditorMeshPreviewPlugin::_preview_done(const Variant &p_udata) { - return ClassDB::is_type(p_type,"Mesh"); //any Mesh + preview_done = true; } -Ref<Texture> EditorMeshPreviewPlugin::generate(const RES& p_from) { +void EditorMeshPreviewPlugin::_bind_methods() { + + ClassDB::bind_method("_preview_done", &EditorMeshPreviewPlugin::_preview_done); +} +bool EditorMeshPreviewPlugin::handles(const String &p_type) const { + + return ClassDB::is_parent_class(p_type, "Mesh"); //any Mesh +} +Ref<Texture> EditorMeshPreviewPlugin::generate(const RES &p_from) { + + print_line("**Generating for mesh finally??"); Ref<Mesh> mesh = p_from; - ERR_FAIL_COND_V(mesh.is_null(),Ref<Texture>()); + ERR_FAIL_COND_V(mesh.is_null(), Ref<Texture>()); - VS::get_singleton()->instance_set_base(mesh_instance,mesh->get_rid()); + VS::get_singleton()->instance_set_base(mesh_instance, mesh->get_rid()); - AABB aabb= mesh->get_aabb(); - Vector3 ofs = aabb.pos + aabb.size*0.5; - aabb.pos-=ofs; + Rect3 aabb = mesh->get_aabb(); + print_line("mesh aabb: " + aabb); + Vector3 ofs = aabb.position + aabb.size * 0.5; + aabb.position -= ofs; Transform xform; - xform.basis=Matrix3().rotated(Vector3(0,1,0),-Math_PI*0.125); - xform.basis = Matrix3().rotated(Vector3(1,0,0),Math_PI*0.125)*xform.basis; - AABB rot_aabb = xform.xform(aabb); - float m = MAX(rot_aabb.size.x,rot_aabb.size.y)*0.5; - if (m==0) + xform.basis = Basis().rotated(Vector3(0, 1, 0), -Math_PI * 0.125); + xform.basis = Basis().rotated(Vector3(1, 0, 0), Math_PI * 0.125) * xform.basis; + Rect3 rot_aabb = xform.xform(aabb); + float m = MAX(rot_aabb.size.x, rot_aabb.size.y) * 0.5; + if (m == 0) return Ref<Texture>(); - m=1.0/m; - m*=0.5; + m = 1.0 / m; + m *= 0.5; //print_line("scale: "+rtos(m)); - xform.basis.scale(Vector3(m,m,m)); - xform.origin=-xform.basis.xform(ofs); //-ofs*m; - xform.origin.z-=rot_aabb.size.z*2; - VS::get_singleton()->instance_set_transform(mesh_instance,xform); - + xform.basis.scale(Vector3(m, m, m)); + xform.origin = -xform.basis.xform(ofs); //-ofs*m; + xform.origin.z -= rot_aabb.size.z * 2; + VS::get_singleton()->instance_set_transform(mesh_instance, xform); - - VS::get_singleton()->viewport_queue_screen_capture(viewport); - VS::get_singleton()->viewport_set_render_target_update_mode(viewport,VS::RENDER_TARGET_UPDATE_ONCE); //once used for capture + VS::get_singleton()->viewport_set_update_mode(viewport, VS::VIEWPORT_UPDATE_ONCE); //once used for capture //print_line("queue capture!"); - Image img; - int timeout=1000; - while(timeout) { - //print_line("try capture?"); + preview_done = false; + VS::get_singleton()->request_frame_drawn_callback(this, "_preview_done", Variant()); + + while (!preview_done) { OS::get_singleton()->delay_usec(10); - img = VS::get_singleton()->viewport_get_screen_capture(viewport); - if (!img.empty()) - break; - timeout--; } - //print_line("captured!"); - VS::get_singleton()->instance_set_base(mesh_instance,RID()); + Ref<Image> img = VS::get_singleton()->VS::get_singleton()->texture_get_data(viewport_texture); + ERR_FAIL_COND_V(img.is_null(), Ref<ImageTexture>()); + + print_line("captured! " + itos(img->get_width()) + "x" + itos(img->get_height())); + VS::get_singleton()->instance_set_base(mesh_instance, RID()); int thumbnail_size = EditorSettings::get_singleton()->get("filesystem/file_dialog/thumbnail_size"); - thumbnail_size*=EDSCALE; - img.resize(thumbnail_size,thumbnail_size); + thumbnail_size *= EDSCALE; + img->convert(Image::FORMAT_RGBA8); + img->resize(thumbnail_size, thumbnail_size); - Ref<ImageTexture> ptex = Ref<ImageTexture>( memnew( ImageTexture )); - ptex->create_from_image(img,0); + Ref<ImageTexture> ptex = Ref<ImageTexture>(memnew(ImageTexture)); + ptex->create_from_image(img, 0); return ptex; } EditorMeshPreviewPlugin::EditorMeshPreviewPlugin() { scenario = VS::get_singleton()->scenario_create(); + viewport = VS::get_singleton()->viewport_create(); - VS::get_singleton()->viewport_set_as_render_target(viewport,true); - VS::get_singleton()->viewport_set_render_target_update_mode(viewport,VS::RENDER_TARGET_UPDATE_DISABLED); - VS::get_singleton()->viewport_set_scenario(viewport,scenario); - VS::ViewportRect vr; - vr.x=0; - vr.y=0; - vr.width=128; - vr.height=128; - VS::get_singleton()->viewport_set_rect(viewport,vr); + VS::get_singleton()->viewport_set_update_mode(viewport, VS::VIEWPORT_UPDATE_DISABLED); + VS::get_singleton()->viewport_set_vflip(viewport, true); + VS::get_singleton()->viewport_set_scenario(viewport, scenario); + VS::get_singleton()->viewport_set_size(viewport, 128, 128); + VS::get_singleton()->viewport_set_transparent_background(viewport, true); + VS::get_singleton()->viewport_set_active(viewport, true); + viewport_texture = VS::get_singleton()->viewport_get_texture(viewport); camera = VS::get_singleton()->camera_create(); - VS::get_singleton()->viewport_attach_camera(viewport,camera); - VS::get_singleton()->camera_set_transform(camera,Transform(Matrix3(),Vector3(0,0,3))); + VS::get_singleton()->viewport_attach_camera(viewport, camera); + VS::get_singleton()->camera_set_transform(camera, Transform(Basis(), Vector3(0, 0, 3))); //VS::get_singleton()->camera_set_perspective(camera,45,0.1,10); - VS::get_singleton()->camera_set_orthogonal(camera,1.0,0.01,1000.0); + VS::get_singleton()->camera_set_orthogonal(camera, 1.0, 0.01, 1000.0); light = VS::get_singleton()->light_create(VS::LIGHT_DIRECTIONAL); - light_instance = VS::get_singleton()->instance_create2(light,scenario); - VS::get_singleton()->instance_set_transform(light_instance,Transform().looking_at(Vector3(-1,-1,-1),Vector3(0,1,0))); + light_instance = VS::get_singleton()->instance_create2(light, scenario); + VS::get_singleton()->instance_set_transform(light_instance, Transform().looking_at(Vector3(-1, -1, -1), Vector3(0, 1, 0))); light2 = VS::get_singleton()->light_create(VS::LIGHT_DIRECTIONAL); - VS::get_singleton()->light_set_color(light2,VS::LIGHT_COLOR_DIFFUSE,Color(0.7,0.7,0.7)); - VS::get_singleton()->light_set_color(light2,VS::LIGHT_COLOR_SPECULAR,Color(0.0,0.0,0.0)); - light_instance2 = VS::get_singleton()->instance_create2(light2,scenario); + VS::get_singleton()->light_set_color(light2, Color(0.7, 0.7, 0.7)); + //VS::get_singleton()->light_set_color(light2, VS::LIGHT_COLOR_SPECULAR, Color(0.0, 0.0, 0.0)); + light_instance2 = VS::get_singleton()->instance_create2(light2, scenario); - VS::get_singleton()->instance_set_transform(light_instance2,Transform().looking_at(Vector3(0,1,0),Vector3(0,0,1))); + VS::get_singleton()->instance_set_transform(light_instance2, Transform().looking_at(Vector3(0, 1, 0), Vector3(0, 0, 1))); //sphere = VS::get_singleton()->mesh_create(); mesh_instance = VS::get_singleton()->instance_create(); - VS::get_singleton()->instance_set_scenario(mesh_instance,scenario); - - - + VS::get_singleton()->instance_set_scenario(mesh_instance, scenario); } - EditorMeshPreviewPlugin::~EditorMeshPreviewPlugin() { //VS::get_singleton()->free(sphere); @@ -905,6 +885,4 @@ EditorMeshPreviewPlugin::~EditorMeshPreviewPlugin() { VS::get_singleton()->free(light_instance2); VS::get_singleton()->free(camera); VS::get_singleton()->free(scenario); - } -#endif diff --git a/editor/plugins/editor_preview_plugins.h b/editor/plugins/editor_preview_plugins.h index 993e36df02..7e7d36eb1e 100644 --- a/editor/plugins/editor_preview_plugins.h +++ b/editor/plugins/editor_preview_plugins.h @@ -32,55 +32,58 @@ #include "editor/editor_resource_preview.h" -#if 0 class EditorTexturePreviewPlugin : public EditorResourcePreviewGenerator { + GDCLASS(EditorTexturePreviewPlugin, EditorResourcePreviewGenerator) public: - - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); EditorTexturePreviewPlugin(); }; - class EditorBitmapPreviewPlugin : public EditorResourcePreviewGenerator { + GDCLASS(EditorBitmapPreviewPlugin, EditorResourcePreviewGenerator) public: - - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); EditorBitmapPreviewPlugin(); }; - - class EditorPackedScenePreviewPlugin : public EditorResourcePreviewGenerator { - Ref<Texture> _gen_from_imd(Ref<ResourceImportMetadata> p_imd); public: - - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); - virtual Ref<Texture> generate_from_path(const String& p_path); + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); + virtual Ref<Texture> generate_from_path(const String &p_path); EditorPackedScenePreviewPlugin(); }; class EditorMaterialPreviewPlugin : public EditorResourcePreviewGenerator { + GDCLASS(EditorMaterialPreviewPlugin, EditorResourcePreviewGenerator) + RID scenario; RID sphere; RID sphere_instance; RID viewport; + RID viewport_texture; RID light; RID light_instance; RID light2; RID light_instance2; RID camera; -public: + volatile bool preview_done; - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); + void _preview_done(const Variant &p_udata); + +protected: + static void _bind_methods(); + +public: + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); EditorMaterialPreviewPlugin(); ~EditorMaterialPreviewPlugin(); @@ -88,9 +91,8 @@ public: class EditorScriptPreviewPlugin : public EditorResourcePreviewGenerator { public: - - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); EditorScriptPreviewPlugin(); }; @@ -108,22 +110,30 @@ public: #endif class EditorMeshPreviewPlugin : public EditorResourcePreviewGenerator { + GDCLASS(EditorMeshPreviewPlugin, EditorResourcePreviewGenerator) + RID scenario; RID mesh_instance; RID viewport; + RID viewport_texture; RID light; RID light_instance; RID light2; RID light_instance2; RID camera; -public: + volatile bool preview_done; - virtual bool handles(const String& p_type) const; - virtual Ref<Texture> generate(const RES& p_from); + void _preview_done(const Variant &p_udata); + +protected: + static void _bind_methods(); + +public: + virtual bool handles(const String &p_type) const; + virtual Ref<Texture> generate(const RES &p_from); EditorMeshPreviewPlugin(); ~EditorMeshPreviewPlugin(); }; -#endif #endif // EDITORPREVIEWPLUGINS_H diff --git a/editor/plugins/color_ramp_editor_plugin.cpp b/editor/plugins/gradient_editor_plugin.cpp index 63369e5475..9884db934b 100644 --- a/editor/plugins/color_ramp_editor_plugin.cpp +++ b/editor/plugins/gradient_editor_plugin.cpp @@ -27,15 +27,15 @@ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#include "color_ramp_editor_plugin.h" +#include "gradient_editor_plugin.h" #include "canvas_item_editor_plugin.h" #include "spatial_editor_plugin.h" -ColorRampEditorPlugin::ColorRampEditorPlugin(EditorNode *p_node) { +GradientEditorPlugin::GradientEditorPlugin(EditorNode *p_node) { editor = p_node; - ramp_editor = memnew(ColorRampEdit); + ramp_editor = memnew(GradientEdit); add_control_to_container(CONTAINER_PROPERTY_EDITOR_BOTTOM, ramp_editor); @@ -44,21 +44,21 @@ ColorRampEditorPlugin::ColorRampEditorPlugin(EditorNode *p_node) { ramp_editor->connect("ramp_changed", this, "ramp_changed"); } -void ColorRampEditorPlugin::edit(Object *p_object) { +void GradientEditorPlugin::edit(Object *p_object) { - ColorRamp *color_ramp = p_object->cast_to<ColorRamp>(); - if (!color_ramp) + Gradient *gradient = p_object->cast_to<Gradient>(); + if (!gradient) return; - color_ramp_ref = Ref<ColorRamp>(color_ramp); - ramp_editor->set_points(color_ramp_ref->get_points()); + gradient_ref = Ref<Gradient>(gradient); + ramp_editor->set_points(gradient_ref->get_points()); } -bool ColorRampEditorPlugin::handles(Object *p_object) const { +bool GradientEditorPlugin::handles(Object *p_object) const { - return p_object->is_class("ColorRamp"); + return p_object->is_class("Gradient"); } -void ColorRampEditorPlugin::make_visible(bool p_visible) { +void GradientEditorPlugin::make_visible(bool p_visible) { if (p_visible) { ramp_editor->show(); @@ -67,43 +67,43 @@ void ColorRampEditorPlugin::make_visible(bool p_visible) { } } -void ColorRampEditorPlugin::_ramp_changed() { +void GradientEditorPlugin::_ramp_changed() { - if (color_ramp_ref.is_valid()) { + if (gradient_ref.is_valid()) { UndoRedo *ur = EditorNode::get_singleton()->get_undo_redo(); //Not sure if I should convert this data to PoolVector Vector<float> new_offsets = ramp_editor->get_offsets(); Vector<Color> new_colors = ramp_editor->get_colors(); - Vector<float> old_offsets = color_ramp_ref->get_offsets(); - Vector<Color> old_colors = color_ramp_ref->get_colors(); + Vector<float> old_offsets = gradient_ref->get_offsets(); + Vector<Color> old_colors = gradient_ref->get_colors(); if (old_offsets.size() != new_offsets.size()) ur->create_action(TTR("Add/Remove Color Ramp Point")); else ur->create_action(TTR("Modify Color Ramp"), UndoRedo::MERGE_ENDS); - ur->add_do_method(this, "undo_redo_color_ramp", new_offsets, new_colors); - ur->add_undo_method(this, "undo_redo_color_ramp", old_offsets, old_colors); + ur->add_do_method(this, "undo_redo_gradient", new_offsets, new_colors); + ur->add_undo_method(this, "undo_redo_gradient", old_offsets, old_colors); ur->commit_action(); //color_ramp_ref->set_points(ramp_editor->get_points()); } } -void ColorRampEditorPlugin::_undo_redo_color_ramp(const Vector<float> &offsets, +void GradientEditorPlugin::_undo_redo_gradient(const Vector<float> &offsets, const Vector<Color> &colors) { - color_ramp_ref->set_offsets(offsets); - color_ramp_ref->set_colors(colors); - ramp_editor->set_points(color_ramp_ref->get_points()); + gradient_ref->set_offsets(offsets); + gradient_ref->set_colors(colors); + ramp_editor->set_points(gradient_ref->get_points()); ramp_editor->update(); } -ColorRampEditorPlugin::~ColorRampEditorPlugin() { +GradientEditorPlugin::~GradientEditorPlugin() { } -void ColorRampEditorPlugin::_bind_methods() { - ClassDB::bind_method(D_METHOD("ramp_changed"), &ColorRampEditorPlugin::_ramp_changed); - ClassDB::bind_method(D_METHOD("undo_redo_color_ramp", "offsets", "colors"), &ColorRampEditorPlugin::_undo_redo_color_ramp); +void GradientEditorPlugin::_bind_methods() { + ClassDB::bind_method(D_METHOD("ramp_changed"), &GradientEditorPlugin::_ramp_changed); + ClassDB::bind_method(D_METHOD("undo_redo_gradient", "offsets", "colors"), &GradientEditorPlugin::_undo_redo_gradient); } diff --git a/editor/plugins/color_ramp_editor_plugin.h b/editor/plugins/gradient_editor_plugin.h index 73b15b85a1..843e98a917 100644 --- a/editor/plugins/color_ramp_editor_plugin.h +++ b/editor/plugins/gradient_editor_plugin.h @@ -32,21 +32,21 @@ #include "editor/editor_node.h" #include "editor/editor_plugin.h" -#include "scene/gui/color_ramp_edit.h" +#include "scene/gui/gradient_edit.h" -class ColorRampEditorPlugin : public EditorPlugin { +class GradientEditorPlugin : public EditorPlugin { - GDCLASS(ColorRampEditorPlugin, EditorPlugin); + GDCLASS(GradientEditorPlugin, EditorPlugin); bool _2d; - Ref<ColorRamp> color_ramp_ref; - ColorRampEdit *ramp_editor; + Ref<Gradient> gradient_ref; + GradientEdit *ramp_editor; EditorNode *editor; protected: static void _bind_methods(); void _ramp_changed(); - void _undo_redo_color_ramp(const Vector<float> &offsets, const Vector<Color> &colors); + void _undo_redo_gradient(const Vector<float> &offsets, const Vector<Color> &colors); public: virtual String get_name() const { return "ColorRamp"; } @@ -55,8 +55,8 @@ public: virtual bool handles(Object *p_node) const; virtual void make_visible(bool p_visible); - ColorRampEditorPlugin(EditorNode *p_node); - ~ColorRampEditorPlugin(); + GradientEditorPlugin(EditorNode *p_node); + ~GradientEditorPlugin(); }; #endif /* TOOLS_EDITOR_PLUGINS_COLOR_RAMP_EDITOR_PLUGIN_H_ */ diff --git a/editor/plugins/gradient_texture_editor_plugin.cpp b/editor/plugins/gradient_texture_editor_plugin.cpp index 9551fe19fa..bc985dcdf7 100644 --- a/editor/plugins/gradient_texture_editor_plugin.cpp +++ b/editor/plugins/gradient_texture_editor_plugin.cpp @@ -1,10 +1,39 @@ +/*************************************************************************/ +/* gradient_texture_editor_plugin.cpp */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #include "gradient_texture_editor_plugin.h" #include "canvas_item_editor_plugin.h" -#include "spatial_editor_plugin.h" - #include "os/keyboard.h" #include "scene/resources/default_theme/theme_data.h" +#include "spatial_editor_plugin.h" + #define POINT_WIDTH 8 GradientTextureEdit::GradientTextureEdit() { @@ -19,7 +48,8 @@ GradientTextureEdit::GradientTextureEdit() { add_child(popup); checker = Ref<ImageTexture>(memnew(ImageTexture)); - checker->create_from_image(Image(checker_bg_png), ImageTexture::FLAG_REPEAT); + Ref<Image> checker_bg = memnew(Image(checker_bg_png)); + checker->create_from_image(checker_bg, ImageTexture::FLAG_REPEAT); } int GradientTextureEdit::_get_point_from_pos(int x) { @@ -47,9 +77,11 @@ void GradientTextureEdit::_show_color_picker() { GradientTextureEdit::~GradientTextureEdit() { } -void GradientTextureEdit::_gui_input(const InputEvent &p_event) { +void GradientTextureEdit::_gui_input(const Ref<InputEvent> &p_event) { + + Ref<InputEventKey> k = p_event; - if (p_event.type == InputEvent::KEY && p_event.key.pressed && p_event.key.scancode == KEY_DELETE && grabbed != -1) { + if (k.is_valid() && k->is_pressed() && k->get_scancode() == KEY_DELETE && grabbed != -1) { points.remove(grabbed); grabbed = -1; @@ -59,16 +91,17 @@ void GradientTextureEdit::_gui_input(const InputEvent &p_event) { accept_event(); } + Ref<InputEventMouseButton> mb = p_event; //Show color picker on double click. - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.doubleclick && p_event.mouse_button.pressed) { - grabbed = _get_point_from_pos(p_event.mouse_button.x); + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_doubleclick() && mb->is_pressed()) { + grabbed = _get_point_from_pos(mb->get_position().x); _show_color_picker(); accept_event(); } //Delete point on right click - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 2 && p_event.mouse_button.pressed) { - grabbed = _get_point_from_pos(p_event.mouse_button.x); + if (mb.is_valid() && mb->get_button_index() == 2 && mb->is_pressed()) { + grabbed = _get_point_from_pos(mb->get_position().x); if (grabbed != -1) { points.remove(grabbed); grabbed = -1; @@ -80,9 +113,9 @@ void GradientTextureEdit::_gui_input(const InputEvent &p_event) { } //Hold alt key to duplicate selected color - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.pressed && p_event.key.mod.alt) { + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed() && mb->get_alt()) { - int x = p_event.mouse_button.x; + int x = mb->get_position().x; grabbed = _get_point_from_pos(x); if (grabbed != -1) { @@ -104,10 +137,10 @@ void GradientTextureEdit::_gui_input(const InputEvent &p_event) { } } - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.pressed) { + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed()) { update(); - int x = p_event.mouse_button.x; + int x = mb->get_position().x; int total_w = get_size().width - get_size().height - 3; //Check if color selector was clicked. @@ -172,7 +205,7 @@ void GradientTextureEdit::_gui_input(const InputEvent &p_event) { emit_signal("ramp_changed"); } - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && !p_event.mouse_button.pressed) { + if (mb.is_valid() && mb->get_button_index() == 1 && !mb->is_pressed()) { if (grabbing) { grabbing = false; @@ -181,15 +214,17 @@ void GradientTextureEdit::_gui_input(const InputEvent &p_event) { update(); } - if (p_event.type == InputEvent::MOUSE_MOTION && grabbing) { + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid() && grabbing) { int total_w = get_size().width - get_size().height - 3; - int x = p_event.mouse_motion.x; + int x = mm->get_position().x; float newofs = CLAMP(x / float(total_w), 0, 1); //Snap to nearest point if holding shift - if (p_event.key.mod.shift) { + if (mm->get_shift()) { float snap_treshhold = 0.03; float smallest_ofs = snap_treshhold; bool founded = false; diff --git a/editor/plugins/gradient_texture_editor_plugin.h b/editor/plugins/gradient_texture_editor_plugin.h index 5af828f17c..842d586541 100644 --- a/editor/plugins/gradient_texture_editor_plugin.h +++ b/editor/plugins/gradient_texture_editor_plugin.h @@ -1,3 +1,32 @@ +/*************************************************************************/ +/* gradient_texture_editor_plugin.h */ +/*************************************************************************/ +/* This file is part of: */ +/* GODOT ENGINE */ +/* http://www.godotengine.org */ +/*************************************************************************/ +/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ +/* */ +/* Permission is hereby granted, free of charge, to any person obtaining */ +/* a copy of this software and associated documentation files (the */ +/* "Software"), to deal in the Software without restriction, including */ +/* without limitation the rights to use, copy, modify, merge, publish, */ +/* distribute, sublicense, and/or sell copies of the Software, and to */ +/* permit persons to whom the Software is furnished to do so, subject to */ +/* the following conditions: */ +/* */ +/* The above copyright notice and this permission notice shall be */ +/* included in all copies or substantial portions of the Software. */ +/* */ +/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ +/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ +/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ +/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ +/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ +/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ +/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/*************************************************************************/ #ifndef GRADIENT_TEXTURE_EDITOR_PLUGIN_H #define GRADIENT_TEXTURE_EDITOR_PLUGIN_H @@ -24,7 +53,7 @@ class GradientTextureEdit : public Control { void _show_color_picker(); protected: - void _gui_input(const InputEvent &p_event); + void _gui_input(const Ref<InputEvent> &p_event); void _notification(int p_what); static void _bind_methods(); diff --git a/editor/plugins/light_occluder_2d_editor_plugin.cpp b/editor/plugins/light_occluder_2d_editor_plugin.cpp index 73b615d817..09021446dc 100644 --- a/editor/plugins/light_occluder_2d_editor_plugin.cpp +++ b/editor/plugins/light_occluder_2d_editor_plugin.cpp @@ -98,225 +98,223 @@ void LightOccluder2DEditor::_wip_close(bool p_closed) { edited_point = -1; } -bool LightOccluder2DEditor::forward_gui_input(const InputEvent &p_event) { +bool LightOccluder2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) return false; if (node->get_occluder_polygon().is_null()) { - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.pressed) { + Ref<InputEventMouseButton> mb = p_event; + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed()) { create_poly->set_text("No OccluderPolygon2D resource on this node.\nCreate and assign one?"); create_poly->popup_centered_minsize(); } - return (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1); + return (mb.is_valid() && mb->get_button_index() == 1); } - switch (p_event.type) { - case InputEvent::MOUSE_BUTTON: { + Ref<InputEventMouseButton> mb = p_event; - const InputEventMouseButton &mb = p_event.mouse_button; + if (mb.is_valid()) { - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - cpoint = node->get_global_transform().affine_inverse().xform(cpoint); + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + cpoint = node->get_global_transform().affine_inverse().xform(cpoint); - Vector<Vector2> poly = Variant(node->get_occluder_polygon()->get_polygon()); + Vector<Vector2> poly = Variant(node->get_occluder_polygon()->get_polygon()); - //first check if a point is to be added (segment split) - real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); + //first check if a point is to be added (segment split) + real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); - switch (mode) { + switch (mode) { - case MODE_CREATE: { + case MODE_CREATE: { - if (mb.button_index == BUTTON_LEFT && mb.pressed) { + if (mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) { - if (!wip_active) { + if (!wip_active) { - wip.clear(); - wip.push_back(cpoint); - wip_active = true; - edited_point_pos = cpoint; - canvas_item_editor->get_viewport_control()->update(); - edited_point = 1; - return true; - } else { + wip.clear(); + wip.push_back(cpoint); + wip_active = true; + edited_point_pos = cpoint; + canvas_item_editor->get_viewport_control()->update(); + edited_point = 1; + return true; + } else { - if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { - //wip closed - _wip_close(true); + if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { + //wip closed + _wip_close(true); - return true; - } else if (wip.size() > 1 && xform.xform(wip[wip.size() - 1]).distance_to(gpoint) < grab_treshold) { - //wip closed - _wip_close(false); - return true; + return true; + } else if (wip.size() > 1 && xform.xform(wip[wip.size() - 1]).distance_to(gpoint) < grab_treshold) { + //wip closed + _wip_close(false); + return true; - } else { + } else { - wip.push_back(cpoint); - edited_point = wip.size(); - canvas_item_editor->get_viewport_control()->update(); - return true; + wip.push_back(cpoint); + edited_point = wip.size(); + canvas_item_editor->get_viewport_control()->update(); + return true; - //add wip point - } + //add wip point } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && wip_active) { - _wip_close(true); } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && wip_active) { + _wip_close(true); + } - } break; - - case MODE_EDIT: { - - if (mb.button_index == BUTTON_LEFT) { - if (mb.pressed) { - - if (mb.mod.control) { + } break; - if (poly.size() < 3) { + case MODE_EDIT: { - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); - poly.push_back(cpoint); - undo_redo->add_do_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - return true; - } + if (mb->get_button_index() == BUTTON_LEFT) { + if (mb->is_pressed()) { - //search edges - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { - - Vector2 points[2] = { xform.xform(poly[i]), - xform.xform(poly[(i + 1) % poly.size()]) }; - - Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); - if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) - continue; //not valid to reuse point - - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } - } + if (mb->get_control()) { - if (closest_idx >= 0) { + if (poly.size() < 3) { - pre_move_edit = poly; - poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); - edited_point = closest_idx + 1; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - node->get_occluder_polygon()->set_polygon(Variant(poly)); - canvas_item_editor->get_viewport_control()->update(); - return true; - } - } else { + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); + poly.push_back(cpoint); + undo_redo->add_do_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } - //look for points to move + //search edges + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { + Vector2 points[2] = { xform.xform(poly[i]), + xform.xform(poly[(i + 1) % poly.size()]) }; - Vector2 cp = xform.xform(poly[i]); + Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); + if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) + continue; //not valid to reuse point - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; } + } - if (closest_idx >= 0) { + if (closest_idx >= 0) { - pre_move_edit = poly; - edited_point = closest_idx; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - canvas_item_editor->get_viewport_control()->update(); - return true; - } + pre_move_edit = poly; + poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); + edited_point = closest_idx + 1; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + node->get_occluder_polygon()->set_polygon(Variant(poly)); + canvas_item_editor->get_viewport_control()->update(); + return true; } } else { - if (edited_point != -1) { + //look for points to move - //apply + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - ERR_FAIL_INDEX_V(edited_point, poly.size(), false); - poly[edited_point] = edited_point_pos; - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_do_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); - undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", pre_move_edit); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + Vector2 cp = xform.xform(poly[i]); - edited_point = -1; - return true; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } } - } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && edited_point == -1) { - - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { - Vector2 cp = xform.xform(poly[i]); + if (closest_idx >= 0) { - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; + pre_move_edit = poly; + edited_point = closest_idx; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + canvas_item_editor->get_viewport_control()->update(); + return true; } } + } else { + + if (edited_point != -1) { - if (closest_idx >= 0) { + //apply - undo_redo->create_action(TTR("Edit Poly (Remove Point)")); - undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); - poly.remove(closest_idx); + ERR_FAIL_INDEX_V(edited_point, poly.size(), false); + poly[edited_point] = edited_point_pos; + undo_redo->create_action(TTR("Edit Poly")); undo_redo->add_do_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); + undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", pre_move_edit); undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->commit_action(); + + edited_point = -1; return true; } } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && edited_point == -1) { - } break; - } + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - } break; - case InputEvent::MOUSE_MOTION: { + Vector2 cp = xform.xform(poly[i]); - const InputEventMouseMotion &mm = p_event.mouse_motion; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } + } - if (edited_point != -1 && (wip_active || mm.button_mask & BUTTON_MASK_LEFT)) { + if (closest_idx >= 0) { - Vector2 gpoint = Point2(mm.x, mm.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + undo_redo->create_action(TTR("Edit Poly (Remove Point)")); + undo_redo->add_undo_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); + poly.remove(closest_idx); + undo_redo->add_do_method(node->get_occluder_polygon().ptr(), "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } + } - canvas_item_editor->get_viewport_control()->update(); - } + } break; + } + } - } break; + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid()) { + + if (edited_point != -1 && (wip_active || mm->get_button_mask() & BUTTON_MASK_LEFT)) { + + Vector2 gpoint = mm->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + + canvas_item_editor->get_viewport_control()->update(); + } } return false; diff --git a/editor/plugins/light_occluder_2d_editor_plugin.h b/editor/plugins/light_occluder_2d_editor_plugin.h index 8e0817e61e..d6579fc94c 100644 --- a/editor/plugins/light_occluder_2d_editor_plugin.h +++ b/editor/plugins/light_occluder_2d_editor_plugin.h @@ -84,7 +84,7 @@ protected: public: Vector2 snap_point(const Vector2 &p_point) const; - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_collision_polygon); LightOccluder2DEditor(EditorNode *p_editor); }; @@ -97,7 +97,7 @@ class LightOccluder2DEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } virtual String get_name() const { return "LightOccluder2D"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/line_2d_editor_plugin.cpp b/editor/plugins/line_2d_editor_plugin.cpp index 69e329eb1a..76906a5b93 100644 --- a/editor/plugins/line_2d_editor_plugin.cpp +++ b/editor/plugins/line_2d_editor_plugin.cpp @@ -62,7 +62,7 @@ Vector2 Line2DEditor::mouse_to_local_pos(Vector2 gpoint, bool alt) { int Line2DEditor::get_point_index_at(Vector2 gpos) { ERR_FAIL_COND_V(node == 0, -1); - real_t grab_treshold = EDITOR_DEF("poly_editor/point_grab_radius", 8); + real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); for (int i = 0; i < node->get_point_count(); ++i) { @@ -75,7 +75,7 @@ int Line2DEditor::get_point_index_at(Vector2 gpos) { return -1; } -bool Line2DEditor::forward_gui_input(const InputEvent &p_event) { +bool Line2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) return false; @@ -83,75 +83,74 @@ bool Line2DEditor::forward_gui_input(const InputEvent &p_event) { if (!node->is_visible()) return false; - switch (p_event.type) { - - case InputEvent::MOUSE_BUTTON: { - - const InputEventMouseButton &mb = p_event.mouse_button; - - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = mouse_to_local_pos(gpoint, mb.mod.alt); - - if (mb.pressed && _dragging == false) { - int i = get_point_index_at(gpoint); - if (i != -1) { - if (mb.button_index == BUTTON_LEFT && !mb.mod.shift && mode == MODE_EDIT) { - _dragging = true; - action_point = i; - moving_from = node->get_point_pos(i); - moving_screen_from = gpoint; - } else if ((mb.button_index == BUTTON_RIGHT && mode == MODE_EDIT) || (mb.button_index == BUTTON_LEFT && mode == MODE_DELETE)) { - undo_redo->create_action(TTR("Remove Point from Line2D")); - undo_redo->add_do_method(node, "remove_point", i); - undo_redo->add_undo_method(node, "add_point", node->get_point_pos(i), i); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - } - return true; + Ref<InputEventMouseButton> mb = p_event; + + if (mb.is_valid()) { + + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = mouse_to_local_pos(gpoint, mb->get_alt()); + + if (mb->is_pressed() && _dragging == false) { + int i = get_point_index_at(gpoint); + if (i != -1) { + if (mb->get_button_index() == BUTTON_LEFT && !mb->get_shift() && mode == MODE_EDIT) { + _dragging = true; + action_point = i; + moving_from = node->get_point_pos(i); + moving_screen_from = gpoint; + } else if ((mb->get_button_index() == BUTTON_RIGHT && mode == MODE_EDIT) || (mb->get_button_index() == BUTTON_LEFT && mode == MODE_DELETE)) { + undo_redo->create_action(TTR("Remove Point from Line2D")); + undo_redo->add_do_method(node, "remove_point", i); + undo_redo->add_undo_method(node, "add_point", node->get_point_pos(i), i); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); } + return true; } + } - if (mb.pressed && mb.button_index == BUTTON_LEFT && ((mb.mod.command && mode == MODE_EDIT) || mode == MODE_CREATE)) { + if (mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT && ((mb->get_command() && mode == MODE_EDIT) || mode == MODE_CREATE)) { - undo_redo->create_action(TTR("Add Point to Line2D")); - undo_redo->add_do_method(node, "add_point", cpoint); - undo_redo->add_undo_method(node, "remove_point", node->get_point_count()); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + undo_redo->create_action(TTR("Add Point to Line2D")); + undo_redo->add_do_method(node, "add_point", cpoint); + undo_redo->add_undo_method(node, "remove_point", node->get_point_count()); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - _dragging = true; - action_point = node->get_point_count() - 1; - moving_from = node->get_point_pos(action_point); - moving_screen_from = gpoint; + _dragging = true; + action_point = node->get_point_count() - 1; + moving_from = node->get_point_pos(action_point); + moving_screen_from = gpoint; - canvas_item_editor->get_viewport_control()->update(); + canvas_item_editor->get_viewport_control()->update(); - return true; - } + return true; + } - if (!mb.pressed && mb.button_index == BUTTON_LEFT && _dragging) { - undo_redo->create_action(TTR("Move Point in Line2D")); - undo_redo->add_do_method(node, "set_point_pos", action_point, cpoint); - undo_redo->add_undo_method(node, "set_point_pos", action_point, moving_from); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - _dragging = false; - return true; - } - } break; - - case InputEvent::MOUSE_MOTION: { - if (_dragging) { - const InputEventMouseMotion &mm = p_event.mouse_motion; - Vector2 cpoint = mouse_to_local_pos(Vector2(mm.x, mm.y), mm.mod.alt); - node->set_point_pos(action_point, cpoint); - canvas_item_editor->get_viewport_control()->update(); - return true; - } - } break; + if (!mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT && _dragging) { + undo_redo->create_action(TTR("Move Point in Line2D")); + undo_redo->add_do_method(node, "set_point_pos", action_point, cpoint); + undo_redo->add_undo_method(node, "set_point_pos", action_point, moving_from); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + _dragging = false; + return true; + } + } + + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid()) { + + if (_dragging) { + Vector2 cpoint = mouse_to_local_pos(mm->get_position(), mm->get_alt()); + node->set_point_pos(action_point, cpoint); + canvas_item_editor->get_viewport_control()->update(); + return true; + } } return false; diff --git a/editor/plugins/line_2d_editor_plugin.h b/editor/plugins/line_2d_editor_plugin.h index 7477f7eee5..3a1f841556 100644 --- a/editor/plugins/line_2d_editor_plugin.h +++ b/editor/plugins/line_2d_editor_plugin.h @@ -43,7 +43,7 @@ class Line2DEditor : public HBoxContainer { GDCLASS(Line2DEditor, HBoxContainer) public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_line2d); Line2DEditor(EditorNode *p_editor); @@ -95,7 +95,7 @@ class Line2DEditorPlugin : public EditorPlugin { public: virtual bool forward_canvas_gui_input( const Transform2D &p_canvas_xform, - const InputEvent &p_event) { + const Ref<InputEvent> &p_event) { return line2d_editor->forward_gui_input(p_event); } diff --git a/editor/plugins/mesh_editor_plugin.cpp b/editor/plugins/mesh_editor_plugin.cpp index 61da860cab..f377d3a7cc 100644 --- a/editor/plugins/mesh_editor_plugin.cpp +++ b/editor/plugins/mesh_editor_plugin.cpp @@ -33,10 +33,10 @@ void MeshEditor::_gui_input(InputEvent p_event) { - if (p_event.type==InputEvent::MOUSE_MOTION && p_event.mouse_motion.button_mask&BUTTON_MASK_LEFT) { + if (p_event.type==InputEvent::MOUSE_MOTION && p_event->get_button_mask()&BUTTON_MASK_LEFT) { - rot_x-=p_event.mouse_motion.relative_y*0.01; - rot_y-=p_event.mouse_motion.relative_x*0.01; + rot_x-=p_event->get_relative().y*0.01; + rot_y-=p_event->get_relative().x*0.01; if (rot_x<-Math_PI/2) rot_x=-Math_PI/2; else if (rot_x>Math_PI/2) { diff --git a/editor/plugins/navigation_polygon_editor_plugin.cpp b/editor/plugins/navigation_polygon_editor_plugin.cpp index be8c46f379..1457b28ed1 100644 --- a/editor/plugins/navigation_polygon_editor_plugin.cpp +++ b/editor/plugins/navigation_polygon_editor_plugin.cpp @@ -112,263 +112,262 @@ void NavigationPolygonEditor::_wip_close() { edited_point = -1; } -bool NavigationPolygonEditor::forward_gui_input(const InputEvent &p_event) { +bool NavigationPolygonEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) return false; if (node->get_navigation_polygon().is_null()) { - if (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1 && p_event.mouse_button.pressed) { + + Ref<InputEventMouseButton> mb = p_event; + + if (mb.is_valid() && mb->get_button_index() == 1 && mb->is_pressed()) { create_nav->set_text("No NavigationPolygon resource on this node.\nCreate and assign one?"); create_nav->popup_centered_minsize(); } - return (p_event.type == InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index == 1); + return (mb.is_valid() && mb->get_button_index() == 1); } - switch (p_event.type) { + Ref<InputEventMouseButton> mb = p_event; - case InputEvent::MOUSE_BUTTON: { + if (mb.is_valid()) { - const InputEventMouseButton &mb = p_event.mouse_button; + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + cpoint = node->get_global_transform().affine_inverse().xform(cpoint); - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - cpoint = node->get_global_transform().affine_inverse().xform(cpoint); + //first check if a point is to be added (segment split) + real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); - //first check if a point is to be added (segment split) - real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); + switch (mode) { - switch (mode) { + case MODE_CREATE: { - case MODE_CREATE: { + if (mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) { - if (mb.button_index == BUTTON_LEFT && mb.pressed) { + if (!wip_active) { - if (!wip_active) { + wip.clear(); + wip.push_back(cpoint); + wip_active = true; + edited_point_pos = cpoint; + edited_outline = -1; + canvas_item_editor->get_viewport_control()->update(); + edited_point = 1; + return true; + } else { + + if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { + //wip closed + _wip_close(); - wip.clear(); - wip.push_back(cpoint); - wip_active = true; - edited_point_pos = cpoint; - edited_outline = -1; - canvas_item_editor->get_viewport_control()->update(); - edited_point = 1; return true; } else { - if (wip.size() > 1 && xform.xform(wip[0]).distance_to(gpoint) < grab_treshold) { - //wip closed - _wip_close(); - - return true; - } else { - - wip.push_back(cpoint); - edited_point = wip.size(); - canvas_item_editor->get_viewport_control()->update(); - return true; + wip.push_back(cpoint); + edited_point = wip.size(); + canvas_item_editor->get_viewport_control()->update(); + return true; - //add wip point - } + //add wip point } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && wip_active) { - _wip_close(); } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && wip_active) { + _wip_close(); + } - } break; + } break; - case MODE_EDIT: { + case MODE_EDIT: { - if (mb.button_index == BUTTON_LEFT) { - if (mb.pressed) { + if (mb->get_button_index() == BUTTON_LEFT) { + if (mb->is_pressed()) { - if (mb.mod.control) { + if (mb->get_control()) { - //search edges - int closest_outline = -1; - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; + //search edges + int closest_outline = -1; + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; - for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { + for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { - PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); + PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); - int pc = points.size(); - PoolVector<Vector2>::Read poly = points.read(); + int pc = points.size(); + PoolVector<Vector2>::Read poly = points.read(); - for (int i = 0; i < pc; i++) { + for (int i = 0; i < pc; i++) { - Vector2 points[2] = { xform.xform(poly[i]), - xform.xform(poly[(i + 1) % pc]) }; + Vector2 points[2] = { xform.xform(poly[i]), + xform.xform(poly[(i + 1) % pc]) }; - Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); - if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) - continue; //not valid to reuse point + Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); + if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) + continue; //not valid to reuse point - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_outline = j; - closest_pos = cp; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_outline = j; + closest_pos = cp; + closest_idx = i; } } + } - if (closest_idx >= 0) { - - pre_move_edit = node->get_navigation_polygon()->get_outline(closest_outline); - PoolVector<Point2> poly = pre_move_edit; - poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); - edited_point = closest_idx + 1; - edited_outline = closest_outline; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - node->get_navigation_polygon()->set_outline(closest_outline, poly); - canvas_item_editor->get_viewport_control()->update(); - return true; - } - } else { + if (closest_idx >= 0) { + + pre_move_edit = node->get_navigation_polygon()->get_outline(closest_outline); + PoolVector<Point2> poly = pre_move_edit; + poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos)); + edited_point = closest_idx + 1; + edited_outline = closest_outline; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + node->get_navigation_polygon()->set_outline(closest_outline, poly); + canvas_item_editor->get_viewport_control()->update(); + return true; + } + } else { - //look for points to move - int closest_outline = -1; - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; + //look for points to move + int closest_outline = -1; + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; - for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { + for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { - PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); + PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); - int pc = points.size(); - PoolVector<Vector2>::Read poly = points.read(); + int pc = points.size(); + PoolVector<Vector2>::Read poly = points.read(); - for (int i = 0; i < pc; i++) { + for (int i = 0; i < pc; i++) { - Vector2 cp = xform.xform(poly[i]); + Vector2 cp = xform.xform(poly[i]); - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_outline = j; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_outline = j; + closest_idx = i; } } + } - if (closest_idx >= 0) { + if (closest_idx >= 0) { - pre_move_edit = node->get_navigation_polygon()->get_outline(closest_outline); - edited_point = closest_idx; - edited_outline = closest_outline; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - canvas_item_editor->get_viewport_control()->update(); - return true; - } + pre_move_edit = node->get_navigation_polygon()->get_outline(closest_outline); + edited_point = closest_idx; + edited_outline = closest_outline; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + canvas_item_editor->get_viewport_control()->update(); + return true; } - } else { + } + } else { - if (edited_point != -1) { + if (edited_point != -1) { - //apply + //apply - PoolVector<Vector2> poly = node->get_navigation_polygon()->get_outline(edited_outline); - ERR_FAIL_INDEX_V(edited_point, poly.size(), false); - poly.set(edited_point, edited_point_pos); - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "set_outline", edited_outline, poly); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "set_outline", edited_outline, pre_move_edit); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + PoolVector<Vector2> poly = node->get_navigation_polygon()->get_outline(edited_outline); + ERR_FAIL_INDEX_V(edited_point, poly.size(), false); + poly.set(edited_point, edited_point_pos); + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "set_outline", edited_outline, poly); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "set_outline", edited_outline, pre_move_edit); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - edited_point = -1; - return true; - } + edited_point = -1; + return true; } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && edited_point == -1) { + } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && edited_point == -1) { - int closest_outline = -1; - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; + int closest_outline = -1; + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; - for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { + for (int j = 0; j < node->get_navigation_polygon()->get_outline_count(); j++) { - PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); + PoolVector<Vector2> points = node->get_navigation_polygon()->get_outline(j); - int pc = points.size(); - PoolVector<Vector2>::Read poly = points.read(); + int pc = points.size(); + PoolVector<Vector2>::Read poly = points.read(); - for (int i = 0; i < pc; i++) { + for (int i = 0; i < pc; i++) { - Vector2 cp = xform.xform(poly[i]); + Vector2 cp = xform.xform(poly[i]); - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_outline = j; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_outline = j; + closest_idx = i; } } + } - if (closest_idx >= 0) { - - PoolVector<Vector2> poly = node->get_navigation_polygon()->get_outline(closest_outline); - - if (poly.size() > 3) { - undo_redo->create_action(TTR("Edit Poly (Remove Point)")); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "set_outline", closest_outline, poly); - poly.remove(closest_idx); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "set_outline", closest_outline, poly); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - } else { - - undo_redo->create_action(TTR("Remove Poly And Point")); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "add_outline_at_index", poly, closest_outline); - poly.remove(closest_idx); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "remove_outline", closest_outline); - undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - } - return true; + if (closest_idx >= 0) { + + PoolVector<Vector2> poly = node->get_navigation_polygon()->get_outline(closest_outline); + + if (poly.size() > 3) { + undo_redo->create_action(TTR("Edit Poly (Remove Point)")); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "set_outline", closest_outline, poly); + poly.remove(closest_idx); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "set_outline", closest_outline, poly); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + } else { + + undo_redo->create_action(TTR("Remove Poly And Point")); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "add_outline_at_index", poly, closest_outline); + poly.remove(closest_idx); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "remove_outline", closest_outline); + undo_redo->add_do_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_undo_method(node->get_navigation_polygon().ptr(), "make_polygons_from_outlines"); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); } + return true; } + } - } break; - } - - } break; - case InputEvent::MOUSE_MOTION: { + } break; + } + } - const InputEventMouseMotion &mm = p_event.mouse_motion; + Ref<InputEventMouseMotion> mm = p_event; - if (edited_point != -1 && (wip_active || mm.button_mask & BUTTON_MASK_LEFT)) { + if (mm.is_valid()) { - Vector2 gpoint = Point2(mm.x, mm.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + if (edited_point != -1 && (wip_active || mm->get_button_mask() & BUTTON_MASK_LEFT)) { - canvas_item_editor->get_viewport_control()->update(); - } + Vector2 gpoint = mm->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); - } break; + canvas_item_editor->get_viewport_control()->update(); + } } return false; diff --git a/editor/plugins/navigation_polygon_editor_plugin.h b/editor/plugins/navigation_polygon_editor_plugin.h index 6de77b5ef3..62a83983fd 100644 --- a/editor/plugins/navigation_polygon_editor_plugin.h +++ b/editor/plugins/navigation_polygon_editor_plugin.h @@ -85,7 +85,7 @@ protected: static void _bind_methods(); public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_collision_polygon); NavigationPolygonEditor(EditorNode *p_editor); }; @@ -98,7 +98,7 @@ class NavigationPolygonEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } virtual String get_name() const { return "NavigationPolygonInstance"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/particles_2d_editor_plugin.cpp b/editor/plugins/particles_2d_editor_plugin.cpp index 35743ce0b3..c6c85d8be2 100644 --- a/editor/plugins/particles_2d_editor_plugin.cpp +++ b/editor/plugins/particles_2d_editor_plugin.cpp @@ -64,17 +64,18 @@ void Particles2DEditorPlugin::_file_selected(const String &p_file) { int epc = epoints->get_value(); - Image img; - Error err = ImageLoader::load_image(p_file, &img); + Ref<Image> img; + img.instance(); + Error err = ImageLoader::load_image(p_file, img); ERR_EXPLAIN(TTR("Error loading image:") + " " + p_file); ERR_FAIL_COND(err != OK); - img.convert(Image::FORMAT_LA8); - ERR_FAIL_COND(img.get_format() != Image::FORMAT_LA8); - Size2i s = Size2(img.get_width(), img.get_height()); + img->convert(Image::FORMAT_LA8); + ERR_FAIL_COND(img->get_format() != Image::FORMAT_LA8); + Size2i s = Size2(img->get_width(), img->get_height()); ERR_FAIL_COND(s.width == 0 || s.height == 0); - PoolVector<uint8_t> data = img.get_data(); + PoolVector<uint8_t> data = img->get_data(); PoolVector<uint8_t>::Read r = data.read(); Vector<Point2i> valid_positions; @@ -98,7 +99,7 @@ void Particles2DEditorPlugin::_file_selected(const String &p_file) { epoints.resize(epc); PoolVector<Point2>::Write w = epoints.write(); - Size2 extents = Size2(img.get_width() * 0.5, img.get_height() * 0.5); + Size2 extents = Size2(img->get_width() * 0.5, img->get_height() * 0.5); for (int i = 0; i < epc; i++) { diff --git a/editor/plugins/particles_editor_plugin.cpp b/editor/plugins/particles_editor_plugin.cpp index 4c84e831c1..d918a3e24e 100644 --- a/editor/plugins/particles_editor_plugin.cpp +++ b/editor/plugins/particles_editor_plugin.cpp @@ -254,7 +254,7 @@ void ParticlesEditor::_generate_emission_points() { for (int j = 0; j < 3; j++) { if (i == 0 && j == 0) - aabb.pos = r[i].vertex[j]; + aabb.position = r[i].vertex[j]; else aabb.expand_to(r[i].vertex[j]); } @@ -272,7 +272,7 @@ void ParticlesEditor::_generate_emission_points() { dir[Math::rand() % 3] = 1.0; Vector3 ofs = Vector3(1, 1, 1) - dir; ofs = (Vector3(1, 1, 1) - dir) * Vector3(Math::randf(), Math::randf(), Math::randf()) * aabb.size; - ofs += aabb.pos; + ofs += aabb.position; Vector3 ofsv = ofs + aabb.size * dir; @@ -329,7 +329,7 @@ void ParticlesEditor::_generate_emission_points() { copymem(iw.ptr(), r.ptr(), point_count * sizeof(float) * 3); } - Image image(w, h, false, Image::FORMAT_RGBF, point_img); + Ref<Image> image = memnew(Image(w, h, false, Image::FORMAT_RGBF, point_img)); Ref<ImageTexture> tex; tex.instance(); @@ -354,7 +354,7 @@ void ParticlesEditor::_generate_emission_points() { copymem(iw.ptr(), r.ptr(), point_count * sizeof(float) * 3); } - Image image2(w, h, false, Image::FORMAT_RGBF, point_img2); + Ref<Image> image2 = memnew(Image(w, h, false, Image::FORMAT_RGBF, point_img2)); Ref<ImageTexture> tex2; tex2.instance(); diff --git a/editor/plugins/path_2d_editor_plugin.cpp b/editor/plugins/path_2d_editor_plugin.cpp index e00111b565..f9f16fea16 100644 --- a/editor/plugins/path_2d_editor_plugin.cpp +++ b/editor/plugins/path_2d_editor_plugin.cpp @@ -58,8 +58,7 @@ void Path2DEditor::_node_removed(Node *p_node) { } } -bool Path2DEditor::forward_gui_input(const InputEvent &p_event) { - +bool Path2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node) return false; @@ -69,70 +68,50 @@ bool Path2DEditor::forward_gui_input(const InputEvent &p_event) { if (!node->get_curve().is_valid()) return false; - switch (p_event.type) { - - case InputEvent::MOUSE_BUTTON: { - - const InputEventMouseButton &mb = p_event.mouse_button; - - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Ref<InputEventMouseButton> mb = p_event; - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = !mb.mod.alt ? canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)) : node->get_global_transform().affine_inverse().xform(canvas_item_editor->snap_point(canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint))); + if (mb.is_valid()) { - //first check if a point is to be added (segment split) - real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - // Test move point!! + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = + !mb->get_alt() ? + canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)) : + node->get_global_transform().affine_inverse().xform(canvas_item_editor->snap_point(canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint))); - if (mb.pressed && action == ACTION_NONE) { + real_t grab_threshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); - Ref<Curve2D> curve = node->get_curve(); + if (mb->is_pressed() && action == ACTION_NONE) { - for (int i = 0; i < curve->get_point_count(); i++) { + Ref<Curve2D> curve = node->get_curve(); - bool pointunder = false; + for (int i = 0; i < curve->get_point_count(); i++) { - { - Point2 p = xform.xform(curve->get_point_pos(i)); - if (gpoint.distance_to(p) < grab_treshold) { + real_t dist_to_p = gpoint.distance_to(xform.xform(curve->get_point_pos(i))); + real_t dist_to_p_out = gpoint.distance_to(xform.xform(curve->get_point_pos(i) + curve->get_point_out(i))); + real_t dist_to_p_in = gpoint.distance_to(xform.xform(curve->get_point_pos(i) + curve->get_point_in(i))); - if (mb.button_index == BUTTON_LEFT && !mb.mod.shift && mode == MODE_EDIT) { + // Check for point movement start (for point + in/out controls). + if (mb->get_button_index() == BUTTON_LEFT) { + if (mode == MODE_EDIT && !mb->get_shift() && dist_to_p < grab_threshold) { + // Points can only be moved in edit mode. - action = ACTION_MOVING_POINT; - action_point = i; - moving_from = curve->get_point_pos(i); - moving_screen_from = gpoint; - return true; - } else if ((mb.button_index == BUTTON_RIGHT && mode == MODE_EDIT) || (mb.button_index == BUTTON_LEFT && mode == MODE_DELETE)) { - - undo_redo->create_action(TTR("Remove Point from Curve")); - undo_redo->add_do_method(curve.ptr(), "remove_point", i); - undo_redo->add_undo_method(curve.ptr(), "add_point", curve->get_point_pos(i), curve->get_point_in(i), curve->get_point_out(i), i); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - return true; - } else - pointunder = true; - } - } - - if (mb.button_index == BUTTON_LEFT && i < (curve->get_point_count() - 1)) { - Point2 p = xform.xform(curve->get_point_pos(i) + curve->get_point_out(i)); - if (gpoint.distance_to(p) < grab_treshold && (mode == MODE_EDIT || mode == MODE_EDIT_CURVE)) { + action = ACTION_MOVING_POINT; + action_point = i; + moving_from = curve->get_point_pos(i); + moving_screen_from = gpoint; + return true; + } else if (mode == MODE_EDIT || mode == MODE_EDIT_CURVE) { + // In/out controls can be moved in multiple modes. + if (dist_to_p_out < grab_threshold && i < (curve->get_point_count() - 1)) { action = ACTION_MOVING_OUT; action_point = i; moving_from = curve->get_point_out(i); moving_screen_from = gpoint; return true; - } - } - - if (mb.button_index == BUTTON_LEFT && i > 0) { - Point2 p = xform.xform(curve->get_point_pos(i) + curve->get_point_in(i)); - if (gpoint.distance_to(p) < grab_treshold && (mode == MODE_EDIT || mode == MODE_EDIT_CURVE)) { + } else if (dist_to_p_in < grab_threshold && i > 0) { action = ACTION_MOVING_IN; action_point = i; @@ -141,314 +120,362 @@ bool Path2DEditor::forward_gui_input(const InputEvent &p_event) { return true; } } + } - if (pointunder) + // Check for point deletion. + if ((mb->get_button_index() == BUTTON_RIGHT && mode == MODE_EDIT) || (mb->get_button_index() == BUTTON_LEFT && mode == MODE_DELETE)) { + if (dist_to_p < grab_threshold) { + + undo_redo->create_action(TTR("Remove Point from Curve")); + undo_redo->add_do_method(curve.ptr(), "remove_point", i); + undo_redo->add_undo_method(curve.ptr(), "add_point", curve->get_point_pos(i), curve->get_point_in(i), curve->get_point_out(i), i); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } else if (dist_to_p_out < grab_threshold) { + + undo_redo->create_action(TTR("Remove Out-Control from Curve")); + undo_redo->add_do_method(curve.ptr(), "set_point_out", i, Vector2()); + undo_redo->add_undo_method(curve.ptr(), "set_point_out", i, curve->get_point_out(i)); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); return true; + } else if (dist_to_p_in < grab_threshold) { + + undo_redo->create_action(TTR("Remove In-Control from Curve")); + undo_redo->add_do_method(curve.ptr(), "set_point_in", i, Vector2()); + undo_redo->add_undo_method(curve.ptr(), "set_point_in", i, curve->get_point_in(i)); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } } } + } - // Test add point in empty space! + // Check for point creation. + if (mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT && ((mb->get_command() && mode == MODE_EDIT) || mode == MODE_CREATE)) { - if (mb.pressed && mb.button_index == BUTTON_LEFT && ((mb.mod.command && mode == MODE_EDIT) || mode == MODE_CREATE)) { + Ref<Curve2D> curve = node->get_curve(); - Ref<Curve2D> curve = node->get_curve(); + undo_redo->create_action(TTR("Add Point to Curve")); + undo_redo->add_do_method(curve.ptr(), "add_point", cpoint); + undo_redo->add_undo_method(curve.ptr(), "remove_point", curve->get_point_count()); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - undo_redo->create_action(TTR("Add Point to Curve")); - undo_redo->add_do_method(curve.ptr(), "add_point", cpoint); - undo_redo->add_undo_method(curve.ptr(), "remove_point", curve->get_point_count()); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + action = ACTION_MOVING_POINT; + action_point = curve->get_point_count() - 1; + moving_from = curve->get_point_pos(action_point); + moving_screen_from = gpoint; - action = ACTION_MOVING_POINT; - action_point = curve->get_point_count() - 1; - moving_from = curve->get_point_pos(action_point); - moving_screen_from = gpoint; + canvas_item_editor->get_viewport_control()->update(); - canvas_item_editor->get_viewport_control()->update(); + return true; + } - return true; - } + // Check for point movement completion. + if (!mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT && action != ACTION_NONE) { - if (!mb.pressed && mb.button_index == BUTTON_LEFT && action != ACTION_NONE) { + Ref<Curve2D> curve = node->get_curve(); - Ref<Curve2D> curve = node->get_curve(); + Vector2 new_pos = moving_from + xform.affine_inverse().basis_xform(gpoint - moving_screen_from); + switch (action) { - Vector2 new_pos = moving_from + xform.affine_inverse().basis_xform(gpoint - moving_screen_from); - switch (action) { + case ACTION_NONE: + // N/A, handled in above condition. + break; - case ACTION_MOVING_POINT: { + case ACTION_MOVING_POINT: { - undo_redo->create_action(TTR("Move Point in Curve")); - undo_redo->add_do_method(curve.ptr(), "set_point_pos", action_point, cpoint); - undo_redo->add_undo_method(curve.ptr(), "set_point_pos", action_point, moving_from); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + undo_redo->create_action(TTR("Move Point in Curve")); + undo_redo->add_do_method(curve.ptr(), "set_point_pos", action_point, cpoint); + undo_redo->add_undo_method(curve.ptr(), "set_point_pos", action_point, moving_from); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - } break; - case ACTION_MOVING_IN: { + } break; - undo_redo->create_action(TTR("Move In-Control in Curve")); - undo_redo->add_do_method(curve.ptr(), "set_point_in", action_point, new_pos); - undo_redo->add_undo_method(curve.ptr(), "set_point_in", action_point, moving_from); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + case ACTION_MOVING_IN: { - } break; - case ACTION_MOVING_OUT: { + undo_redo->create_action(TTR("Move In-Control in Curve")); + undo_redo->add_do_method(curve.ptr(), "set_point_in", action_point, new_pos); + undo_redo->add_undo_method(curve.ptr(), "set_point_in", action_point, moving_from); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - undo_redo->create_action(TTR("Move Out-Control in Curve")); - undo_redo->add_do_method(curve.ptr(), "set_point_out", action_point, new_pos); - undo_redo->add_undo_method(curve.ptr(), "set_point_out", action_point, moving_from); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + } break; - } break; - } + case ACTION_MOVING_OUT: { - action = ACTION_NONE; + undo_redo->create_action(TTR("Move Out-Control in Curve")); + undo_redo->add_do_method(curve.ptr(), "set_point_out", action_point, new_pos); + undo_redo->add_undo_method(curve.ptr(), "set_point_out", action_point, moving_from); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); - return true; + } break; } + action = ACTION_NONE; + + return true; + } + #if 0 - switch(mode) { + switch(mode) { - case MODE_CREATE: { + case MODE_CREATE: { - if (mb.button_index==BUTTON_LEFT && mb.pressed) { + if (mb->get_button_index()==BUTTON_LEFT && mb->is_pressed()) { - if (!wip_active) { + if (!wip_active) { - wip.clear(); - wip.push_back( canvas_item_editor->snap_point(cpoint) ); - wip_active=true; - edited_point_pos=canvas_item_editor->snap_point(cpoint); - canvas_item_editor->update(); - edited_point=1; - return true; - } else { + wip.clear(); + wip.push_back( canvas_item_editor->snap_point(cpoint) ); + wip_active=true; + edited_point_pos=canvas_item_editor->snap_point(cpoint); + canvas_item_editor->update(); + edited_point=1; + return true; + } else { + if (wip.size()>1 && xform.xform(wip[0]).distance_to(gpoint)<grab_treshold) { + //wip closed + _wip_close(); - if (wip.size()>1 && xform.xform(wip[0]).distance_to(gpoint)<grab_treshold) { - //wip closed - _wip_close(); - return true; - } else { + return true; + } else { - wip.push_back( canvas_item_editor->snap_point(cpoint) ); - edited_point=wip.size(); - canvas_item_editor->update(); - return true; + wip.push_back( canvas_item_editor->snap_point(cpoint) ); + edited_point=wip.size(); + canvas_item_editor->update(); + return true; - //add wip point - } + //add wip point } - } else if (mb.button_index==BUTTON_RIGHT && mb.pressed && wip_active) { - _wip_close(); } + } else if (mb->get_button_index()==BUTTON_RIGHT && mb->is_pressed() && wip_active) { + _wip_close(); + } + } break; + case MODE_EDIT: { - } break; - - case MODE_EDIT: { - - if (mb.button_index==BUTTON_LEFT) { - if (mb.pressed) { - - if (mb.mod.control) { + if (mb->get_button_index()==BUTTON_LEFT) { + if (mb->is_pressed()) { + if (mb->get_control()) { - if (poly.size() < 3) { - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_undo_method(node,"set_polygon",poly); - poly.push_back(cpoint); - undo_redo->add_do_method(node,"set_polygon",poly); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->commit_action(); - return true; - } + if (poly.size() < 3) { - //search edges - int closest_idx=-1; - Vector2 closest_pos; - real_t closest_dist=1e10; - for(int i=0;i<poly.size();i++) { - - Vector2 points[2] ={ xform.xform(poly[i]), - xform.xform(poly[(i+1)%poly.size()]) }; + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_undo_method(node,"set_polygon",poly); + poly.push_back(cpoint); + undo_redo->add_do_method(node,"set_polygon",poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->commit_action(); + return true; + } - Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint,points); - if (cp.distance_squared_to(points[0])<CMP_EPSILON2 || cp.distance_squared_to(points[1])<CMP_EPSILON2) - continue; //not valid to reuse point + //search edges + int closest_idx=-1; + Vector2 closest_pos; + real_t closest_dist=1e10; + for(int i=0;i<poly.size();i++) { - real_t d = cp.distance_to(gpoint); - if (d<closest_dist && d<grab_treshold) { + if (d<closest_dist && d<grab_threshold) { closest_dist=d; closest_pos=cp; closest_idx=i; } + Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint,points); + if (cp.distance_squared_to(points[0])<CMP_EPSILON2 || cp.distance_squared_to(points[1])<CMP_EPSILON2) + continue; //not valid to reuse point + real_t d = cp.distance_to(gpoint); + if (d<closest_dist && d<grab_treshold) { + closest_dist=d; + closest_pos=cp; + closest_idx=i; } - if (closest_idx>=0) { - - pre_move_edit=poly; - poly.insert(closest_idx+1,canvas_item_editor->snap_point(xform.affine_inverse().xform(closest_pos))); - edited_point=closest_idx+1; - edited_point_pos=canvas_item_editor->snap_point(xform.affine_inverse().xform(closest_pos)); - node->set_polygon(poly); - canvas_item_editor->update(); - return true; - } - } else { - //look for points to move + } - int closest_idx=-1; - Vector2 closest_pos; - real_t closest_dist=1e10; - for(int i=0;i<poly.size();i++) { + if (closest_idx>=0) { - Vector2 cp =xform.xform(poly[i]); + pre_move_edit=poly; + poly.insert(closest_idx+1,canvas_item_editor->snap_point(xform.affine_inverse().xform(closest_pos))); + edited_point=closest_idx+1; + edited_point_pos=canvas_item_editor->snap_point(xform.affine_inverse().xform(closest_pos)); + node->set_polygon(poly); + canvas_item_editor->update(); + return true; + } + } else { real_t d = cp.distance_to(gpoint); - if (d<closest_dist && d<grab_treshold) { + if (d<closest_dist && d<grab_threshold) { closest_dist=d; closest_pos=cp; closest_idx=i; } - } + int closest_idx=-1; + Vector2 closest_pos; + real_t closest_dist=1e10; + for(int i=0;i<poly.size();i++) { - if (closest_idx>=0) { + Vector2 cp =xform.xform(poly[i]); - pre_move_edit=poly; - edited_point=closest_idx; - edited_point_pos=xform.affine_inverse().xform(closest_pos); - canvas_item_editor->update(); - return true; + real_t d = cp.distance_to(gpoint); + if (d<closest_dist && d<grab_treshold) { + closest_dist=d; + closest_pos=cp; + closest_idx=i; } - } - } else { - if (edited_point!=-1) { + } - //apply + if (closest_idx>=0) { - ERR_FAIL_INDEX_V(edited_point,poly.size(),false); - poly[edited_point]=edited_point_pos; - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_do_method(node,"set_polygon",poly); - undo_redo->add_undo_method(node,"set_polygon",pre_move_edit); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->commit_action(); - - edited_point=-1; + pre_move_edit=poly; + edited_point=closest_idx; + edited_point_pos=xform.affine_inverse().xform(closest_pos); + canvas_item_editor->update(); return true; } } - } if (mb.button_index==BUTTON_RIGHT && mb.pressed && edited_point==-1) { + } else { + if (edited_point!=-1) { + //apply - int closest_idx=-1; - Vector2 closest_pos; - real_t closest_dist=1e10; - for(int i=0;i<poly.size();i++) { + ERR_FAIL_INDEX_V(edited_point,poly.size(),false); + poly[edited_point]=edited_point_pos; + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_do_method(node,"set_polygon",poly); + undo_redo->add_undo_method(node,"set_polygon",pre_move_edit); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->commit_action(); - Vector2 cp =xform.xform(poly[i]); + edited_point=-1; + return true; + } + } + } if (mb->get_button_index()==BUTTON_RIGHT && mb->is_pressed() && edited_point==-1) { real_t d = cp.distance_to(gpoint); - if (d<closest_dist && d<grab_treshold) { + if (d<closest_dist && d<grab_threshold) { closest_dist=d; closest_pos=cp; closest_idx=i; } - } - - if (closest_idx>=0) { + int closest_idx=-1; + Vector2 closest_pos; + real_t closest_dist=1e10; + for(int i=0;i<poly.size();i++) { + Vector2 cp =xform.xform(poly[i]); - undo_redo->create_action(TTR("Edit Poly (Remove Point)")); - undo_redo->add_undo_method(node,"set_polygon",poly); - poly.remove(closest_idx); - undo_redo->add_do_method(node,"set_polygon",poly); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); - undo_redo->commit_action(); - return true; + real_t d = cp.distance_to(gpoint); + if (d<closest_dist && d<grab_treshold) { + closest_dist=d; + closest_pos=cp; + closest_idx=i; } } + if (closest_idx>=0) { - } break; - } - -#endif - } break; - case InputEvent::MOUSE_MOTION: { - - const InputEventMouseMotion &mm = p_event.mouse_motion; + undo_redo->create_action(TTR("Edit Poly (Remove Point)")); + undo_redo->add_undo_method(node,"set_polygon",poly); + poly.remove(closest_idx); + undo_redo->add_do_method(node,"set_polygon",poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(),"update"); + undo_redo->commit_action(); + return true; + } - if (action != ACTION_NONE) { + } - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - Vector2 gpoint = Point2(mm.x, mm.y); - Vector2 cpoint = !mm.mod.alt ? canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)) : node->get_global_transform().affine_inverse().xform(canvas_item_editor->snap_point(canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint))); + } break; + } +#endif + } - Ref<Curve2D> curve = node->get_curve(); + Ref<InputEventMouseMotion> mm = p_event; - Vector2 new_pos = moving_from + xform.affine_inverse().basis_xform(gpoint - moving_screen_from); + if (mm.is_valid()) { - switch (action) { + if (action != ACTION_NONE) { + // Handle point/control movement. + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Vector2 gpoint = mm->get_position(); + Vector2 cpoint = + !mm->get_alt() ? + canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)) : + node->get_global_transform().affine_inverse().xform(canvas_item_editor->snap_point(canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint))); - case ACTION_MOVING_POINT: { + Ref<Curve2D> curve = node->get_curve(); - curve->set_point_pos(action_point, cpoint); - } break; - case ACTION_MOVING_IN: { + Vector2 new_pos = moving_from + xform.affine_inverse().basis_xform(gpoint - moving_screen_from); - curve->set_point_in(action_point, new_pos); + switch (action) { - } break; - case ACTION_MOVING_OUT: { + case ACTION_NONE: + // N/A, handled in above condition. + break; - curve->set_point_out(action_point, new_pos); + case ACTION_MOVING_POINT: { + curve->set_point_pos(action_point, cpoint); + } break; - } break; - } + case ACTION_MOVING_IN: { + curve->set_point_in(action_point, new_pos); + } break; - canvas_item_editor->get_viewport_control()->update(); - return true; + case ACTION_MOVING_OUT: { + curve->set_point_out(action_point, new_pos); + } break; } + canvas_item_editor->get_viewport_control()->update(); + return true; + } + #if 0 - if (edited_point!=-1 && (wip_active || mm.button_mask&BUTTON_MASK_LEFT)) { + if (edited_point!=-1 && (wip_active || mm->get_button_mask()&BUTTON_MASK_LEFT)) { - Matrix32 xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Matrix32 xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - Vector2 gpoint = Point2(mm.x,mm.y); - edited_point_pos = canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)); - canvas_item_editor->update(); + Vector2 gpoint = Point2(mm.x,mm.y); + edited_point_pos = canvas_item_editor->snap_point(xform.affine_inverse().xform(gpoint)); + canvas_item_editor->update(); - } + } #endif - } break; } return false; diff --git a/editor/plugins/path_2d_editor_plugin.h b/editor/plugins/path_2d_editor_plugin.h index 67c6f3c8cb..70911444ad 100644 --- a/editor/plugins/path_2d_editor_plugin.h +++ b/editor/plugins/path_2d_editor_plugin.h @@ -95,7 +95,7 @@ protected: static void _bind_methods(); public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_path2d); Path2DEditor(EditorNode *p_editor); }; @@ -108,7 +108,7 @@ class Path2DEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return path2d_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return path2d_editor->forward_gui_input(p_event); } virtual String get_name() const { return "Path2D"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/path_editor_plugin.cpp b/editor/plugins/path_editor_plugin.cpp index 9c95cee388..877707d77b 100644 --- a/editor/plugins/path_editor_plugin.cpp +++ b/editor/plugins/path_editor_plugin.cpp @@ -33,61 +33,57 @@ #include "scene/resources/curve.h" #include "spatial_editor_plugin.h" -#if 0 String PathSpatialGizmo::get_handle_name(int p_idx) const { Ref<Curve3D> c = path->get_curve(); if (c.is_null()) return ""; - if (p_idx<c->get_point_count()) { + if (p_idx < c->get_point_count()) { - return TTR("Curve Point #")+itos(p_idx); + return TTR("Curve Point #") + itos(p_idx); } - p_idx=p_idx-c->get_point_count()+1; + p_idx = p_idx - c->get_point_count() + 1; - int idx=p_idx/2; - int t=p_idx%2; - String n = TTR("Curve Point #")+itos(idx); - if (t==0) - n+=" In"; + int idx = p_idx / 2; + int t = p_idx % 2; + String n = TTR("Curve Point #") + itos(idx); + if (t == 0) + n += " In"; else - n+=" Out"; + n += " Out"; return n; - - } -Variant PathSpatialGizmo::get_handle_value(int p_idx) const{ +Variant PathSpatialGizmo::get_handle_value(int p_idx) const { Ref<Curve3D> c = path->get_curve(); if (c.is_null()) return Variant(); - if (p_idx<c->get_point_count()) { + if (p_idx < c->get_point_count()) { - original=c->get_point_pos(p_idx); + original = c->get_point_pos(p_idx); return original; } - p_idx=p_idx-c->get_point_count()+1; + p_idx = p_idx - c->get_point_count() + 1; - int idx=p_idx/2; - int t=p_idx%2; + int idx = p_idx / 2; + int t = p_idx % 2; Vector3 ofs; - if (t==0) - ofs=c->get_point_in(idx); + if (t == 0) + ofs = c->get_point_in(idx); else - ofs= c->get_point_out(idx); + ofs = c->get_point_out(idx); - original=ofs+c->get_point_pos(idx); + original = ofs + c->get_point_pos(idx); return ofs; - } -void PathSpatialGizmo::set_handle(int p_idx,Camera *p_camera, const Point2& p_point){ +void PathSpatialGizmo::set_handle(int p_idx, Camera *p_camera, const Point2 &p_point) { Ref<Curve3D> c = path->get_curve(); if (c.is_null()) @@ -98,51 +94,49 @@ void PathSpatialGizmo::set_handle(int p_idx,Camera *p_camera, const Point2& p_po Vector3 ray_from = p_camera->project_ray_origin(p_point); Vector3 ray_dir = p_camera->project_ray_normal(p_point); - if (p_idx<c->get_point_count()) { + if (p_idx < c->get_point_count()) { - Plane p(gt.xform(original),p_camera->get_transform().basis.get_axis(2)); + Plane p(gt.xform(original), p_camera->get_transform().basis.get_axis(2)); Vector3 inters; - if (p.intersects_ray(ray_from,ray_dir,&inters)) { + if (p.intersects_ray(ray_from, ray_dir, &inters)) { - if(SpatialEditor::get_singleton()->is_snap_enabled()) - { + if (SpatialEditor::get_singleton()->is_snap_enabled()) { float snap = SpatialEditor::get_singleton()->get_translate_snap(); inters.snap(snap); } - + Vector3 local = gi.xform(inters); - c->set_point_pos(p_idx,local); + c->set_point_pos(p_idx, local); } return; } - p_idx=p_idx-c->get_point_count()+1; + p_idx = p_idx - c->get_point_count() + 1; - int idx=p_idx/2; - int t=p_idx%2; + int idx = p_idx / 2; + int t = p_idx % 2; Vector3 base = c->get_point_pos(idx); - Plane p(gt.xform(original),p_camera->get_transform().basis.get_axis(2)); + Plane p(gt.xform(original), p_camera->get_transform().basis.get_axis(2)); Vector3 inters; - if (p.intersects_ray(ray_from,ray_dir,&inters)) { + if (p.intersects_ray(ray_from, ray_dir, &inters)) { - Vector3 local = gi.xform(inters)-base; - if (t==0) { - c->set_point_in(idx,local); + Vector3 local = gi.xform(inters) - base; + if (t == 0) { + c->set_point_in(idx, local); } else { - c->set_point_out(idx,local); + c->set_point_out(idx, local); } } - } -void PathSpatialGizmo::commit_handle(int p_idx,const Variant& p_restore,bool p_cancel){ +void PathSpatialGizmo::commit_handle(int p_idx, const Variant &p_restore, bool p_cancel) { Ref<Curve3D> c = path->get_curve(); if (c.is_null()) @@ -150,67 +144,59 @@ void PathSpatialGizmo::commit_handle(int p_idx,const Variant& p_restore,bool p_c UndoRedo *ur = SpatialEditor::get_singleton()->get_undo_redo(); - if (p_idx<c->get_point_count()) { + if (p_idx < c->get_point_count()) { if (p_cancel) { - c->set_point_pos(p_idx,p_restore); + c->set_point_pos(p_idx, p_restore); return; } ur->create_action(TTR("Set Curve Point Pos")); - ur->add_do_method(c.ptr(),"set_point_pos",p_idx,c->get_point_pos(p_idx)); - ur->add_undo_method(c.ptr(),"set_point_pos",p_idx,p_restore); + ur->add_do_method(c.ptr(), "set_point_pos", p_idx, c->get_point_pos(p_idx)); + ur->add_undo_method(c.ptr(), "set_point_pos", p_idx, p_restore); ur->commit_action(); return; } - p_idx=p_idx-c->get_point_count()+1; + p_idx = p_idx - c->get_point_count() + 1; - int idx=p_idx/2; - int t=p_idx%2; + int idx = p_idx / 2; + int t = p_idx % 2; Vector3 ofs; if (p_cancel) { - - return; } - - - if (t==0) { + if (t == 0) { if (p_cancel) { - c->set_point_in(p_idx,p_restore); + c->set_point_in(p_idx, p_restore); return; } ur->create_action(TTR("Set Curve In Pos")); - ur->add_do_method(c.ptr(),"set_point_in",idx,c->get_point_in(idx)); - ur->add_undo_method(c.ptr(),"set_point_in",idx,p_restore); + ur->add_do_method(c.ptr(), "set_point_in", idx, c->get_point_in(idx)); + ur->add_undo_method(c.ptr(), "set_point_in", idx, p_restore); ur->commit_action(); - } else { if (p_cancel) { - c->set_point_out(idx,p_restore); + c->set_point_out(idx, p_restore); return; } ur->create_action(TTR("Set Curve Out Pos")); - ur->add_do_method(c.ptr(),"set_point_out",idx,c->get_point_out(idx)); - ur->add_undo_method(c.ptr(),"set_point_out",idx,p_restore); + ur->add_do_method(c.ptr(), "set_point_out", idx, c->get_point_out(idx)); + ur->add_undo_method(c.ptr(), "set_point_out", idx, p_restore); ur->commit_action(); - } - } - -void PathSpatialGizmo::redraw(){ +void PathSpatialGizmo::redraw() { clear(); @@ -218,80 +204,76 @@ void PathSpatialGizmo::redraw(){ if (c.is_null()) return; - Vector3Array v3a=c->tesselate(); - //Vector3Array v3a=c->get_baked_points(); + PoolVector<Vector3> v3a = c->tesselate(); + //PoolVector<Vector3> v3a=c->get_baked_points(); int v3s = v3a.size(); - if (v3s==0) + if (v3s == 0) return; Vector<Vector3> v3p; - Vector3Array::Read r = v3a.read(); + PoolVector<Vector3>::Read r = v3a.read(); - for(int i=0;i<v3s-1;i++) { + // BUG: the following won't work when v3s, avoid drawing as a temporary workaround. + for (int i = 0; i < v3s - 1; i++) { v3p.push_back(r[i]); - v3p.push_back(r[i+1]); + v3p.push_back(r[i + 1]); //v3p.push_back(r[i]); //v3p.push_back(r[i]+Vector3(0,0.2,0)); } - add_lines(v3p,PathEditorPlugin::singleton->path_material); + add_lines(v3p, PathEditorPlugin::singleton->path_material); add_collision_segments(v3p); - if (PathEditorPlugin::singleton->get_edited_path()==path) { + if (PathEditorPlugin::singleton->get_edited_path() == path) { v3p.clear(); Vector<Vector3> handles; Vector<Vector3> sec_handles; - for(int i=0;i<c->get_point_count();i++) { + for (int i = 0; i < c->get_point_count(); i++) { Vector3 p = c->get_point_pos(i); handles.push_back(p); - if (i>0) { + if (i > 0) { v3p.push_back(p); - v3p.push_back(p+c->get_point_in(i)); - sec_handles.push_back(p+c->get_point_in(i)); + v3p.push_back(p + c->get_point_in(i)); + sec_handles.push_back(p + c->get_point_in(i)); } - if (i<c->get_point_count()-1) { + if (i < c->get_point_count() - 1) { v3p.push_back(p); - v3p.push_back(p+c->get_point_out(i)); - sec_handles.push_back(p+c->get_point_out(i)); + v3p.push_back(p + c->get_point_out(i)); + sec_handles.push_back(p + c->get_point_out(i)); } } - add_lines(v3p,PathEditorPlugin::singleton->path_thin_material); + add_lines(v3p, PathEditorPlugin::singleton->path_thin_material); add_handles(handles); - add_handles(sec_handles,false,true); + add_handles(sec_handles, false, true); } - } -PathSpatialGizmo::PathSpatialGizmo(Path* p_path){ +PathSpatialGizmo::PathSpatialGizmo(Path *p_path) { - path=p_path; + path = p_path; set_spatial_node(p_path); - - - } -Ref<SpatialEditorGizmo> PathEditorPlugin::create_spatial_gizmo(Spatial* p_spatial) { - +Ref<SpatialEditorGizmo> PathEditorPlugin::create_spatial_gizmo(Spatial *p_spatial) { if (p_spatial->cast_to<Path>()) { - return memnew( PathSpatialGizmo(p_spatial->cast_to<Path>())); + return memnew(PathSpatialGizmo(p_spatial->cast_to<Path>())); } return Ref<SpatialEditorGizmo>(); } -bool PathEditorPlugin::forward_spatial_gui_input(Camera* p_camera,const InputEvent& p_event) { +bool PathEditorPlugin::forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event) { if (!path) return false; - Ref<Curve3D> c=path->get_curve(); + Ref<Curve3D> c = path->get_curve(); if (c.is_null()) return false; Transform gt = path->get_global_transform(); @@ -299,105 +281,99 @@ bool PathEditorPlugin::forward_spatial_gui_input(Camera* p_camera,const InputEve static const int click_dist = 10; //should make global + Ref<InputEventMouseButton> mb = p_event; - if (p_event.type==InputEvent::MOUSE_BUTTON) { + if (mb.is_valid()) { - const InputEventMouseButton &mb=p_event.mouse_button; - Point2 mbpos(mb.x,mb.y); + Point2 mbpos(mb->get_position().x, mb->get_position().y); - if (mb.pressed && mb.button_index==BUTTON_LEFT && (curve_create->is_pressed() || (curve_edit->is_pressed() && mb.mod.control))) { + if (mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT && (curve_create->is_pressed() || (curve_edit->is_pressed() && mb->get_control()))) { //click into curve, break it down - Vector3Array v3a = c->tesselate(); - int idx=0; - int rc=v3a.size(); - int closest_seg=-1; + PoolVector<Vector3> v3a = c->tesselate(); + int idx = 0; + int rc = v3a.size(); + int closest_seg = -1; Vector3 closest_seg_point; - float closest_d=1e20; + float closest_d = 1e20; - if (rc>=2) { - Vector3Array::Read r = v3a.read(); + if (rc >= 2) { + PoolVector<Vector3>::Read r = v3a.read(); - if (p_camera->unproject_position(gt.xform(c->get_point_pos(0))).distance_to(mbpos)<click_dist) + if (p_camera->unproject_position(gt.xform(c->get_point_pos(0))).distance_to(mbpos) < click_dist) return false; //nope, existing - - for(int i=0;i<c->get_point_count()-1;i++) { + for (int i = 0; i < c->get_point_count() - 1; i++) { //find the offset and point index of the place to break up - int j=idx; - if (p_camera->unproject_position(gt.xform(c->get_point_pos(i+1))).distance_to(mbpos)<click_dist) + int j = idx; + if (p_camera->unproject_position(gt.xform(c->get_point_pos(i + 1))).distance_to(mbpos) < click_dist) return false; //nope, existing + while (j < rc && c->get_point_pos(i + 1) != r[j]) { - while(j<rc && c->get_point_pos(i+1)!=r[j]) { - - Vector3 from =r[j]; - Vector3 to =r[j+1]; + Vector3 from = r[j]; + Vector3 to = r[j + 1]; real_t cdist = from.distance_to(to); - from=gt.xform(from); - to=gt.xform(to); - if (cdist>0) { + from = gt.xform(from); + to = gt.xform(to); + if (cdist > 0) { Vector2 s[2]; s[0] = p_camera->unproject_position(from); s[1] = p_camera->unproject_position(to); - Vector2 inters = Geometry::get_closest_point_to_segment_2d(mbpos,s); + Vector2 inters = Geometry::get_closest_point_to_segment_2d(mbpos, s); float d = inters.distance_to(mbpos); - if (d<10 && d<closest_d) { + if (d < 10 && d < closest_d) { + closest_d = d; + closest_seg = i; + Vector3 ray_from = p_camera->project_ray_origin(mbpos); + Vector3 ray_dir = p_camera->project_ray_normal(mbpos); - closest_d=d; - closest_seg=i; - Vector3 ray_from=p_camera->project_ray_origin(mbpos); - Vector3 ray_dir=p_camera->project_ray_normal(mbpos); + Vector3 ra, rb; + Geometry::get_closest_points_between_segments(ray_from, ray_from + ray_dir * 4096, from, to, ra, rb); - Vector3 ra,rb; - Geometry::get_closest_points_between_segments(ray_from,ray_from+ray_dir*4096,from,to,ra,rb); - - closest_seg_point=it.xform(rb); + closest_seg_point = it.xform(rb); } - } j++; - } - if (idx==j) + if (idx == j) idx++; //force next else - idx=j; //swap + idx = j; //swap - - if (j==rc) + if (j == rc) break; } } UndoRedo *ur = editor->get_undo_redo(); - if (closest_seg!=-1) { + if (closest_seg != -1) { //subdivide ur->create_action(TTR("Split Path")); - ur->add_do_method(c.ptr(),"add_point",closest_seg_point,Vector3(),Vector3(),closest_seg+1); - ur->add_undo_method(c.ptr(),"remove_point",closest_seg+1); + ur->add_do_method(c.ptr(), "add_point", closest_seg_point, Vector3(), Vector3(), closest_seg + 1); + ur->add_undo_method(c.ptr(), "remove_point", closest_seg + 1); ur->commit_action(); return true; } else { Vector3 org; - if (c->get_point_count()==0) - org=path->get_transform().get_origin(); + if (c->get_point_count() == 0) + org = path->get_transform().get_origin(); else - org=gt.xform(c->get_point_pos(c->get_point_count())); - Plane p(org,p_camera->get_transform().basis.get_axis(2)); - Vector3 ray_from=p_camera->project_ray_origin(mbpos); - Vector3 ray_dir=p_camera->project_ray_normal(mbpos); + org = gt.xform(c->get_point_pos(c->get_point_count() - 1)); + Plane p(org, p_camera->get_transform().basis.get_axis(2)); + Vector3 ray_from = p_camera->project_ray_origin(mbpos); + Vector3 ray_dir = p_camera->project_ray_normal(mbpos); Vector3 inters; - if (p.intersects_ray(ray_from,ray_dir,&inters)) { + if (p.intersects_ray(ray_from, ray_dir, &inters)) { ur->create_action(TTR("Add Point to Curve")); - ur->add_do_method(c.ptr(),"add_point",it.xform(inters),Vector3(),Vector3(),-1); - ur->add_undo_method(c.ptr(),"remove_point",c->get_point_count()); + ur->add_do_method(c.ptr(), "add_point", it.xform(inters), Vector3(), Vector3(), -1); + ur->add_undo_method(c.ptr(), "remove_point", c->get_point_count()); ur->commit_action(); return true; } @@ -405,39 +381,51 @@ bool PathEditorPlugin::forward_spatial_gui_input(Camera* p_camera,const InputEve //add new at pos } - } else if (mb.pressed && ((mb.button_index==BUTTON_LEFT && curve_del->is_pressed()) || (mb.button_index==BUTTON_RIGHT && curve_edit->is_pressed()))) { + } else if (mb->is_pressed() && ((mb->get_button_index() == BUTTON_LEFT && curve_del->is_pressed()) || (mb->get_button_index() == BUTTON_RIGHT && curve_edit->is_pressed()))) { - int erase_idx=-1; - for(int i=0;i<c->get_point_count();i++) { - //find the offset and point index of the place to break up - if (p_camera->unproject_position(gt.xform(c->get_point_pos(i))).distance_to(mbpos)<click_dist) { + for (int i = 0; i < c->get_point_count(); i++) { + real_t dist_to_p = p_camera->unproject_position(gt.xform(c->get_point_pos(i))).distance_to(mbpos); + real_t dist_to_p_out = p_camera->unproject_position(gt.xform(c->get_point_pos(i) + c->get_point_out(i))).distance_to(mbpos); + real_t dist_to_p_in = p_camera->unproject_position(gt.xform(c->get_point_pos(i) + c->get_point_in(i))).distance_to(mbpos); - erase_idx=i; - break; - } - } + // Find the offset and point index of the place to break up. + // Also check for the control points. + if (dist_to_p < click_dist) { - if (erase_idx!=-1) { + UndoRedo *ur = editor->get_undo_redo(); + ur->create_action(TTR("Remove Path Point")); + ur->add_do_method(c.ptr(), "remove_point", i); + ur->add_undo_method(c.ptr(), "add_point", c->get_point_pos(i), c->get_point_in(i), c->get_point_out(i), i); + ur->commit_action(); + return true; + } else if (dist_to_p_out < click_dist) { - UndoRedo *ur = editor->get_undo_redo(); - ur->create_action(TTR("Remove Path Point")); - ur->add_do_method(c.ptr(),"remove_point",erase_idx); - ur->add_undo_method(c.ptr(),"add_point",c->get_point_pos(erase_idx),c->get_point_in(erase_idx),c->get_point_out(erase_idx),erase_idx); - ur->commit_action(); - return true; + UndoRedo *ur = editor->get_undo_redo(); + ur->create_action(TTR("Remove Out-Control Point")); + ur->add_do_method(c.ptr(), "set_point_out", i, Vector3()); + ur->add_undo_method(c.ptr(), "set_point_out", i, c->get_point_out(i)); + ur->commit_action(); + return true; + } else if (dist_to_p_in < click_dist) { + + UndoRedo *ur = editor->get_undo_redo(); + ur->create_action(TTR("Remove In-Control Point")); + ur->add_do_method(c.ptr(), "set_point_in", i, Vector3()); + ur->add_undo_method(c.ptr(), "set_point_in", i, c->get_point_in(i)); + ur->commit_action(); + return true; + } } } - } return false; } - void PathEditorPlugin::edit(Object *p_object) { if (p_object) { - path=p_object->cast_to<Path>(); + path = p_object->cast_to<Path>(); if (path) { if (path->get_curve().is_valid()) { @@ -445,8 +433,8 @@ void PathEditorPlugin::edit(Object *p_object) { } } } else { - Path *pre=path; - path=NULL; + Path *pre = path; + path = NULL; if (pre) { pre->get_curve()->emit_signal("changed"); } @@ -456,7 +444,7 @@ void PathEditorPlugin::edit(Object *p_object) { bool PathEditorPlugin::handles(Object *p_object) const { - return p_object->is_type("Path"); + return p_object->is_class("Path"); } void PathEditorPlugin::make_visible(bool p_visible) { @@ -466,120 +454,115 @@ void PathEditorPlugin::make_visible(bool p_visible) { curve_create->show(); curve_edit->show(); curve_del->show(); - curve_close->show(); - sep->show(); + curve_close->show(); + sep->show(); } else { curve_create->hide(); curve_edit->hide(); curve_del->hide(); - curve_close->hide(); - sep->hide(); + curve_close->hide(); + sep->hide(); { - Path *pre=path; - path=NULL; + Path *pre = path; + path = NULL; if (pre && pre->get_curve().is_valid()) { pre->get_curve()->emit_signal("changed"); } } } - } void PathEditorPlugin::_mode_changed(int p_idx) { - curve_create->set_pressed(p_idx==0); - curve_edit->set_pressed(p_idx==1); - curve_del->set_pressed(p_idx==2); + curve_create->set_pressed(p_idx == 0); + curve_edit->set_pressed(p_idx == 1); + curve_del->set_pressed(p_idx == 2); } void PathEditorPlugin::_close_curve() { - Ref<Curve3D> c = path->get_curve(); - if (c.is_null()) - return ; - if (c->get_point_count()<2) - return; - c->add_point(c->get_point_pos(0),c->get_point_in(0),c->get_point_out(0)); - + Ref<Curve3D> c = path->get_curve(); + if (c.is_null()) + return; + if (c->get_point_count() < 2) + return; + c->add_point(c->get_point_pos(0), c->get_point_in(0), c->get_point_out(0)); } void PathEditorPlugin::_notification(int p_what) { - if (p_what==NOTIFICATION_ENTER_TREE) { + if (p_what == NOTIFICATION_ENTER_TREE) { - curve_create->connect("pressed",this,"_mode_changed",make_binds(0)); - curve_edit->connect("pressed",this,"_mode_changed",make_binds(1)); - curve_del->connect("pressed",this,"_mode_changed",make_binds(2)); - curve_close->connect("pressed",this,"_close_curve"); - } + curve_create->connect("pressed", this, "_mode_changed", make_binds(0)); + curve_edit->connect("pressed", this, "_mode_changed", make_binds(1)); + curve_del->connect("pressed", this, "_mode_changed", make_binds(2)); + curve_close->connect("pressed", this, "_close_curve"); + } } void PathEditorPlugin::_bind_methods() { - ClassDB::bind_method(D_METHOD("_mode_changed"),&PathEditorPlugin::_mode_changed); - ClassDB::bind_method(D_METHOD("_close_curve"),&PathEditorPlugin::_close_curve); + ClassDB::bind_method(D_METHOD("_mode_changed"), &PathEditorPlugin::_mode_changed); + ClassDB::bind_method(D_METHOD("_close_curve"), &PathEditorPlugin::_close_curve); } -PathEditorPlugin* PathEditorPlugin::singleton=NULL; - +PathEditorPlugin *PathEditorPlugin::singleton = NULL; PathEditorPlugin::PathEditorPlugin(EditorNode *p_node) { - path=NULL; - editor=p_node; - singleton=this; + path = NULL; + editor = p_node; + singleton = this; - path_material = Ref<SpatialMaterial>( memnew( SpatialMaterial )); - path_material->set_parameter( SpatialMaterial::PARAM_DIFFUSE,Color(0.5,0.5,1.0,0.8) ); - path_material->set_fixed_flag(SpatialMaterial::FLAG_USE_ALPHA, true); + path_material = Ref<SpatialMaterial>(memnew(SpatialMaterial)); + path_material->set_albedo(Color(0.5, 0.5, 1.0, 0.8)); + path_material->set_feature(SpatialMaterial::FEATURE_TRANSPARENT, true); path_material->set_line_width(3); - path_material->set_flag(Material::FLAG_DOUBLE_SIDED,true); - path_material->set_flag(Material::FLAG_UNSHADED,true); + path_material->set_cull_mode(SpatialMaterial::CULL_DISABLED); + path_material->set_flag(SpatialMaterial::FLAG_UNSHADED, true); - path_thin_material = Ref<SpatialMaterial>( memnew( SpatialMaterial )); - path_thin_material->set_parameter( SpatialMaterial::PARAM_DIFFUSE,Color(0.5,0.5,1.0,0.4) ); - path_thin_material->set_fixed_flag(SpatialMaterial::FLAG_USE_ALPHA, true); + path_thin_material = Ref<SpatialMaterial>(memnew(SpatialMaterial)); + path_thin_material->set_albedo(Color(0.5, 0.5, 1.0, 0.4)); + path_thin_material->set_feature(SpatialMaterial::FEATURE_TRANSPARENT, true); path_thin_material->set_line_width(1); - path_thin_material->set_flag(Material::FLAG_DOUBLE_SIDED,true); - path_thin_material->set_flag(Material::FLAG_UNSHADED,true); + path_thin_material->set_cull_mode(SpatialMaterial::CULL_DISABLED); + path_thin_material->set_flag(SpatialMaterial::FLAG_UNSHADED, true); //SpatialEditor::get_singleton()->add_gizmo_plugin(this); - sep = memnew( VSeparator); + sep = memnew(VSeparator); sep->hide(); SpatialEditor::get_singleton()->add_control_to_menu_panel(sep); - curve_edit = memnew( ToolButton ); - curve_edit->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveEdit","EditorIcons")); + curve_edit = memnew(ToolButton); + curve_edit->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveEdit", "EditorIcons")); curve_edit->set_toggle_mode(true); curve_edit->hide(); curve_edit->set_focus_mode(Control::FOCUS_NONE); - curve_edit->set_tooltip(TTR("Select Points")+"\n"+TTR("Shift+Drag: Select Control Points")+"\n"+keycode_get_string(KEY_MASK_CMD)+TTR("Click: Add Point")+"\n"+TTR("Right Click: Delete Point")); + curve_edit->set_tooltip(TTR("Select Points") + "\n" + TTR("Shift+Drag: Select Control Points") + "\n" + keycode_get_string(KEY_MASK_CMD) + TTR("Click: Add Point") + "\n" + TTR("Right Click: Delete Point")); SpatialEditor::get_singleton()->add_control_to_menu_panel(curve_edit); - curve_create = memnew( ToolButton ); - curve_create->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveCreate","EditorIcons")); + curve_create = memnew(ToolButton); + curve_create->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveCreate", "EditorIcons")); curve_create->set_toggle_mode(true); curve_create->hide(); curve_create->set_focus_mode(Control::FOCUS_NONE); - curve_create->set_tooltip(TTR("Add Point (in empty space)")+"\n"+TTR("Split Segment (in curve)")); + curve_create->set_tooltip(TTR("Add Point (in empty space)") + "\n" + TTR("Split Segment (in curve)")); SpatialEditor::get_singleton()->add_control_to_menu_panel(curve_create); - curve_del = memnew( ToolButton ); - curve_del->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveDelete","EditorIcons")); + curve_del = memnew(ToolButton); + curve_del->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveDelete", "EditorIcons")); curve_del->set_toggle_mode(true); curve_del->hide(); curve_del->set_focus_mode(Control::FOCUS_NONE); curve_del->set_tooltip(TTR("Delete Point")); SpatialEditor::get_singleton()->add_control_to_menu_panel(curve_del); - curve_close = memnew( ToolButton ); - curve_close->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveClose","EditorIcons")); + curve_close = memnew(ToolButton); + curve_close->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("CurveClose", "EditorIcons")); curve_close->hide(); curve_close->set_focus_mode(Control::FOCUS_NONE); curve_close->set_tooltip(TTR("Close Curve")); SpatialEditor::get_singleton()->add_control_to_menu_panel(curve_close); - - curve_edit->set_pressed(true); /* collision_polygon_editor = memnew( PathEditor(p_node) ); @@ -593,13 +576,7 @@ PathEditorPlugin::PathEditorPlugin(EditorNode *p_node) { collision_polygon_editor->hide(); */ - - } - -PathEditorPlugin::~PathEditorPlugin() -{ +PathEditorPlugin::~PathEditorPlugin() { } - -#endif diff --git a/editor/plugins/path_editor_plugin.h b/editor/plugins/path_editor_plugin.h index 4dbda10263..651dcdaa78 100644 --- a/editor/plugins/path_editor_plugin.h +++ b/editor/plugins/path_editor_plugin.h @@ -32,30 +32,27 @@ #include "editor/spatial_editor_gizmos.h" #include "scene/3d/path.h" -#if 0 -class PathSpatialGizmo : public EditorSpatialGizmo { - GDCLASS(PathSpatialGizmo,EditorSpatialGizmo); +class PathSpatialGizmo : public EditorSpatialGizmo { - Path* path; + GDCLASS(PathSpatialGizmo, EditorSpatialGizmo); + + Path *path; mutable Vector3 original; public: - virtual String get_handle_name(int p_idx) const; virtual Variant get_handle_value(int p_idx) const; - virtual void set_handle(int p_idx,Camera *p_camera, const Point2& p_point); - virtual void commit_handle(int p_idx,const Variant& p_restore,bool p_cancel=false); + virtual void set_handle(int p_idx, Camera *p_camera, const Point2 &p_point); + virtual void commit_handle(int p_idx, const Variant &p_restore, bool p_cancel = false); void redraw(); - PathSpatialGizmo(Path* p_path=NULL); - + PathSpatialGizmo(Path *p_path = NULL); }; class PathEditorPlugin : public EditorPlugin { - GDCLASS( PathEditorPlugin, EditorPlugin ); - + GDCLASS(PathEditorPlugin, EditorPlugin); Separator *sep; ToolButton *curve_create; @@ -65,26 +62,25 @@ class PathEditorPlugin : public EditorPlugin { EditorNode *editor; - Path *path; void _mode_changed(int p_idx); - void _close_curve(); + void _close_curve(); + protected: void _notification(int p_what); static void _bind_methods(); public: - Path *get_edited_path() { return path; } - static PathEditorPlugin* singleton; + static PathEditorPlugin *singleton; Ref<SpatialMaterial> path_material; Ref<SpatialMaterial> path_thin_material; - virtual bool forward_spatial_gui_input(Camera* p_camera,const InputEvent& p_event); + virtual bool forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event); //virtual bool forward_gui_input(const InputEvent& p_event) { return collision_polygon_editor->forward_gui_input(p_event); } - virtual Ref<SpatialEditorGizmo> create_spatial_gizmo(Spatial* p_spatial); + virtual Ref<SpatialEditorGizmo> create_spatial_gizmo(Spatial *p_spatial); virtual String get_name() const { return "Path"; } bool has_main_screen() const { return false; } virtual void edit(Object *p_node); @@ -93,8 +89,6 @@ public: PathEditorPlugin(EditorNode *p_node); ~PathEditorPlugin(); - }; -#endif #endif // PATH_EDITOR_PLUGIN_H diff --git a/editor/plugins/polygon_2d_editor_plugin.cpp b/editor/plugins/polygon_2d_editor_plugin.cpp index e84e782580..dd13ca0e63 100644 --- a/editor/plugins/polygon_2d_editor_plugin.cpp +++ b/editor/plugins/polygon_2d_editor_plugin.cpp @@ -201,213 +201,209 @@ void Polygon2DEditor::_wip_close() { edited_point = -1; } -bool Polygon2DEditor::forward_gui_input(const InputEvent &p_event) { +bool Polygon2DEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (node == NULL) return false; - switch (p_event.type) { + Ref<InputEventMouseButton> mb = p_event; - case InputEvent::MOUSE_BUTTON: { + if (mb.is_valid()) { - const InputEventMouseButton &mb = p_event.mouse_button; + Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); - Transform2D xform = canvas_item_editor->get_canvas_transform() * node->get_global_transform(); + Vector2 gpoint = mb->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + cpoint = node->get_global_transform().affine_inverse().xform(cpoint); - Vector2 gpoint = Point2(mb.x, mb.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - cpoint = node->get_global_transform().affine_inverse().xform(cpoint); + Vector<Vector2> poly = Variant(node->get_polygon()); - Vector<Vector2> poly = Variant(node->get_polygon()); + //first check if a point is to be added (segment split) + real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); - //first check if a point is to be added (segment split) - real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8); + switch (mode) { - switch (mode) { + case MODE_CREATE: { - case MODE_CREATE: { + if (mb->get_button_index() == BUTTON_LEFT && mb->is_pressed()) { - if (mb.button_index == BUTTON_LEFT && mb.pressed) { + if (!wip_active) { - if (!wip_active) { + wip.clear(); + wip.push_back(cpoint - node->get_offset()); + wip_active = true; + edited_point_pos = cpoint; + canvas_item_editor->get_viewport_control()->update(); + edited_point = 1; + return true; + } else { + + if (wip.size() > 1 && xform.xform(wip[0] + node->get_offset()).distance_to(gpoint) < grab_treshold) { + //wip closed + _wip_close(); - wip.clear(); - wip.push_back(cpoint - node->get_offset()); - wip_active = true; - edited_point_pos = cpoint; - canvas_item_editor->get_viewport_control()->update(); - edited_point = 1; return true; } else { - if (wip.size() > 1 && xform.xform(wip[0] + node->get_offset()).distance_to(gpoint) < grab_treshold) { - //wip closed - _wip_close(); - - return true; - } else { - - wip.push_back(cpoint - node->get_offset()); - edited_point = wip.size(); - canvas_item_editor->get_viewport_control()->update(); - return true; + wip.push_back(cpoint - node->get_offset()); + edited_point = wip.size(); + canvas_item_editor->get_viewport_control()->update(); + return true; - //add wip point - } + //add wip point } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && wip_active) { - _wip_close(); } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && wip_active) { + _wip_close(); + } - } break; - - case MODE_EDIT: { - - if (mb.button_index == BUTTON_LEFT) { - if (mb.pressed) { - - if (mb.mod.control) { + } break; - if (poly.size() < 3) { + case MODE_EDIT: { - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_undo_method(node, "set_polygon", poly); - poly.push_back(cpoint); - undo_redo->add_do_method(node, "set_polygon", poly); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); - return true; - } + if (mb->get_button_index() == BUTTON_LEFT) { + if (mb->is_pressed()) { - //search edges - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { - - Vector2 points[2] = { xform.xform(poly[i] + node->get_offset()), - xform.xform(poly[(i + 1) % poly.size()] + node->get_offset()) }; - - Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); - if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) - continue; //not valid to reuse point - - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } - } + if (mb->get_control()) { - if (closest_idx >= 0) { + if (poly.size() < 3) { - pre_move_edit = poly; - poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos) - node->get_offset()); - edited_point = closest_idx + 1; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - node->set_polygon(Variant(poly)); - canvas_item_editor->get_viewport_control()->update(); - return true; - } - } else { + undo_redo->create_action(TTR("Edit Poly")); + undo_redo->add_undo_method(node, "set_polygon", poly); + poly.push_back(cpoint); + undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } - //look for points to move + //search edges + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { + Vector2 points[2] = { xform.xform(poly[i] + node->get_offset()), + xform.xform(poly[(i + 1) % poly.size()] + node->get_offset()) }; - Vector2 cp = xform.xform(poly[i] + node->get_offset()); + Vector2 cp = Geometry::get_closest_point_to_segment_2d(gpoint, points); + if (cp.distance_squared_to(points[0]) < CMP_EPSILON2 || cp.distance_squared_to(points[1]) < CMP_EPSILON2) + continue; //not valid to reuse point - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; - } + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; } + } - if (closest_idx >= 0) { + if (closest_idx >= 0) { - pre_move_edit = poly; - edited_point = closest_idx; - edited_point_pos = xform.affine_inverse().xform(closest_pos); - canvas_item_editor->get_viewport_control()->update(); - return true; - } + pre_move_edit = poly; + poly.insert(closest_idx + 1, xform.affine_inverse().xform(closest_pos) - node->get_offset()); + edited_point = closest_idx + 1; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + node->set_polygon(Variant(poly)); + canvas_item_editor->get_viewport_control()->update(); + return true; } } else { - if (edited_point != -1) { + //look for points to move - //apply + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - ERR_FAIL_INDEX_V(edited_point, poly.size(), false); - poly[edited_point] = edited_point_pos - node->get_offset(); - undo_redo->create_action(TTR("Edit Poly")); - undo_redo->add_do_method(node, "set_polygon", poly); - undo_redo->add_undo_method(node, "set_polygon", pre_move_edit); - undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); - undo_redo->commit_action(); + Vector2 cp = xform.xform(poly[i] + node->get_offset()); - edited_point = -1; - return true; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } } - } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed && edited_point == -1) { - int closest_idx = -1; - Vector2 closest_pos; - real_t closest_dist = 1e10; - for (int i = 0; i < poly.size(); i++) { + if (closest_idx >= 0) { - Vector2 cp = xform.xform(poly[i] + node->get_offset()); - - real_t d = cp.distance_to(gpoint); - if (d < closest_dist && d < grab_treshold) { - closest_dist = d; - closest_pos = cp; - closest_idx = i; + pre_move_edit = poly; + edited_point = closest_idx; + edited_point_pos = xform.affine_inverse().xform(closest_pos); + canvas_item_editor->get_viewport_control()->update(); + return true; } } + } else { + + if (edited_point != -1) { - if (closest_idx >= 0) { + //apply - undo_redo->create_action(TTR("Edit Poly (Remove Point)")); - undo_redo->add_undo_method(node, "set_polygon", poly); - poly.remove(closest_idx); + ERR_FAIL_INDEX_V(edited_point, poly.size(), false); + poly[edited_point] = edited_point_pos - node->get_offset(); + undo_redo->create_action(TTR("Edit Poly")); undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_undo_method(node, "set_polygon", pre_move_edit); undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); undo_redo->commit_action(); + + edited_point = -1; return true; } } + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed() && edited_point == -1) { - } break; - } + int closest_idx = -1; + Vector2 closest_pos; + real_t closest_dist = 1e10; + for (int i = 0; i < poly.size(); i++) { - } break; - case InputEvent::MOUSE_MOTION: { + Vector2 cp = xform.xform(poly[i] + node->get_offset()); - const InputEventMouseMotion &mm = p_event.mouse_motion; + real_t d = cp.distance_to(gpoint); + if (d < closest_dist && d < grab_treshold) { + closest_dist = d; + closest_pos = cp; + closest_idx = i; + } + } - if (edited_point != -1 && (wip_active || mm.button_mask & BUTTON_MASK_LEFT)) { + if (closest_idx >= 0) { - Vector2 gpoint = Point2(mm.x, mm.y); - Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); - cpoint = canvas_item_editor->snap_point(cpoint); - edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + undo_redo->create_action(TTR("Edit Poly (Remove Point)")); + undo_redo->add_undo_method(node, "set_polygon", poly); + poly.remove(closest_idx); + undo_redo->add_do_method(node, "set_polygon", poly); + undo_redo->add_do_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->add_undo_method(canvas_item_editor->get_viewport_control(), "update"); + undo_redo->commit_action(); + return true; + } + } - canvas_item_editor->get_viewport_control()->update(); - } + } break; + } + } - } break; + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid()) { + + if (edited_point != -1 && (wip_active || mm->get_button_mask() & BUTTON_MASK_LEFT)) { + + Vector2 gpoint = mm->get_position(); + Vector2 cpoint = canvas_item_editor->get_canvas_transform().affine_inverse().xform(gpoint); + cpoint = canvas_item_editor->snap_point(cpoint); + edited_point_pos = node->get_global_transform().affine_inverse().xform(cpoint); + + canvas_item_editor->get_viewport_control()->update(); + } } return false; @@ -455,31 +451,31 @@ void Polygon2DEditor::_uv_mode(int p_mode) { } } -void Polygon2DEditor::_uv_input(const InputEvent &p_input) { +void Polygon2DEditor::_uv_input(const Ref<InputEvent> &p_input) { Transform2D mtx; mtx.elements[2] = -uv_draw_ofs; mtx.scale_basis(Vector2(uv_draw_zoom, uv_draw_zoom)); - if (p_input.type == InputEvent::MOUSE_BUTTON) { + Ref<InputEventMouseButton> mb = p_input; - const InputEventMouseButton &mb = p_input.mouse_button; + if (mb.is_valid()) { - if (mb.button_index == BUTTON_LEFT) { + if (mb->get_button_index() == BUTTON_LEFT) { - if (mb.pressed) { + if (mb->is_pressed()) { - uv_drag_from = Vector2(mb.x, mb.y); + uv_drag_from = Vector2(mb->get_position().x, mb->get_position().y); uv_drag = true; uv_prev = node->get_uv(); uv_move_current = uv_mode; if (uv_move_current == UV_MODE_EDIT_POINT) { - if (mb.mod.shift && mb.mod.command) + if (mb->get_shift() && mb->get_command()) uv_move_current = UV_MODE_SCALE; - else if (mb.mod.shift) + else if (mb->get_shift()) uv_move_current = UV_MODE_MOVE; - else if (mb.mod.command) + else if (mb->get_command()) uv_move_current = UV_MODE_ROTATE; } @@ -489,7 +485,7 @@ void Polygon2DEditor::_uv_input(const InputEvent &p_input) { for (int i = 0; i < uv_prev.size(); i++) { Vector2 tuv = mtx.xform(uv_prev[i]); - if (tuv.distance_to(Vector2(mb.x, mb.y)) < 8) { + if (tuv.distance_to(Vector2(mb->get_position().x, mb->get_position().y)) < 8) { uv_drag_from = tuv; uv_drag_index = i; } @@ -511,7 +507,7 @@ void Polygon2DEditor::_uv_input(const InputEvent &p_input) { uv_drag = false; } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed) { + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed()) { if (uv_drag) { @@ -520,27 +516,28 @@ void Polygon2DEditor::_uv_input(const InputEvent &p_input) { uv_edit_draw->update(); } - } else if (mb.button_index == BUTTON_WHEEL_UP && mb.pressed) { + } else if (mb->get_button_index() == BUTTON_WHEEL_UP && mb->is_pressed()) { - uv_zoom->set_value(uv_zoom->get_value() / 0.9); - } else if (mb.button_index == BUTTON_WHEEL_DOWN && mb.pressed) { + uv_zoom->set_value(uv_zoom->get_value() / (1 - (0.1 * mb->get_factor()))); + } else if (mb->get_button_index() == BUTTON_WHEEL_DOWN && mb->is_pressed()) { - uv_zoom->set_value(uv_zoom->get_value() * 0.9); + uv_zoom->set_value(uv_zoom->get_value() * (1 - (0.1 * mb->get_factor()))); } + } - } else if (p_input.type == InputEvent::MOUSE_MOTION) { + Ref<InputEventMouseMotion> mm = p_input; - const InputEventMouseMotion &mm = p_input.mouse_motion; + if (mm.is_valid()) { - if (mm.button_mask & BUTTON_MASK_MIDDLE || Input::get_singleton()->is_key_pressed(KEY_SPACE)) { + if (mm->get_button_mask() & BUTTON_MASK_MIDDLE || Input::get_singleton()->is_key_pressed(KEY_SPACE)) { - Vector2 drag(mm.relative_x, mm.relative_y); + Vector2 drag(mm->get_relative().x, mm->get_relative().y); uv_hscroll->set_value(uv_hscroll->get_value() - drag.x); uv_vscroll->set_value(uv_vscroll->get_value() - drag.y); } else if (uv_drag) { - Vector2 uv_drag_to = snap_point(Vector2(mm.x, mm.y)); + Vector2 uv_drag_to = mm->get_position(); Vector2 drag = mtx.affine_inverse().xform(uv_drag_to) - mtx.affine_inverse().xform(uv_drag_from); switch (uv_move_current) { @@ -678,14 +675,14 @@ void Polygon2DEditor::_uv_draw() { rect = rect.grow(200); updating_uv_scroll = true; - uv_hscroll->set_min(rect.pos.x); - uv_hscroll->set_max(rect.pos.x + rect.size.x); + uv_hscroll->set_min(rect.position.x); + uv_hscroll->set_max(rect.position.x + rect.size.x); uv_hscroll->set_page(uv_edit_draw->get_size().x); uv_hscroll->set_value(uv_draw_ofs.x); uv_hscroll->set_step(0.001); - uv_vscroll->set_min(rect.pos.y); - uv_vscroll->set_max(rect.pos.y + rect.size.y); + uv_vscroll->set_min(rect.position.y); + uv_vscroll->set_max(rect.position.y + rect.size.y); uv_vscroll->set_page(uv_edit_draw->get_size().y); uv_vscroll->set_value(uv_draw_ofs.y); uv_vscroll->set_step(0.001); diff --git a/editor/plugins/polygon_2d_editor_plugin.h b/editor/plugins/polygon_2d_editor_plugin.h index 00926bf2d1..0901cc9082 100644 --- a/editor/plugins/polygon_2d_editor_plugin.h +++ b/editor/plugins/polygon_2d_editor_plugin.h @@ -113,7 +113,7 @@ class Polygon2DEditor : public HBoxContainer { Vector2 snap_step; void _uv_scroll_changed(float); - void _uv_input(const InputEvent &p_input); + void _uv_input(const Ref<InputEvent> &p_input); void _uv_draw(); void _uv_mode(int p_mode); void _wip_close(); @@ -135,7 +135,7 @@ protected: Vector2 snap_point(Vector2 p_target) const; public: - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_collision_polygon); Polygon2DEditor(EditorNode *p_editor); }; @@ -148,7 +148,7 @@ class Polygon2DEditorPlugin : public EditorPlugin { EditorNode *editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return collision_polygon_editor->forward_gui_input(p_event); } virtual String get_name() const { return "Polygon2D"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/resource_preloader_editor_plugin.cpp b/editor/plugins/resource_preloader_editor_plugin.cpp index 3b8d655af7..ea7a84d2f4 100644 --- a/editor/plugins/resource_preloader_editor_plugin.cpp +++ b/editor/plugins/resource_preloader_editor_plugin.cpp @@ -33,7 +33,7 @@ #include "global_config.h" #include "io/resource_loader.h" -void ResourcePreloaderEditor::_gui_input(InputEvent p_event) { +void ResourcePreloaderEditor::_gui_input(Ref<InputEvent> p_event) { } void ResourcePreloaderEditor::_notification(int p_what) { diff --git a/editor/plugins/resource_preloader_editor_plugin.h b/editor/plugins/resource_preloader_editor_plugin.h index fad3ba93f1..1f54620ba4 100644 --- a/editor/plugins/resource_preloader_editor_plugin.h +++ b/editor/plugins/resource_preloader_editor_plugin.h @@ -70,7 +70,7 @@ class ResourcePreloaderEditor : public PanelContainer { protected: void _notification(int p_what); - void _gui_input(InputEvent p_event); + void _gui_input(Ref<InputEvent> p_event); static void _bind_methods(); public: diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index 8ce0f51211..f3941d6a16 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -38,7 +38,6 @@ #include "os/file_access.h" #include "os/input.h" #include "os/keyboard.h" -#include "os/keyboard.h" #include "os/os.h" #include "scene/main/viewport.h" @@ -48,6 +47,7 @@ void ScriptEditorBase::_bind_methods() { ADD_SIGNAL(MethodInfo("name_changed")); ADD_SIGNAL(MethodInfo("request_help_search", PropertyInfo(Variant::STRING, "topic"))); + ADD_SIGNAL(MethodInfo("request_help_index")); ADD_SIGNAL(MethodInfo("request_open_script_at_line", PropertyInfo(Variant::OBJECT, "script"), PropertyInfo(Variant::INT, "line"))); ADD_SIGNAL(MethodInfo("request_save_history")); ADD_SIGNAL(MethodInfo("go_to_help", PropertyInfo(Variant::STRING, "what"))); @@ -164,14 +164,16 @@ void ScriptEditorQuickOpen::_text_changed(const String &p_newtext) { _update_search(); } -void ScriptEditorQuickOpen::_sbox_input(const InputEvent &p_ie) { +void ScriptEditorQuickOpen::_sbox_input(const Ref<InputEvent> &p_ie) { + + Ref<InputEventKey> k = p_ie; - if (p_ie.type == InputEvent::KEY && (p_ie.key.scancode == KEY_UP || - p_ie.key.scancode == KEY_DOWN || - p_ie.key.scancode == KEY_PAGEUP || - p_ie.key.scancode == KEY_PAGEDOWN)) { + if (k.is_valid() && (k->get_scancode() == KEY_UP || + k->get_scancode() == KEY_DOWN || + k->get_scancode() == KEY_PAGEUP || + k->get_scancode() == KEY_PAGEDOWN)) { - search_options->call("_gui_input", p_ie); + search_options->call("_gui_input", k); search_box->accept_event(); } } @@ -408,7 +410,83 @@ void ScriptEditor::_go_to_tab(int p_idx) { c->set_meta("__editor_pass", ++edit_pass); _update_history_arrows(); _update_script_colors(); + _update_members_overview(); _update_selected_editor_menu(); + _update_members_overview_visibility(); +} + +void ScriptEditor::_add_recent_script(String p_path) { + + if (p_path.empty()) { + return; + } + + // remove if already stored + int already_recent = previous_scripts.find(p_path); + if (already_recent >= 0) { + previous_scripts.remove(already_recent); + } + + // add to list + previous_scripts.insert(0, p_path); + + _update_recent_scripts(); +} + +void ScriptEditor::_update_recent_scripts() { + + // make sure we don't exceed max size + const int max_history = EDITOR_DEF("text_editor/files/maximum_recent_files", 20); + if (previous_scripts.size() > max_history) { + previous_scripts.resize(max_history); + } + + recent_scripts->clear(); + + recent_scripts->add_shortcut(ED_SHORTCUT("script_editor/open_recent", TTR("Open Recent"), KEY_MASK_CMD | KEY_MASK_SHIFT | KEY_T)); + recent_scripts->add_separator(); + + const int max_shown = 8; + for (int i = 0; i < previous_scripts.size() && i <= max_shown; i++) { + String path = previous_scripts.get(i); + // just show script name and last dir + recent_scripts->add_item(path.get_slice("/", path.get_slice_count("/") - 2) + "/" + path.get_file()); + } + + recent_scripts->add_separator(); + recent_scripts->add_shortcut(ED_SHORTCUT("script_editor/clear_recent", TTR("Clear Recent Files"))); +} + +void ScriptEditor::_open_recent_script(int p_idx) { + + // clear button + if (p_idx == recent_scripts->get_item_count() - 1) { + previous_scripts.clear(); + _update_recent_scripts(); + return; + } + + // take two for the open recent button + if (p_idx > 0) { + p_idx -= 2; + } + + if (p_idx < previous_scripts.size() && p_idx >= 0) { + + String path = previous_scripts.get(p_idx); + // if its not on disk its a help file or deleted + if (FileAccess::exists(path)) { + Ref<Script> script = ResourceLoader::load(path); + if (script.is_valid()) { + edit(script, true); + } + // if it's a path then its most likely a delted file not help + } else if (!path.is_resource_file()) { + _help_class_open(path); + } + previous_scripts.remove(p_idx); + _update_recent_scripts(); + } } void ScriptEditor::_close_tab(int p_idx, bool p_save) { @@ -420,12 +498,16 @@ void ScriptEditor::_close_tab(int p_idx, bool p_save) { Node *tselected = tab_container->get_child(selected); ScriptEditorBase *current = tab_container->get_child(selected)->cast_to<ScriptEditorBase>(); if (current) { + _add_recent_script(current->get_edited_script()->get_path()); if (p_save) { apply_scripts(); } if (current->get_edit_menu()) { memdelete(current->get_edit_menu()); } + } else { + EditorHelp *help = tab_container->get_child(selected)->cast_to<EditorHelp>(); + _add_recent_script(help->get_class()); } //remove from history @@ -460,6 +542,7 @@ void ScriptEditor::_close_tab(int p_idx, bool p_save) { _update_history_arrows(); _update_script_names(); + _update_members_overview_visibility(); _save_layout(); } @@ -530,6 +613,15 @@ void ScriptEditor::_resave_scripts(const String &p_str) { if (trim_trailing_whitespace_on_save) { se->trim_trailing_whitespace(); } + + if (convert_indent_on_save) { + if (use_space_indentation) { + se->convert_indent_to_spaces(); + } else { + se->convert_indent_to_tabs(); + } + } + editor->save_resource(script); se->tag_saved_version(); } @@ -795,12 +887,28 @@ void ScriptEditor::_menu_option(int p_option) { if (trim_trailing_whitespace_on_save) current->trim_trailing_whitespace(); + + if (convert_indent_on_save) { + if (use_space_indentation) { + current->convert_indent_to_spaces(); + } else { + current->convert_indent_to_tabs(); + } + } editor->save_resource(current->get_edited_script()); } break; case FILE_SAVE_AS: { current->trim_trailing_whitespace(); + + if (convert_indent_on_save) { + if (use_space_indentation) { + current->convert_indent_to_spaces(); + } else { + current->convert_indent_to_tabs(); + } + } editor->push_item(current->get_edited_script()->cast_to<Object>()); editor->save_resource_as(current->get_edited_script()); @@ -878,28 +986,29 @@ void ScriptEditor::_menu_option(int p_option) { } } } - } + } else { - EditorHelp *help = tab_container->get_current_tab_control()->cast_to<EditorHelp>(); - if (help) { + EditorHelp *help = tab_container->get_current_tab_control()->cast_to<EditorHelp>(); + if (help) { - switch (p_option) { + switch (p_option) { - case HELP_SEARCH_FIND: { - help->popup_search(); - } break; - case HELP_SEARCH_FIND_NEXT: { - help->search_again(); - } break; - case FILE_CLOSE: { - _close_current_tab(); - } break; - case CLOSE_DOCS: { - _close_docs_tab(); - } break; - case CLOSE_ALL: { - _close_all_tabs(); - } break; + case HELP_SEARCH_FIND: { + help->popup_search(); + } break; + case HELP_SEARCH_FIND_NEXT: { + help->search_again(); + } break; + case FILE_CLOSE: { + _close_current_tab(); + } break; + case CLOSE_DOCS: { + _close_docs_tab(); + } break; + case CLOSE_ALL: { + _close_all_tabs(); + } break; + } } } } @@ -919,6 +1028,7 @@ void ScriptEditor::_notification(int p_what) { editor->connect("script_add_function_request", this, "_add_callback"); editor->connect("resource_saved", this, "_res_saved_callback"); script_list->connect("item_selected", this, "_script_selected"); + members_overview->connect("item_selected", this, "_members_overview_selected"); script_split->connect("dragged", this, "_script_split_dragged"); autosave_timer->connect("timeout", this, "_autosave_scripts"); { @@ -933,7 +1043,7 @@ void ScriptEditor::_notification(int p_what) { EditorSettings::get_singleton()->connect("settings_changed", this, "_editor_settings_changed"); help_search->set_icon(get_icon("Help", "EditorIcons")); - site_search->set_icon(get_icon("Godot", "EditorIcons")); + site_search->set_icon(get_icon("Instance", "EditorIcons")); class_search->set_icon(get_icon("ClassList", "EditorIcons")); script_forward->set_icon(get_icon("Forward", "EditorIcons")); @@ -944,6 +1054,8 @@ void ScriptEditor::_notification(int p_what) { get_tree()->connect("tree_changed", this, "_tree_changed"); editor->connect("request_help", this, "_request_help"); + editor->connect("request_help_search", this, "_help_search"); + editor->connect("request_help_index", this, "_help_index"); } if (p_what == NOTIFICATION_EXIT_TREE) { @@ -1165,6 +1277,16 @@ void ScriptEditor::ensure_focus_current() { se->ensure_focus(); } +void ScriptEditor::_members_overview_selected(int p_idx) { + Node *current = tab_container->get_child(tab_container->get_current_tab()); + ScriptEditorBase *se = current->cast_to<ScriptEditorBase>(); + if (!se) { + return; + } + se->goto_line(members_overview->get_item_metadata(p_idx)); + se->ensure_focus(); +} + void ScriptEditor::_script_selected(int p_idx) { grab_focus_block = !Input::get_singleton()->is_mouse_button_pressed(1); //amazing hack, simply amazing @@ -1234,6 +1356,37 @@ struct _ScriptEditorItemData { } }; +void ScriptEditor::_update_members_overview_visibility() { + Node *current = tab_container->get_child(tab_container->get_current_tab()); + ScriptEditorBase *se = current->cast_to<ScriptEditorBase>(); + if (!se) { + members_overview->set_visible(false); + return; + } + + if (members_overview_enabled && se->show_members_overview()) { + members_overview->set_visible(true); + } else { + members_overview->set_visible(false); + } +} + +void ScriptEditor::_update_members_overview() { + members_overview->clear(); + + Node *current = tab_container->get_child(tab_container->get_current_tab()); + ScriptEditorBase *se = current->cast_to<ScriptEditorBase>(); + if (!se) { + return; + } + + Vector<String> functions = se->get_functions(); + for (int i = 0; i < functions.size(); i++) { + members_overview->add_item(functions[i].get_slice(":", 0)); + members_overview->set_item_metadata(i, functions[i].get_slice(":", 1).to_int() - 1); + } +} + void ScriptEditor::_update_script_colors() { bool script_temperature_enabled = EditorSettings::get_singleton()->get("text_editor/open_scripts/script_temperature_enabled"); @@ -1377,13 +1530,14 @@ void ScriptEditor::_update_script_names() { } } + _update_members_overview(); _update_script_colors(); } -void ScriptEditor::edit(const Ref<Script> &p_script, bool p_grab_focus) { +bool ScriptEditor::edit(const Ref<Script> &p_script, int p_line, int p_col, bool p_grab_focus) { if (p_script.is_null()) - return; + return false; // refuse to open built-in if scene is not loaded @@ -1391,22 +1545,46 @@ void ScriptEditor::edit(const Ref<Script> &p_script, bool p_grab_focus) { bool open_dominant = EditorSettings::get_singleton()->get("text_editor/files/open_dominant_script_on_scene_change"); + Error err = p_script->get_language()->open_in_external_editor(p_script, p_line >= 0 ? p_line : 0, p_col); + if (err == OK) + return false; + if (err != ERR_UNAVAILABLE) + WARN_PRINT("Couldn't open in custom external text editor"); + if (p_script->get_path().is_resource_file() && bool(EditorSettings::get_singleton()->get("text_editor/external/use_external_editor"))) { String path = EditorSettings::get_singleton()->get("text_editor/external/exec_path"); String flags = EditorSettings::get_singleton()->get("text_editor/external/exec_flags"); + + Dictionary keys; + keys["project"] = GlobalConfig::get_singleton()->get_resource_path(); + keys["file"] = GlobalConfig::get_singleton()->globalize_path(p_script->get_path()); + keys["line"] = p_line >= 0 ? p_line : 0; + keys["col"] = p_col; + + flags = flags.format(keys).strip_edges().replace("\\\\", "\\"); + List<String> args; - flags = flags.strip_edges(); - if (flags != String()) { - Vector<String> flagss = flags.split(" ", false); - for (int i = 0; i < flagss.size(); i++) - args.push_back(flagss[i]); + + if (flags.size()) { + int from = 0, to = 0; + bool inside_quotes = false; + for (int i = 0; i < flags.size(); i++) { + if (flags[i] == '"' && (!i || flags[i - 1] != '\\')) { + inside_quotes = !inside_quotes; + } else if (flags[i] == '\0' || (!inside_quotes && flags[i] == ' ')) { + args.push_back(flags.substr(from, to)); + from = i + 1; + to = 0; + } else { + to++; + } + } } - args.push_back(GlobalConfig::get_singleton()->globalize_path(p_script->get_path())); Error err = OS::get_singleton()->execute(path, args, false); if (err == OK) - return; + return false; WARN_PRINT("Couldn't open external text editor, using internal"); } @@ -1425,8 +1603,11 @@ void ScriptEditor::edit(const Ref<Script> &p_script, bool p_grab_focus) { } if (is_visible_in_tree()) se->ensure_focus(); + + if (p_line >= 0) + se->goto_line(p_line - 1); } - return; + return true; } } @@ -1439,7 +1620,7 @@ void ScriptEditor::edit(const Ref<Script> &p_script, bool p_grab_focus) { if (se) break; } - ERR_FAIL_COND(!se); + ERR_FAIL_COND_V(!se, false); tab_container->add_child(se); se->set_edited_script(p_script); @@ -1466,6 +1647,11 @@ void ScriptEditor::edit(const Ref<Script> &p_script, bool p_grab_focus) { _test_script_times_on_disk(p_script); _update_modified_scripts_for_external_editor(p_script); + + if (p_line >= 0) + se->goto_line(p_line - 1); + + return true; } void ScriptEditor::save_all_scripts() { @@ -1476,13 +1662,21 @@ void ScriptEditor::save_all_scripts() { if (!se) continue; - if (!se->is_unsaved()) - continue; + if (convert_indent_on_save) { + if (use_space_indentation) { + se->convert_indent_to_spaces(); + } else { + se->convert_indent_to_tabs(); + } + } if (trim_trailing_whitespace_on_save) { se->trim_trailing_whitespace(); } + if (!se->is_unsaved()) + continue; + Ref<Script> script = se->get_edited_script(); if (script.is_valid()) se->apply_code(); @@ -1582,6 +1776,12 @@ void ScriptEditor::_save_layout() { void ScriptEditor::_editor_settings_changed() { trim_trailing_whitespace_on_save = EditorSettings::get_singleton()->get("text_editor/files/trim_trailing_whitespace_on_save"); + convert_indent_on_save = EditorSettings::get_singleton()->get("text_editor/indent/convert_indent_on_save"); + use_space_indentation = EditorSettings::get_singleton()->get("text_editor/indent/type"); + + members_overview_enabled = EditorSettings::get_singleton()->get("text_editor/open_scripts/show_members_overview"); + _update_members_overview_visibility(); + float autosave_time = EditorSettings::get_singleton()->get("text_editor/files/autosave_interval_secs"); if (autosave_time > 0) { autosave_timer->set_wait_time(autosave_time); @@ -1630,8 +1830,8 @@ void ScriptEditor::_script_split_dragged(float) { _save_layout(); } -void ScriptEditor::_unhandled_input(const InputEvent &p_event) { - if (p_event.key.pressed || !is_visible_in_tree()) return; +void ScriptEditor::_unhandled_input(const Ref<InputEvent> &p_event) { + if (p_event->is_pressed() || !is_visible_in_tree()) return; if (ED_IS_SHORTCUT("script_editor/next_script", p_event)) { int next_tab = script_list->get_current() + 1; next_tab %= script_list->get_item_count(); @@ -1863,20 +2063,14 @@ void ScriptEditor::set_scene_root_script(Ref<Script> p_script) { } } -bool ScriptEditor::script_go_to_method(Ref<Script> p_script, const String &p_method) { +bool ScriptEditor::script_goto_method(Ref<Script> p_script, const String &p_method) { - for (int i = 0; i < tab_container->get_child_count(); i++) { - ScriptEditorBase *current = tab_container->get_child(i)->cast_to<ScriptEditorBase>(); + int line = p_script->get_member_line(p_method); - if (current && current->get_edited_script() == p_script) { - if (current->goto_method(p_method)) { - edit(p_script); - return true; - } - break; - } - } - return false; + if (line == -1) + return false; + + return edit(p_script, line, 0); } void ScriptEditor::set_live_auto_reload_running_scripts(bool p_enabled) { @@ -1884,6 +2078,10 @@ void ScriptEditor::set_live_auto_reload_running_scripts(bool p_enabled) { auto_reload_running_scripts = p_enabled; } +void ScriptEditor::_help_index(String p_text) { + help_index->popup(); +} + void ScriptEditor::_help_search(String p_text) { help_search_dialog->popup(p_text); } @@ -1914,6 +2112,7 @@ void ScriptEditor::_bind_methods() { ClassDB::bind_method("_close_discard_current_tab", &ScriptEditor::_close_discard_current_tab); ClassDB::bind_method("_close_docs_tab", &ScriptEditor::_close_docs_tab); ClassDB::bind_method("_close_all_tabs", &ScriptEditor::_close_all_tabs); + ClassDB::bind_method("_open_recent_script", &ScriptEditor::_open_recent_script); ClassDB::bind_method("_editor_play", &ScriptEditor::_editor_play); ClassDB::bind_method("_editor_pause", &ScriptEditor::_editor_pause); ClassDB::bind_method("_editor_stop", &ScriptEditor::_editor_stop); @@ -1924,6 +2123,7 @@ void ScriptEditor::_bind_methods() { ClassDB::bind_method("_goto_script_line", &ScriptEditor::_goto_script_line); ClassDB::bind_method("_goto_script_line2", &ScriptEditor::_goto_script_line2); ClassDB::bind_method("_help_search", &ScriptEditor::_help_search); + ClassDB::bind_method("_help_index", &ScriptEditor::_help_index); ClassDB::bind_method("_save_history", &ScriptEditor::_save_history); ClassDB::bind_method("_breaked", &ScriptEditor::_breaked); @@ -1933,6 +2133,7 @@ void ScriptEditor::_bind_methods() { ClassDB::bind_method("_editor_settings_changed", &ScriptEditor::_editor_settings_changed); ClassDB::bind_method("_update_script_names", &ScriptEditor::_update_script_names); ClassDB::bind_method("_tree_changed", &ScriptEditor::_tree_changed); + ClassDB::bind_method("_members_overview_selected", &ScriptEditor::_members_overview_selected); ClassDB::bind_method("_script_selected", &ScriptEditor::_script_selected); ClassDB::bind_method("_script_created", &ScriptEditor::_script_created); ClassDB::bind_method("_script_split_dragged", &ScriptEditor::_script_split_dragged); @@ -1954,6 +2155,7 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { waiting_update_names = false; pending_auto_reload = false; auto_reload_running_scripts = false; + members_overview_enabled = true; editor = p_editor; menu_hb = memnew(HBoxContainer); @@ -1963,12 +2165,22 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { add_child(script_split); script_split->set_v_size_flags(SIZE_EXPAND_FILL); + list_split = memnew(VSplitContainer); + script_split->add_child(list_split); + list_split->set_v_size_flags(SIZE_EXPAND_FILL); + script_list = memnew(ItemList); - script_split->add_child(script_list); + list_split->add_child(script_list); script_list->set_custom_minimum_size(Size2(0, 0)); script_split->set_split_offset(140); + list_split->set_split_offset(500); + + members_overview = memnew(ItemList); + list_split->add_child(members_overview); + members_overview->set_custom_minimum_size(Size2(0, 0)); tab_container = memnew(TabContainer); + tab_container->add_style_override("panel", p_editor->get_gui_base()->get_stylebox("ScriptPanel", "EditorStyles")); tab_container->set_tabs_visible(false); script_split->add_child(tab_container); @@ -1983,6 +2195,14 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { file_menu->set_text(TTR("File")); file_menu->get_popup()->add_shortcut(ED_SHORTCUT("script_editor/new", TTR("New")), FILE_NEW); file_menu->get_popup()->add_shortcut(ED_SHORTCUT("script_editor/open", TTR("Open")), FILE_OPEN); + file_menu->get_popup()->add_submenu_item(TTR("Open Recent"), "RecentScripts", FILE_OPEN_RECENT); + + recent_scripts = memnew(PopupMenu); + recent_scripts->set_name("RecentScripts"); + file_menu->get_popup()->add_child(recent_scripts); + recent_scripts->connect("id_pressed", this, "_open_recent_script"); + _update_recent_scripts(); + file_menu->get_popup()->add_separator(); file_menu->get_popup()->add_shortcut(ED_SHORTCUT("script_editor/save", TTR("Save"), KEY_MASK_ALT | KEY_MASK_CMD | KEY_S), FILE_SAVE); file_menu->get_popup()->add_shortcut(ED_SHORTCUT("script_editor/save_as", TTR("Save As..")), FILE_SAVE_AS); @@ -2057,10 +2277,10 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { menu_hb->add_spacer(); site_search = memnew(ToolButton); - site_search->set_text(TTR("Tutorials")); + site_search->set_text(TTR("Online Docs")); site_search->connect("pressed", this, "_menu_option", varray(SEARCH_WEBSITE)); menu_hb->add_child(site_search); - site_search->set_tooltip(TTR("Open https://godotengine.org at tutorials section.")); + site_search->set_tooltip(TTR("Open Godot online documentation")); class_search = memnew(ToolButton); class_search->set_text(TTR("Classes")); @@ -2160,6 +2380,8 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { edit_pass = 0; trim_trailing_whitespace_on_save = false; + convert_indent_on_save = false; + use_space_indentation = false; ScriptServer::edit_request_func = _open_script_request; } @@ -2287,6 +2509,9 @@ ScriptEditorPlugin::ScriptEditorPlugin(EditorNode *p_node) { EDITOR_DEF("text_editor/open_scripts/list_script_names_as", 0); EditorSettings::get_singleton()->add_property_hint(PropertyInfo(Variant::STRING, "text_editor/external/exec_path", PROPERTY_HINT_GLOBAL_FILE)); EDITOR_DEF("text_editor/external/exec_flags", ""); + + ED_SHORTCUT("script_editor/open_recent", TTR("Open Recent"), KEY_MASK_CMD | KEY_MASK_SHIFT | KEY_T); + ED_SHORTCUT("script_editor/clear_recent", TTR("Clear Recent Files")); } ScriptEditorPlugin::~ScriptEditorPlugin() { diff --git a/editor/plugins/script_editor_plugin.h b/editor/plugins/script_editor_plugin.h index 51d9bd3fc8..e036d1ed9c 100644 --- a/editor/plugins/script_editor_plugin.h +++ b/editor/plugins/script_editor_plugin.h @@ -54,7 +54,7 @@ class ScriptEditorQuickOpen : public ConfirmationDialog { void _update_search(); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); Vector<String> functions; void _confirmed(); @@ -91,16 +91,19 @@ public: virtual void set_edit_state(const Variant &p_state) = 0; virtual void goto_line(int p_line, bool p_with_error = false) = 0; virtual void trim_trailing_whitespace() = 0; + virtual void convert_indent_to_spaces() = 0; + virtual void convert_indent_to_tabs() = 0; virtual void ensure_focus() = 0; virtual void tag_saved_version() = 0; virtual void reload(bool p_soft) = 0; virtual void get_breakpoints(List<int> *p_breakpoints) = 0; - virtual bool goto_method(const String &p_method) = 0; virtual void add_callback(const String &p_function, PoolStringArray p_args) = 0; virtual void update_settings() = 0; virtual void set_debugger_active(bool p_active) = 0; virtual bool can_lose_focus_on_node_selection() { return true; } + virtual bool show_members_overview() = 0; + virtual void set_tooltip_request_func(String p_method, Object *p_obj) = 0; virtual Control *get_edit_menu() = 0; @@ -119,6 +122,7 @@ class ScriptEditor : public VBoxContainer { enum { FILE_NEW, FILE_OPEN, + FILE_OPEN_RECENT, FILE_SAVE, FILE_SAVE_AS, FILE_SAVE_ALL, @@ -168,6 +172,8 @@ class ScriptEditor : public VBoxContainer { Timer *autosave_timer; uint64_t idle; + PopupMenu *recent_scripts; + Button *help_search; Button *site_search; Button *class_search; @@ -175,6 +181,9 @@ class ScriptEditor : public VBoxContainer { ItemList *script_list; HSplitContainer *script_split; + ItemList *members_overview; + bool members_overview_enabled; + VSplitContainer *list_split; TabContainer *tab_container; EditorFileDialog *file_dialog; ConfirmationDialog *erase_tab_confirm; @@ -206,6 +215,8 @@ class ScriptEditor : public VBoxContainer { Vector<ScriptHistory> history; int history_pos; + Vector<String> previous_scripts; + EditorHelpIndex *help_index; void _tab_changed(int p_which); @@ -223,6 +234,10 @@ class ScriptEditor : public VBoxContainer { bool _test_script_times_on_disk(Ref<Script> p_for_script = Ref<Script>()); + void _add_recent_script(String p_path); + void _update_recent_scripts(); + void _open_recent_script(int p_idx); + void _close_tab(int p_idx, bool p_save = true); void _close_current_tab(); @@ -252,6 +267,8 @@ class ScriptEditor : public VBoxContainer { void _res_saved_callback(const Ref<Resource> &p_res); bool trim_trailing_whitespace_on_save; + bool use_space_indentation; + bool convert_indent_on_save; void _trim_trailing_whitespace(TextEdit *tx); @@ -266,8 +283,11 @@ class ScriptEditor : public VBoxContainer { void _editor_settings_changed(); void _autosave_scripts(); + void _update_members_overview_visibility(); + void _update_members_overview(); void _update_script_names(); + void _members_overview_selected(int p_idx); void _script_selected(int p_idx); void _find_scripts(Node *p_base, Node *p_current, Set<Ref<Script> > &used); @@ -276,9 +296,10 @@ class ScriptEditor : public VBoxContainer { void _script_split_dragged(float); - void _unhandled_input(const InputEvent &p_event); + void _unhandled_input(const Ref<InputEvent> &p_event); void _help_search(String p_text); + void _help_index(String p_text); void _history_forward(); void _history_back(); @@ -312,7 +333,9 @@ public: void apply_scripts() const; void ensure_select_current(); - void edit(const Ref<Script> &p_script, bool p_grab_focus = true); + + _FORCE_INLINE_ bool edit(const Ref<Script> &p_script, bool p_grab_focus = true) { return edit(p_script, -1, 0, p_grab_focus); } + bool edit(const Ref<Script> &p_script, int p_line, int p_col, bool p_grab_focus = true); Dictionary get_state() const; void set_state(const Dictionary &p_state); @@ -329,7 +352,7 @@ public: void set_scene_root_script(Ref<Script> p_script); - bool script_go_to_method(Ref<Script> p_script, const String &p_method); + bool script_goto_method(Ref<Script> p_script, const String &p_method); virtual void edited_scene_changed(); diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index f020e36247..9f76119374 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -69,26 +69,6 @@ Ref<Script> ScriptTextEditor::get_edited_script() const { return script; } -bool ScriptTextEditor::goto_method(const String &p_method) { - - Vector<String> functions = get_functions(); - - String method_search = p_method + ":"; - - for (int i = 0; i < functions.size(); i++) { - String function = functions[i]; - - if (function.begins_with(method_search)) { - - int line = function.get_slice(":", 1).to_int(); - goto_line(line - 1); - return true; - } - } - - return false; -} - void ScriptTextEditor::_load_theme_settings() { TextEdit *text_edit = code_editor->get_text_edit(); @@ -144,7 +124,6 @@ void ScriptTextEditor::_load_theme_settings() { text_edit->add_keyword_color("Transform", basetype_color); text_edit->add_keyword_color("Color", basetype_color); text_edit->add_keyword_color("Image", basetype_color); - text_edit->add_keyword_color("InputEvent", basetype_color); text_edit->add_keyword_color("Rect2", basetype_color); text_edit->add_keyword_color("NodePath", basetype_color); @@ -239,6 +218,10 @@ void ScriptTextEditor::add_callback(const String &p_function, PoolStringArray p_ code_editor->get_text_edit()->cursor_set_column(1); } +bool ScriptTextEditor::show_members_overview() { + return true; +} + void ScriptTextEditor::update_settings() { code_editor->update_editor_settings(); @@ -260,6 +243,48 @@ Variant ScriptTextEditor::get_edit_state() { return state; } +void ScriptTextEditor::_convert_case(CaseStyle p_case) { + TextEdit *te = code_editor->get_text_edit(); + Ref<Script> scr = get_edited_script(); + if (scr.is_null()) { + return; + } + + if (te->is_selection_active()) { + te->begin_complex_operation(); + + int begin = te->get_selection_from_line(); + int end = te->get_selection_to_line(); + int begin_col = te->get_selection_from_column(); + int end_col = te->get_selection_to_column(); + + for (int i = begin; i <= end; i++) { + String new_line = te->get_line(i); + + switch (p_case) { + case UPPER: { + new_line = new_line.to_upper(); + } break; + case LOWER: { + new_line = new_line.to_lower(); + } break; + case CAPITALIZE: { + new_line = new_line.capitalize(); + } break; + } + + if (i == begin) { + new_line = te->get_line(i).left(begin_col) + new_line.right(begin_col); + } + if (i == end) { + new_line = new_line.left(end_col) + te->get_line(i).right(end_col); + } + te->set_line(i, new_line); + } + te->end_complex_operation(); + } +} + void ScriptTextEditor::trim_trailing_whitespace() { TextEdit *tx = code_editor->get_text_edit(); @@ -290,13 +315,116 @@ void ScriptTextEditor::trim_trailing_whitespace() { } } +void ScriptTextEditor::convert_indent_to_spaces() { + TextEdit *tx = code_editor->get_text_edit(); + Ref<Script> scr = get_edited_script(); + + if (scr.is_null()) { + return; + } + + int indent_size = EditorSettings::get_singleton()->get("text_editor/indent/size"); + String indent = ""; + + for (int i = 0; i < indent_size; i++) { + indent += " "; + } + + int cursor_line = tx->cursor_get_line(); + int cursor_column = tx->cursor_get_column(); + + bool changed_indentation = false; + for (int i = 0; i < tx->get_line_count(); i++) { + String line = tx->get_line(i); + + if (line.length() <= 0) { + continue; + } + + int j = 0; + while (j < line.length() && (line[j] == ' ' || line[j] == '\t')) { + if (line[j] == '\t') { + if (!changed_indentation) { + tx->begin_complex_operation(); + changed_indentation = true; + } + if (cursor_line == i && cursor_column > j) { + cursor_column += indent_size - 1; + } + line = line.left(j) + indent + line.right(j + 1); + } + j++; + } + tx->set_line(i, line); + } + if (changed_indentation) { + tx->cursor_set_column(cursor_column); + tx->end_complex_operation(); + tx->update(); + } +} + +void ScriptTextEditor::convert_indent_to_tabs() { + TextEdit *tx = code_editor->get_text_edit(); + Ref<Script> scr = get_edited_script(); + + if (scr.is_null()) { + return; + } + + int indent_size = EditorSettings::get_singleton()->get("text_editor/indent/size"); + indent_size -= 1; + + int cursor_line = tx->cursor_get_line(); + int cursor_column = tx->cursor_get_column(); + + bool changed_indentation = false; + for (int i = 0; i < tx->get_line_count(); i++) { + String line = tx->get_line(i); + + if (line.length() <= 0) { + continue; + } + + int j = 0; + int space_count = -1; + while (j < line.length() && (line[j] == ' ' || line[j] == '\t')) { + if (line[j] != '\t') { + space_count++; + + if (space_count == indent_size) { + if (!changed_indentation) { + tx->begin_complex_operation(); + changed_indentation = true; + } + if (cursor_line == i && cursor_column > j) { + cursor_column -= indent_size; + } + line = line.left(j - indent_size) + "\t" + line.right(j + 1); + j = 0; + space_count = -1; + } + } else { + space_count = -1; + } + j++; + } + tx->set_line(i, line); + } + if (changed_indentation) { + tx->cursor_set_column(cursor_column); + tx->end_complex_operation(); + tx->update(); + } +} + void ScriptTextEditor::tag_saved_version() { code_editor->get_text_edit()->tag_saved_version(); } void ScriptTextEditor::goto_line(int p_line, bool p_with_error) { - code_editor->get_text_edit()->cursor_set_line(p_line); + code_editor->get_text_edit()->call_deferred("cursor_set_line", p_line); } void ScriptTextEditor::ensure_focus() { @@ -827,10 +955,24 @@ void ScriptTextEditor::_edit_option(int p_op) { case EDIT_TRIM_TRAILING_WHITESAPCE: { trim_trailing_whitespace(); } break; + case EDIT_CONVERT_INDENT_TO_SPACES: { + convert_indent_to_spaces(); + } break; + case EDIT_CONVERT_INDENT_TO_TABS: { + convert_indent_to_tabs(); + } break; case EDIT_PICK_COLOR: { color_panel->popup(); } break; - + case EDIT_TO_UPPERCASE: { + _convert_case(UPPER); + } break; + case EDIT_TO_LOWERCASE: { + _convert_case(LOWER); + } break; + case EDIT_CAPITALIZE: { + _convert_case(CAPITALIZE); + } break; case SEARCH_FIND: { code_editor->get_find_replace_bar()->popup_search(); @@ -1088,15 +1230,18 @@ void ScriptTextEditor::drop_data_fw(const Point2 &p_point, const Variant &p_data } } -void ScriptTextEditor::_text_edit_gui_input(const InputEvent &ev) { - if (ev.type == InputEvent::MOUSE_BUTTON) { - InputEventMouseButton mb = ev.mouse_button; - if (mb.button_index == BUTTON_RIGHT && !mb.pressed) { +void ScriptTextEditor::_text_edit_gui_input(const Ref<InputEvent> &ev) { + + Ref<InputEventMouseButton> mb = ev; + + if (mb.is_valid()) { + + if (mb->get_button_index() == BUTTON_RIGHT && !mb->is_pressed()) { int col, row; TextEdit *tx = code_editor->get_text_edit(); - tx->_get_mouse_pos(Point2i(mb.global_x, mb.global_y) - tx->get_global_position(), row, col); - Vector2 mpos = Vector2(mb.global_x, mb.global_y) - tx->get_global_position(); + tx->_get_mouse_pos(mb->get_global_position() - tx->get_global_position(), row, col); + Vector2 mpos = mb->get_global_position() - tx->get_global_position(); bool have_selection = (tx->get_selection_text().length() > 0); bool have_color = (tx->get_word_at_pos(mpos) == "Color"); if (have_color) { @@ -1183,6 +1328,7 @@ ScriptTextEditor::ScriptTextEditor() { code_editor = memnew(CodeTextEditor); add_child(code_editor); + code_editor->add_constant_override("separation", 0); code_editor->set_area_as_parent_rect(); code_editor->connect("validate_script", this, "_validate_script"); code_editor->connect("load_theme_settings", this, "_load_theme_settings"); @@ -1237,6 +1383,8 @@ ScriptTextEditor::ScriptTextEditor() { edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/complete_symbol"), EDIT_COMPLETE); #endif edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/trim_trailing_whitespace"), EDIT_TRIM_TRAILING_WHITESAPCE); + edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/convert_indent_to_spaces"), EDIT_CONVERT_INDENT_TO_SPACES); + edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/convert_indent_to_tabs"), EDIT_CONVERT_INDENT_TO_TABS); edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/auto_indent"), EDIT_AUTO_INDENT); edit_menu->get_popup()->connect("id_pressed", this, "_edit_option"); edit_menu->get_popup()->add_separator(); @@ -1244,6 +1392,15 @@ ScriptTextEditor::ScriptTextEditor() { edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/remove_all_breakpoints"), DEBUG_REMOVE_ALL_BREAKPOINTS); edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/goto_next_breakpoint"), DEBUG_GOTO_NEXT_BREAKPOINT); edit_menu->get_popup()->add_shortcut(ED_GET_SHORTCUT("script_text_editor/goto_previous_breakpoint"), DEBUG_GOTO_PREV_BREAKPOINT); + edit_menu->get_popup()->add_separator(); + PopupMenu *convert_case = memnew(PopupMenu); + convert_case->set_name("convert_case"); + edit_menu->get_popup()->add_child(convert_case); + edit_menu->get_popup()->add_submenu_item(TTR("Convert Case"), "convert_case"); + convert_case->add_shortcut(ED_SHORTCUT("script_text_editor/convert_to_uppercase", TTR("Uppercase")), EDIT_TO_UPPERCASE); + convert_case->add_shortcut(ED_SHORTCUT("script_text_editor/convert_to_lowercase", TTR("Lowercase")), EDIT_TO_LOWERCASE); + convert_case->add_shortcut(ED_SHORTCUT("script_text_editor/capitalize", TTR("Capitalize")), EDIT_CAPITALIZE); + convert_case->connect("id_pressed", this, "_edit_option"); search_menu = memnew(MenuButton); edit_hb->add_child(search_menu); @@ -1305,6 +1462,8 @@ void ScriptTextEditor::register_editor() { ED_SHORTCUT("script_text_editor/complete_symbol", TTR("Complete Symbol"), KEY_MASK_CMD | KEY_SPACE); #endif ED_SHORTCUT("script_text_editor/trim_trailing_whitespace", TTR("Trim Trailing Whitespace"), KEY_MASK_CTRL | KEY_MASK_ALT | KEY_T); + ED_SHORTCUT("script_text_editor/convert_indent_to_spaces", TTR("Convert Indent To Spaces"), KEY_MASK_CTRL | KEY_MASK_SHIFT | KEY_Y); + ED_SHORTCUT("script_text_editor/convert_indent_to_tabs", TTR("Convert Indent To Tabs"), KEY_MASK_CTRL | KEY_MASK_SHIFT | KEY_X); ED_SHORTCUT("script_text_editor/auto_indent", TTR("Auto Indent"), KEY_MASK_CMD | KEY_I); ED_SHORTCUT("script_text_editor/toggle_breakpoint", TTR("Toggle Breakpoint"), KEY_F9); @@ -1312,6 +1471,10 @@ void ScriptTextEditor::register_editor() { ED_SHORTCUT("script_text_editor/goto_next_breakpoint", TTR("Goto Next Breakpoint"), KEY_MASK_CTRL | KEY_PERIOD); ED_SHORTCUT("script_text_editor/goto_previous_breakpoint", TTR("Goto Previous Breakpoint"), KEY_MASK_CTRL | KEY_COMMA); + ED_SHORTCUT("script_text_editor/convert_to_uppercase", TTR("Convert To Uppercase"), KEY_MASK_SHIFT | KEY_F4); + ED_SHORTCUT("script_text_editor/convert_to_lowercase", TTR("Convert To Lowercase"), KEY_MASK_SHIFT | KEY_F3); + ED_SHORTCUT("script_text_editor/capitalize", TTR("Capitalize"), KEY_MASK_SHIFT | KEY_F2); + ED_SHORTCUT("script_text_editor/find", TTR("Find.."), KEY_MASK_CMD | KEY_F); ED_SHORTCUT("script_text_editor/find_next", TTR("Find Next"), KEY_F3); ED_SHORTCUT("script_text_editor/find_previous", TTR("Find Previous"), KEY_MASK_SHIFT | KEY_F3); diff --git a/editor/plugins/script_text_editor.h b/editor/plugins/script_text_editor.h index 0649e39ab7..ba40645161 100644 --- a/editor/plugins/script_text_editor.h +++ b/editor/plugins/script_text_editor.h @@ -67,6 +67,8 @@ class ScriptTextEditor : public ScriptEditorBase { EDIT_COMPLETE, EDIT_AUTO_INDENT, EDIT_TRIM_TRAILING_WHITESAPCE, + EDIT_CONVERT_INDENT_TO_SPACES, + EDIT_CONVERT_INDENT_TO_TABS, EDIT_TOGGLE_COMMENT, EDIT_MOVE_LINE_UP, EDIT_MOVE_LINE_DOWN, @@ -74,6 +76,9 @@ class ScriptTextEditor : public ScriptEditorBase { EDIT_INDENT_LEFT, EDIT_CLONE_DOWN, EDIT_PICK_COLOR, + EDIT_TO_UPPERCASE, + EDIT_TO_LOWERCASE, + EDIT_CAPITALIZE, SEARCH_FIND, SEARCH_FIND_NEXT, SEARCH_FIND_PREV, @@ -101,12 +106,19 @@ protected: void _edit_option(int p_op); void _make_context_menu(bool p_selection, bool p_color); - void _text_edit_gui_input(const InputEvent &ev); + void _text_edit_gui_input(const Ref<InputEvent> &ev); void _color_changed(const Color &p_color); void _goto_line(int p_line) { goto_line(p_line); } void _lookup_symbol(const String &p_symbol, int p_row, int p_column); + enum CaseStyle { + UPPER, + LOWER, + CAPITALIZE, + }; + void _convert_case(CaseStyle p_case); + Variant get_drag_data_fw(const Point2 &p_point, Control *p_from); bool can_drop_data_fw(const Point2 &p_point, const Variant &p_data, Control *p_from) const; void drop_data_fw(const Point2 &p_point, const Variant &p_data, Control *p_from); @@ -125,6 +137,8 @@ public: virtual void set_edit_state(const Variant &p_state); virtual void ensure_focus(); virtual void trim_trailing_whitespace(); + virtual void convert_indent_to_spaces(); + virtual void convert_indent_to_tabs(); virtual void tag_saved_version(); virtual void goto_line(int p_line, bool p_with_error = false); @@ -134,7 +148,8 @@ public: virtual void add_callback(const String &p_function, PoolStringArray p_args); virtual void update_settings(); - virtual bool goto_method(const String &p_method); + + virtual bool show_members_overview(); virtual void set_tooltip_request_func(String p_method, Object *p_obj); diff --git a/editor/plugins/shader_editor_plugin.cpp b/editor/plugins/shader_editor_plugin.cpp index b693913e45..7c8ee97f22 100644 --- a/editor/plugins/shader_editor_plugin.cpp +++ b/editor/plugins/shader_editor_plugin.cpp @@ -370,7 +370,8 @@ void ShaderEditor::_editor_settings_changed() { shader_editor->get_text_edit()->set_auto_brace_completion(EditorSettings::get_singleton()->get("text_editor/completion/auto_brace_complete")); shader_editor->get_text_edit()->set_scroll_pass_end_of_file(EditorSettings::get_singleton()->get("text_editor/cursor/scroll_past_end_of_file")); - shader_editor->get_text_edit()->set_tab_size(EditorSettings::get_singleton()->get("text_editor/indent/tab_size")); + shader_editor->get_text_edit()->set_indent_size(EditorSettings::get_singleton()->get("text_editor/indent/size")); + shader_editor->get_text_edit()->set_indent_using_spaces(EditorSettings::get_singleton()->get("text_editor/indent/type")); shader_editor->get_text_edit()->set_draw_tabs(EditorSettings::get_singleton()->get("text_editor/indent/draw_tabs")); shader_editor->get_text_edit()->set_show_line_numbers(EditorSettings::get_singleton()->get("text_editor/line_numbers/show_line_numbers")); shader_editor->get_text_edit()->set_syntax_coloring(EditorSettings::get_singleton()->get("text_editor/highlighting/syntax_highlighting")); @@ -551,7 +552,8 @@ ShaderEditorPlugin::ShaderEditorPlugin(EditorNode *p_node) { shader_editor = memnew(ShaderEditor); shader_editor->set_custom_minimum_size(Size2(0, 300)); - button = editor->add_bottom_panel_item("Shader", shader_editor); + button = editor->add_bottom_panel_item(TTR("Shader"), shader_editor); + button->hide(); } ShaderEditorPlugin::~ShaderEditorPlugin() { diff --git a/editor/plugins/shader_graph_editor_plugin.cpp b/editor/plugins/shader_graph_editor_plugin.cpp index 0fd28a0b59..9c65ef667a 100644 --- a/editor/plugins/shader_graph_editor_plugin.cpp +++ b/editor/plugins/shader_graph_editor_plugin.cpp @@ -40,7 +40,7 @@ void GraphColorRampEdit::_gui_input(const InputEvent& p_event) { - if (p_event.type==InputEvent::KEY && p_event.key.pressed && p_event.key.scancode==KEY_DELETE && grabbed!=-1) { + if (p_event.type==InputEvent::KEY && p_event->is_pressed() && p_event->get_scancode()==KEY_DELETE && grabbed!=-1) { points.remove(grabbed); grabbed=-1; @@ -49,10 +49,10 @@ void GraphColorRampEdit::_gui_input(const InputEvent& p_event) { accept_event(); } - if (p_event.type==InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index==1 && p_event.mouse_button.pressed) { + if (p_event.type==InputEvent::MOUSE_BUTTON && p_event->get_button_index()==1 && p_event->is_pressed()) { update(); - int x = p_event.mouse_button.x; + int x = p_event->get_pos().x; int total_w = get_size().width-get_size().height-3; if (x>total_w+3) { @@ -132,7 +132,7 @@ void GraphColorRampEdit::_gui_input(const InputEvent& p_event) { } - if (p_event.type==InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index==1 && !p_event.mouse_button.pressed) { + if (p_event.type==InputEvent::MOUSE_BUTTON && p_event->get_button_index()==1 && !p_event->is_pressed()) { if (grabbing) { grabbing=false; @@ -319,7 +319,7 @@ GraphColorRampEdit::GraphColorRampEdit(){ void GraphCurveMapEdit::_gui_input(const InputEvent& p_event) { - if (p_event.type==InputEvent::KEY && p_event.key.pressed && p_event.key.scancode==KEY_DELETE && grabbed!=-1) { + if (p_event.type==InputEvent::KEY && p_event->is_pressed() && p_event->get_scancode()==KEY_DELETE && grabbed!=-1) { points.remove(grabbed); grabbed=-1; @@ -328,10 +328,10 @@ void GraphCurveMapEdit::_gui_input(const InputEvent& p_event) { accept_event(); } - if (p_event.type==InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index==1 && p_event.mouse_button.pressed) { + if (p_event.type==InputEvent::MOUSE_BUTTON && p_event->get_button_index()==1 && p_event->is_pressed()) { update(); - Point2 p = Vector2(p_event.mouse_button.x,p_event.mouse_button.y)/get_size(); + Point2 p = Vector2(p_event->get_pos().x,p_event->get_pos().y)/get_size(); p.y=1.0-p.y; grabbed=-1; grabbing=true; @@ -371,7 +371,7 @@ void GraphCurveMapEdit::_gui_input(const InputEvent& p_event) { } - if (p_event.type==InputEvent::MOUSE_BUTTON && p_event.mouse_button.button_index==1 && !p_event.mouse_button.pressed) { + if (p_event.type==InputEvent::MOUSE_BUTTON && p_event->get_button_index()==1 && !p_event->is_pressed()) { if (grabbing) { grabbing=false; @@ -382,7 +382,7 @@ void GraphCurveMapEdit::_gui_input(const InputEvent& p_event) { if (p_event.type==InputEvent::MOUSE_MOTION && grabbing && grabbed != -1) { - Point2 p = Vector2(p_event.mouse_button.x,p_event.mouse_button.y)/get_size(); + Point2 p = Vector2(p_event->get_pos().x,p_event->get_pos().y)/get_size(); p.y=1.0-p.y; p.x = CLAMP(p.x,0.0,1.0); diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp index d73349f773..2d27e218ec 100644 --- a/editor/plugins/spatial_editor_plugin.cpp +++ b/editor/plugins/spatial_editor_plugin.cpp @@ -51,6 +51,12 @@ //#define GIZMO_SCALE_DEFAULT 0.28 #define GIZMO_SCALE_DEFAULT 0.15 +#define ZOOM_MIN_DISTANCE 0.001 +#define ZOOM_MULTIPLIER 1.08 +#define ZOOM_INDICATOR_DELAY_S 1.5 + +#define FREELOOK_MIN_SPEED 0.1 + void SpatialEditorViewport::_update_camera() { if (orthogonal) { //camera->set_orthogonal(size.width*cursor.distance,get_znear(),get_zfar()); @@ -58,20 +64,26 @@ void SpatialEditorViewport::_update_camera() { } else camera->set_perspective(get_fov(), get_znear(), get_zfar()); + Transform camera_transform = to_camera_transform(cursor); + + if (camera->get_global_transform() != camera_transform) { + camera->set_global_transform(camera_transform); + update_transform_gizmo_view(); + } +} + +Transform SpatialEditorViewport::to_camera_transform(const Cursor &p_cursor) const { Transform camera_transform; - camera_transform.translate(cursor.pos); - camera_transform.basis.rotate(Vector3(1, 0, 0), -cursor.x_rot); - camera_transform.basis.rotate(Vector3(0, 1, 0), -cursor.y_rot); + camera_transform.translate(p_cursor.pos); + camera_transform.basis.rotate(Vector3(1, 0, 0), -p_cursor.x_rot); + camera_transform.basis.rotate(Vector3(0, 1, 0), -p_cursor.y_rot); if (orthogonal) camera_transform.translate(0, 0, 4096); else - camera_transform.translate(0, 0, cursor.distance); + camera_transform.translate(0, 0, p_cursor.distance); - if (camera->get_global_transform() != camera_transform) { - camera->set_global_transform(camera_transform); - update_transform_gizmo_view(); - } + return camera_transform; } String SpatialEditorGizmo::get_handle_name(int p_idx) const { @@ -519,12 +531,12 @@ static int _get_key_modifier(const String &p_property) { return 0; } -bool SpatialEditorViewport::_gizmo_select(const Vector2 &p_screenpos, bool p_hilite_only) { +bool SpatialEditorViewport::_gizmo_select(const Vector2 &p_screenpos, bool p_highlight_only) { if (!spatial_editor->is_gizmo_visible()) return false; if (get_selected_count() == 0) { - if (p_hilite_only) + if (p_highlight_only) spatial_editor->select_gizmo_highlight_axis(-1); return false; } @@ -557,7 +569,7 @@ bool SpatialEditorViewport::_gizmo_select(const Vector2 &p_screenpos, bool p_hil if (col_axis != -1) { - if (p_hilite_only) { + if (p_highlight_only) { spatial_editor->select_gizmo_highlight_axis(col_axis); @@ -597,7 +609,7 @@ bool SpatialEditorViewport::_gizmo_select(const Vector2 &p_screenpos, bool p_hil if (col_axis != -1) { - if (p_hilite_only) { + if (p_highlight_only) { spatial_editor->select_gizmo_highlight_axis(col_axis + 3); } else { @@ -610,7 +622,7 @@ bool SpatialEditorViewport::_gizmo_select(const Vector2 &p_screenpos, bool p_hil } } - if (p_hilite_only) + if (p_highlight_only) spatial_editor->select_gizmo_highlight_axis(-1); return false; @@ -622,9 +634,9 @@ void SpatialEditorViewport::_smouseenter() { surface->grab_focus(); } -void SpatialEditorViewport::_list_select(InputEventMouseButton b) { +void SpatialEditorViewport::_list_select(Ref<InputEventMouseButton> b) { - _find_items_at_pos(Vector2(b.x, b.y), clicked_includes_current, selection_results, b.mod.shift); + _find_items_at_pos(b->get_position(), clicked_includes_current, selection_results, b->get_shift()); Node *scene = editor->get_edited_scene(); @@ -637,7 +649,7 @@ void SpatialEditorViewport::_list_select(InputEventMouseButton b) { } } - clicked_wants_append = b.mod.shift; + clicked_wants_append = b->get_shift(); if (selection_results.size() == 1) { @@ -669,877 +681,933 @@ void SpatialEditorViewport::_list_select(InputEventMouseButton b) { selection_menu->add_item(spat->get_name()); selection_menu->set_item_icon(i, icon); selection_menu->set_item_metadata(i, node_path); - selection_menu->set_item_tooltip(i, String(spat->get_name()) + - "\nType: " + spat->get_class() + "\nPath: " + node_path); + selection_menu->set_item_tooltip(i, String(spat->get_name()) + "\nType: " + spat->get_class() + "\nPath: " + node_path); } - selection_menu->set_global_position(Vector2(b.global_x, b.global_y)); + selection_menu->set_global_position(b->get_global_position()); selection_menu->popup(); selection_menu->call_deferred("grab_click_focus"); selection_menu->set_invalidate_click_until_motion(); } } -void SpatialEditorViewport::_sinput(const InputEvent &p_event) { +void SpatialEditorViewport::_sinput(const Ref<InputEvent> &p_event) { if (previewing) return; //do NONE { - + EditorNode *en = editor; + EditorPluginList *force_input_forwarding_list = en->get_editor_plugins_force_input_forwarding(); + if (!force_input_forwarding_list->empty()) { + bool discard = force_input_forwarding_list->forward_spatial_gui_input(camera, p_event, true); + if (discard) + return; + } + } + { EditorNode *en = editor; EditorPluginList *over_plugin_list = en->get_editor_plugins_over(); - if (!over_plugin_list->empty()) { - bool discard = over_plugin_list->forward_spatial_gui_input(camera, p_event); + bool discard = over_plugin_list->forward_spatial_gui_input(camera, p_event, false); if (discard) return; } } - switch (p_event.type) { - case InputEvent::MOUSE_BUTTON: { - - const InputEventMouseButton &b = p_event.mouse_button; - - switch (b.button_index) { + Ref<InputEventMouseButton> b = p_event; - case BUTTON_WHEEL_UP: { + if (b.is_valid()) { - cursor.distance /= 1.08; - if (cursor.distance < 0.001) - cursor.distance = 0.001; + switch (b->get_button_index()) { - } break; - case BUTTON_WHEEL_DOWN: { + case BUTTON_WHEEL_UP: { + scale_cursor_distance(is_freelook_active() ? ZOOM_MULTIPLIER : 1.0 / ZOOM_MULTIPLIER); + } break; - if (cursor.distance < 0.001) - cursor.distance = 0.001; - cursor.distance *= 1.08; + case BUTTON_WHEEL_DOWN: { + scale_cursor_distance(is_freelook_active() ? 1.0 / ZOOM_MULTIPLIER : ZOOM_MULTIPLIER); + } break; - } break; - case BUTTON_RIGHT: { + case BUTTON_RIGHT: { - NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); + NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); - if (b.pressed && _edit.gizmo.is_valid()) { - //restore - _edit.gizmo->commit_handle(_edit.gizmo_handle, _edit.gizmo_initial_value, true); - _edit.gizmo = Ref<SpatialEditorGizmo>(); - } + if (b->is_pressed() && _edit.gizmo.is_valid()) { + //restore + _edit.gizmo->commit_handle(_edit.gizmo_handle, _edit.gizmo_initial_value, true); + _edit.gizmo = Ref<SpatialEditorGizmo>(); + } - if (_edit.mode == TRANSFORM_NONE && b.pressed) { + if (_edit.mode == TRANSFORM_NONE && b->is_pressed()) { - Plane cursor_plane(cursor.cursor_pos, _get_camera_normal()); + if (b->get_alt()) { - Vector3 ray_origin = _get_ray_pos(Vector2(b.x, b.y)); - Vector3 ray_dir = _get_ray(Vector2(b.x, b.y)); + if (nav_scheme == NAVIGATION_MAYA) + break; - //gizmo modify + _list_select(b); + return; + } + } - if (b.mod.control) { + if (_edit.mode != TRANSFORM_NONE && b->is_pressed()) { + //cancel motion + _edit.mode = TRANSFORM_NONE; + //_validate_selection(); - Vector<ObjectID> instances = VisualServer::get_singleton()->instances_cull_ray(ray_origin, ray_dir, get_tree()->get_root()->get_world()->get_scenario()); + List<Node *> &selection = editor_selection->get_selected_node_list(); - Plane p(ray_origin, _get_camera_normal()); + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { - float min_d = 1e10; - bool found = false; + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) + continue; - for (int i = 0; i < instances.size(); i++) { + SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); + if (!se) + continue; - Object *obj = ObjectDB::get_instance(instances[i]); + sp->set_global_transform(se->original); + } + surface->update(); + //VisualServer::get_singleton()->poly_clear(indicators); + set_message(TTR("Transform Aborted."), 3); + } - if (!obj) - continue; + freelook_active = b->is_pressed(); - VisualInstance *vi = obj->cast_to<VisualInstance>(); - if (!vi) - continue; + } break; + case BUTTON_MIDDLE: { - //optimize by checking AABB (although should pre sort by distance) - Rect3 aabb = vi->get_global_transform().xform(vi->get_aabb()); - if (p.distance_to(aabb.get_support(-ray_dir)) > min_d) - continue; + if (b->is_pressed() && _edit.mode != TRANSFORM_NONE) { - PoolVector<Face3> faces = vi->get_faces(VisualInstance::FACES_SOLID); - int c = faces.size(); - if (c > 0) { - PoolVector<Face3>::Read r = faces.read(); + switch (_edit.plane) { - for (int j = 0; j < c; j++) { + case TRANSFORM_VIEW: { - Vector3 inters; - if (r[j].intersects_ray(ray_origin, ray_dir, &inters)) { + _edit.plane = TRANSFORM_X_AXIS; + set_message(TTR("X-Axis Transform."), 2); + name = ""; + _update_name(); + } break; + case TRANSFORM_X_AXIS: { - float d = p.distance_to(inters); - if (d < 0) - continue; + _edit.plane = TRANSFORM_Y_AXIS; + set_message(TTR("Y-Axis Transform."), 2); - if (d < min_d) { - min_d = d; - found = true; - } - } - } - } - } + } break; + case TRANSFORM_Y_AXIS: { - if (found) { + _edit.plane = TRANSFORM_Z_AXIS; + set_message(TTR("Z-Axis Transform."), 2); - //cursor.cursor_pos=ray_origin+ray_dir*min_d; - //VisualServer::get_singleton()->instance_set_transform(cursor_instance,Transform(Matrix3(),cursor.cursor_pos)); - } + } break; + case TRANSFORM_Z_AXIS: { - } else { - Vector3 new_pos; - if (cursor_plane.intersects_ray(ray_origin, ray_dir, &new_pos)) { + _edit.plane = TRANSFORM_VIEW; + set_message(TTR("View Plane Transform."), 2); - //cursor.cursor_pos=new_pos; - //VisualServer::get_singleton()->instance_set_transform(cursor_instance,Transform(Matrix3(),cursor.cursor_pos)); - } - } + } break; + } + } + } break; + case BUTTON_LEFT: { - if (b.mod.alt) { + if (b->is_pressed()) { - if (nav_scheme == NAVIGATION_MAYA) - break; + NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); + if ((nav_scheme == NAVIGATION_MAYA || nav_scheme == NAVIGATION_MODO) && b->get_alt()) { + break; + } - _list_select(b); - return; - } + if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_LIST_SELECT) { + _list_select(b); + break; } - if (_edit.mode != TRANSFORM_NONE && b.pressed) { - //cancel motion - _edit.mode = TRANSFORM_NONE; - //_validate_selection(); + _edit.mouse_pos = b->get_position(); + _edit.snap = false; + _edit.mode = TRANSFORM_NONE; - List<Node *> &selection = editor_selection->get_selected_node_list(); + //gizmo has priority over everything - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + bool can_select_gizmos = true; - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) - continue; + { + int idx = view_menu->get_popup()->get_item_index(VIEW_GIZMOS); + can_select_gizmos = view_menu->get_popup()->is_item_checked(idx); + } - SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); - if (!se) - continue; + if (can_select_gizmos && spatial_editor->get_selected()) { + + Ref<SpatialEditorGizmo> seg = spatial_editor->get_selected()->get_gizmo(); + if (seg.is_valid()) { + int handle = -1; + Vector3 point; + Vector3 normal; + bool inters = seg->intersect_ray(camera, _edit.mouse_pos, point, normal, &handle, b->get_shift()); + if (inters && handle != -1) { - sp->set_global_transform(se->original); + _edit.gizmo = seg; + _edit.gizmo_handle = handle; + //_edit.gizmo_initial_pos=seg->get_handle_pos(gizmo_handle); + _edit.gizmo_initial_value = seg->get_handle_value(handle); + break; + } } - surface->update(); - //VisualServer::get_singleton()->poly_clear(indicators); - set_message(TTR("Transform Aborted."), 3); } - } break; - case BUTTON_MIDDLE: { - if (b.pressed && _edit.mode != TRANSFORM_NONE) { + if (_gizmo_select(_edit.mouse_pos)) + break; - switch (_edit.plane) { + clicked = 0; + clicked_includes_current = false; - case TRANSFORM_VIEW: { + if ((spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_SELECT && b->get_control()) || spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_ROTATE) { - _edit.plane = TRANSFORM_X_AXIS; - set_message(TTR("X-Axis Transform."), 2); - name = ""; - _update_name(); - } break; - case TRANSFORM_X_AXIS: { + /* HANDLE ROTATION */ + if (get_selected_count() == 0) + break; //bye + //handle rotate + _edit.mode = TRANSFORM_ROTATE; + _compute_edit(b->get_position()); + break; + } - _edit.plane = TRANSFORM_Y_AXIS; - set_message(TTR("Y-Axis Transform."), 2); + if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_MOVE) { - } break; - case TRANSFORM_Y_AXIS: { + if (get_selected_count() == 0) + break; //bye + //handle rotate + _edit.mode = TRANSFORM_TRANSLATE; + _compute_edit(b->get_position()); + break; + } - _edit.plane = TRANSFORM_Z_AXIS; - set_message(TTR("Z-Axis Transform."), 2); + if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_SCALE) { - } break; - case TRANSFORM_Z_AXIS: { + if (get_selected_count() == 0) + break; //bye + //handle rotate + _edit.mode = TRANSFORM_SCALE; + _compute_edit(b->get_position()); + break; + } - _edit.plane = TRANSFORM_VIEW; - set_message(TTR("View Plane Transform."), 2); + // todo scale - } break; - } - } - } break; - case BUTTON_LEFT: { + int gizmo_handle = -1; - if (b.pressed) { + clicked = _select_ray(b->get_position(), b->get_shift(), clicked_includes_current, &gizmo_handle, b->get_shift()); - NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); - if ((nav_scheme == NAVIGATION_MAYA || nav_scheme == NAVIGATION_MODO) && b.mod.alt) { - break; - } + //clicking is always deferred to either move or release - if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_LIST_SELECT) { - _list_select(b); - break; - } + clicked_wants_append = b->get_shift(); - _edit.mouse_pos = Point2(b.x, b.y); - _edit.snap = false; - _edit.mode = TRANSFORM_NONE; + if (!clicked) { - //gizmo has priority over everything + if (!clicked_wants_append) + _clear_selected(); - bool can_select_gizmos = true; + //default to regionselect + cursor.region_select = true; + cursor.region_begin = b->get_position(); + cursor.region_end = b->get_position(); + } - { - int idx = view_menu->get_popup()->get_item_index(VIEW_GIZMOS); - can_select_gizmos = view_menu->get_popup()->is_item_checked(idx); - } + if (clicked && gizmo_handle >= 0) { + + Object *obj = ObjectDB::get_instance(clicked); + if (obj) { - if (can_select_gizmos && spatial_editor->get_selected()) { + Spatial *spa = obj->cast_to<Spatial>(); + if (spa) { - Ref<SpatialEditorGizmo> seg = spatial_editor->get_selected()->get_gizmo(); - if (seg.is_valid()) { - int handle = -1; - Vector3 point; - Vector3 normal; - bool inters = seg->intersect_ray(camera, _edit.mouse_pos, point, normal, &handle, b.mod.shift); - if (inters && handle != -1) { + Ref<SpatialEditorGizmo> seg = spa->get_gizmo(); + if (seg.is_valid()) { _edit.gizmo = seg; - _edit.gizmo_handle = handle; + _edit.gizmo_handle = gizmo_handle; //_edit.gizmo_initial_pos=seg->get_handle_pos(gizmo_handle); - _edit.gizmo_initial_value = seg->get_handle_value(handle); + _edit.gizmo_initial_value = seg->get_handle_value(gizmo_handle); + //print_line("GIZMO: "+itos(gizmo_handle)+" FROMPOS: "+_edit.orig_gizmo_pos); break; } } } + //_compute_edit(Point2(b.x,b.y)); //in case a motion happens.. + } - if (_gizmo_select(_edit.mouse_pos)) - break; - - clicked = 0; - clicked_includes_current = false; - - if ((spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_SELECT && b.mod.control) || spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_ROTATE) { - - /* HANDLE ROTATION */ - if (get_selected_count() == 0) - break; //bye - //handle rotate - _edit.mode = TRANSFORM_ROTATE; - _compute_edit(Point2(b.x, b.y)); - break; - } - - if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_MOVE) { - - if (get_selected_count() == 0) - break; //bye - //handle rotate - _edit.mode = TRANSFORM_TRANSLATE; - _compute_edit(Point2(b.x, b.y)); - break; - } - - if (spatial_editor->get_tool_mode() == SpatialEditor::TOOL_MODE_SCALE) { - - if (get_selected_count() == 0) - break; //bye - //handle rotate - _edit.mode = TRANSFORM_SCALE; - _compute_edit(Point2(b.x, b.y)); - break; - } - - // todo scale - - int gizmo_handle = -1; - - clicked = _select_ray(Vector2(b.x, b.y), b.mod.shift, clicked_includes_current, &gizmo_handle, b.mod.shift); - - //clicking is always deferred to either move or release - - clicked_wants_append = b.mod.shift; - - if (!clicked) { - - if (!clicked_wants_append) - _clear_selected(); - - //default to regionselect - cursor.region_select = true; - cursor.region_begin = Point2(b.x, b.y); - cursor.region_end = Point2(b.x, b.y); - } - - if (clicked && gizmo_handle >= 0) { - - Object *obj = ObjectDB::get_instance(clicked); - if (obj) { - - Spatial *spa = obj->cast_to<Spatial>(); - if (spa) { + surface->update(); + } else { - Ref<SpatialEditorGizmo> seg = spa->get_gizmo(); - if (seg.is_valid()) { + if (_edit.gizmo.is_valid()) { - _edit.gizmo = seg; - _edit.gizmo_handle = gizmo_handle; - //_edit.gizmo_initial_pos=seg->get_handle_pos(gizmo_handle); - _edit.gizmo_initial_value = seg->get_handle_value(gizmo_handle); - //print_line("GIZMO: "+itos(gizmo_handle)+" FROMPOS: "+_edit.orig_gizmo_pos); - break; - } - } - } - //_compute_edit(Point2(b.x,b.y)); //in case a motion happens.. - } + _edit.gizmo->commit_handle(_edit.gizmo_handle, _edit.gizmo_initial_value, false); + _edit.gizmo = Ref<SpatialEditorGizmo>(); + break; + } + if (clicked) { + _select_clicked(clicked_wants_append, true); + //clickd processing was deferred + clicked = 0; + } + if (cursor.region_select) { + _select_region(); + cursor.region_select = false; surface->update(); - } else { + } - if (_edit.gizmo.is_valid()) { + if (_edit.mode != TRANSFORM_NONE) { - _edit.gizmo->commit_handle(_edit.gizmo_handle, _edit.gizmo_initial_value, false); - _edit.gizmo = Ref<SpatialEditorGizmo>(); - break; - } - if (clicked) { - _select_clicked(clicked_wants_append, true); - //clickd processing was deferred - clicked = 0; - } + static const char *_transform_name[4] = { "None", "Rotate", "Translate", "Scale" }; + undo_redo->create_action(_transform_name[_edit.mode]); - if (cursor.region_select) { - _select_region(); - cursor.region_select = false; - surface->update(); - } + List<Node *> &selection = editor_selection->get_selected_node_list(); - if (_edit.mode != TRANSFORM_NONE) { + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { - static const char *_transform_name[4] = { "None", "Rotate", "Translate", "Scale" }; - undo_redo->create_action(_transform_name[_edit.mode]); + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) + continue; - List<Node *> &selection = editor_selection->get_selected_node_list(); + SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); + if (!se) + continue; - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + undo_redo->add_do_method(sp, "set_global_transform", sp->get_global_transform()); + undo_redo->add_undo_method(sp, "set_global_transform", se->original); + } + undo_redo->commit_action(); + _edit.mode = TRANSFORM_NONE; + //VisualServer::get_singleton()->poly_clear(indicators); + set_message(""); + } - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) - continue; + surface->update(); + } - SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); - if (!se) - continue; + } break; + } + } - undo_redo->add_do_method(sp, "set_global_transform", sp->get_global_transform()); - undo_redo->add_undo_method(sp, "set_global_transform", se->original); - } - undo_redo->commit_action(); - _edit.mode = TRANSFORM_NONE; - //VisualServer::get_singleton()->poly_clear(indicators); - set_message(""); - } + Ref<InputEventMouseMotion> m = p_event; - surface->update(); - } - } break; - } - } break; - case InputEvent::MOUSE_MOTION: { - const InputEventMouseMotion &m = p_event.mouse_motion; - _edit.mouse_pos = Point2(p_event.mouse_motion.x, p_event.mouse_motion.y); + if (m.is_valid()) { - if (spatial_editor->get_selected()) { + _edit.mouse_pos = m->get_position(); - Ref<SpatialEditorGizmo> seg = spatial_editor->get_selected()->get_gizmo(); - if (seg.is_valid()) { + if (spatial_editor->get_selected()) { - int selected_handle = -1; + Ref<SpatialEditorGizmo> seg = spatial_editor->get_selected()->get_gizmo(); + if (seg.is_valid()) { - int handle = -1; - Vector3 point; - Vector3 normal; - bool inters = seg->intersect_ray(camera, _edit.mouse_pos, point, normal, &handle, false); - if (inters && handle != -1) { + int selected_handle = -1; - selected_handle = handle; - } + int handle = -1; + Vector3 point; + Vector3 normal; + bool inters = seg->intersect_ray(camera, _edit.mouse_pos, point, normal, &handle, false); + if (inters && handle != -1) { - if (selected_handle != spatial_editor->get_over_gizmo_handle()) { - spatial_editor->set_over_gizmo_handle(selected_handle); - spatial_editor->get_selected()->update_gizmo(); - if (selected_handle != -1) - spatial_editor->select_gizmo_highlight_axis(-1); - } + selected_handle = handle; } - } - - if (spatial_editor->get_over_gizmo_handle() == -1 && !(m.button_mask & 1) && !_edit.gizmo.is_valid()) { - _gizmo_select(_edit.mouse_pos, true); + if (selected_handle != spatial_editor->get_over_gizmo_handle()) { + spatial_editor->set_over_gizmo_handle(selected_handle); + spatial_editor->get_selected()->update_gizmo(); + if (selected_handle != -1) + spatial_editor->select_gizmo_highlight_axis(-1); + } } + } - NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); - NavigationMode nav_mode = NAVIGATION_NONE; + if (spatial_editor->get_over_gizmo_handle() == -1 && !(m->get_button_mask() & 1) && !_edit.gizmo.is_valid()) { - if (_edit.gizmo.is_valid()) { + _gizmo_select(_edit.mouse_pos, true); + } - _edit.gizmo->set_handle(_edit.gizmo_handle, camera, Vector2(m.x, m.y)); - Variant v = _edit.gizmo->get_handle_value(_edit.gizmo_handle); - String n = _edit.gizmo->get_handle_name(_edit.gizmo_handle); - set_message(n + ": " + String(v)); + NavigationScheme nav_scheme = (NavigationScheme)EditorSettings::get_singleton()->get("editors/3d/navigation_scheme").operator int(); + NavigationMode nav_mode = NAVIGATION_NONE; - } else if (m.button_mask & 1) { + if (_edit.gizmo.is_valid()) { - if (nav_scheme == NAVIGATION_MAYA && m.mod.alt) { - nav_mode = NAVIGATION_ORBIT; - } else if (nav_scheme == NAVIGATION_MODO && m.mod.alt && m.mod.shift) { - nav_mode = NAVIGATION_PAN; - } else if (nav_scheme == NAVIGATION_MODO && m.mod.alt && m.mod.control) { - nav_mode = NAVIGATION_ZOOM; - } else if (nav_scheme == NAVIGATION_MODO && m.mod.alt) { - nav_mode = NAVIGATION_ORBIT; - } else { - if (clicked) { + _edit.gizmo->set_handle(_edit.gizmo_handle, camera, m->get_position()); + Variant v = _edit.gizmo->get_handle_value(_edit.gizmo_handle); + String n = _edit.gizmo->get_handle_name(_edit.gizmo_handle); + set_message(n + ": " + String(v)); - if (!clicked_includes_current) { + } else if (m->get_button_mask() & BUTTON_MASK_LEFT) { - _select_clicked(clicked_wants_append, true); - //clickd processing was deferred - } + if (nav_scheme == NAVIGATION_MAYA && m->get_alt()) { + nav_mode = NAVIGATION_ORBIT; + } else if (nav_scheme == NAVIGATION_MODO && m->get_alt() && m->get_shift()) { + nav_mode = NAVIGATION_PAN; + } else if (nav_scheme == NAVIGATION_MODO && m->get_alt() && m->get_control()) { + nav_mode = NAVIGATION_ZOOM; + } else if (nav_scheme == NAVIGATION_MODO && m->get_alt()) { + nav_mode = NAVIGATION_ORBIT; + } else { + if (clicked) { - _compute_edit(_edit.mouse_pos); - clicked = 0; + if (!clicked_includes_current) { - _edit.mode = TRANSFORM_TRANSLATE; + _select_clicked(clicked_wants_append, true); + //clickd processing was deferred } - if (cursor.region_select && nav_mode == NAVIGATION_NONE) { + _compute_edit(_edit.mouse_pos); + clicked = 0; - cursor.region_end = Point2(m.x, m.y); - surface->update(); - return; - } + _edit.mode = TRANSFORM_TRANSLATE; + } - if (_edit.mode == TRANSFORM_NONE && nav_mode == NAVIGATION_NONE) - break; + if (cursor.region_select && nav_mode == NAVIGATION_NONE) { - Vector3 ray_pos = _get_ray_pos(Vector2(m.x, m.y)); - Vector3 ray = _get_ray(Vector2(m.x, m.y)); + cursor.region_end = m->get_position(); + surface->update(); + return; + } - switch (_edit.mode) { + if (_edit.mode == TRANSFORM_NONE && nav_mode == NAVIGATION_NONE) + return; - case TRANSFORM_SCALE: { + Vector3 ray_pos = _get_ray_pos(m->get_position()); + Vector3 ray = _get_ray(m->get_position()); - Plane plane = Plane(_edit.center, _get_camera_normal()); + switch (_edit.mode) { - Vector3 intersection; - if (!plane.intersects_ray(ray_pos, ray, &intersection)) - break; + case TRANSFORM_SCALE: { - Vector3 click; - if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) - break; + Plane plane = Plane(_edit.center, _get_camera_normal()); - float center_click_dist = click.distance_to(_edit.center); - float center_inters_dist = intersection.distance_to(_edit.center); - if (center_click_dist == 0) - break; + Vector3 intersection; + if (!plane.intersects_ray(ray_pos, ray, &intersection)) + break; - float scale = (center_inters_dist / center_click_dist) * 100.0; + Vector3 click; + if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) + break; - if (_edit.snap || spatial_editor->is_snap_enabled()) { + float center_click_dist = click.distance_to(_edit.center); + float center_inters_dist = intersection.distance_to(_edit.center); + if (center_click_dist == 0) + break; - scale = Math::stepify(scale, spatial_editor->get_scale_snap()); - } + float scale = (center_inters_dist / center_click_dist) * 100.0; - set_message(vformat(TTR("Scaling to %s%%."), String::num(scale, 1))); - scale /= 100.0; + if (_edit.snap || spatial_editor->is_snap_enabled()) { - Transform r; - r.basis.scale(Vector3(scale, scale, scale)); + scale = Math::stepify(scale, spatial_editor->get_scale_snap()); + } - List<Node *> &selection = editor_selection->get_selected_node_list(); + set_message(vformat(TTR("Scaling to %s%%."), String::num(scale, 1))); + scale /= 100.0; - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + Transform r; + r.basis.scale(Vector3(scale, scale, scale)); - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) - continue; + List<Node *> &selection = editor_selection->get_selected_node_list(); - SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); - if (!se) - continue; + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { - Transform original = se->original; + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) + continue; - Transform base = Transform(Basis(), _edit.center); - Transform t = base * (r * (base.inverse() * original)); + SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); + if (!se) + continue; - sp->set_global_transform(t); - } + Transform original = se->original; - surface->update(); + Transform base = Transform(Basis(), _edit.center); + Transform t = base * (r * (base.inverse() * original)); - } break; + sp->set_global_transform(t); + } - case TRANSFORM_TRANSLATE: { + surface->update(); - Vector3 motion_mask; - Plane plane; + } break; - switch (_edit.plane) { - case TRANSFORM_VIEW: - motion_mask = Vector3(0, 0, 0); - plane = Plane(_edit.center, _get_camera_normal()); - break; - case TRANSFORM_X_AXIS: - motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(0); - plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); - break; - case TRANSFORM_Y_AXIS: - motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(1); - plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); - break; - case TRANSFORM_Z_AXIS: - motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(2); - plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); - break; - } + case TRANSFORM_TRANSLATE: { - Vector3 intersection; - if (!plane.intersects_ray(ray_pos, ray, &intersection)) - break; + Vector3 motion_mask; + Plane plane; - Vector3 click; - if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) + switch (_edit.plane) { + case TRANSFORM_VIEW: + motion_mask = Vector3(0, 0, 0); + plane = Plane(_edit.center, _get_camera_normal()); break; + case TRANSFORM_X_AXIS: + motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(0); + plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); + break; + case TRANSFORM_Y_AXIS: + motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(1); + plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); + break; + case TRANSFORM_Z_AXIS: + motion_mask = spatial_editor->get_gizmo_transform().basis.get_axis(2); + plane = Plane(_edit.center, motion_mask.cross(motion_mask.cross(_get_camera_normal())).normalized()); + break; + } - //_validate_selection(); - Vector3 motion = intersection - click; - if (motion_mask != Vector3()) { - motion = motion_mask.dot(motion) * motion_mask; - } + Vector3 intersection; + if (!plane.intersects_ray(ray_pos, ray, &intersection)) + break; - float snap = 0; + Vector3 click; + if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) + break; - if (_edit.snap || spatial_editor->is_snap_enabled()) { + //_validate_selection(); + Vector3 motion = intersection - click; + if (motion_mask != Vector3()) { + motion = motion_mask.dot(motion) * motion_mask; + } - snap = spatial_editor->get_translate_snap(); - motion.snap(snap); - } + float snap = 0; - //set_message("Translating: "+motion); + if (_edit.snap || spatial_editor->is_snap_enabled()) { - List<Node *> &selection = editor_selection->get_selected_node_list(); + snap = spatial_editor->get_translate_snap(); + motion.snap(snap); + } - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + //set_message("Translating: "+motion); - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) { - continue; - } + List<Node *> &selection = editor_selection->get_selected_node_list(); - SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); - if (!se) { - continue; - } + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) { + continue; + } - Transform t = se->original; - t.origin += motion; - sp->set_global_transform(t); + SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); + if (!se) { + continue; } - } break; - case TRANSFORM_ROTATE: { + Transform t = se->original; + t.origin += motion; + sp->set_global_transform(t); + } + } break; - Plane plane; + case TRANSFORM_ROTATE: { - switch (_edit.plane) { - case TRANSFORM_VIEW: - plane = Plane(_edit.center, _get_camera_normal()); - break; - case TRANSFORM_X_AXIS: - plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(0)); - break; - case TRANSFORM_Y_AXIS: - plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(1)); - break; - case TRANSFORM_Z_AXIS: - plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(2)); - break; - } + Plane plane; - Vector3 intersection; - if (!plane.intersects_ray(ray_pos, ray, &intersection)) + switch (_edit.plane) { + case TRANSFORM_VIEW: + plane = Plane(_edit.center, _get_camera_normal()); break; - - Vector3 click; - if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) + case TRANSFORM_X_AXIS: + plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(0)); + break; + case TRANSFORM_Y_AXIS: + plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(1)); break; + case TRANSFORM_Z_AXIS: + plane = Plane(_edit.center, spatial_editor->get_gizmo_transform().basis.get_axis(2)); + break; + } - Vector3 y_axis = (click - _edit.center).normalized(); - Vector3 x_axis = plane.normal.cross(y_axis).normalized(); + Vector3 intersection; + if (!plane.intersects_ray(ray_pos, ray, &intersection)) + break; - float angle = Math::atan2(x_axis.dot(intersection - _edit.center), y_axis.dot(intersection - _edit.center)); - if (_edit.snap || spatial_editor->is_snap_enabled()) { + Vector3 click; + if (!plane.intersects_ray(_edit.click_ray_pos, _edit.click_ray, &click)) + break; + + Vector3 y_axis = (click - _edit.center).normalized(); + Vector3 x_axis = plane.normal.cross(y_axis).normalized(); - float snap = spatial_editor->get_rotate_snap(); + float angle = Math::atan2(x_axis.dot(intersection - _edit.center), y_axis.dot(intersection - _edit.center)); + if (_edit.snap || spatial_editor->is_snap_enabled()) { - if (snap) { - angle = Math::rad2deg(angle) + snap * 0.5; //else it wont reach +180 - angle -= Math::fmod(angle, snap); - set_message(vformat(TTR("Rotating %s degrees."), rtos(angle))); - angle = Math::deg2rad(angle); - } else - set_message(vformat(TTR("Rotating %s degrees."), rtos(Math::rad2deg(angle)))); + float snap = spatial_editor->get_rotate_snap(); - } else { + if (snap) { + angle = Math::rad2deg(angle) + snap * 0.5; //else it wont reach +180 + angle -= Math::fmod(angle, snap); + set_message(vformat(TTR("Rotating %s degrees."), rtos(angle))); + angle = Math::deg2rad(angle); + } else set_message(vformat(TTR("Rotating %s degrees."), rtos(Math::rad2deg(angle)))); - } - Transform r; - r.basis.rotate(plane.normal, angle); + } else { + set_message(vformat(TTR("Rotating %s degrees."), rtos(Math::rad2deg(angle)))); + } - List<Node *> &selection = editor_selection->get_selected_node_list(); + Transform r; + r.basis.rotate(plane.normal, angle); - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + List<Node *> &selection = editor_selection->get_selected_node_list(); - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) - continue; + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { - SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); - if (!se) - continue; + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) + continue; - Transform original = se->original; + SpatialEditorSelectedItem *se = editor_selection->get_node_editor_data<SpatialEditorSelectedItem>(sp); + if (!se) + continue; - Transform base = Transform(Basis(), _edit.center); - Transform t = base * r * base.inverse() * original; + Transform original = se->original; - sp->set_global_transform(t); - } + Transform base = Transform(Basis(), _edit.center); + Transform t = base * r * base.inverse() * original; - surface->update(); - /* - VisualServer::get_singleton()->poly_clear(indicators); - - Vector<Vector3> points; - Vector<Vector3> empty; - Vector<Color> colors; - points.push_back(intersection); - points.push_back(_edit.original.origin); - colors.push_back( Color(255,155,100) ); - colors.push_back( Color(255,155,100) ); - VisualServer::get_singleton()->poly_add_primitive(indicators,points,empty,colors,empty); - */ - } break; - default: {} - } + sp->set_global_transform(t); + } + + surface->update(); + /* + VisualServer::get_singleton()->poly_clear(indicators); + + Vector<Vector3> points; + Vector<Vector3> empty; + Vector<Color> colors; + points.push_back(intersection); + points.push_back(_edit.original.origin); + colors.push_back( Color(255,155,100) ); + colors.push_back( Color(255,155,100) ); + VisualServer::get_singleton()->poly_add_primitive(indicators,points,empty,colors,empty); + */ + } break; + default: {} } + } - } else if (m.button_mask & 2) { + } else if (m->get_button_mask() & BUTTON_MASK_RIGHT) { - if (nav_scheme == NAVIGATION_MAYA && m.mod.alt) { - nav_mode = NAVIGATION_ZOOM; - } + if (nav_scheme == NAVIGATION_MAYA && m->get_alt()) { + nav_mode = NAVIGATION_ZOOM; + } else { + nav_mode = NAVIGATION_LOOK; + } - } else if (m.button_mask & 4) { - - if (nav_scheme == NAVIGATION_GODOT) { - - int mod = 0; - if (m.mod.shift) - mod = KEY_SHIFT; - if (m.mod.alt) - mod = KEY_ALT; - if (m.mod.control) - mod = KEY_CONTROL; - if (m.mod.meta) - mod = KEY_META; - - if (mod == _get_key_modifier("editors/3d/pan_modifier")) - nav_mode = NAVIGATION_PAN; - else if (mod == _get_key_modifier("editors/3d/zoom_modifier")) - nav_mode = NAVIGATION_ZOOM; - else if (mod == _get_key_modifier("editors/3d/orbit_modifier")) - nav_mode = NAVIGATION_ORBIT; - - } else if (nav_scheme == NAVIGATION_MAYA) { - if (m.mod.alt) - nav_mode = NAVIGATION_PAN; - } + } else if (m->get_button_mask() & BUTTON_MASK_MIDDLE) { + + if (nav_scheme == NAVIGATION_GODOT) { - } else if (EditorSettings::get_singleton()->get("editors/3d/emulate_3_button_mouse")) { - // Handle trackpad (no external mouse) use case int mod = 0; - if (m.mod.shift) + if (m->get_shift()) mod = KEY_SHIFT; - if (m.mod.alt) + if (m->get_alt()) mod = KEY_ALT; - if (m.mod.control) + if (m->get_control()) mod = KEY_CONTROL; - if (m.mod.meta) + if (m->get_metakey()) mod = KEY_META; - if (mod) { - if (mod == _get_key_modifier("editors/3d/pan_modifier")) - nav_mode = NAVIGATION_PAN; - else if (mod == _get_key_modifier("editors/3d/zoom_modifier")) - nav_mode = NAVIGATION_ZOOM; - else if (mod == _get_key_modifier("editors/3d/orbit_modifier")) - nav_mode = NAVIGATION_ORBIT; - } + if (mod == _get_key_modifier("editors/3d/pan_modifier")) + nav_mode = NAVIGATION_PAN; + else if (mod == _get_key_modifier("editors/3d/zoom_modifier")) + nav_mode = NAVIGATION_ZOOM; + else if (mod == _get_key_modifier("editors/3d/orbit_modifier")) + nav_mode = NAVIGATION_ORBIT; + + } else if (nav_scheme == NAVIGATION_MAYA) { + if (m->get_alt()) + nav_mode = NAVIGATION_PAN; } - switch (nav_mode) { - case NAVIGATION_PAN: { + } else if (EditorSettings::get_singleton()->get("editors/3d/emulate_3_button_mouse")) { + // Handle trackpad (no external mouse) use case + int mod = 0; + if (m->get_shift()) + mod = KEY_SHIFT; + if (m->get_alt()) + mod = KEY_ALT; + if (m->get_control()) + mod = KEY_CONTROL; + if (m->get_metakey()) + mod = KEY_META; + + if (mod) { + if (mod == _get_key_modifier("editors/3d/pan_modifier")) + nav_mode = NAVIGATION_PAN; + else if (mod == _get_key_modifier("editors/3d/zoom_modifier")) + nav_mode = NAVIGATION_ZOOM; + else if (mod == _get_key_modifier("editors/3d/orbit_modifier")) + nav_mode = NAVIGATION_ORBIT; + } + } - real_t pan_speed = 1 / 150.0; - int pan_speed_modifier = 10; - if (nav_scheme == NAVIGATION_MAYA && m.mod.shift) - pan_speed *= pan_speed_modifier; + switch (nav_mode) { + case NAVIGATION_PAN: { - Point2i relative; - if (bool(EditorSettings::get_singleton()->get("editors/3d/warped_mouse_panning"))) { - relative = Input::get_singleton()->warp_mouse_motion(m, surface->get_global_rect()); - } else { - relative = Point2i(m.relative_x, m.relative_y); - } + real_t pan_speed = 1 / 150.0; + int pan_speed_modifier = 10; + if (nav_scheme == NAVIGATION_MAYA && m->get_shift()) + pan_speed *= pan_speed_modifier; - Transform camera_transform; - - camera_transform.translate(cursor.pos); - camera_transform.basis.rotate(Vector3(1, 0, 0), -cursor.x_rot); - camera_transform.basis.rotate(Vector3(0, 1, 0), -cursor.y_rot); - Vector3 translation(-relative.x * pan_speed, relative.y * pan_speed, 0); - translation *= cursor.distance / DISTANCE_DEFAULT; - camera_transform.translate(translation); - cursor.pos = camera_transform.origin; - - } break; - - case NAVIGATION_ZOOM: { - real_t zoom_speed = 1 / 80.0; - int zoom_speed_modifier = 10; - if (nav_scheme == NAVIGATION_MAYA && m.mod.shift) - zoom_speed *= zoom_speed_modifier; - - NavigationZoomStyle zoom_style = (NavigationZoomStyle)EditorSettings::get_singleton()->get("editors/3d/zoom_style").operator int(); - if (zoom_style == NAVIGATION_ZOOM_HORIZONTAL) { - if (m.relative_x > 0) - cursor.distance *= 1 - m.relative_x * zoom_speed; - else if (m.relative_x < 0) - cursor.distance /= 1 + m.relative_x * zoom_speed; - } else { - if (m.relative_y > 0) - cursor.distance *= 1 + m.relative_y * zoom_speed; - else if (m.relative_y < 0) - cursor.distance /= 1 - m.relative_y * zoom_speed; - } + Point2i relative = _get_warped_mouse_motion(m); - } break; + Transform camera_transform; + + camera_transform.translate(cursor.pos); + camera_transform.basis.rotate(Vector3(1, 0, 0), -cursor.x_rot); + camera_transform.basis.rotate(Vector3(0, 1, 0), -cursor.y_rot); + Vector3 translation(-relative.x * pan_speed, relative.y * pan_speed, 0); + translation *= cursor.distance / DISTANCE_DEFAULT; + camera_transform.translate(translation); + cursor.pos = camera_transform.origin; + + } break; + + case NAVIGATION_ZOOM: { + real_t zoom_speed = 1 / 80.0; + int zoom_speed_modifier = 10; + if (nav_scheme == NAVIGATION_MAYA && m->get_shift()) + zoom_speed *= zoom_speed_modifier; + + NavigationZoomStyle zoom_style = (NavigationZoomStyle)EditorSettings::get_singleton()->get("editors/3d/zoom_style").operator int(); + if (zoom_style == NAVIGATION_ZOOM_HORIZONTAL) { + if (m->get_relative().x > 0) + scale_cursor_distance(1 - m->get_relative().x * zoom_speed); + else if (m->get_relative().x < 0) + scale_cursor_distance(1.0 / (1 + m->get_relative().x * zoom_speed)); + } else { + if (m->get_relative().y > 0) + scale_cursor_distance(1 + m->get_relative().y * zoom_speed); + else if (m->get_relative().y < 0) + scale_cursor_distance(1.0 / (1 - m->get_relative().y * zoom_speed)); + } + + } break; + + case NAVIGATION_ORBIT: { + Point2i relative = _get_warped_mouse_motion(m); + cursor.x_rot += relative.y / 80.0; + cursor.y_rot += relative.x / 80.0; + if (cursor.x_rot > Math_PI / 2.0) + cursor.x_rot = Math_PI / 2.0; + if (cursor.x_rot < -Math_PI / 2.0) + cursor.x_rot = -Math_PI / 2.0; + name = ""; + _update_name(); + } break; - case NAVIGATION_ORBIT: { - cursor.x_rot += m.relative_y / 80.0; - cursor.y_rot += m.relative_x / 80.0; + case NAVIGATION_LOOK: { + // Freelook only works properly in perspective. + // It technically works too in ortho, but it's awful for a user due to fov being near zero + if (!orthogonal) { + Point2i relative = _get_warped_mouse_motion(m); + cursor.x_rot += relative.y / 120.0; + cursor.y_rot += relative.x / 120.0; if (cursor.x_rot > Math_PI / 2.0) cursor.x_rot = Math_PI / 2.0; if (cursor.x_rot < -Math_PI / 2.0) cursor.x_rot = -Math_PI / 2.0; + + // Look is like Orbit, except the cursor translates, not the camera + Transform camera_transform = to_camera_transform(cursor); + Vector3 pos = camera_transform.xform(Vector3(0, 0, 0)); + Vector3 diff = camera->get_translation() - pos; + cursor.pos += diff; + name = ""; _update_name(); - } break; + } - default: {} - } - } break; - case InputEvent::KEY: { - const InputEventKey &k = p_event.key; - if (!k.pressed) - break; + } break; - if (ED_IS_SHORTCUT("spatial_editor/snap", p_event)) { - if (_edit.mode != TRANSFORM_NONE) { - _edit.snap = true; - } - } - if (ED_IS_SHORTCUT("spatial_editor/bottom_view", p_event)) { - cursor.y_rot = 0; - cursor.x_rot = -Math_PI / 2.0; - set_message(TTR("Bottom View."), 2); - name = TTR("Bottom"); - _update_name(); - } - if (ED_IS_SHORTCUT("spatial_editor/top_view", p_event)) { - cursor.y_rot = 0; - cursor.x_rot = Math_PI / 2.0; - set_message(TTR("Top View."), 2); - name = TTR("Top"); - _update_name(); - } - if (ED_IS_SHORTCUT("spatial_editor/rear_view", p_event)) { - cursor.x_rot = 0; - cursor.y_rot = Math_PI; - set_message(TTR("Rear View."), 2); - name = TTR("Rear"); - _update_name(); - } - if (ED_IS_SHORTCUT("spatial_editor/front_view", p_event)) { - cursor.x_rot = 0; - cursor.y_rot = 0; - set_message(TTR("Front View."), 2); - name = TTR("Front"); - _update_name(); - } - if (ED_IS_SHORTCUT("spatial_editor/left_view", p_event)) { - cursor.x_rot = 0; - cursor.y_rot = Math_PI / 2.0; - set_message(TTR("Left View."), 2); - name = TTR("Left"); - _update_name(); + default: {} + } + } + + Ref<InputEventKey> k = p_event; + + if (k.is_valid()) { + if (!k->is_pressed()) + return; + + if (ED_IS_SHORTCUT("spatial_editor/snap", p_event)) { + if (_edit.mode != TRANSFORM_NONE) { + _edit.snap = true; } - if (ED_IS_SHORTCUT("spatial_editor/right_view", p_event)) { - cursor.x_rot = 0; - cursor.y_rot = -Math_PI / 2.0; - set_message(TTR("Right View."), 2); - name = TTR("Right"); - _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/bottom_view", p_event)) { + cursor.y_rot = 0; + cursor.x_rot = -Math_PI / 2.0; + set_message(TTR("Bottom View."), 2); + name = TTR("Bottom"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/top_view", p_event)) { + cursor.y_rot = 0; + cursor.x_rot = Math_PI / 2.0; + set_message(TTR("Top View."), 2); + name = TTR("Top"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/rear_view", p_event)) { + cursor.x_rot = 0; + cursor.y_rot = Math_PI; + set_message(TTR("Rear View."), 2); + name = TTR("Rear"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/front_view", p_event)) { + cursor.x_rot = 0; + cursor.y_rot = 0; + set_message(TTR("Front View."), 2); + name = TTR("Front"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/left_view", p_event)) { + cursor.x_rot = 0; + cursor.y_rot = Math_PI / 2.0; + set_message(TTR("Left View."), 2); + name = TTR("Left"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/right_view", p_event)) { + cursor.x_rot = 0; + cursor.y_rot = -Math_PI / 2.0; + set_message(TTR("Right View."), 2); + name = TTR("Right"); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/switch_perspective_orthogonal", p_event)) { + _menu_option(orthogonal ? VIEW_PERSPECTIVE : VIEW_ORTHOGONAL); + _update_name(); + } + if (ED_IS_SHORTCUT("spatial_editor/insert_anim_key", p_event)) { + if (!get_selected_count() || _edit.mode != TRANSFORM_NONE) + return; + + if (!AnimationPlayerEditor::singleton->get_key_editor()->has_keying()) { + set_message(TTR("Keying is disabled (no key inserted).")); + return; } - if (ED_IS_SHORTCUT("spatial_editor/switch_perspective_orthogonal", p_event)) { - _menu_option(orthogonal ? VIEW_PERSPECTIVE : VIEW_ORTHOGONAL); - _update_name(); + + List<Node *> &selection = editor_selection->get_selected_node_list(); + + for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { + + Spatial *sp = E->get()->cast_to<Spatial>(); + if (!sp) + continue; + + emit_signal("transform_key_request", sp, "", sp->get_transform()); } - if (ED_IS_SHORTCUT("spatial_editor/insert_anim_key", p_event)) { - if (!get_selected_count() || _edit.mode != TRANSFORM_NONE) - break; - if (!AnimationPlayerEditor::singleton->get_key_editor()->has_keying()) { - set_message(TTR("Keying is disabled (no key inserted).")); - break; - } + set_message(TTR("Animation Key Inserted.")); + } - List<Node *> &selection = editor_selection->get_selected_node_list(); + if (k->get_scancode() == KEY_SPACE) { + if (!k->is_pressed()) emit_signal("toggle_maximize_view", this); + } + } +} - for (List<Node *>::Element *E = selection.front(); E; E = E->next()) { +void SpatialEditorViewport::scale_cursor_distance(real_t scale) { - Spatial *sp = E->get()->cast_to<Spatial>(); - if (!sp) - continue; + // Prevents zero distance which would short-circuit any scaling + if (cursor.distance < ZOOM_MIN_DISTANCE) + cursor.distance = ZOOM_MIN_DISTANCE; - emit_signal("transform_key_request", sp, "", sp->get_transform()); - } + real_t prev_distance = cursor.distance; + cursor.distance *= scale; - set_message(TTR("Animation Key Inserted.")); - } + if (cursor.distance < ZOOM_MIN_DISTANCE) + cursor.distance = ZOOM_MIN_DISTANCE; - if (k.scancode == KEY_SPACE) { - if (!k.pressed) emit_signal("toggle_maximize_view", this); - } + if (is_freelook_active()) { + // In freelook mode, cursor reference is reversed so it needs to be adjusted + Vector3 forward = camera->get_transform().basis.xform(Vector3(0, 0, -1)); + cursor.pos += (cursor.distance - prev_distance) * forward; + } - } break; + zoom_indicator_delay = ZOOM_INDICATOR_DELAY_S; + surface->update(); +} + +Point2i SpatialEditorViewport::_get_warped_mouse_motion(const Ref<InputEventMouseMotion> &p_ev_mouse_motion) const { + Point2i relative; + if (bool(EditorSettings::get_singleton()->get("editors/3d/warped_mouse_panning"))) { + relative = Input::get_singleton()->warp_mouse_motion(p_ev_mouse_motion, surface->get_global_rect()); + } else { + relative = p_ev_mouse_motion->get_relative(); + } + return relative; +} + +void SpatialEditorViewport::_update_freelook(real_t delta) { + + if (!is_freelook_active()) + return; + + Vector3 forward = camera->get_transform().basis.xform(Vector3(0, 0, -1)); + Vector3 right = camera->get_transform().basis.xform(Vector3(1, 0, 0)); + Vector3 up = camera->get_transform().basis.xform(Vector3(0, 1, 0)); + + int key_left = ED_SHORTCUT("spatial_editor/freelook_left", TTR("Freelook Left"), KEY_A)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_right = ED_SHORTCUT("spatial_editor/freelook_right", TTR("Freelook Right"), KEY_D)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_forward = ED_SHORTCUT("spatial_editor/freelook_forward", TTR("Freelook Forward"), KEY_W)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_backwards = ED_SHORTCUT("spatial_editor/freelook_backwards", TTR("Freelook Backwards"), KEY_S)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_up = ED_SHORTCUT("spatial_editor/freelook_up", TTR("Freelook Up"), KEY_Q)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_down = ED_SHORTCUT("spatial_editor/freelook_down", TTR("Freelook Down"), KEY_E)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + int key_speed_modifier = ED_SHORTCUT("spatial_editor/freelook_speed_modifier", TTR("Freelook Speed Modifier"), KEY_SHIFT)->get_shortcut()->cast_to<InputEventKey>()->get_scancode(); + + Vector3 velocity; + bool pressed = false; + bool speed_modifier = false; + + const Input &input = *Input::get_singleton(); + + if (input.is_key_pressed(key_left)) { + velocity -= right; + pressed = true; + } + if (input.is_key_pressed(key_right)) { + velocity += right; + pressed = true; + } + if (input.is_key_pressed(key_forward)) { + velocity += forward; + pressed = true; + } + if (input.is_key_pressed(key_backwards)) { + velocity -= forward; + pressed = true; + } + if (input.is_key_pressed(key_up)) { + velocity += up; + pressed = true; + } + if (input.is_key_pressed(key_down)) { + velocity -= up; + pressed = true; + } + if (input.is_key_pressed(key_speed_modifier)) { + speed_modifier = true; + } + + if (pressed) { + const EditorSettings &s = *EditorSettings::get_singleton(); + const real_t base_speed = s.get("editors/3d/freelook_base_speed"); + const real_t modifier_speed_factor = s.get("editors/3d/freelook_modifier_speed_factor"); + + real_t speed = base_speed * cursor.distance; + if (speed_modifier) + speed *= modifier_speed_factor; + + velocity.normalize(); + + cursor.pos += velocity * (speed * delta); } } @@ -1579,6 +1647,17 @@ void SpatialEditorViewport::_notification(int p_what) { } */ + real_t delta = get_tree()->get_idle_process_time(); + + if (zoom_indicator_delay > 0) { + zoom_indicator_delay -= delta; + if (zoom_indicator_delay <= 0) { + surface->update(); + } + } + + _update_freelook(delta); + _update_camera(); Map<Node *, Object *> &selection = editor_selection->get_selection(); @@ -1604,7 +1683,7 @@ void SpatialEditorViewport::_notification(int p_what) { } Transform t = sp->get_global_transform(); - t.translate(se->aabb.pos); + t.translate(se->aabb.position); t.basis.scale(se->aabb.size); exist = true; @@ -1652,6 +1731,33 @@ void SpatialEditorViewport::_notification(int p_what) { bool hdr = GlobalConfig::get_singleton()->get("rendering/quality/hdr"); viewport->set_hdr(hdr); + + bool show_info = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(VIEW_INFORMATION)); + if (show_info != info->is_visible()) { + if (show_info) + info->show(); + else + info->hide(); + } + + if (show_info) { + + String text; + text += TTR("Objects Drawn") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_OBJECTS_IN_FRAME)) + "\n"; + text += TTR("Material Changes") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_MATERIAL_CHANGES_IN_FRAME)) + "\n"; + text += TTR("Shader Changes") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_SHADER_CHANGES_IN_FRAME)) + "\n"; + text += TTR("Surface Changes") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_SURFACE_CHANGES_IN_FRAME)) + "\n"; + text += TTR("Draw Calls") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_DRAW_CALLS_IN_FRAME)) + "\n"; + text += TTR("Vertices") + ": " + itos(viewport->get_render_info(Viewport::RENDER_INFO_VERTICES_IN_FRAME)); + + if (info_label->get_text() != text || surface->get_size() != prev_size) { + info_label->set_text(text); + Size2 ms = info->get_minimum_size(); + info->set_position(surface->get_size() - ms - Vector2(20, 20) * EDSCALE); + } + } + + prev_size = surface->get_size(); } if (p_what == NOTIFICATION_ENTER_TREE) { @@ -1659,6 +1765,7 @@ void SpatialEditorViewport::_notification(int p_what) { surface->connect("draw", this, "_draw"); surface->connect("gui_input", this, "_sinput"); surface->connect("mouse_entered", this, "_smouseenter"); + info->add_style_override("panel", get_stylebox("panel", "Panel")); preview_camera->set_icon(get_icon("Camera", "EditorIcons")); _init_gizmo_instance(index); } @@ -1674,12 +1781,29 @@ void SpatialEditorViewport::_notification(int p_what) { } } +// TODO That should be part of the drawing API... +static void stroke_rect(CanvasItem *ci, Rect2 rect, Color color, real_t width = 1.0) { + + // a---b + // | | + // c---d + Vector2 a(rect.position); + Vector2 b(rect.position.x + rect.size.x, rect.position.y); + Vector2 c(rect.position.x, rect.position.y + rect.size.y); + Vector2 d(rect.position + rect.size); + + ci->draw_line(a, b, color, width); + ci->draw_line(b, d, color, width); + ci->draw_line(d, c, color, width); + ci->draw_line(c, a, color, width); +} + void SpatialEditorViewport::_draw() { if (surface->has_focus()) { Size2 size = surface->get_size(); Rect2 r = Rect2(Point2(), size); - get_stylebox("EditorFocus", "EditorStyles")->draw(surface->get_canvas_item(), r); + get_stylebox("Focus", "EditorStyles")->draw(surface->get_canvas_item(), r); } RID ci = surface->get_canvas_item(); @@ -1715,25 +1839,52 @@ void SpatialEditorViewport::_draw() { case Camera::KEEP_WIDTH: { draw_rect.size = Size2(s.width, s.width / aspect); - draw_rect.pos.x = 0; - draw_rect.pos.y = (s.height - draw_rect.size.y) * 0.5; + draw_rect.position.x = 0; + draw_rect.position.y = (s.height - draw_rect.size.y) * 0.5; } break; case Camera::KEEP_HEIGHT: { draw_rect.size = Size2(s.height * aspect, s.height); - draw_rect.pos.y = 0; - draw_rect.pos.x = (s.width - draw_rect.size.x) * 0.5; + draw_rect.position.y = 0; + draw_rect.position.x = (s.width - draw_rect.size.x) * 0.5; } break; } draw_rect = Rect2(Vector2(), s).clip(draw_rect); - surface->draw_line(draw_rect.pos, draw_rect.pos + Vector2(draw_rect.size.x, 0), Color(0.6, 0.6, 0.1, 0.5), 2.0); - surface->draw_line(draw_rect.pos + Vector2(draw_rect.size.x, 0), draw_rect.pos + draw_rect.size, Color(0.6, 0.6, 0.1, 0.5), 2.0); - surface->draw_line(draw_rect.pos + draw_rect.size, draw_rect.pos + Vector2(0, draw_rect.size.y), Color(0.6, 0.6, 0.1, 0.5), 2.0); - surface->draw_line(draw_rect.pos, draw_rect.pos + Vector2(0, draw_rect.size.y), Color(0.6, 0.6, 0.1, 0.5), 2.0); + stroke_rect(surface, draw_rect, Color(0.6, 0.6, 0.1, 0.5), 2.0); + + } else { + + if (zoom_indicator_delay > 0.0) { + // Show indicative zoom factor + + real_t min_distance = ZOOM_MIN_DISTANCE; // TODO Why not pick znear to limit zoom? + real_t max_distance = camera->get_zfar(); + real_t scale_length = (max_distance - min_distance); + + if (Math::abs(scale_length) > CMP_EPSILON) { + real_t logscale_t = 1.0 - Math::log(1 + cursor.distance - min_distance) / Math::log(1 + scale_length); + + // There is no real maximum distance so that factor can become negative, + // Let's make it look asymptotic instead (will decrease slower and slower). + if (logscale_t < 0.25) + logscale_t = 0.25 * Math::exp(4.0 * logscale_t - 1.0); + + Vector2 surface_size = surface->get_size(); + real_t h = surface_size.y / 2.0; + real_t y = (surface_size.y - h) / 2.0; + + Rect2 r(10, y, 6, h); + real_t sy = r.size.y * logscale_t; + + surface->draw_rect(r, Color(1, 1, 1, 0.2)); + surface->draw_rect(Rect2(r.position.x, r.position.y + r.size.y - sy, r.size.x, sy), Color(1, 1, 1, 0.6)); + stroke_rect(surface, r.grow(1), Color(0, 0, 0, 0.7)); + } + } } } @@ -1881,6 +2032,52 @@ void SpatialEditorViewport::_menu_option(int p_option) { view_menu->get_popup()->set_item_checked(idx, current); } break; + case VIEW_INFORMATION: { + + int idx = view_menu->get_popup()->get_item_index(VIEW_INFORMATION); + bool current = view_menu->get_popup()->is_item_checked(idx); + view_menu->get_popup()->set_item_checked(idx, !current); + + } break; + case VIEW_DISPLAY_NORMAL: { + + viewport->set_debug_draw(Viewport::DEBUG_DRAW_DISABLED); + + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL), true); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_WIREFRAME), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_OVERDRAW), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_SHADELESS), false); + + } break; + case VIEW_DISPLAY_WIREFRAME: { + + viewport->set_debug_draw(Viewport::DEBUG_DRAW_WIREFRAME); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_WIREFRAME), true); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_OVERDRAW), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_SHADELESS), false); + + } break; + case VIEW_DISPLAY_OVERDRAW: { + + viewport->set_debug_draw(Viewport::DEBUG_DRAW_OVERDRAW); + VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_OVERDRAW); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_WIREFRAME), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_OVERDRAW), true); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_SHADELESS), false); + + } break; + case VIEW_DISPLAY_SHADELESS: { + + viewport->set_debug_draw(Viewport::DEBUG_DRAW_UNSHADED); + VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_SHADELESS); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_WIREFRAME), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_OVERDRAW), false); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_SHADELESS), true); + + } break; } } @@ -2143,6 +2340,7 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed clicked_includes_current = false; orthogonal = false; message_time = 0; + zoom_indicator_delay = 0.0; spatial_editor = p_spatial_editor; ViewportContainer *c = memnew(ViewportContainer); @@ -2156,6 +2354,7 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed surface = memnew(Control); add_child(surface); surface->set_area_as_parent_rect(); + surface->set_clip_contents(true); camera = memnew(Camera); camera->set_disable_gizmo(true); camera->set_cull_mask(((1 << 20) - 1) | (1 << (GIZMO_BASE_LAYER + p_index)) | (1 << GIZMO_EDIT_LAYER) | (1 << GIZMO_GRID_LAYER)); @@ -2179,12 +2378,18 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed view_menu->get_popup()->add_check_item(TTR("Orthogonal") + " (" + ED_GET_SHORTCUT("spatial_editor/switch_perspective_orthogonal")->get_as_text() + ")", VIEW_ORTHOGONAL); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_PERSPECTIVE), true); view_menu->get_popup()->add_separator(); - view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_environment", TTR("Environment")), VIEW_ENVIRONMENT); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_display_normal", TTR("Display Normal")), VIEW_DISPLAY_NORMAL); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_display_wireframe", TTR("Display Wireframe")), VIEW_DISPLAY_WIREFRAME); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_display_overdraw", TTR("Display Overdraw")), VIEW_DISPLAY_OVERDRAW); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_display_unshaded", TTR("Display Unshaded")), VIEW_DISPLAY_SHADELESS); + view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL), true); + view_menu->get_popup()->add_separator(); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_environment", TTR("View Environment")), VIEW_ENVIRONMENT); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_gizmos", TTR("View Gizmos")), VIEW_GIZMOS); + view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_information", TTR("View Information")), VIEW_INFORMATION); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_ENVIRONMENT), true); view_menu->get_popup()->add_separator(); view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_audio_listener", TTR("Audio Listener")), VIEW_AUDIO_LISTENER); - view_menu->get_popup()->add_separator(); - view_menu->get_popup()->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_gizmos", TTR("Gizmos")), VIEW_GIZMOS); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(VIEW_GIZMOS), true); view_menu->get_popup()->add_separator(); @@ -2205,6 +2410,15 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed preview = NULL; gizmo_scale = 1.0; + info = memnew(PanelContainer); + info->set_self_modulate(Color(1, 1, 1, 0.4)); + surface->add_child(info); + info_label = memnew(Label); + info->add_child(info_label); + info->hide(); + + freelook_active = false; + selection_menu = memnew(PopupMenu); add_child(selection_menu); selection_menu->set_custom_minimum_size(Vector2(100, 0)); @@ -2222,6 +2436,305 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed EditorSettings::get_singleton()->connect("settings_changed", this, "update_transform_gizmo_view"); } +////////////////////////////////////////////////////////////// + +void SpatialEditorViewportContainer::_gui_input(const Ref<InputEvent> &p_event) { + + Ref<InputEventMouseButton> mb = p_event; + + if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) { + + Vector2 size = get_size(); + + int h_sep = get_constant("separation", "HSplitContainer"); + int v_sep = get_constant("separation", "VSplitContainer"); + + int mid_w = size.width * ratio_h; + int mid_h = size.height * ratio_v; + + dragging_h = mb->get_position().x > (mid_w - h_sep / 2) && mb->get_position().x < (mid_w + h_sep / 2); + dragging_v = mb->get_position().y > (mid_h - v_sep / 2) && mb->get_position().y < (mid_h + v_sep / 2); + + drag_begin_pos = mb->get_position(); + drag_begin_ratio.x = ratio_h; + drag_begin_ratio.y = ratio_v; + + switch (view) { + case VIEW_USE_1_VIEWPORT: { + + dragging_h = false; + dragging_v = false; + + } break; + case VIEW_USE_2_VIEWPORTS: { + + dragging_h = false; + + } break; + case VIEW_USE_2_VIEWPORTS_ALT: { + + dragging_v = false; + + } break; + case VIEW_USE_3_VIEWPORTS: { + + if (dragging_v) + dragging_h = false; + else + dragging_v = false; + + } break; + case VIEW_USE_3_VIEWPORTS_ALT: { + + if (dragging_h) + dragging_v = false; + else + dragging_h = false; + } break; + case VIEW_USE_4_VIEWPORTS: { + + } break; + } + } + + if (mb.is_valid() && !mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) { + dragging_h = false; + dragging_v = false; + } + + Ref<InputEventMouseMotion> mm = p_event; + + if (mm.is_valid() && (dragging_h || dragging_v)) { + + if (dragging_h) { + float new_ratio = drag_begin_ratio.x + (mm->get_position().x - drag_begin_pos.x) / get_size().width; + new_ratio = CLAMP(new_ratio, 40 / get_size().width, (get_size().width - 40) / get_size().width); + ratio_h = new_ratio; + queue_sort(); + update(); + } + if (dragging_v) { + float new_ratio = drag_begin_ratio.y + (mm->get_position().y - drag_begin_pos.y) / get_size().height; + new_ratio = CLAMP(new_ratio, 40 / get_size().height, (get_size().height - 40) / get_size().height); + ratio_v = new_ratio; + queue_sort(); + update(); + } + } +} + +void SpatialEditorViewportContainer::_notification(int p_what) { + + if (p_what == NOTIFICATION_MOUSE_ENTER || p_what == NOTIFICATION_MOUSE_EXIT) { + + mouseover = (p_what == NOTIFICATION_MOUSE_ENTER); + update(); + } + + if (p_what == NOTIFICATION_DRAW && mouseover) { + + Ref<Texture> h_grabber = get_icon("grabber", "HSplitContainer"); + + Ref<Texture> v_grabber = get_icon("grabber", "VSplitContainer"); + + Vector2 size = get_size(); + + int h_sep = get_constant("separation", "HSplitContainer"); + + int v_sep = get_constant("separation", "VSplitContainer"); + + int mid_w = size.width * ratio_h; + int mid_h = size.height * ratio_v; + + int size_left = mid_w - h_sep / 2; + int size_bottom = size.height - mid_h - v_sep / 2; + + switch (view) { + + case VIEW_USE_1_VIEWPORT: { + + //nothing to show + + } break; + case VIEW_USE_2_VIEWPORTS: { + + draw_texture(v_grabber, Vector2((size.width - v_grabber->get_width()) / 2, mid_h - v_grabber->get_height() / 2)); + + } break; + case VIEW_USE_2_VIEWPORTS_ALT: { + + draw_texture(h_grabber, Vector2(mid_w - h_grabber->get_width() / 2, (size.height - h_grabber->get_height()) / 2)); + + } break; + case VIEW_USE_3_VIEWPORTS: { + + draw_texture(v_grabber, Vector2((size.width - v_grabber->get_width()) / 2, mid_h - v_grabber->get_height() / 2)); + draw_texture(h_grabber, Vector2(mid_w - h_grabber->get_width() / 2, mid_h + v_grabber->get_height() / 2 + (size_bottom - h_grabber->get_height()) / 2)); + + } break; + case VIEW_USE_3_VIEWPORTS_ALT: { + + draw_texture(v_grabber, Vector2((size_left - v_grabber->get_width()) / 2, mid_h - v_grabber->get_height() / 2)); + draw_texture(h_grabber, Vector2(mid_w - h_grabber->get_width() / 2, (size.height - h_grabber->get_height()) / 2)); + } break; + case VIEW_USE_4_VIEWPORTS: { + + Vector2 half(mid_w, mid_h); + draw_texture(v_grabber, half - v_grabber->get_size() / 2.0); + draw_texture(h_grabber, half - h_grabber->get_size() / 2.0); + + } break; + } + } + + if (p_what == NOTIFICATION_SORT_CHILDREN) { + + SpatialEditorViewport *viewports[4]; + int vc = 0; + for (int i = 0; i < get_child_count(); i++) { + viewports[vc] = get_child(i)->cast_to<SpatialEditorViewport>(); + if (viewports[vc]) { + vc++; + } + } + + ERR_FAIL_COND(vc != 4); + + Size2 size = get_size(); + + if (size.x < 10 || size.y < 10) { + for (int i = 0; i < 4; i++) { + viewports[i]->hide(); + } + return; + } + int h_sep = get_constant("separation", "HSplitContainer"); + + int v_sep = get_constant("separation", "VSplitContainer"); + + int mid_w = size.width * ratio_h; + int mid_h = size.height * ratio_v; + + int size_left = mid_w - h_sep / 2; + int size_right = size.width - mid_w - h_sep / 2; + + int size_top = mid_h - v_sep / 2; + int size_bottom = size.height - mid_h - v_sep / 2; + + switch (view) { + + case VIEW_USE_1_VIEWPORT: { + + for (int i = 1; i < 4; i++) { + + viewports[i]->hide(); + } + + fit_child_in_rect(viewports[0], Rect2(Vector2(), size)); + + } break; + case VIEW_USE_2_VIEWPORTS: { + + for (int i = 1; i < 4; i++) { + + if (i == 1 || i == 3) + viewports[i]->hide(); + else + viewports[i]->show(); + } + + fit_child_in_rect(viewports[0], Rect2(Vector2(), Vector2(size.width, size_top))); + fit_child_in_rect(viewports[2], Rect2(Vector2(0, mid_h + v_sep / 2), Vector2(size.width, size_bottom))); + + } break; + case VIEW_USE_2_VIEWPORTS_ALT: { + + for (int i = 1; i < 4; i++) { + + if (i == 1 || i == 3) + viewports[i]->hide(); + else + viewports[i]->show(); + } + fit_child_in_rect(viewports[0], Rect2(Vector2(), Vector2(size_left, size.height))); + fit_child_in_rect(viewports[2], Rect2(Vector2(mid_w + h_sep / 2, 0), Vector2(size_right, size.height))); + + } break; + case VIEW_USE_3_VIEWPORTS: { + + for (int i = 1; i < 4; i++) { + + if (i == 1) + viewports[i]->hide(); + else + viewports[i]->show(); + } + + fit_child_in_rect(viewports[0], Rect2(Vector2(), Vector2(size.width, size_top))); + fit_child_in_rect(viewports[2], Rect2(Vector2(0, mid_h + v_sep / 2), Vector2(size_left, size_bottom))); + fit_child_in_rect(viewports[3], Rect2(Vector2(mid_w + h_sep / 2, mid_h + v_sep / 2), Vector2(size_right, size_bottom))); + + } break; + case VIEW_USE_3_VIEWPORTS_ALT: { + + for (int i = 1; i < 4; i++) { + + if (i == 1) + viewports[i]->hide(); + else + viewports[i]->show(); + } + + fit_child_in_rect(viewports[0], Rect2(Vector2(), Vector2(size_left, size_top))); + fit_child_in_rect(viewports[2], Rect2(Vector2(0, mid_h + v_sep / 2), Vector2(size_left, size_bottom))); + fit_child_in_rect(viewports[3], Rect2(Vector2(mid_w + h_sep / 2, 0), Vector2(size_right, size.height))); + + } break; + case VIEW_USE_4_VIEWPORTS: { + + for (int i = 1; i < 4; i++) { + + viewports[i]->show(); + } + + fit_child_in_rect(viewports[0], Rect2(Vector2(), Vector2(size_left, size_top))); + fit_child_in_rect(viewports[1], Rect2(Vector2(mid_w + h_sep / 2, 0), Vector2(size_right, size_top))); + fit_child_in_rect(viewports[2], Rect2(Vector2(0, mid_h + v_sep / 2), Vector2(size_left, size_bottom))); + fit_child_in_rect(viewports[3], Rect2(Vector2(mid_w + h_sep / 2, mid_h + v_sep / 2), Vector2(size_right, size_bottom))); + + } break; + } + } +} + +void SpatialEditorViewportContainer::set_view(View p_view) { + + view = p_view; + queue_sort(); +} + +SpatialEditorViewportContainer::View SpatialEditorViewportContainer::get_view() { + + return view; +} + +void SpatialEditorViewportContainer::_bind_methods() { + + ClassDB::bind_method("_gui_input", &SpatialEditorViewportContainer::_gui_input); +} + +SpatialEditorViewportContainer::SpatialEditorViewportContainer() { + + view = VIEW_USE_1_VIEWPORT; + mouseover = false; + ratio_h = 0.5; + ratio_v = 0.5; + dragging_v = false; + dragging_h = false; +} + +/////////////////////////////////////////////////////////////////// + SpatialEditor *SpatialEditor::singleton = NULL; SpatialEditorSelectedItem::~SpatialEditorSelectedItem() { @@ -2260,7 +2773,7 @@ void SpatialEditor::update_transform_gizmo() { Transform xf = se->sp->get_global_transform(); if (first) { - center.pos = xf.origin; + center.position = xf.origin; first = false; if (local_gizmo_coords) { gizmo_basis = xf.basis; @@ -2273,12 +2786,12 @@ void SpatialEditor::update_transform_gizmo() { //count++; } - Vector3 pcenter = center.pos + center.size * 0.5; + Vector3 pcenter = center.position + center.size * 0.5; gizmo.visible = !first; gizmo.transform.origin = pcenter; gizmo.transform.basis = gizmo_basis; - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { viewports[i]->update_transform_gizmo_view(); } } @@ -2374,17 +2887,11 @@ Dictionary SpatialEditor::get_state() const { d["viewports"] = vpdata; - d["default_light"] = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_DEFAULT_LIGHT)); - d["ambient_light_color"] = settings_ambient_color->get_pick_color(); - - d["default_srgb"] = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_DEFAULT_SRGB)); d["show_grid"] = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_GRID)); d["show_origin"] = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_ORIGIN)); d["fov"] = get_fov(); d["znear"] = get_znear(); d["zfar"] = get_zfar(); - d["deflight_rot_x"] = settings_default_light_rot_x; - d["deflight_rot_y"] = settings_default_light_rot_y; return d; } @@ -2434,7 +2941,7 @@ void SpatialEditor::set_state(const Dictionary &p_state) { Array vp = d["viewports"]; ERR_FAIL_COND(vp.size() > 4); - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { viewports[i]->set_state(vp[i]); } } @@ -2446,26 +2953,6 @@ void SpatialEditor::set_state(const Dictionary &p_state) { if (d.has("fov")) settings_fov->set_value(float(d["fov"])); - if (d.has("default_light")) { - bool use = d["default_light"]; - - bool existing = light_instance.is_valid(); - if (use != existing) { - if (existing) { - VisualServer::get_singleton()->free(light_instance); - light_instance = RID(); - } else { - light_instance = VisualServer::get_singleton()->instance_create2(light, get_tree()->get_root()->get_world()->get_scenario()); - VisualServer::get_singleton()->instance_set_transform(light_instance, light_transform); - } - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_DEFAULT_LIGHT), light_instance.is_valid()); - } - } - if (d.has("ambient_light_color")) { - settings_ambient_color->set_pick_color(d["ambient_light_color"]); - //viewport_environment->fx_set_param(Environment::FX_PARAM_AMBIENT_LIGHT_COLOR,d["ambient_light_color"]); - } - if (d.has("default_srgb")) { bool use = d["default_srgb"]; @@ -2488,13 +2975,6 @@ void SpatialEditor::set_state(const Dictionary &p_state) { VisualServer::get_singleton()->instance_set_visible(origin_instance, use); } } - - if (d.has("deflight_rot_x")) - settings_default_light_rot_x = d["deflight_rot_x"]; - if (d.has("deflight_rot_y")) - settings_default_light_rot_y = d["deflight_rot_y"]; - - _update_default_light_angle(); } void SpatialEditor::edit(Spatial *p_spatial) { @@ -2631,46 +3111,9 @@ void SpatialEditor::_menu_item_pressed(int p_option) { xform_dialog->popup_centered(Size2(200, 200)); } break; - case MENU_VIEW_USE_DEFAULT_LIGHT: { - - bool is_checked = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(p_option)); - - if (is_checked) { - VisualServer::get_singleton()->free(light_instance); - light_instance = RID(); - } else { - light_instance = VisualServer::get_singleton()->instance_create2(light, get_tree()->get_root()->get_world()->get_scenario()); - VisualServer::get_singleton()->instance_set_transform(light_instance, light_transform); - - _update_default_light_angle(); - } - - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(p_option), light_instance.is_valid()); - - } break; - case MENU_VIEW_USE_DEFAULT_SRGB: { - - bool is_checked = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(p_option)); - - if (is_checked) { - //viewport_environment->set_enable_fx(Environment::FX_SRGB,false); - } else { - //viewport_environment->set_enable_fx(Environment::FX_SRGB,true); - } - - is_checked = !is_checked; - - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(p_option), is_checked); - - } break; case MENU_VIEW_USE_1_VIEWPORT: { - for (int i = 1; i < 4; i++) { - - viewports[i]->hide(); - } - - viewports[0]->set_area_as_parent_rect(); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_1_VIEWPORT); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), true); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), false); @@ -2682,17 +3125,7 @@ void SpatialEditor::_menu_item_pressed(int p_option) { } break; case MENU_VIEW_USE_2_VIEWPORTS: { - for (int i = 1; i < 4; i++) { - - if (i == 1 || i == 3) - viewports[i]->hide(); - else - viewports[i]->show(); - } - viewports[0]->set_area_as_parent_rect(); - //viewports[0]->set_anchor_and_margin(MARGIN_BOTTOM,ANCHOR_RATIO,0.5); - viewports[2]->set_area_as_parent_rect(); - //viewports[2]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_2_VIEWPORTS); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), false); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), true); @@ -2704,17 +3137,7 @@ void SpatialEditor::_menu_item_pressed(int p_option) { } break; case MENU_VIEW_USE_2_VIEWPORTS_ALT: { - for (int i = 1; i < 4; i++) { - - if (i == 1 || i == 3) - viewports[i]->hide(); - else - viewports[i]->show(); - } - viewports[0]->set_area_as_parent_rect(); - //viewports[0]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - viewports[2]->set_area_as_parent_rect(); - //viewports[2]->set_anchor_and_margin(MARGIN_LEFT,ANCHOR_RATIO,0.5); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_2_VIEWPORTS_ALT); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), false); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), false); @@ -2726,21 +3149,7 @@ void SpatialEditor::_menu_item_pressed(int p_option) { } break; case MENU_VIEW_USE_3_VIEWPORTS: { - for (int i = 1; i < 4; i++) { - - if (i == 1) - viewports[i]->hide(); - else - viewports[i]->show(); - } - viewports[0]->set_area_as_parent_rect(); - //viewports[0]->set_anchor_and_margin(MARGIN_BOTTOM,ANCHOR_RATIO,0.5); - viewports[2]->set_area_as_parent_rect(); - //viewports[2]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - //viewports[2]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); - viewports[3]->set_area_as_parent_rect(); - //viewports[3]->set_anchor_and_margin(MARGIN_LEFT,ANCHOR_RATIO,0.5); - //viewports[3]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_3_VIEWPORTS); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), false); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), false); @@ -2752,21 +3161,7 @@ void SpatialEditor::_menu_item_pressed(int p_option) { } break; case MENU_VIEW_USE_3_VIEWPORTS_ALT: { - for (int i = 1; i < 4; i++) { - - if (i == 1) - viewports[i]->hide(); - else - viewports[i]->show(); - } - viewports[0]->set_area_as_parent_rect(); - //viewports[0]->set_anchor_and_margin(MARGIN_BOTTOM,ANCHOR_RATIO,0.5); - //viewports[0]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - viewports[2]->set_area_as_parent_rect(); - //viewports[2]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); - //viewports[2]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - viewports[3]->set_area_as_parent_rect(); - //viewports[3]->set_anchor_and_margin(MARGIN_LEFT,ANCHOR_RATIO,0.5); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_3_VIEWPORTS_ALT); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), false); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), false); @@ -2778,22 +3173,7 @@ void SpatialEditor::_menu_item_pressed(int p_option) { } break; case MENU_VIEW_USE_4_VIEWPORTS: { - for (int i = 1; i < 4; i++) { - - viewports[i]->show(); - } - viewports[0]->set_area_as_parent_rect(); - //viewports[0]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - //viewports[0]->set_anchor_and_margin(MARGIN_BOTTOM,ANCHOR_RATIO,0.5); - viewports[1]->set_area_as_parent_rect(); - //viewports[1]->set_anchor_and_margin(MARGIN_LEFT,ANCHOR_RATIO,0.5); - //viewports[1]->set_anchor_and_margin(MARGIN_BOTTOM,ANCHOR_RATIO,0.5); - viewports[2]->set_area_as_parent_rect(); - //viewports[2]->set_anchor_and_margin(MARGIN_RIGHT,ANCHOR_RATIO,0.5); - //viewports[2]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); - viewports[3]->set_area_as_parent_rect(); - //viewports[3]->set_anchor_and_margin(MARGIN_LEFT,ANCHOR_RATIO,0.5); - //viewports[3]->set_anchor_and_margin(MARGIN_TOP,ANCHOR_RATIO,0.5); + viewport_base->set_view(SpatialEditorViewportContainer::VIEW_USE_4_VIEWPORTS); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), false); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), false); @@ -2803,43 +3183,6 @@ void SpatialEditor::_menu_item_pressed(int p_option) { view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_3_VIEWPORTS_ALT), false); } break; - case MENU_VIEW_DISPLAY_NORMAL: { - - VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_DISABLED); - - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_NORMAL), true); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_WIREFRAME), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_OVERDRAW), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_SHADELESS), false); - - } break; - case MENU_VIEW_DISPLAY_WIREFRAME: { - - VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_WIREFRAME); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_NORMAL), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_WIREFRAME), true); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_OVERDRAW), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_SHADELESS), false); - - } break; - case MENU_VIEW_DISPLAY_OVERDRAW: { - - VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_OVERDRAW); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_NORMAL), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_WIREFRAME), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_OVERDRAW), true); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_SHADELESS), false); - - } break; - case MENU_VIEW_DISPLAY_SHADELESS: { - - VisualServer::get_singleton()->scenario_set_debug(get_tree()->get_root()->get_world()->get_scenario(), VisualServer::SCENARIO_DEBUG_SHADELESS); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_NORMAL), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_WIREFRAME), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_OVERDRAW), false); - view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_SHADELESS), true); - - } break; case MENU_VIEW_ORIGIN: { bool is_checked = view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(p_option)); @@ -2874,14 +3217,6 @@ void SpatialEditor::_menu_item_pressed(int p_option) { void SpatialEditor::_init_indicators() { - //make sure that the camera indicator is not selectable - light = VisualServer::get_singleton()->light_create(VisualServer::LIGHT_DIRECTIONAL); - //VisualServer::get_singleton()->light_set_shadow( light, true ); - light_instance = VisualServer::get_singleton()->instance_create2(light, get_tree()->get_root()->get_world()->get_scenario()); - - light_transform.rotate(Vector3(1, 0, 0), -Math_PI / 5.0); - VisualServer::get_singleton()->instance_set_transform(light_instance, light_transform); - //RID mat = VisualServer::get_singleton()->fixed_material_create(); ///VisualServer::get_singleton()->fixed_material_set_flag(mat, VisualServer::FIXED_MATERIAL_FLAG_USE_ALPHA,true); //VisualServer::get_singleton()->fixed_material_set_flag(mat, VisualServer::FIXED_MATERIAL_FLAG_USE_COLOR_ARRAY,true); @@ -3009,8 +3344,8 @@ void SpatialEditor::_init_indicators() { for (int i = 0; i < 3; i++) { - move_gizmo[i] = Ref<Mesh>(memnew(Mesh)); - rotate_gizmo[i] = Ref<Mesh>(memnew(Mesh)); + move_gizmo[i] = Ref<ArrayMesh>(memnew(ArrayMesh)); + rotate_gizmo[i] = Ref<ArrayMesh>(memnew(ArrayMesh)); Ref<SpatialMaterial> mat = memnew(SpatialMaterial); mat->set_flag(SpatialMaterial::FLAG_UNSHADED, true); @@ -3139,8 +3474,6 @@ void SpatialEditor::_finish_indicators() { VisualServer::get_singleton()->free(grid_instance[i]); VisualServer::get_singleton()->free(grid[i]); } - VisualServer::get_singleton()->free(light_instance); - VisualServer::get_singleton()->free(light); //VisualServer::get_singleton()->free(poly); //VisualServer::get_singleton()->free(indicators_instance); //VisualServer::get_singleton()->free(indicators); @@ -3149,37 +3482,15 @@ void SpatialEditor::_finish_indicators() { VisualServer::get_singleton()->free(cursor_mesh); } -void SpatialEditor::_instance_scene() { -#if 0 - EditorNode *en = get_scene()->get_root_node()->cast_to<EditorNode>(); - ERR_FAIL_COND(!en); - String path = en->get_filesystem_dock()->get_selected_path(); - if (path=="") { - set_message(TTR("No scene selected to instance!")); - return; - } - - undo_redo->create_action(TTR("Instance at Cursor")); - - Node* scene = en->request_instance_scene(path); - - if (!scene) { - set_message(TTR("Could not instance scene!")); - undo_redo->commit_action(); //bleh - return; - } - - Spatial *s = scene->cast_to<Spatial>(); - if (s) { - - undo_redo->add_do_method(s,"set_global_transform",Transform(Matrix3(),cursor.cursor_pos)); +bool SpatialEditor::is_any_freelook_active() const { + for (unsigned int i = 0; i < VIEWPORTS_COUNT; ++i) { + if (viewports[i]->is_freelook_active()) + return true; } - - undo_redo->commit_action(); -#endif + return false; } -void SpatialEditor::_unhandled_key_input(InputEvent p_event) { +void SpatialEditor::_unhandled_key_input(Ref<InputEvent> p_event) { if (!is_visible_in_tree() || get_viewport()->gui_has_modal_stack()) return; @@ -3199,38 +3510,28 @@ void SpatialEditor::_unhandled_key_input(InputEvent p_event) { } #endif - switch (p_event.type) { - - case InputEvent::KEY: { + Ref<InputEventKey> k = p_event; - const InputEventKey &k = p_event.key; + if (k.is_valid()) { - if (!k.pressed) - break; + // Note: need to check is_echo because first person movement keys might still be held + if (!is_any_freelook_active() && !p_event->is_echo()) { - switch (k.scancode) { + if (!k->is_pressed()) + return; - case KEY_Q: _menu_item_pressed(MENU_TOOL_SELECT); break; - case KEY_W: _menu_item_pressed(MENU_TOOL_MOVE); break; - case KEY_E: _menu_item_pressed(MENU_TOOL_ROTATE); break; - case KEY_R: _menu_item_pressed(MENU_TOOL_SCALE); break; + if (ED_IS_SHORTCUT("spatial_editor/tool_select", p_event)) + _menu_item_pressed(MENU_TOOL_SELECT); - case KEY_Z: { - if (k.mod.shift || k.mod.control || k.mod.command) - break; + else if (ED_IS_SHORTCUT("spatial_editor/tool_move", p_event)) + _menu_item_pressed(MENU_TOOL_MOVE); - if (view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_DISPLAY_WIREFRAME))) { - _menu_item_pressed(MENU_VIEW_DISPLAY_NORMAL); - } else { - _menu_item_pressed(MENU_VIEW_DISPLAY_WIREFRAME); - } - } break; + else if (ED_IS_SHORTCUT("spatial_editor/tool_rotate", p_event)) + _menu_item_pressed(MENU_TOOL_ROTATE); -#if 0 -#endif - } - - } break; + else if (ED_IS_SHORTCUT("spatial_editor/tool_scale", p_event)) + _menu_item_pressed(MENU_TOOL_SCALE); + } } } void SpatialEditor::_notification(int p_what) { @@ -3242,8 +3543,6 @@ void SpatialEditor::_notification(int p_what) { tool_button[SpatialEditor::TOOL_MODE_ROTATE]->set_icon(get_icon("ToolRotate", "EditorIcons")); tool_button[SpatialEditor::TOOL_MODE_SCALE]->set_icon(get_icon("ToolScale", "EditorIcons")); tool_button[SpatialEditor::TOOL_MODE_LIST_SELECT]->set_icon(get_icon("ListSelect", "EditorIcons")); - instance_button->set_icon(get_icon("SpatialAdd", "EditorIcons")); - instance_button->hide(); view_menu->get_popup()->set_item_icon(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT), get_icon("Panels1", "EditorIcons")); view_menu->get_popup()->set_item_icon(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_2_VIEWPORTS), get_icon("Panels2", "EditorIcons")); @@ -3255,14 +3554,12 @@ void SpatialEditor::_notification(int p_what) { _menu_item_pressed(MENU_VIEW_USE_1_VIEWPORT); get_tree()->connect("node_removed", this, "_node_removed"); - VS::get_singleton()->scenario_set_fallback_environment(get_viewport()->find_world()->get_scenario(), viewport_environment->get_rid()); } if (p_what == NOTIFICATION_ENTER_TREE) { gizmos = memnew(SpatialEditorGizmos); _init_indicators(); - _update_default_light_angle(); } if (p_what == NOTIFICATION_EXIT_TREE) { @@ -3344,7 +3641,7 @@ void SpatialEditor::_toggle_maximize_view(Object *p_viewport) { if (!maximized) { - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { if (i == index) viewports[i]->set_area_as_parent_rect(); else @@ -3352,7 +3649,7 @@ void SpatialEditor::_toggle_maximize_view(Object *p_viewport) { } } else { - for (int i = 0; i < 4; i++) + for (int i = 0; i < VIEWPORTS_COUNT; i++) viewports[i]->show(); if (view_menu->get_popup()->is_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_USE_1_VIEWPORT))) @@ -3383,11 +3680,8 @@ void SpatialEditor::_bind_methods() { ClassDB::bind_method("_node_removed", &SpatialEditor::_node_removed); ClassDB::bind_method("_menu_item_pressed", &SpatialEditor::_menu_item_pressed); ClassDB::bind_method("_xform_dialog_action", &SpatialEditor::_xform_dialog_action); - ClassDB::bind_method("_instance_scene", &SpatialEditor::_instance_scene); ClassDB::bind_method("_get_editor_data", &SpatialEditor::_get_editor_data); ClassDB::bind_method("_request_gizmo", &SpatialEditor::_request_gizmo); - ClassDB::bind_method("_default_light_angle_input", &SpatialEditor::_default_light_angle_input); - ClassDB::bind_method("_update_ambient_light_color", &SpatialEditor::_update_ambient_light_color); ClassDB::bind_method("_toggle_maximize_view", &SpatialEditor::_toggle_maximize_view); ADD_SIGNAL(MethodInfo("transform_key_request")); @@ -3395,17 +3689,14 @@ void SpatialEditor::_bind_methods() { void SpatialEditor::clear() { - settings_fov->set_value(EDITOR_DEF("editors/3d/default_fov", 60.0)); + settings_fov->set_value(EDITOR_DEF("editors/3d/default_fov", 55.0)); settings_znear->set_value(EDITOR_DEF("editors/3d/default_z_near", 0.1)); settings_zfar->set_value(EDITOR_DEF("editors/3d/default_z_far", 1500.0)); - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { viewports[i]->reset(); } - _menu_item_pressed(MENU_VIEW_USE_1_VIEWPORT); - _menu_item_pressed(MENU_VIEW_DISPLAY_NORMAL); - VisualServer::get_singleton()->instance_set_visible(origin_instance, true); view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_ORIGIN), true); for (int i = 0; i < 3; ++i) { @@ -3415,49 +3706,13 @@ void SpatialEditor::clear() { } } - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { viewports[i]->view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(SpatialEditorViewport::VIEW_AUDIO_LISTENER), i == 0); viewports[i]->viewport->set_as_audio_listener(i == 0); } view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_GRID), true); - - settings_default_light_rot_x = Math_PI * 0.3; - settings_default_light_rot_y = Math_PI * 0.2; - - //viewport_environment->fx_set_param(Environment::FX_PARAM_AMBIENT_LIGHT_COLOR,Color(0.15,0.15,0.15)); - settings_ambient_color->set_pick_color(Color(0.15, 0.15, 0.15)); - if (!light_instance.is_valid()) - _menu_item_pressed(MENU_VIEW_USE_DEFAULT_LIGHT); - - _update_default_light_angle(); -} - -void SpatialEditor::_update_ambient_light_color(const Color &p_color) { - - //viewport_environment->fx_set_param(Environment::FX_PARAM_AMBIENT_LIGHT_COLOR,settings_ambient_color->get_color()); -} - -void SpatialEditor::_update_default_light_angle() { - - Transform t; - t.basis.rotate(Vector3(1, 0, 0), -settings_default_light_rot_x); - t.basis.rotate(Vector3(0, 1, 0), -settings_default_light_rot_y); - settings_dlight->set_transform(t); - if (light_instance.is_valid()) { - VS::get_singleton()->instance_set_transform(light_instance, t); - } -} - -void SpatialEditor::_default_light_angle_input(const InputEvent &p_event) { - - if (p_event.type == InputEvent::MOUSE_MOTION && p_event.mouse_motion.button_mask & (0x1 | 0x2 | 0x4)) { - - settings_default_light_rot_y = Math::fposmod(settings_default_light_rot_y - p_event.mouse_motion.relative_x * 0.01, Math_PI * 2.0); - settings_default_light_rot_x = Math::fposmod(settings_default_light_rot_x - p_event.mouse_motion.relative_y * 0.01, Math_PI * 2.0); - _update_default_light_angle(); - } } SpatialEditor::SpatialEditor(EditorNode *p_editor) { @@ -3520,12 +3775,6 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { tool_button[TOOL_MODE_SCALE]->connect("pressed", this, "_menu_item_pressed", button_binds); tool_button[TOOL_MODE_SCALE]->set_tooltip(TTR("Scale Mode (R)")); - instance_button = memnew(Button); - hbc_menu->add_child(instance_button); - instance_button->set_flat(true); - instance_button->connect("pressed", this, "_instance_scene"); - instance_button->hide(); - VSeparator *vs = memnew(VSeparator); hbc_menu->add_child(vs); @@ -3553,6 +3802,13 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { ED_SHORTCUT("spatial_editor/focus_selection", TTR("Focus Selection"), KEY_F); ED_SHORTCUT("spatial_editor/align_selection_with_view", TTR("Align Selection With View"), KEY_MASK_ALT + KEY_MASK_CMD + KEY_F); + ED_SHORTCUT("spatial_editor/tool_select", TTR("Tool Select"), KEY_Q); + ED_SHORTCUT("spatial_editor/tool_move", TTR("Tool Move"), KEY_W); + ED_SHORTCUT("spatial_editor/tool_rotate", TTR("Tool Rotate"), KEY_E); + ED_SHORTCUT("spatial_editor/tool_scale", TTR("Tool Scale"), KEY_R); + + ED_SHORTCUT("spatial_editor/display_wireframe", TTR("Display Wireframe"), KEY_Z); + PopupMenu *p; transform_menu = memnew(MenuButton); @@ -3577,10 +3833,6 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { p = view_menu->get_popup(); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/use_default_light", TTR("Use Default Light")), MENU_VIEW_USE_DEFAULT_LIGHT); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/use_default_srgb", TTR("Use Default sRGB")), MENU_VIEW_USE_DEFAULT_SRGB); - p->add_separator(); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/1_viewport", TTR("1 Viewport"), KEY_MASK_CMD + KEY_1), MENU_VIEW_USE_1_VIEWPORT); p->add_check_shortcut(ED_SHORTCUT("spatial_editor/2_viewports", TTR("2 Viewports"), KEY_MASK_CMD + KEY_2), MENU_VIEW_USE_2_VIEWPORTS); p->add_check_shortcut(ED_SHORTCUT("spatial_editor/2_viewports_alt", TTR("2 Viewports (Alt)"), KEY_MASK_ALT + KEY_MASK_CMD + KEY_2), MENU_VIEW_USE_2_VIEWPORTS_ALT); @@ -3589,18 +3841,11 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { p->add_check_shortcut(ED_SHORTCUT("spatial_editor/4_viewports", TTR("4 Viewports"), KEY_MASK_CMD + KEY_4), MENU_VIEW_USE_4_VIEWPORTS); p->add_separator(); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/display_normal", TTR("Display Normal")), MENU_VIEW_DISPLAY_NORMAL); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/display_wireframe", TTR("Display Wireframe")), MENU_VIEW_DISPLAY_WIREFRAME); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/display_overdraw", TTR("Display Overdraw")), MENU_VIEW_DISPLAY_OVERDRAW); - p->add_check_shortcut(ED_SHORTCUT("spatial_editor/display_shadeless", TTR("Display Shadeless")), MENU_VIEW_DISPLAY_SHADELESS); - p->add_separator(); p->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_origin", TTR("View Origin")), MENU_VIEW_ORIGIN); p->add_check_shortcut(ED_SHORTCUT("spatial_editor/view_grid", TTR("View Grid")), MENU_VIEW_GRID); p->add_separator(); p->add_shortcut(ED_SHORTCUT("spatial_editor/settings", TTR("Settings")), MENU_VIEW_CAMERA_SETTINGS); - p->set_item_checked(p->get_item_index(MENU_VIEW_USE_DEFAULT_LIGHT), true); - p->set_item_checked(p->get_item_index(MENU_VIEW_DISPLAY_NORMAL), true); p->set_item_checked(p->get_item_index(MENU_VIEW_ORIGIN), true); p->set_item_checked(p->get_item_index(MENU_VIEW_GRID), true); @@ -3615,10 +3860,10 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { shader_split = memnew(VSplitContainer); shader_split->set_h_size_flags(SIZE_EXPAND_FILL); palette_split->add_child(shader_split); - viewport_base = memnew(Control); + viewport_base = memnew(SpatialEditorViewportContainer); shader_split->add_child(viewport_base); viewport_base->set_v_size_flags(SIZE_EXPAND_FILL); - for (int i = 0; i < 4; i++) { + for (int i = 0; i < VIEWPORTS_COUNT; i++) { viewports[i] = memnew(SpatialEditorViewport(this, editor, i)); viewports[i]->connect("toggle_maximize_view", this, "_toggle_maximize_view"); @@ -3658,41 +3903,11 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) { settings_dialog->add_child(settings_vbc); //settings_dialog->set_child_rect(settings_vbc); - settings_light_base = memnew(ViewportContainer); - settings_light_base->set_custom_minimum_size(Size2(128, 128)); - settings_light_base->connect("gui_input", this, "_default_light_angle_input"); - settings_vbc->add_margin_child(TTR("Default Light Normal:"), settings_light_base); - settings_light_vp = memnew(Viewport); - settings_light_vp->set_disable_input(true); - settings_light_vp->set_use_own_world(true); - settings_light_base->add_child(settings_light_vp); - - settings_dlight = memnew(DirectionalLight); - settings_light_vp->add_child(settings_dlight); - settings_sphere = memnew(ImmediateGeometry); - settings_sphere->begin(Mesh::PRIMITIVE_TRIANGLES, Ref<Texture>()); - settings_sphere->set_color(Color(1, 1, 1)); - settings_sphere->add_sphere(32, 16, 1); - settings_sphere->end(); - settings_light_vp->add_child(settings_sphere); - settings_camera = memnew(Camera); - settings_light_vp->add_child(settings_camera); - settings_camera->set_translation(Vector3(0, 0, 2)); - settings_camera->set_orthogonal(2.1, 0.1, 5); - - settings_default_light_rot_x = Math_PI * 0.3; - settings_default_light_rot_y = Math_PI * 0.2; - - settings_ambient_color = memnew(ColorPickerButton); - settings_vbc->add_margin_child(TTR("Ambient Light Color:"), settings_ambient_color); - settings_ambient_color->connect("color_changed", this, "_update_ambient_light_color"); - settings_ambient_color->set_pick_color(Color(0.15, 0.15, 0.15)); - settings_fov = memnew(SpinBox); settings_fov->set_max(179); settings_fov->set_min(1); settings_fov->set_step(0.01); - settings_fov->set_value(EDITOR_DEF("editors/3d/default_fov", 60.0)); + settings_fov->set_value(EDITOR_DEF("editors/3d/default_fov", 55.0)); settings_vbc->add_margin_child(TTR("Perspective FOV (deg.):"), settings_fov); settings_znear = memnew(SpinBox); diff --git a/editor/plugins/spatial_editor_plugin.h b/editor/plugins/spatial_editor_plugin.h index 4302927426..6b05a8b370 100644 --- a/editor/plugins/spatial_editor_plugin.h +++ b/editor/plugins/spatial_editor_plugin.h @@ -84,6 +84,11 @@ class SpatialEditorViewport : public Control { VIEW_ORTHOGONAL, VIEW_AUDIO_LISTENER, VIEW_GIZMOS, + VIEW_INFORMATION, + VIEW_DISPLAY_NORMAL, + VIEW_DISPLAY_WIREFRAME, + VIEW_DISPLAY_OVERDRAW, + VIEW_DISPLAY_SHADELESS, }; public: @@ -114,6 +119,11 @@ private: bool orthogonal; float gizmo_scale; + bool freelook_active; + + PanelContainer *info; + Label *info_label; + struct _RayResult { Spatial *item; @@ -140,7 +150,7 @@ private: Vector3 _get_screen_to_space(const Vector3 &p_vector3); void _select_region(); - bool _gizmo_select(const Vector2 &p_screenpos, bool p_hilite_only = false); + bool _gizmo_select(const Vector2 &p_screenpos, bool p_highlight_only = false); float get_znear() const; float get_zfar() const; @@ -168,7 +178,8 @@ private: NAVIGATION_NONE, NAVIGATION_PAN, NAVIGATION_ZOOM, - NAVIGATION_ORBIT + NAVIGATION_ORBIT, + NAVIGATION_LOOK }; enum TransformMode { TRANSFORM_NONE, @@ -203,8 +214,6 @@ private: struct Cursor { - Vector3 cursor_pos; - Vector3 pos; float x_rot, y_rot, distance; bool region_select; @@ -217,6 +226,10 @@ private: } } cursor; + void scale_cursor_distance(real_t scale); + + real_t zoom_indicator_delay; + RID move_gizmo_instance[3], rotate_gizmo_instance[3]; String last_message; @@ -227,10 +240,12 @@ private: // void _update_camera(); + Transform to_camera_transform(const Cursor &p_cursor) const; void _draw(); void _smouseenter(); - void _sinput(const InputEvent &p_ie); + void _sinput(const Ref<InputEvent> &p_ie); + void _update_freelook(real_t delta); SpatialEditor *spatial_editor; Camera *previewing; @@ -242,7 +257,8 @@ private: void _finish_gizmo_instances(); void _selection_result_pressed(int); void _selection_menu_hide(); - void _list_select(InputEventMouseButton b); + void _list_select(Ref<InputEventMouseButton> b); + Point2i _get_warped_mouse_motion(const Ref<InputEventMouseMotion> &p_ev_mouse_motion) const; protected: void _notification(int p_what); @@ -255,6 +271,7 @@ public: void set_state(const Dictionary &p_state); Dictionary get_state() const; void reset(); + bool is_freelook_active() const { return freelook_active; } void focus_selection(); @@ -278,6 +295,43 @@ public: ~SpatialEditorSelectedItem(); }; +class SpatialEditorViewportContainer : public Container { + + GDCLASS(SpatialEditorViewportContainer, Container) +public: + enum View { + VIEW_USE_1_VIEWPORT, + VIEW_USE_2_VIEWPORTS, + VIEW_USE_2_VIEWPORTS_ALT, + VIEW_USE_3_VIEWPORTS, + VIEW_USE_3_VIEWPORTS_ALT, + VIEW_USE_4_VIEWPORTS, + }; + +private: + View view; + bool mouseover; + float ratio_h; + float ratio_v; + + bool dragging_v; + bool dragging_h; + Vector2 drag_begin_pos; + Vector2 drag_begin_ratio; + + void _gui_input(const Ref<InputEvent> &p_event); + +protected: + void _notification(int p_what); + static void _bind_methods(); + +public: + void set_view(View p_view); + View get_view(); + + SpatialEditorViewportContainer(); +}; + class SpatialEditor : public VBoxContainer { GDCLASS(SpatialEditor, VBoxContainer); @@ -295,11 +349,13 @@ public: }; private: + static const unsigned int VIEWPORTS_COUNT = 4; + EditorNode *editor; EditorSelection *editor_selection; - Control *viewport_base; - SpatialEditorViewport *viewports[4]; + SpatialEditorViewportContainer *viewport_base; + SpatialEditorViewport *viewports[VIEWPORTS_COUNT]; VSplitContainer *shader_split; HSplitContainer *palette_split; @@ -310,10 +366,6 @@ private: VisualServer::ScenarioDebugMode scenario_debug; - RID light; - RID light_instance; - Transform light_transform; - RID origin; RID origin_instance; RID grid[3]; @@ -323,13 +375,13 @@ private: bool grid_enable[3]; //should be always visible if true bool grid_enabled; - Ref<Mesh> move_gizmo[3], rotate_gizmo[3]; + Ref<ArrayMesh> move_gizmo[3], rotate_gizmo[3]; Ref<SpatialMaterial> gizmo_color[3]; Ref<SpatialMaterial> gizmo_hl; int over_gizmo_handle; - Ref<Mesh> selection_box; + Ref<ArrayMesh> selection_box; RID indicators; RID indicators_instance; RID cursor_mesh; @@ -372,12 +424,6 @@ private: MENU_VIEW_USE_3_VIEWPORTS, MENU_VIEW_USE_3_VIEWPORTS_ALT, MENU_VIEW_USE_4_VIEWPORTS, - MENU_VIEW_USE_DEFAULT_LIGHT, - MENU_VIEW_USE_DEFAULT_SRGB, - MENU_VIEW_DISPLAY_NORMAL, - MENU_VIEW_DISPLAY_WIREFRAME, - MENU_VIEW_DISPLAY_OVERDRAW, - MENU_VIEW_DISPLAY_SHADELESS, MENU_VIEW_ORIGIN, MENU_VIEW_GRID, MENU_VIEW_CAMERA_SETTINGS, @@ -385,7 +431,6 @@ private: }; Button *tool_button[TOOL_MAX]; - Button *instance_button; MenuButton *transform_menu; MenuButton *view_menu; @@ -409,16 +454,6 @@ private: SpinBox *settings_fov; SpinBox *settings_znear; SpinBox *settings_zfar; - DirectionalLight *settings_dlight; - ImmediateGeometry *settings_sphere; - Camera *settings_camera; - float settings_default_light_rot_x; - float settings_default_light_rot_y; - - ViewportContainer *settings_light_base; - Viewport *settings_light_vp; - ColorPickerButton *settings_ambient_color; - Image settings_light_dir_image; void _xform_dialog_action(); void _menu_item_pressed(int p_option); @@ -452,14 +487,12 @@ private: SpatialEditorGizmos *gizmos; SpatialEditor(); - void _update_ambient_light_color(const Color &p_color); - void _update_default_light_angle(); - void _default_light_angle_input(const InputEvent &p_event); + bool is_any_freelook_active() const; protected: void _notification(int p_what); //void _gui_input(InputEvent p_event); - void _unhandled_key_input(InputEvent p_event); + void _unhandled_key_input(Ref<InputEvent> p_event); static void _bind_methods(); @@ -480,8 +513,8 @@ public: float get_rotate_snap() const { return snap_rotate->get_text().to_double(); } float get_scale_snap() const { return snap_scale->get_text().to_double(); } - Ref<Mesh> get_move_gizmo(int idx) const { return move_gizmo[idx]; } - Ref<Mesh> get_rotate_gizmo(int idx) const { return rotate_gizmo[idx]; } + Ref<ArrayMesh> get_move_gizmo(int idx) const { return move_gizmo[idx]; } + Ref<ArrayMesh> get_rotate_gizmo(int idx) const { return rotate_gizmo[idx]; } void update_transform_gizmo(); diff --git a/editor/plugins/sprite_frames_editor_plugin.cpp b/editor/plugins/sprite_frames_editor_plugin.cpp index c7c77fa960..d06c065f4f 100644 --- a/editor/plugins/sprite_frames_editor_plugin.cpp +++ b/editor/plugins/sprite_frames_editor_plugin.cpp @@ -34,7 +34,7 @@ #include "io/resource_loader.h" #include "scene/3d/sprite_3d.h" -void SpriteFramesEditor::_gui_input(InputEvent p_event) { +void SpriteFramesEditor::_gui_input(Ref<InputEvent> p_event) { } void SpriteFramesEditor::_notification(int p_what) { diff --git a/editor/plugins/sprite_frames_editor_plugin.h b/editor/plugins/sprite_frames_editor_plugin.h index 3778e4ca55..c9081c599a 100644 --- a/editor/plugins/sprite_frames_editor_plugin.h +++ b/editor/plugins/sprite_frames_editor_plugin.h @@ -100,7 +100,7 @@ class SpriteFramesEditor : public PanelContainer { protected: void _notification(int p_what); - void _gui_input(InputEvent p_event); + void _gui_input(Ref<InputEvent> p_event); static void _bind_methods(); public: diff --git a/editor/plugins/texture_editor_plugin.cpp b/editor/plugins/texture_editor_plugin.cpp index 62977d86ea..676e50d61c 100644 --- a/editor/plugins/texture_editor_plugin.cpp +++ b/editor/plugins/texture_editor_plugin.cpp @@ -33,7 +33,7 @@ #include "global_config.h" #include "io/resource_loader.h" -void TextureEditor::_gui_input(InputEvent p_event) { +void TextureEditor::_gui_input(Ref<InputEvent> p_event) { } void TextureEditor::_notification(int p_what) { @@ -71,6 +71,8 @@ void TextureEditor::_notification(int p_what) { String format; if (texture->cast_to<ImageTexture>()) { format = Image::get_format_name(texture->cast_to<ImageTexture>()->get_format()); + } else if (texture->cast_to<StreamTexture>()) { + format = Image::get_format_name(texture->cast_to<StreamTexture>()->get_format()); } else { format = texture->get_class(); } diff --git a/editor/plugins/texture_editor_plugin.h b/editor/plugins/texture_editor_plugin.h index 8750ce4d5e..9382983538 100644 --- a/editor/plugins/texture_editor_plugin.h +++ b/editor/plugins/texture_editor_plugin.h @@ -42,7 +42,7 @@ class TextureEditor : public Control { protected: void _notification(int p_what); - void _gui_input(InputEvent p_event); + void _gui_input(Ref<InputEvent> p_event); static void _bind_methods(); public: diff --git a/editor/plugins/texture_region_editor_plugin.cpp b/editor/plugins/texture_region_editor_plugin.cpp index fe93a5aac6..ea5bf437ff 100644 --- a/editor/plugins/texture_region_editor_plugin.cpp +++ b/editor/plugins/texture_region_editor_plugin.cpp @@ -114,10 +114,10 @@ void TextureRegionEditor::_region_draw() { for (List<Rect2>::Element *E = autoslice_cache.front(); E; E = E->next()) { Rect2 r = E->get(); Vector2 endpoints[4] = { - mtx.basis_xform(r.pos), - mtx.basis_xform(r.pos + Vector2(r.size.x, 0)), - mtx.basis_xform(r.pos + r.size), - mtx.basis_xform(r.pos + Vector2(0, r.size.y)) + mtx.basis_xform(r.position), + mtx.basis_xform(r.position + Vector2(r.size.x, 0)), + mtx.basis_xform(r.position + r.size), + mtx.basis_xform(r.position + Vector2(0, r.size.y)) }; for (int i = 0; i < 4; i++) { int next = (i + 1) % 4; @@ -132,10 +132,10 @@ void TextureRegionEditor::_region_draw() { scroll_rect.expand_to(mtx.basis_xform(edit_draw->get_size())); Vector2 endpoints[4] = { - mtx.basis_xform(rect.pos), - mtx.basis_xform(rect.pos + Vector2(rect.size.x, 0)), - mtx.basis_xform(rect.pos + rect.size), - mtx.basis_xform(rect.pos + Vector2(0, rect.size.y)) + mtx.basis_xform(rect.position), + mtx.basis_xform(rect.position + Vector2(rect.size.x, 0)), + mtx.basis_xform(rect.position + rect.size), + mtx.basis_xform(rect.position + Vector2(0, rect.size.y)) }; Color color(0.9, 0.5, 0.5); for (int i = 0; i < 4; i++) { @@ -162,14 +162,14 @@ void TextureRegionEditor::_region_draw() { scroll_rect = scroll_rect.grow(200); updating_scroll = true; - hscroll->set_min(scroll_rect.pos.x); - hscroll->set_max(scroll_rect.pos.x + scroll_rect.size.x); + hscroll->set_min(scroll_rect.position.x); + hscroll->set_max(scroll_rect.position.x + scroll_rect.size.x); hscroll->set_page(edit_draw->get_size().x); hscroll->set_value(draw_ofs.x); hscroll->set_step(0.001); - vscroll->set_min(scroll_rect.pos.y); - vscroll->set_max(scroll_rect.pos.y + scroll_rect.size.y); + vscroll->set_min(scroll_rect.position.y); + vscroll->set_max(scroll_rect.position.y + scroll_rect.size.y); vscroll->set_page(edit_draw->get_size().y); vscroll->set_value(draw_ofs.y); vscroll->set_step(0.001); @@ -202,29 +202,28 @@ void TextureRegionEditor::_region_draw() { } } -void TextureRegionEditor::_region_input(const InputEvent &p_input) { +void TextureRegionEditor::_region_input(const Ref<InputEvent> &p_input) { Transform2D mtx; mtx.elements[2] = -draw_ofs; mtx.scale_basis(Vector2(draw_zoom, draw_zoom)); Vector2 endpoints[8] = { - mtx.xform(rect.pos) + Vector2(-4, -4), - mtx.xform(rect.pos + Vector2(rect.size.x / 2, 0)) + Vector2(0, -4), - mtx.xform(rect.pos + Vector2(rect.size.x, 0)) + Vector2(4, -4), - mtx.xform(rect.pos + Vector2(rect.size.x, rect.size.y / 2)) + Vector2(4, 0), - mtx.xform(rect.pos + rect.size) + Vector2(4, 4), - mtx.xform(rect.pos + Vector2(rect.size.x / 2, rect.size.y)) + Vector2(0, 4), - mtx.xform(rect.pos + Vector2(0, rect.size.y)) + Vector2(-4, 4), - mtx.xform(rect.pos + Vector2(0, rect.size.y / 2)) + Vector2(-4, 0) + mtx.xform(rect.position) + Vector2(-4, -4), + mtx.xform(rect.position + Vector2(rect.size.x / 2, 0)) + Vector2(0, -4), + mtx.xform(rect.position + Vector2(rect.size.x, 0)) + Vector2(4, -4), + mtx.xform(rect.position + Vector2(rect.size.x, rect.size.y / 2)) + Vector2(4, 0), + mtx.xform(rect.position + rect.size) + Vector2(4, 4), + mtx.xform(rect.position + Vector2(rect.size.x / 2, rect.size.y)) + Vector2(0, 4), + mtx.xform(rect.position + Vector2(0, rect.size.y)) + Vector2(-4, 4), + mtx.xform(rect.position + Vector2(0, rect.size.y / 2)) + Vector2(-4, 0) }; - if (p_input.type == InputEvent::MOUSE_BUTTON) { + Ref<InputEventMouseButton> mb; + if (mb.is_valid()) { - const InputEventMouseButton &mb = p_input.mouse_button; + if (mb->get_button_index() == BUTTON_LEFT) { - if (mb.button_index == BUTTON_LEFT) { - - if (mb.pressed) { + if (mb->is_pressed()) { if (node_patch9 || obj_styleBox.is_valid()) { edited_margin = -1; float margins[4]; @@ -240,31 +239,31 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { margins[3] = obj_styleBox->get_margin_size(MARGIN_RIGHT); } Vector2 pos[4] = { - mtx.basis_xform(rect.pos + Vector2(0, margins[0])) - draw_ofs, - mtx.basis_xform(rect.pos + rect.size - Vector2(0, margins[1])) - draw_ofs, - mtx.basis_xform(rect.pos + Vector2(margins[2], 0)) - draw_ofs, - mtx.basis_xform(rect.pos + rect.size - Vector2(margins[3], 0)) - draw_ofs + mtx.basis_xform(rect.position + Vector2(0, margins[0])) - draw_ofs, + mtx.basis_xform(rect.position + rect.size - Vector2(0, margins[1])) - draw_ofs, + mtx.basis_xform(rect.position + Vector2(margins[2], 0)) - draw_ofs, + mtx.basis_xform(rect.position + rect.size - Vector2(margins[3], 0)) - draw_ofs }; - if (Math::abs(mb.y - pos[0].y) < 8) { + if (Math::abs(mb->get_position().y - pos[0].y) < 8) { edited_margin = 0; prev_margin = margins[0]; - } else if (Math::abs(mb.y - pos[1].y) < 8) { + } else if (Math::abs(mb->get_position().y - pos[1].y) < 8) { edited_margin = 1; prev_margin = margins[1]; - } else if (Math::abs(mb.x - pos[2].x) < 8) { + } else if (Math::abs(mb->get_position().x - pos[2].x) < 8) { edited_margin = 2; prev_margin = margins[2]; - } else if (Math::abs(mb.x - pos[3].x) < 8) { + } else if (Math::abs(mb->get_position().x - pos[3].x) < 8) { edited_margin = 3; prev_margin = margins[3]; } if (edited_margin >= 0) { - drag_from = Vector2(mb.x, mb.y); + drag_from = Vector2(mb->get_position().x, mb->get_position().y); drag = true; } } if (edited_margin < 0 && snap_mode == SNAP_AUTOSLICE) { - Vector2 point = mtx.affine_inverse().xform(Vector2(mb.x, mb.y)); + Vector2 point = mtx.affine_inverse().xform(Vector2(mb->get_position().x, mb->get_position().y)); for (List<Rect2>::Element *E = autoslice_cache.front(); E; E = E->next()) { if (E->get().has_point(point)) { rect = E->get(); @@ -278,8 +277,8 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { r = obj_styleBox->get_region_rect(); else if (atlas_tex.is_valid()) r = atlas_tex->get_region(); - rect.expand_to(r.pos); - rect.expand_to(r.pos + r.size); + rect.expand_to(r.position); + rect.expand_to(r.position + r.size); } undo_redo->create_action("Set Region Rect"); if (node_sprite) { @@ -302,7 +301,7 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { } } } else if (edited_margin < 0) { - drag_from = mtx.affine_inverse().xform(Vector2(mb.x, mb.y)); + drag_from = mtx.affine_inverse().xform(Vector2(mb->get_position().x, mb->get_position().y)); if (snap_mode == SNAP_PIXEL) drag_from = drag_from.snapped(Vector2(1, 1)); else if (snap_mode == SNAP_GRID) @@ -319,7 +318,7 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { for (int i = 0; i < 8; i++) { Vector2 tuv = endpoints[i]; - if (tuv.distance_to(Vector2(mb.x, mb.y)) < 8) { + if (tuv.distance_to(Vector2(mb->get_position().x, mb->get_position().y)) < 8) { drag_index = i; } } @@ -369,7 +368,7 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { creating = false; } - } else if (mb.button_index == BUTTON_RIGHT && mb.pressed) { + } else if (mb->get_button_index() == BUTTON_RIGHT && mb->is_pressed()) { if (drag) { drag = false; @@ -387,18 +386,20 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { drag_index = -1; } } - } else if (mb.button_index == BUTTON_WHEEL_UP && mb.pressed) { + } else if (mb->get_button_index() == BUTTON_WHEEL_UP && mb->is_pressed()) { _zoom_in(); - } else if (mb.button_index == BUTTON_WHEEL_DOWN && mb.pressed) { + } else if (mb->get_button_index() == BUTTON_WHEEL_DOWN && mb->is_pressed()) { _zoom_out(); } - } else if (p_input.type == InputEvent::MOUSE_MOTION) { + } + + Ref<InputEventMouseMotion> mm = p_input; - const InputEventMouseMotion &mm = p_input.mouse_motion; + if (mm.is_valid()) { - if (mm.button_mask & BUTTON_MASK_MIDDLE || Input::get_singleton()->is_key_pressed(KEY_SPACE)) { + if (mm->get_button_mask() & BUTTON_MASK_MIDDLE || Input::get_singleton()->is_key_pressed(KEY_SPACE)) { - Vector2 draged(mm.relative_x, mm.relative_y); + Vector2 draged(mm->get_relative().x, mm->get_relative().y); hscroll->set_value(hscroll->get_value() - draged.x); vscroll->set_value(vscroll->get_value() - draged.y); @@ -407,13 +408,13 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { if (edited_margin >= 0) { float new_margin; if (edited_margin == 0) - new_margin = prev_margin + (mm.y - drag_from.y) / draw_zoom; + new_margin = prev_margin + (mm->get_position().y - drag_from.y) / draw_zoom; else if (edited_margin == 1) - new_margin = prev_margin - (mm.y - drag_from.y) / draw_zoom; + new_margin = prev_margin - (mm->get_position().y - drag_from.y) / draw_zoom; else if (edited_margin == 2) - new_margin = prev_margin + (mm.x - drag_from.x) / draw_zoom; + new_margin = prev_margin + (mm->get_position().x - drag_from.x) / draw_zoom; else if (edited_margin == 3) - new_margin = prev_margin - (mm.x - drag_from.x) / draw_zoom; + new_margin = prev_margin - (mm->get_position().x - drag_from.x) / draw_zoom; if (new_margin < 0) new_margin = 0; static Margin m[4] = { MARGIN_TOP, MARGIN_BOTTOM, MARGIN_LEFT, MARGIN_RIGHT }; @@ -422,7 +423,7 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { if (obj_styleBox.is_valid()) obj_styleBox->set_margin_size(m[edited_margin], new_margin); } else { - Vector2 new_pos = mtx.affine_inverse().xform(Vector2(mm.x, mm.y)); + Vector2 new_pos = mtx.affine_inverse().xform(mm->get_position()); if (snap_mode == SNAP_PIXEL) new_pos = new_pos.snapped(Vector2(1, 1)); else if (snap_mode == SNAP_GRID) @@ -438,49 +439,49 @@ void TextureRegionEditor::_region_input(const InputEvent &p_input) { switch (drag_index) { case 0: { - Vector2 p = rect_prev.pos + rect_prev.size; + Vector2 p = rect_prev.position + rect_prev.size; rect = Rect2(p, Size2()); rect.expand_to(new_pos); apply_rect(rect); } break; case 1: { - Vector2 p = rect_prev.pos + Vector2(0, rect_prev.size.y); + Vector2 p = rect_prev.position + Vector2(0, rect_prev.size.y); rect = Rect2(p, Size2(rect_prev.size.x, 0)); rect.expand_to(new_pos); apply_rect(rect); } break; case 2: { - Vector2 p = rect_prev.pos + Vector2(0, rect_prev.size.y); + Vector2 p = rect_prev.position + Vector2(0, rect_prev.size.y); rect = Rect2(p, Size2()); rect.expand_to(new_pos); apply_rect(rect); } break; case 3: { - Vector2 p = rect_prev.pos; + Vector2 p = rect_prev.position; rect = Rect2(p, Size2(0, rect_prev.size.y)); rect.expand_to(new_pos); apply_rect(rect); } break; case 4: { - Vector2 p = rect_prev.pos; + Vector2 p = rect_prev.position; rect = Rect2(p, Size2()); rect.expand_to(new_pos); apply_rect(rect); } break; case 5: { - Vector2 p = rect_prev.pos; + Vector2 p = rect_prev.position; rect = Rect2(p, Size2(rect_prev.size.x, 0)); rect.expand_to(new_pos); apply_rect(rect); } break; case 6: { - Vector2 p = rect_prev.pos + Vector2(rect_prev.size.x, 0); + Vector2 p = rect_prev.position + Vector2(rect_prev.size.x, 0); rect = Rect2(p, Size2()); rect.expand_to(new_pos); apply_rect(rect); } break; case 7: { - Vector2 p = rect_prev.pos + Vector2(rect_prev.size.x, 0); + Vector2 p = rect_prev.position + Vector2(rect_prev.size.x, 0); rect = Rect2(p, Size2(0, rect_prev.size.y)); rect.expand_to(new_pos); apply_rect(rect); @@ -678,12 +679,13 @@ void TextureRegionEditor::_edit_region() { } autoslice_cache.clear(); - Image i; - if (i.load(texture->get_path()) == OK) { + Ref<Image> i; + i.instance(); + if (i->load(texture->get_path()) == OK) { BitMap bm; bm.create_from_image_alpha(i); - for (int y = 0; y < i.get_height(); y++) { - for (int x = 0; x < i.get_width(); x++) { + for (int y = 0; y < i->get_height(); y++) { + for (int x = 0; x < i->get_width(); x++) { if (bm.get_bit(Point2(x, y))) { bool found = false; for (List<Rect2>::Element *E = autoslice_cache.front(); E; E = E->next()) { @@ -691,7 +693,7 @@ void TextureRegionEditor::_edit_region() { if (grown.has_point(Point2(x, y))) { E->get().expand_to(Point2(x, y)); E->get().expand_to(Point2(x + 1, y + 1)); - x = E->get().pos.x + E->get().size.x - 1; + x = E->get().position.x + E->get().size.x - 1; bool merged = true; while (merged) { merged = false; @@ -704,8 +706,8 @@ void TextureRegionEditor::_edit_region() { if (F == E) continue; if (E->get().grow(1).intersects(F->get())) { - E->get().expand_to(F->get().pos); - E->get().expand_to(F->get().pos + F->get().size); + E->get().expand_to(F->get().position); + E->get().expand_to(F->get().position + F->get().size); if (F->prev()) { F = F->prev(); autoslice_cache.erase(F->next()); diff --git a/editor/plugins/texture_region_editor_plugin.h b/editor/plugins/texture_region_editor_plugin.h index 093e2f7d01..cb0b9fc372 100644 --- a/editor/plugins/texture_region_editor_plugin.h +++ b/editor/plugins/texture_region_editor_plugin.h @@ -122,7 +122,7 @@ protected: public: void _edit_region(); void _region_draw(); - void _region_input(const InputEvent &p_input); + void _region_input(const Ref<InputEvent> &p_input); void _scroll_changed(float); void edit(Object *p_obj); diff --git a/editor/plugins/tile_map_editor_plugin.cpp b/editor/plugins/tile_map_editor_plugin.cpp index 9f99a9b978..d12b979121 100644 --- a/editor/plugins/tile_map_editor_plugin.cpp +++ b/editor/plugins/tile_map_editor_plugin.cpp @@ -98,8 +98,8 @@ void TileMapEditor::_menu_option(int p_option) { return; undo_redo->create_action("Erase Selection"); - for (int i = rectangle.pos.y; i <= rectangle.pos.y + rectangle.size.y; i++) { - for (int j = rectangle.pos.x; j <= rectangle.pos.x + rectangle.size.x; j++) { + for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { + for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { _set_cell(Point2i(j, i), TileMap::INVALID_CELL, false, false, false, true); } @@ -179,14 +179,16 @@ void TileMapEditor::_text_changed(const String &p_text) { _update_palette(); } -void TileMapEditor::_sbox_input(const InputEvent &p_ie) { +void TileMapEditor::_sbox_input(const Ref<InputEvent> &p_ie) { - if (p_ie.type == InputEvent::KEY && (p_ie.key.scancode == KEY_UP || - p_ie.key.scancode == KEY_DOWN || - p_ie.key.scancode == KEY_PAGEUP || - p_ie.key.scancode == KEY_PAGEDOWN)) { + Ref<InputEventKey> k = p_ie; - palette->call("_gui_input", p_ie); + if (k.is_valid() && (k->get_scancode() == KEY_UP || + k->get_scancode() == KEY_DOWN || + k->get_scancode() == KEY_PAGEUP || + k->get_scancode() == KEY_PAGEDOWN)) { + + palette->call("_gui_input", k); search_box->accept_event(); } } @@ -331,7 +333,7 @@ PoolVector<Vector2> TileMapEditor::_bucket_fill(const Point2i &p_start, bool era } Rect2i r = node->get_item_rect(); - r.pos = r.pos / node->get_cell_size(); + r.position = r.position / node->get_cell_size(); r.size = r.size / node->get_cell_size(); int area = r.get_area(); @@ -347,7 +349,7 @@ PoolVector<Vector2> TileMapEditor::_bucket_fill(const Point2i &p_start, bool era invalidate_cache = true; } // Tile ID changed or position wasn't visited by the previous fill - int loc = (p_start.x - r.get_pos().x) + (p_start.y - r.get_pos().y) * r.get_size().x; + int loc = (p_start.x - r.position.x) + (p_start.y - r.position.y) * r.get_size().x; if (prev_id != bucket_cache_tile || !bucket_cache_visited[loc]) { invalidate_cache = true; } @@ -378,7 +380,7 @@ PoolVector<Vector2> TileMapEditor::_bucket_fill(const Point2i &p_start, bool era if (node->get_cell(n.x, n.y) == prev_id) { if (preview) { - int loc = (n.x - r.get_pos().x) + (n.y - r.get_pos().y) * r.get_size().x; + int loc = (n.x - r.position.x) + (n.y - r.position.y) * r.get_size().x; if (bucket_cache_visited[loc]) continue; bucket_cache_visited[loc] = true; @@ -439,7 +441,7 @@ void TileMapEditor::_select(const Point2i &p_from, const Point2i &p_to) { SWAP(begin.y, end.y); } - rectangle.pos = begin; + rectangle.position = begin; rectangle.size = end - begin; canvas_item_editor->update(); @@ -458,7 +460,7 @@ void TileMapEditor::_draw_cell(int p_cell, const Point2i &p_point, bool p_flip_h Size2 sc = p_xform.get_scale(); Rect2 rect = Rect2(); - rect.pos = node->map_to_world(p_point) + node->get_cell_draw_offset(); + rect.position = node->map_to_world(p_point) + node->get_cell_draw_offset(); if (r.has_no_area()) { rect.size = t->get_size(); @@ -488,42 +490,42 @@ void TileMapEditor::_draw_cell(int p_cell, const Point2i &p_point, bool p_flip_h if (node->get_tile_origin() == TileMap::TILE_ORIGIN_TOP_LEFT) { - rect.pos += tile_ofs; + rect.position += tile_ofs; } else if (node->get_tile_origin() == TileMap::TILE_ORIGIN_BOTTOM_LEFT) { Size2 cell_size = node->get_cell_size(); - rect.pos += tile_ofs; + rect.position += tile_ofs; if (p_transpose) { if (p_flip_h) - rect.pos.x -= cell_size.x; + rect.position.x -= cell_size.x; else - rect.pos.x += cell_size.x; + rect.position.x += cell_size.x; } else { if (p_flip_v) - rect.pos.y -= cell_size.y; + rect.position.y -= cell_size.y; else - rect.pos.y += cell_size.y; + rect.position.y += cell_size.y; } } else if (node->get_tile_origin() == TileMap::TILE_ORIGIN_CENTER) { - rect.pos += node->get_cell_size() / 2; + rect.position += node->get_cell_size() / 2; Vector2 s = r.size; Vector2 center = (s / 2) - tile_ofs; if (p_flip_h) - rect.pos.x -= s.x - center.x; + rect.position.x -= s.x - center.x; else - rect.pos.x -= center.x; + rect.position.x -= center.x; if (p_flip_v) - rect.pos.y -= s.y - center.y; + rect.position.y -= s.y - center.y; else - rect.pos.y -= center.y; + rect.position.y -= center.y; } - rect.pos = p_xform.xform(rect.pos); + rect.position = p_xform.xform(rect.position); rect.size *= sc; if (r.has_no_area()) @@ -558,9 +560,9 @@ void TileMapEditor::_update_copydata() { if (!selection_active) return; - for (int i = rectangle.pos.y; i <= rectangle.pos.y + rectangle.size.y; i++) { + for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { - for (int j = rectangle.pos.x; j <= rectangle.pos.x + rectangle.size.x; j++) { + for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { TileData tcd; @@ -622,7 +624,7 @@ static inline Vector<Point2i> line(int x0, int x1, int y0, int y1) { return points; } -bool TileMapEditor::forward_gui_input(const InputEvent &p_event) { +bool TileMapEditor::forward_gui_input(const Ref<InputEvent> &p_event) { if (!node || !node->get_tileset().is_valid() || !node->is_visible_in_tree()) return false; @@ -630,464 +632,459 @@ bool TileMapEditor::forward_gui_input(const InputEvent &p_event) { Transform2D xform = CanvasItemEditor::get_singleton()->get_canvas_transform() * node->get_global_transform(); Transform2D xform_inv = xform.affine_inverse(); - switch (p_event.type) { - - case InputEvent::MOUSE_BUTTON: { - - const InputEventMouseButton &mb = p_event.mouse_button; - - if (mb.button_index == BUTTON_LEFT) { + Ref<InputEventMouseButton> mb = p_event; - if (mb.pressed) { + if (mb.is_valid()) { + if (mb->get_button_index() == BUTTON_LEFT) { - if (Input::get_singleton()->is_key_pressed(KEY_SPACE)) - return false; //drag + if (mb->is_pressed()) { - if (tool == TOOL_NONE) { + if (Input::get_singleton()->is_key_pressed(KEY_SPACE)) + return false; //drag - if (mb.mod.shift) { + if (tool == TOOL_NONE) { - if (mb.mod.control) - tool = TOOL_RECTANGLE_PAINT; - else - tool = TOOL_LINE_PAINT; + if (mb->get_shift()) { - selection_active = false; - rectangle_begin = over_tile; + if (mb->get_control()) + tool = TOOL_RECTANGLE_PAINT; + else + tool = TOOL_LINE_PAINT; - return true; - } + selection_active = false; + rectangle_begin = over_tile; - if (mb.mod.control) { + return true; + } - tool = TOOL_PICKING; - _pick_tile(over_tile); + if (mb->get_control()) { - return true; - } + tool = TOOL_PICKING; + _pick_tile(over_tile); - tool = TOOL_PAINTING; + return true; } - if (tool == TOOL_PAINTING) { - - int id = get_selected_tile(); + tool = TOOL_PAINTING; + } - if (id != TileMap::INVALID_CELL) { + if (tool == TOOL_PAINTING) { - tool = TOOL_PAINTING; + int id = get_selected_tile(); - paint_undo.clear(); - paint_undo[over_tile] = _get_op_from_cell(over_tile); + if (id != TileMap::INVALID_CELL) { - _set_cell(over_tile, id, flip_h, flip_v, transpose); - } - } else if (tool == TOOL_PICKING) { + tool = TOOL_PAINTING; - _pick_tile(over_tile); - } else if (tool == TOOL_SELECTING) { + paint_undo.clear(); + paint_undo[over_tile] = _get_op_from_cell(over_tile); - selection_active = true; - rectangle_begin = over_tile; + _set_cell(over_tile, id, flip_h, flip_v, transpose); } + } else if (tool == TOOL_PICKING) { - return true; + _pick_tile(over_tile); + } else if (tool == TOOL_SELECTING) { - } else { + selection_active = true; + rectangle_begin = over_tile; + } + + return true; - if (tool != TOOL_NONE) { + } else { - if (tool == TOOL_PAINTING) { + if (tool != TOOL_NONE) { - int id = get_selected_tile(); + if (tool == TOOL_PAINTING) { - if (id != TileMap::INVALID_CELL && paint_undo.size()) { + int id = get_selected_tile(); - undo_redo->create_action(TTR("Paint TileMap")); - for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + if (id != TileMap::INVALID_CELL && paint_undo.size()) { - Point2 p = E->key(); - undo_redo->add_do_method(node, "set_cellv", p, id, flip_h, flip_v, transpose); - undo_redo->add_undo_method(node, "set_cellv", p, E->get().idx, E->get().xf, E->get().yf, E->get().tr); - } - undo_redo->commit_action(); + undo_redo->create_action(TTR("Paint TileMap")); + for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { - paint_undo.clear(); + Point2 p = E->key(); + undo_redo->add_do_method(node, "set_cellv", p, id, flip_h, flip_v, transpose); + undo_redo->add_undo_method(node, "set_cellv", p, E->get().idx, E->get().xf, E->get().yf, E->get().tr); } - } else if (tool == TOOL_LINE_PAINT) { - - int id = get_selected_tile(); + undo_redo->commit_action(); - if (id != TileMap::INVALID_CELL) { + paint_undo.clear(); + } + } else if (tool == TOOL_LINE_PAINT) { - undo_redo->create_action("Line Draw"); - for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + int id = get_selected_tile(); - _set_cell(E->key(), id, flip_h, flip_v, transpose, true); - } - undo_redo->commit_action(); + if (id != TileMap::INVALID_CELL) { - paint_undo.clear(); + undo_redo->create_action("Line Draw"); + for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { - canvas_item_editor->update(); + _set_cell(E->key(), id, flip_h, flip_v, transpose, true); } - } else if (tool == TOOL_RECTANGLE_PAINT) { - - int id = get_selected_tile(); - - if (id != TileMap::INVALID_CELL) { + undo_redo->commit_action(); - undo_redo->create_action("Rectangle Paint"); - for (int i = rectangle.pos.y; i <= rectangle.pos.y + rectangle.size.y; i++) { - for (int j = rectangle.pos.x; j <= rectangle.pos.x + rectangle.size.x; j++) { + paint_undo.clear(); - _set_cell(Point2i(j, i), id, flip_h, flip_v, transpose, true); - } - } - undo_redo->commit_action(); + canvas_item_editor->update(); + } + } else if (tool == TOOL_RECTANGLE_PAINT) { - canvas_item_editor->update(); - } - } else if (tool == TOOL_DUPLICATING) { + int id = get_selected_tile(); - Point2 ofs = over_tile - rectangle.pos; + if (id != TileMap::INVALID_CELL) { - undo_redo->create_action(TTR("Duplicate")); - for (List<TileData>::Element *E = copydata.front(); E; E = E->next()) { + undo_redo->create_action("Rectangle Paint"); + for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { + for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { - _set_cell(E->get().pos + ofs, E->get().cell, E->get().flip_h, E->get().flip_v, E->get().transpose, true); + _set_cell(Point2i(j, i), id, flip_h, flip_v, transpose, true); + } } undo_redo->commit_action(); - copydata.clear(); - canvas_item_editor->update(); + } + } else if (tool == TOOL_DUPLICATING) { - } else if (tool == TOOL_SELECTING) { + Point2 ofs = over_tile - rectangle.position; - canvas_item_editor->update(); + undo_redo->create_action(TTR("Duplicate")); + for (List<TileData>::Element *E = copydata.front(); E; E = E->next()) { - } else if (tool == TOOL_BUCKET) { + _set_cell(E->get().pos + ofs, E->get().cell, E->get().flip_h, E->get().flip_v, E->get().transpose, true); + } + undo_redo->commit_action(); - Dictionary pop; - pop["id"] = node->get_cell(over_tile.x, over_tile.y); - pop["flip_h"] = node->is_cell_x_flipped(over_tile.x, over_tile.y); - pop["flip_v"] = node->is_cell_y_flipped(over_tile.x, over_tile.y); - pop["transpose"] = node->is_cell_transposed(over_tile.x, over_tile.y); + copydata.clear(); + + canvas_item_editor->update(); - PoolVector<Vector2> points = _bucket_fill(over_tile); + } else if (tool == TOOL_SELECTING) { - if (points.size() == 0) - return false; + canvas_item_editor->update(); - Dictionary op; - op["id"] = get_selected_tile(); - op["flip_h"] = flip_h; - op["flip_v"] = flip_v; - op["transpose"] = transpose; + } else if (tool == TOOL_BUCKET) { - undo_redo->create_action("Bucket Fill"); + Dictionary pop; + pop["id"] = node->get_cell(over_tile.x, over_tile.y); + pop["flip_h"] = node->is_cell_x_flipped(over_tile.x, over_tile.y); + pop["flip_v"] = node->is_cell_y_flipped(over_tile.x, over_tile.y); + pop["transpose"] = node->is_cell_transposed(over_tile.x, over_tile.y); - undo_redo->add_do_method(this, "_fill_points", points, op); - undo_redo->add_undo_method(this, "_fill_points", points, pop); + PoolVector<Vector2> points = _bucket_fill(over_tile); - undo_redo->commit_action(); - } + if (points.size() == 0) + return false; - tool = TOOL_NONE; + Dictionary op; + op["id"] = get_selected_tile(); + op["flip_h"] = flip_h; + op["flip_v"] = flip_v; + op["transpose"] = transpose; - return true; + undo_redo->create_action("Bucket Fill"); + + undo_redo->add_do_method(this, "_fill_points", points, op); + undo_redo->add_undo_method(this, "_fill_points", points, pop); + + undo_redo->commit_action(); } - } - } else if (mb.button_index == BUTTON_RIGHT) { - if (mb.pressed) { + tool = TOOL_NONE; - if (tool == TOOL_SELECTING || selection_active) { + return true; + } + } + } else if (mb->get_button_index() == BUTTON_RIGHT) { - tool = TOOL_NONE; - selection_active = false; + if (mb->is_pressed()) { - canvas_item_editor->update(); + if (tool == TOOL_SELECTING || selection_active) { - return true; - } + tool = TOOL_NONE; + selection_active = false; - if (tool == TOOL_DUPLICATING) { + canvas_item_editor->update(); - tool = TOOL_NONE; - copydata.clear(); + return true; + } - canvas_item_editor->update(); + if (tool == TOOL_DUPLICATING) { - return true; - } + tool = TOOL_NONE; + copydata.clear(); - if (tool == TOOL_NONE) { + canvas_item_editor->update(); - paint_undo.clear(); + return true; + } - Point2 local = node->world_to_map(xform_inv.xform(Point2(mb.x, mb.y))); + if (tool == TOOL_NONE) { - if (mb.mod.shift) { + paint_undo.clear(); - if (mb.mod.control) - tool = TOOL_RECTANGLE_ERASE; - else - tool = TOOL_LINE_ERASE; + Point2 local = node->world_to_map(xform_inv.xform(mb->get_position())); - selection_active = false; - rectangle_begin = local; - } else { + if (mb->get_shift()) { - tool = TOOL_ERASING; + if (mb->get_control()) + tool = TOOL_RECTANGLE_ERASE; + else + tool = TOOL_LINE_ERASE; - paint_undo[local] = _get_op_from_cell(local); - _set_cell(local, TileMap::INVALID_CELL); - } + selection_active = false; + rectangle_begin = local; + } else { - return true; + tool = TOOL_ERASING; + + paint_undo[local] = _get_op_from_cell(local); + _set_cell(local, TileMap::INVALID_CELL); } - } else { - if (tool == TOOL_ERASING || tool == TOOL_RECTANGLE_ERASE || tool == TOOL_LINE_ERASE) { + return true; + } - if (paint_undo.size()) { - undo_redo->create_action(TTR("Erase TileMap")); - for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + } else { + if (tool == TOOL_ERASING || tool == TOOL_RECTANGLE_ERASE || tool == TOOL_LINE_ERASE) { - Point2 p = E->key(); - undo_redo->add_do_method(node, "set_cellv", p, TileMap::INVALID_CELL, false, false, false); - undo_redo->add_undo_method(node, "set_cellv", p, E->get().idx, E->get().xf, E->get().yf, E->get().tr); - } + if (paint_undo.size()) { + undo_redo->create_action(TTR("Erase TileMap")); + for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { - undo_redo->commit_action(); - paint_undo.clear(); + Point2 p = E->key(); + undo_redo->add_do_method(node, "set_cellv", p, TileMap::INVALID_CELL, false, false, false); + undo_redo->add_undo_method(node, "set_cellv", p, E->get().idx, E->get().xf, E->get().yf, E->get().tr); } - if (tool == TOOL_RECTANGLE_ERASE || tool == TOOL_LINE_ERASE) { - canvas_item_editor->update(); - } + undo_redo->commit_action(); + paint_undo.clear(); + } - tool = TOOL_NONE; + if (tool == TOOL_RECTANGLE_ERASE || tool == TOOL_LINE_ERASE) { + canvas_item_editor->update(); + } - return true; + tool = TOOL_NONE; - } else if (tool == TOOL_BUCKET) { + return true; - Dictionary pop; - pop["id"] = node->get_cell(over_tile.x, over_tile.y); - pop["flip_h"] = node->is_cell_x_flipped(over_tile.x, over_tile.y); - pop["flip_v"] = node->is_cell_y_flipped(over_tile.x, over_tile.y); - pop["transpose"] = node->is_cell_transposed(over_tile.x, over_tile.y); + } else if (tool == TOOL_BUCKET) { - PoolVector<Vector2> points = _bucket_fill(over_tile, true); + Dictionary pop; + pop["id"] = node->get_cell(over_tile.x, over_tile.y); + pop["flip_h"] = node->is_cell_x_flipped(over_tile.x, over_tile.y); + pop["flip_v"] = node->is_cell_y_flipped(over_tile.x, over_tile.y); + pop["transpose"] = node->is_cell_transposed(over_tile.x, over_tile.y); - if (points.size() == 0) - return false; + PoolVector<Vector2> points = _bucket_fill(over_tile, true); - undo_redo->create_action("Bucket Fill"); + if (points.size() == 0) + return false; - undo_redo->add_do_method(this, "_erase_points", points); - undo_redo->add_undo_method(this, "_fill_points", points, pop); + undo_redo->create_action("Bucket Fill"); - undo_redo->commit_action(); - } + undo_redo->add_do_method(this, "_erase_points", points); + undo_redo->add_undo_method(this, "_fill_points", points, pop); + + undo_redo->commit_action(); } } - } break; - case InputEvent::MOUSE_MOTION: { + } + } - const InputEventMouseMotion &mm = p_event.mouse_motion; + Ref<InputEventMouseMotion> mm = p_event; - Point2i new_over_tile = node->world_to_map(xform_inv.xform(Point2(mm.x, mm.y))); + if (mm.is_valid()) { - if (new_over_tile != over_tile) { + Point2i new_over_tile = node->world_to_map(xform_inv.xform(mm->get_position())); - over_tile = new_over_tile; - canvas_item_editor->update(); - } + if (new_over_tile != over_tile) { - int tile_under = node->get_cell(over_tile.x, over_tile.y); - String tile_name = "none"; + over_tile = new_over_tile; + canvas_item_editor->update(); + } - if (node->get_tileset()->has_tile(tile_under)) - tile_name = node->get_tileset()->tile_get_name(tile_under); - tile_info->set_text(String::num(over_tile.x) + ", " + String::num(over_tile.y) + " [" + tile_name + "]"); + int tile_under = node->get_cell(over_tile.x, over_tile.y); + String tile_name = "none"; - if (tool == TOOL_PAINTING) { + if (node->get_tileset()->has_tile(tile_under)) + tile_name = node->get_tileset()->tile_get_name(tile_under); + tile_info->set_text(String::num(over_tile.x) + ", " + String::num(over_tile.y) + " [" + tile_name + "]"); - int id = get_selected_tile(); - if (id != TileMap::INVALID_CELL) { + if (tool == TOOL_PAINTING) { - if (!paint_undo.has(over_tile)) { - paint_undo[over_tile] = _get_op_from_cell(over_tile); - } - - _set_cell(over_tile, id, flip_h, flip_v, transpose); + int id = get_selected_tile(); + if (id != TileMap::INVALID_CELL) { - return true; + if (!paint_undo.has(over_tile)) { + paint_undo[over_tile] = _get_op_from_cell(over_tile); } - } - if (tool == TOOL_SELECTING) { - - _select(rectangle_begin, over_tile); + _set_cell(over_tile, id, flip_h, flip_v, transpose); return true; } + } - if (tool == TOOL_LINE_PAINT || tool == TOOL_LINE_ERASE) { + if (tool == TOOL_SELECTING) { - int id = get_selected_tile(); - bool erasing = (tool == TOOL_LINE_ERASE); + _select(rectangle_begin, over_tile); - if (erasing && paint_undo.size()) { + return true; + } - for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + if (tool == TOOL_LINE_PAINT || tool == TOOL_LINE_ERASE) { - _set_cell(E->key(), E->get().idx, E->get().xf, E->get().yf, E->get().tr); - } - } + int id = get_selected_tile(); + bool erasing = (tool == TOOL_LINE_ERASE); - paint_undo.clear(); + if (erasing && paint_undo.size()) { + + for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + + _set_cell(E->key(), E->get().idx, E->get().xf, E->get().yf, E->get().tr); + } + } - if (id != TileMap::INVALID_CELL) { + paint_undo.clear(); - Vector<Point2i> points = line(rectangle_begin.x, over_tile.x, rectangle_begin.y, over_tile.y); + if (id != TileMap::INVALID_CELL) { - for (int i = 0; i < points.size(); i++) { + Vector<Point2i> points = line(rectangle_begin.x, over_tile.x, rectangle_begin.y, over_tile.y); - paint_undo[points[i]] = _get_op_from_cell(points[i]); + for (int i = 0; i < points.size(); i++) { - if (erasing) - _set_cell(points[i], TileMap::INVALID_CELL); - } + paint_undo[points[i]] = _get_op_from_cell(points[i]); - canvas_item_editor->update(); + if (erasing) + _set_cell(points[i], TileMap::INVALID_CELL); } - return true; + canvas_item_editor->update(); } - if (tool == TOOL_RECTANGLE_PAINT || tool == TOOL_RECTANGLE_ERASE) { - _select(rectangle_begin, over_tile); + return true; + } + if (tool == TOOL_RECTANGLE_PAINT || tool == TOOL_RECTANGLE_ERASE) { - if (tool == TOOL_RECTANGLE_ERASE) { + _select(rectangle_begin, over_tile); - if (paint_undo.size()) { + if (tool == TOOL_RECTANGLE_ERASE) { - for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + if (paint_undo.size()) { - _set_cell(E->key(), E->get().idx, E->get().xf, E->get().yf, E->get().tr); - } + for (Map<Point2i, CellOp>::Element *E = paint_undo.front(); E; E = E->next()) { + + _set_cell(E->key(), E->get().idx, E->get().xf, E->get().yf, E->get().tr); } + } - paint_undo.clear(); + paint_undo.clear(); - for (int i = rectangle.pos.y; i <= rectangle.pos.y + rectangle.size.y; i++) { - for (int j = rectangle.pos.x; j <= rectangle.pos.x + rectangle.size.x; j++) { + for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { + for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { - Point2i tile = Point2i(j, i); - paint_undo[tile] = _get_op_from_cell(tile); + Point2i tile = Point2i(j, i); + paint_undo[tile] = _get_op_from_cell(tile); - _set_cell(tile, TileMap::INVALID_CELL); - } + _set_cell(tile, TileMap::INVALID_CELL); } } - - return true; } - if (tool == TOOL_ERASING) { - - if (!paint_undo.has(over_tile)) { - paint_undo[over_tile] = _get_op_from_cell(over_tile); - } - _set_cell(over_tile, TileMap::INVALID_CELL); + return true; + } + if (tool == TOOL_ERASING) { - return true; + if (!paint_undo.has(over_tile)) { + paint_undo[over_tile] = _get_op_from_cell(over_tile); } - if (tool == TOOL_PICKING && Input::get_singleton()->is_mouse_button_pressed(BUTTON_LEFT)) { - _pick_tile(over_tile); + _set_cell(over_tile, TileMap::INVALID_CELL); - return true; - } - } break; - case InputEvent::KEY: { + return true; + } + if (tool == TOOL_PICKING && Input::get_singleton()->is_mouse_button_pressed(BUTTON_LEFT)) { - const InputEventKey &k = p_event.key; + _pick_tile(over_tile); - if (!k.pressed) - break; + return true; + } + } - if (k.scancode == KEY_ESCAPE) { + Ref<InputEventKey> k = p_event; - if (tool == TOOL_DUPLICATING) - copydata.clear(); - else if (tool == TOOL_SELECTING || selection_active) - selection_active = false; + if (k.is_valid() && k->is_pressed()) { - tool = TOOL_NONE; + if (k->get_scancode() == KEY_ESCAPE) { - canvas_item_editor->update(); + if (tool == TOOL_DUPLICATING) + copydata.clear(); + else if (tool == TOOL_SELECTING || selection_active) + selection_active = false; - return true; - } + tool = TOOL_NONE; - if (tool != TOOL_NONE || !mouse_over) - return false; + canvas_item_editor->update(); - if (ED_IS_SHORTCUT("tile_map_editor/erase_selection", p_event)) { - _menu_option(OPTION_ERASE_SELECTION); + return true; + } - return true; - } - if (ED_IS_SHORTCUT("tile_map_editor/select", p_event)) { - tool = TOOL_SELECTING; - selection_active = false; + if (tool != TOOL_NONE || !mouse_over) + return false; - canvas_item_editor->update(); + if (ED_IS_SHORTCUT("tile_map_editor/erase_selection", p_event)) { + _menu_option(OPTION_ERASE_SELECTION); - return true; - } - if (ED_IS_SHORTCUT("tile_map_editor/duplicate_selection", p_event)) { - _update_copydata(); + return true; + } + if (ED_IS_SHORTCUT("tile_map_editor/select", p_event)) { + tool = TOOL_SELECTING; + selection_active = false; - if (selection_active) { - tool = TOOL_DUPLICATING; + canvas_item_editor->update(); - canvas_item_editor->update(); + return true; + } + if (ED_IS_SHORTCUT("tile_map_editor/duplicate_selection", p_event)) { + _update_copydata(); - return true; - } - } - if (ED_IS_SHORTCUT("tile_map_editor/find_tile", p_event)) { - search_box->select_all(); - search_box->grab_focus(); + if (selection_active) { + tool = TOOL_DUPLICATING; - return true; - } - if (ED_IS_SHORTCUT("tile_map_editor/mirror_x", p_event)) { - flip_h = !flip_h; - mirror_x->set_pressed(flip_h); - canvas_item_editor->update(); - return true; - } - if (ED_IS_SHORTCUT("tile_map_editor/mirror_y", p_event)) { - flip_v = !flip_v; - mirror_y->set_pressed(flip_v); - canvas_item_editor->update(); - return true; - } - if (ED_IS_SHORTCUT("tile_map_editor/transpose", p_event)) { - transpose = !transpose; - transp->set_pressed(transpose); canvas_item_editor->update(); + return true; } - } break; + } + if (ED_IS_SHORTCUT("tile_map_editor/find_tile", p_event)) { + search_box->select_all(); + search_box->grab_focus(); + + return true; + } + if (ED_IS_SHORTCUT("tile_map_editor/mirror_x", p_event)) { + flip_h = !flip_h; + mirror_x->set_pressed(flip_h); + canvas_item_editor->update(); + return true; + } + if (ED_IS_SHORTCUT("tile_map_editor/mirror_y", p_event)) { + flip_v = !flip_v; + mirror_y->set_pressed(flip_v); + canvas_item_editor->update(); + return true; + } + if (ED_IS_SHORTCUT("tile_map_editor/transpose", p_event)) { + transpose = !transpose; + transp->set_pressed(transpose); + canvas_item_editor->update(); + return true; + } } return false; @@ -1106,7 +1103,7 @@ void TileMapEditor::_canvas_draw() { Size2 screen_size = canvas_item_editor->get_size(); { Rect2 aabb; - aabb.pos = node->world_to_map(xform_inv.xform(Vector2())); + aabb.position = node->world_to_map(xform_inv.xform(Vector2())); aabb.expand_to(node->world_to_map(xform_inv.xform(Vector2(0, screen_size.height)))); aabb.expand_to(node->world_to_map(xform_inv.xform(Vector2(screen_size.width, 0)))); aabb.expand_to(node->world_to_map(xform_inv.xform(screen_size))); @@ -1116,10 +1113,10 @@ void TileMapEditor::_canvas_draw() { int max_lines = 2000; //avoid crash if size too smal - for (int i = (si.pos.x) - 1; i <= (si.pos.x + si.size.x); i++) { + for (int i = (si.position.x) - 1; i <= (si.position.x + si.size.x); i++) { - Vector2 from = xform.xform(node->map_to_world(Vector2(i, si.pos.y))); - Vector2 to = xform.xform(node->map_to_world(Vector2(i, si.pos.y + si.size.y + 1))); + Vector2 from = xform.xform(node->map_to_world(Vector2(i, si.position.y))); + Vector2 to = xform.xform(node->map_to_world(Vector2(i, si.position.y + si.size.y + 1))); Color col = i == 0 ? Color(1, 0.8, 0.2, 0.5) : Color(1, 0.3, 0.1, 0.2); canvas_item_editor->draw_line(from, to, col, 1); @@ -1130,9 +1127,9 @@ void TileMapEditor::_canvas_draw() { int max_lines = 10000; //avoid crash if size too smal - for (int i = (si.pos.x) - 1; i <= (si.pos.x + si.size.x); i++) { + for (int i = (si.position.x) - 1; i <= (si.position.x + si.size.x); i++) { - for (int j = (si.pos.y) - 1; j <= (si.pos.y + si.size.y); j++) { + for (int j = (si.position.y) - 1; j <= (si.position.y + si.size.y); j++) { Vector2 ofs; if (ABS(j) & 1) { @@ -1154,10 +1151,10 @@ void TileMapEditor::_canvas_draw() { if (node->get_half_offset() != TileMap::HALF_OFFSET_Y) { - for (int i = (si.pos.y) - 1; i <= (si.pos.y + si.size.y); i++) { + for (int i = (si.position.y) - 1; i <= (si.position.y + si.size.y); i++) { - Vector2 from = xform.xform(node->map_to_world(Vector2(si.pos.x, i))); - Vector2 to = xform.xform(node->map_to_world(Vector2(si.pos.x + si.size.x + 1, i))); + Vector2 from = xform.xform(node->map_to_world(Vector2(si.position.x, i))); + Vector2 to = xform.xform(node->map_to_world(Vector2(si.position.x + si.size.x + 1, i))); Color col = i == 0 ? Color(1, 0.8, 0.2, 0.5) : Color(1, 0.3, 0.1, 0.2); canvas_item_editor->draw_line(from, to, col, 1); @@ -1167,9 +1164,9 @@ void TileMapEditor::_canvas_draw() { } } else { - for (int i = (si.pos.y) - 1; i <= (si.pos.y + si.size.y); i++) { + for (int i = (si.position.y) - 1; i <= (si.position.y + si.size.y); i++) { - for (int j = (si.pos.x) - 1; j <= (si.pos.x + si.size.x); j++) { + for (int j = (si.position.x) - 1; j <= (si.position.x + si.size.x); j++) { Vector2 ofs; if (ABS(j) & 1) { @@ -1191,10 +1188,10 @@ void TileMapEditor::_canvas_draw() { if (selection_active) { Vector<Vector2> points; - points.push_back(xform.xform(node->map_to_world((rectangle.pos)))); - points.push_back(xform.xform(node->map_to_world((rectangle.pos + Point2(rectangle.size.x + 1, 0))))); - points.push_back(xform.xform(node->map_to_world((rectangle.pos + Point2(rectangle.size.x + 1, rectangle.size.y + 1))))); - points.push_back(xform.xform(node->map_to_world((rectangle.pos + Point2(0, rectangle.size.y + 1))))); + points.push_back(xform.xform(node->map_to_world((rectangle.position)))); + points.push_back(xform.xform(node->map_to_world((rectangle.position + Point2(rectangle.size.x + 1, 0))))); + points.push_back(xform.xform(node->map_to_world((rectangle.position + Point2(rectangle.size.x + 1, rectangle.size.y + 1))))); + points.push_back(xform.xform(node->map_to_world((rectangle.position + Point2(0, rectangle.size.y + 1))))); canvas_item_editor->draw_colored_polygon(points, Color(0.2, 0.8, 1, 0.4)); } @@ -1251,8 +1248,8 @@ void TileMapEditor::_canvas_draw() { if (id == TileMap::INVALID_CELL) return; - for (int i = rectangle.pos.y; i <= rectangle.pos.y + rectangle.size.y; i++) { - for (int j = rectangle.pos.x; j <= rectangle.pos.x + rectangle.size.x; j++) { + for (int i = rectangle.position.y; i <= rectangle.position.y + rectangle.size.y; i++) { + for (int j = rectangle.position.x; j <= rectangle.position.x + rectangle.size.x; j++) { _draw_cell(id, Point2i(j, i), flip_h, flip_v, transpose, xform); } @@ -1267,7 +1264,7 @@ void TileMapEditor::_canvas_draw() { if (ts.is_null()) return; - Point2 ofs = over_tile - rectangle.pos; + Point2 ofs = over_tile - rectangle.position; for (List<TileData>::Element *E = copydata.front(); E; E = E->next()) { @@ -1280,13 +1277,13 @@ void TileMapEditor::_canvas_draw() { } Rect2i duplicate = rectangle; - duplicate.pos = over_tile; + duplicate.position = over_tile; Vector<Vector2> points; - points.push_back(xform.xform(node->map_to_world(duplicate.pos))); - points.push_back(xform.xform(node->map_to_world((duplicate.pos + Point2(duplicate.size.x + 1, 0))))); - points.push_back(xform.xform(node->map_to_world((duplicate.pos + Point2(duplicate.size.x + 1, duplicate.size.y + 1))))); - points.push_back(xform.xform(node->map_to_world((duplicate.pos + Point2(0, duplicate.size.y + 1))))); + points.push_back(xform.xform(node->map_to_world(duplicate.position))); + points.push_back(xform.xform(node->map_to_world((duplicate.position + Point2(duplicate.size.x + 1, 0))))); + points.push_back(xform.xform(node->map_to_world((duplicate.position + Point2(duplicate.size.x + 1, duplicate.size.y + 1))))); + points.push_back(xform.xform(node->map_to_world((duplicate.position + Point2(0, duplicate.size.y + 1))))); canvas_item_editor->draw_colored_polygon(points, Color(0.2, 1.0, 0.8, 0.2)); diff --git a/editor/plugins/tile_map_editor_plugin.h b/editor/plugins/tile_map_editor_plugin.h index 3eedb6c941..981d5c66a1 100644 --- a/editor/plugins/tile_map_editor_plugin.h +++ b/editor/plugins/tile_map_editor_plugin.h @@ -158,7 +158,7 @@ class TileMapEditor : public VBoxContainer { void _text_entered(const String &p_text); void _text_changed(const String &p_text); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _update_palette(); void _canvas_draw(); void _menu_option(int p_option); @@ -179,7 +179,7 @@ protected: public: HBoxContainer *get_toolbar() const { return toolbar; } - bool forward_gui_input(const InputEvent &p_event); + bool forward_gui_input(const Ref<InputEvent> &p_event); void edit(Node *p_tile_map); TileMapEditor(EditorNode *p_editor); @@ -193,7 +193,7 @@ class TileMapEditorPlugin : public EditorPlugin { TileMapEditor *tile_map_editor; public: - virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const InputEvent &p_event) { return tile_map_editor->forward_gui_input(p_event); } + virtual bool forward_canvas_gui_input(const Transform2D &p_canvas_xform, const Ref<InputEvent> &p_event) { return tile_map_editor->forward_gui_input(p_event); } virtual String get_name() const { return "TileMap"; } bool has_main_screen() const { return false; } diff --git a/editor/plugins/tile_set_editor_plugin.cpp b/editor/plugins/tile_set_editor_plugin.cpp index e79cbd0d35..0b088f7171 100644 --- a/editor/plugins/tile_set_editor_plugin.cpp +++ b/editor/plugins/tile_set_editor_plugin.cpp @@ -37,24 +37,18 @@ void TileSetEditor::edit(const Ref<TileSet> &p_tileset) { tileset = p_tileset; } -void TileSetEditor::_import_scene(Node *scene, Ref<TileSet> p_library, bool p_merge) { - - if (!p_merge) - p_library->clear(); +void TileSetEditor::_import_node(Node *p_node, Ref<TileSet> p_library) { - for (int i = 0; i < scene->get_child_count(); i++) { + for (int i = 0; i < p_node->get_child_count(); i++) { - Node *child = scene->get_child(i); + Node *child = p_node->get_child(i); if (!child->cast_to<Sprite>()) { if (child->get_child_count() > 0) { - child = child->get_child(0); - if (!child->cast_to<Sprite>()) { - continue; - } + _import_node(child, p_library); + } - } else - continue; + continue; } Sprite *mi = child->cast_to<Sprite>(); @@ -138,6 +132,14 @@ void TileSetEditor::_import_scene(Node *scene, Ref<TileSet> p_library, bool p_me } } +void TileSetEditor::_import_scene(Node *scene, Ref<TileSet> p_library, bool p_merge) { + + if (!p_merge) + p_library->clear(); + + _import_node(scene, p_library); +} + void TileSetEditor::_menu_confirm() { switch (option) { diff --git a/editor/plugins/tile_set_editor_plugin.h b/editor/plugins/tile_set_editor_plugin.h index 42084c05a3..d04ebc7197 100644 --- a/editor/plugins/tile_set_editor_plugin.h +++ b/editor/plugins/tile_set_editor_plugin.h @@ -59,6 +59,7 @@ class TileSetEditor : public Control { void _menu_confirm(); void _name_dialog_confirm(const String &name); + static void _import_node(Node *p_node, Ref<TileSet> p_library); static void _import_scene(Node *p_scene, Ref<TileSet> p_library, bool p_merge); protected: diff --git a/editor/project_export.cpp b/editor/project_export.cpp index 90db23d236..d58454a223 100644 --- a/editor/project_export.cpp +++ b/editor/project_export.cpp @@ -229,6 +229,8 @@ void ProjectExportDialog::_edit_preset(int p_index) { } if (needs_templates) export_templates_error->show(); + else + export_templates_error->hide(); export_button->set_disabled(true); @@ -752,6 +754,7 @@ ProjectExportDialog::ProjectExportDialog() { settings_vb->add_child(runnable); sections = memnew(TabContainer); + sections->set_tab_align(TabContainer::ALIGN_LEFT); settings_vb->add_child(sections); sections->set_v_size_flags(SIZE_EXPAND_FILL); diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index 7e9dc5f4f1..a3d3d42110 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -92,18 +92,18 @@ private: if (mode != MODE_IMPORT) { - if (d->file_exists("godot.cfg")) { + if (d->file_exists("project.godot")) { - error->set_text(TTR("Invalid project path, godot.cfg must not exist.")); + error->set_text(TTR("Invalid project path, project.godot must not exist.")); memdelete(d); return ""; } } else { - if (valid_path != "" && !d->file_exists("godot.cfg")) { + if (valid_path != "" && !d->file_exists("project.godot")) { - error->set_text(TTR("Invalid project path, godot.cfg must exist.")); + error->set_text(TTR("Invalid project path, project.godot must exist.")); memdelete(d); return ""; } @@ -136,7 +136,7 @@ private: String p = p_path; if (mode == MODE_IMPORT) { - if (p.ends_with("godot.cfg")) { + if (p.ends_with("project.godot")) { p = p.get_base_dir(); } @@ -162,7 +162,7 @@ private: fdialog->set_mode(FileDialog::MODE_OPEN_FILE); fdialog->clear_filters(); - fdialog->add_filter("godot.cfg ; " _MKSTR(VERSION_NAME) " Project"); + fdialog->add_filter("project.godot ; " _MKSTR(VERSION_NAME) " Project"); } else { fdialog->set_mode(FileDialog::MODE_OPEN_DIR); } @@ -186,9 +186,9 @@ private: } else { if (mode == MODE_NEW) { - FileAccess *f = FileAccess::open(dir.plus_file("/godot.cfg"), FileAccess::WRITE); + FileAccess *f = FileAccess::open(dir.plus_file("/project.godot"), FileAccess::WRITE); if (!f) { - error->set_text(TTR("Couldn't create godot.cfg in project path.")); + error->set_text(TTR("Couldn't create project.godot in project path.")); } else { f->store_line("; Engine configuration file."); @@ -203,10 +203,23 @@ private: f->store_line("\n"); f->store_line("name=\"" + project_name->get_text() + "\""); f->store_line("icon=\"res://icon.png\""); - + f->store_line("[rendering]"); + f->store_line("viewport/default_environment=\"res://default_env.tres\""); memdelete(f); ResourceSaver::save(dir.plus_file("/icon.png"), get_icon("DefaultProjectIcon", "EditorIcons")); + + f = FileAccess::open(dir.plus_file("/default_env.tres"), FileAccess::WRITE); + if (!f) { + error->set_text(TTR("Couldn't create project.godot in project path.")); + } else { + f->store_line("[gd_resource type=\"Environment\" load_steps=2 format=2]"); + f->store_line("[sub_resource type=\"ProceduralSky\" id=1]"); + f->store_line("[resource]"); + f->store_line("background_mode = 2"); + f->store_line("background_sky = SubResource( 1 )"); + memdelete(f); + } } } else if (mode == MODE_INSTALL) { @@ -503,14 +516,16 @@ void ProjectManager::_update_project_buttons() { run_btn->set_disabled(!has_runnable_scene); } -void ProjectManager::_panel_input(const InputEvent &p_ev, Node *p_hb) { +void ProjectManager::_panel_input(const Ref<InputEvent> &p_ev, Node *p_hb) { + + Ref<InputEventMouseButton> mb = p_ev; - if (p_ev.type == InputEvent::MOUSE_BUTTON && p_ev.mouse_button.pressed && p_ev.mouse_button.button_index == BUTTON_LEFT) { + if (mb.is_valid() && mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) { String clicked = p_hb->get_meta("name"); String clicked_main_scene = p_hb->get_meta("main_scene"); - if (p_ev.key.mod.shift && selected_list.size() > 0 && last_clicked != "" && clicked != last_clicked) { + if (mb->get_shift() && selected_list.size() > 0 && last_clicked != "" && clicked != last_clicked) { int clicked_id = -1; int last_clicked_id = -1; @@ -527,7 +542,7 @@ void ProjectManager::_panel_input(const InputEvent &p_ev, Node *p_hb) { for (int i = 0; i < scroll_childs->get_child_count(); ++i) { HBoxContainer *hb = scroll_childs->get_child(i)->cast_to<HBoxContainer>(); if (!hb) continue; - if (i != clicked_id && (i < min || i > max) && !p_ev.key.mod.control) { + if (i != clicked_id && (i < min || i > max) && !mb->get_control()) { selected_list.erase(hb->get_meta("name")); } else if (i >= min && i <= max) { selected_list.insert(hb->get_meta("name"), hb->get_meta("main_scene")); @@ -535,14 +550,14 @@ void ProjectManager::_panel_input(const InputEvent &p_ev, Node *p_hb) { } } - } else if (selected_list.has(clicked) && p_ev.key.mod.control) { + } else if (selected_list.has(clicked) && mb->get_control()) { selected_list.erase(clicked); } else { last_clicked = clicked; - if (p_ev.key.mod.control || selected_list.size() == 0) { + if (mb->get_control() || selected_list.size() == 0) { selected_list.insert(clicked, clicked_main_scene); } else { selected_list.clear(); @@ -552,23 +567,23 @@ void ProjectManager::_panel_input(const InputEvent &p_ev, Node *p_hb) { _update_project_buttons(); - if (p_ev.mouse_button.doubleclick) + if (mb->is_doubleclick()) _open_project(); //open if doubleclicked } } -void ProjectManager::_unhandled_input(const InputEvent &p_ev) { +void ProjectManager::_unhandled_input(const Ref<InputEvent> &p_ev) { - if (p_ev.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_ev; - const InputEventKey &k = p_ev.key; + if (k.is_valid()) { - if (!k.pressed) + if (!k->is_pressed()) return; bool scancode_handled = true; - switch (k.scancode) { + switch (k->get_scancode()) { case KEY_RETURN: { @@ -606,7 +621,7 @@ void ProjectManager::_unhandled_input(const InputEvent &p_ev) { } break; case KEY_UP: { - if (k.mod.shift) + if (k->get_shift()) break; if (selected_list.size()) { @@ -645,7 +660,7 @@ void ProjectManager::_unhandled_input(const InputEvent &p_ev) { } case KEY_DOWN: { - if (k.mod.shift) + if (k->get_shift()) break; bool found = selected_list.empty(); @@ -679,7 +694,7 @@ void ProjectManager::_unhandled_input(const InputEvent &p_ev) { } break; case KEY_F: { - if (k.mod.command) + if (k->get_command()) this->project_filter->search_box->grab_focus(); else scancode_handled = false; @@ -741,7 +756,7 @@ void ProjectManager::_load_recent_projects() { continue; String project = _name.get_slice("/", 1); - String conf = path.plus_file("godot.cfg"); + String conf = path.plus_file("project.godot"); bool favorite = (_name.begins_with("favorite_projects/")) ? true : false; uint64_t last_modified = 0; @@ -806,11 +821,12 @@ void ProjectManager::_load_recent_projects() { if (cf->has_section_key("application", "icon")) { String appicon = cf->get_value("application", "icon"); if (appicon != "") { - Image img; - Error err = img.load(appicon.replace_first("res://", path + "/")); + Ref<Image> img; + img.instance(); + Error err = img->load(appicon.replace_first("res://", path + "/")); if (err == OK) { - img.resize(64, 64); + img->resize(64, 64); Ref<ImageTexture> it = memnew(ImageTexture); it->create_from_image(img); icon = it; @@ -898,8 +914,9 @@ void ProjectManager::_on_project_created(const String &dir) { _update_scroll_pos(dir); } else { _load_recent_projects(); - scroll->connect("draw", this, "_update_scroll_pos", varray(dir), CONNECT_ONESHOT); + _update_scroll_pos(dir); } + _open_project(); } void ProjectManager::_update_scroll_pos(const String &dir) { @@ -1006,7 +1023,7 @@ void ProjectManager::_scan_dir(DirAccess *da, float pos, float total, List<Strin while (n != String()) { if (da->current_is_dir() && !n.begins_with(".")) { subdirs.push_front(n); - } else if (n == "godot.cfg") { + } else if (n == "project.godot") { r_projects->push_back(da->get_current_dir()); } n = da->get_next(); @@ -1117,7 +1134,7 @@ void ProjectManager::_files_dropped(PoolStringArray p_files, int p_screen) { dir->list_dir_begin(); String file = dir->get_next(); while (confirm && file != String()) { - if (!dir->current_is_dir() && file.ends_with("godot.cfg")) { + if (!dir->current_is_dir() && file.ends_with("project.godot")) { confirm = false; } file = dir->get_next(); @@ -1191,7 +1208,7 @@ ProjectManager::ProjectManager() { } } - FileDialog::set_default_show_hidden_files(EditorSettings::get_singleton()->get("filesytem/file_dialog/show_hidden_files")); + FileDialog::set_default_show_hidden_files(EditorSettings::get_singleton()->get("filesystem/file_dialog/show_hidden_files")); set_area_as_parent_rect(); set_theme(create_editor_theme()); @@ -1324,7 +1341,7 @@ ProjectManager::ProjectManager() { if (StreamPeerSSL::is_available()) { asset_library = memnew(EditorAssetLibrary(true)); - asset_library->set_name("Templates"); + asset_library->set_name(TTR("Templates")); tabs->add_child(asset_library); asset_library->connect("install_asset", this, "_install_project"); } else { @@ -1453,7 +1470,7 @@ ProjectListFilter::ProjectListFilter() { _current_filter = FILTER_NAME; filter_option = memnew(OptionButton); - filter_option->set_custom_minimum_size(Size2(80, 10)); + filter_option->set_custom_minimum_size(Size2(80 * EDSCALE, 10 * EDSCALE)); filter_option->set_clip_text(true); filter_option->connect("item_selected", this, "_filter_option_selected"); add_child(filter_option); diff --git a/editor/project_manager.h b/editor/project_manager.h index 5be28ce2f0..27886132c5 100644 --- a/editor/project_manager.h +++ b/editor/project_manager.h @@ -91,8 +91,8 @@ class ProjectManager : public Control { void _install_project(const String &p_zip_path, const String &p_title); void _panel_draw(Node *p_hb); - void _panel_input(const InputEvent &p_ev, Node *p_hb); - void _unhandled_input(const InputEvent &p_ev); + void _panel_input(const Ref<InputEvent> &p_ev, Node *p_hb); + void _unhandled_input(const Ref<InputEvent> &p_ev); void _favorite_pressed(Node *p_hb); void _files_dropped(PoolStringArray p_files, int p_screen); void _scan_multiple_folders(PoolStringArray p_files); diff --git a/editor/project_settings.cpp b/editor/project_settings.cpp index a45ea26086..8ef7bd427f 100644 --- a/editor/project_settings.cpp +++ b/editor/project_settings.cpp @@ -83,10 +83,10 @@ void ProjectSettings::_notification(int p_what) { translation_list->connect("button_pressed", this, "_translation_delete"); _update_actions(); - popup_add->add_icon_item(get_icon("Keyboard", "EditorIcons"), TTR("Key "), InputEvent::KEY); //"Key " - because the word 'key' has already been used as a key animation - popup_add->add_icon_item(get_icon("JoyButton", "EditorIcons"), TTR("Joy Button"), InputEvent::JOYPAD_BUTTON); - popup_add->add_icon_item(get_icon("JoyAxis", "EditorIcons"), TTR("Joy Axis"), InputEvent::JOYPAD_MOTION); - popup_add->add_icon_item(get_icon("Mouse", "EditorIcons"), TTR("Mouse Button"), InputEvent::MOUSE_BUTTON); + popup_add->add_icon_item(get_icon("Keyboard", "EditorIcons"), TTR("Key "), INPUT_KEY); //"Key " - because the word 'key' has already been used as a key animation + popup_add->add_icon_item(get_icon("JoyButton", "EditorIcons"), TTR("Joy Button"), INPUT_JOY_BUTTON); + popup_add->add_icon_item(get_icon("JoyAxis", "EditorIcons"), TTR("Joy Axis"), INPUT_JOY_MOTION); + popup_add->add_icon_item(get_icon("Mouse", "EditorIcons"), TTR("Mouse Button"), INPUT_MOUSE_BUTTON); List<String> tfn; ResourceLoader::get_recognized_extensions_for_type("Translation", &tfn); @@ -106,6 +106,9 @@ void ProjectSettings::_notification(int p_what) { case NOTIFICATION_POPUP_HIDE: { EditorSettings::get_singleton()->set("interface/dialogs/project_settings_bounds", get_rect()); } break; + case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: { + _update_actions(); + } break; } } @@ -175,54 +178,74 @@ void ProjectSettings::_action_edited() { void ProjectSettings::_device_input_add() { - InputEvent ie; + Ref<InputEvent> ie; String name = add_at; Variant old_val = GlobalConfig::get_singleton()->get(name); Array arr = old_val; - ie.device = device_id->get_value(); - - ie.type = add_type; + // ie.device = device_id->get_value(); + // ie.type = add_type; switch (add_type) { - case InputEvent::MOUSE_BUTTON: { + case INPUT_MOUSE_BUTTON: { - ie.mouse_button.button_index = device_index->get_selected() + 1; + Ref<InputEventMouseButton> mb; + mb.instance(); + mb->set_button_index(device_index->get_selected() + 1); + mb->set_device(device_id->get_value()); for (int i = 0; i < arr.size(); i++) { - InputEvent aie = arr[i]; - if (aie.device == ie.device && aie.type == InputEvent::MOUSE_BUTTON && aie.mouse_button.button_index == ie.mouse_button.button_index) { + Ref<InputEventMouseButton> aie = arr[i]; + if (aie.is_null()) + continue; + if (aie->get_device() == mb->get_device() && aie->get_button_index() == mb->get_button_index()) { return; } } + ie = mb; + } break; - case InputEvent::JOYPAD_MOTION: { + case INPUT_JOY_MOTION: { - ie.joy_motion.axis = device_index->get_selected() >> 1; - ie.joy_motion.axis_value = device_index->get_selected() & 1 ? 1 : -1; + Ref<InputEventJoypadMotion> jm; + jm.instance(); + jm->set_axis(device_index->get_selected() >> 1); + jm->set_axis_value(device_index->get_selected() & 1 ? 1 : -1); + jm->set_device(device_id->get_value()); for (int i = 0; i < arr.size(); i++) { - InputEvent aie = arr[i]; - if (aie.device == ie.device && aie.type == InputEvent::JOYPAD_MOTION && aie.joy_motion.axis == ie.joy_motion.axis && aie.joy_motion.axis_value == ie.joy_motion.axis_value) { + Ref<InputEventJoypadMotion> aie = arr[i]; + if (aie.is_null()) + continue; + if (aie->get_device() == jm->get_device() && aie->get_axis() == jm->get_axis() && aie->get_axis_value() == jm->get_axis_value()) { return; } } + ie = jm; + } break; - case InputEvent::JOYPAD_BUTTON: { + case INPUT_JOY_BUTTON: { + + Ref<InputEventJoypadButton> jb; + jb.instance(); - ie.joy_button.button_index = device_index->get_selected(); + jb->set_button_index(device_index->get_selected()); + jb->set_device(device_id->get_value()); for (int i = 0; i < arr.size(); i++) { - InputEvent aie = arr[i]; - if (aie.device == ie.device && aie.type == InputEvent::JOYPAD_BUTTON && aie.joy_button.button_index == ie.joy_button.button_index) { + Ref<InputEventJoypadButton> aie = arr[i]; + if (aie.is_null()) + continue; + if (aie->get_device() == jb->get_device() && aie->get_button_index() == jb->get_button_index()) { return; } } + ie = jb; } break; default: {} @@ -244,13 +267,17 @@ void ProjectSettings::_device_input_add() { void ProjectSettings::_press_a_key_confirm() { - if (last_wait_for_key.type != InputEvent::KEY) + if (last_wait_for_key.is_null()) return; - InputEvent ie; - ie.type = InputEvent::KEY; - ie.key.scancode = last_wait_for_key.key.scancode; - ie.key.mod = last_wait_for_key.key.mod; + Ref<InputEventKey> ie; + ie.instance(); + ie->set_scancode(last_wait_for_key->get_scancode()); + ie->set_shift(last_wait_for_key->get_shift()); + ie->set_alt(last_wait_for_key->get_alt()); + ie->set_control(last_wait_for_key->get_control()); + ie->set_metakey(last_wait_for_key->get_metakey()); + String name = add_at; Variant old_val = GlobalConfig::get_singleton()->get(name); @@ -258,8 +285,10 @@ void ProjectSettings::_press_a_key_confirm() { for (int i = 0; i < arr.size(); i++) { - InputEvent aie = arr[i]; - if (aie.type == InputEvent::KEY && aie.key.scancode == ie.key.scancode && aie.key.mod == ie.key.mod) { + Ref<InputEventKey> aie = arr[i]; + if (aie.is_null()) + continue; + if (aie->get_scancode_with_modifiers() == ie->get_scancode_with_modifiers()) { return; } } @@ -278,7 +307,7 @@ void ProjectSettings::_press_a_key_confirm() { _show_last_added(ie, name); } -void ProjectSettings::_show_last_added(const InputEvent &p_event, const String &p_name) { +void ProjectSettings::_show_last_added(const Ref<InputEvent> &p_event, const String &p_name) { TreeItem *r = input_editor->get_root(); String name = p_name; @@ -311,19 +340,21 @@ void ProjectSettings::_show_last_added(const InputEvent &p_event, const String & if (found) input_editor->ensure_cursor_is_visible(); } -void ProjectSettings::_wait_for_key(const InputEvent &p_event) { +void ProjectSettings::_wait_for_key(const Ref<InputEvent> &p_event) { + + Ref<InputEventKey> k = p_event; - if (p_event.type == InputEvent::KEY && p_event.key.pressed && p_event.key.scancode != 0) { + if (k.is_valid() && k->is_pressed() && k->get_scancode() != 0) { last_wait_for_key = p_event; - String str = keycode_get_string(p_event.key.scancode).capitalize(); - if (p_event.key.mod.meta) + String str = keycode_get_string(k->get_scancode()).capitalize(); + if (k->get_metakey()) str = TTR("Meta+") + str; - if (p_event.key.mod.shift) + if (k->get_shift()) str = TTR("Shift+") + str; - if (p_event.key.mod.alt) + if (k->get_alt()) str = TTR("Alt+") + str; - if (p_event.key.mod.control) + if (k->get_control()) str = TTR("Control+") + str; press_a_key_label->set_text(str); @@ -333,18 +364,18 @@ void ProjectSettings::_wait_for_key(const InputEvent &p_event) { void ProjectSettings::_add_item(int p_item) { - add_type = InputEvent::Type(p_item); + add_type = InputType(p_item); switch (add_type) { - case InputEvent::KEY: { + case INPUT_KEY: { press_a_key_label->set_text(TTR("Press a Key..")); - last_wait_for_key = InputEvent(); + last_wait_for_key = Ref<InputEvent>(); press_a_key->popup_centered(Size2(250, 80) * EDSCALE); press_a_key->grab_focus(); } break; - case InputEvent::MOUSE_BUTTON: { + case INPUT_MOUSE_BUTTON: { device_id->set_value(0); device_index_label->set_text(TTR("Mouse Button Index:")); @@ -360,7 +391,7 @@ void ProjectSettings::_add_item(int p_item) { device_index->add_item(TTR("Button 9")); device_input->popup_centered_minsize(Size2(350, 95)); } break; - case InputEvent::JOYPAD_MOTION: { + case INPUT_JOY_MOTION: { device_id->set_value(0); device_index_label->set_text(TTR("Joypad Axis Index:")); @@ -373,7 +404,7 @@ void ProjectSettings::_add_item(int p_item) { device_input->popup_centered_minsize(Size2(350, 95)); } break; - case InputEvent::JOYPAD_BUTTON: { + case INPUT_JOY_BUTTON: { device_id->set_value(0); device_index_label->set_text(TTR("Joypad Button Index:")); @@ -399,8 +430,8 @@ void ProjectSettings::_action_button_pressed(Object *p_obj, int p_column, int p_ if (p_id == 1) { Point2 ofs = input_editor->get_global_position(); Rect2 ir = input_editor->get_item_rect(ti); - ir.pos.y -= input_editor->get_scroll().y; - ofs += ir.pos + ir.size; + ir.position.y -= input_editor->get_scroll().y; + ofs += ir.position + ir.size; ofs.x -= 100; popup_add->set_position(ofs); popup_add->popup(); @@ -481,9 +512,9 @@ void ProjectSettings::_update_actions() { TreeItem *item = input_editor->create_item(root); //item->set_cell_mode(0,TreeItem::CELL_MODE_CHECK); item->set_text(0, name); - item->add_button(0, get_icon("Add", "EditorIcons"), 1); + item->add_button(0, get_icon("Add", "EditorIcons"), 1, false, TTR("Add Event")); if (!GlobalConfig::get_singleton()->get_input_presets().find(pi.name)) { - item->add_button(0, get_icon("Remove", "EditorIcons"), 2); + item->add_button(0, get_icon("Remove", "EditorIcons"), 2, false, TTR("Remove")); item->set_editable(0, true); } item->set_custom_bg_color(0, get_color("prop_subsection", "Editor")); @@ -493,67 +524,72 @@ void ProjectSettings::_update_actions() { for (int i = 0; i < actions.size(); i++) { - if (actions[i].get_type() != Variant::INPUT_EVENT) + Ref<InputEvent> ie = actions[i]; + if (ie.is_null()) continue; - InputEvent ie = actions[i]; TreeItem *action = input_editor->create_item(item); - switch (ie.type) { - - case InputEvent::KEY: { - - String str = keycode_get_string(ie.key.scancode).capitalize(); - if (ie.key.mod.meta) - str = TTR("Meta+") + str; - if (ie.key.mod.shift) - str = TTR("Shift+") + str; - if (ie.key.mod.alt) - str = TTR("Alt+") + str; - if (ie.key.mod.control) - str = TTR("Control+") + str; - - action->set_text(0, str); - action->set_icon(0, get_icon("Keyboard", "EditorIcons")); - - } break; - case InputEvent::JOYPAD_BUTTON: { - - String str = TTR("Device") + " " + itos(ie.device) + ", " + TTR("Button") + " " + itos(ie.joy_button.button_index); - if (ie.joy_button.button_index >= 0 && ie.joy_button.button_index < JOY_BUTTON_MAX) - str += String() + " (" + _button_names[ie.joy_button.button_index] + ")."; - else - str += "."; - - action->set_text(0, str); - action->set_icon(0, get_icon("JoyButton", "EditorIcons")); - } break; - case InputEvent::MOUSE_BUTTON: { - - String str = TTR("Device") + " " + itos(ie.device) + ", "; - switch (ie.mouse_button.button_index) { - case BUTTON_LEFT: str += TTR("Left Button."); break; - case BUTTON_RIGHT: str += TTR("Right Button."); break; - case BUTTON_MIDDLE: str += TTR("Middle Button."); break; - case BUTTON_WHEEL_UP: str += TTR("Wheel Up."); break; - case BUTTON_WHEEL_DOWN: str += TTR("Wheel Down."); break; - default: str += TTR("Button") + " " + itos(ie.mouse_button.button_index) + "."; - } - - action->set_text(0, str); - action->set_icon(0, get_icon("Mouse", "EditorIcons")); - } break; - case InputEvent::JOYPAD_MOTION: { - - int ax = ie.joy_motion.axis; - int n = 2 * ax + (ie.joy_motion.axis_value < 0 ? 0 : 1); - String desc = _axis_names[n]; - String str = TTR("Device") + " " + itos(ie.device) + ", " + TTR("Axis") + " " + itos(ax) + " " + (ie.joy_motion.axis_value < 0 ? "-" : "+") + desc + "."; - action->set_text(0, str); - action->set_icon(0, get_icon("JoyAxis", "EditorIcons")); - } break; + Ref<InputEventKey> k = ie; + if (k.is_valid()) { + + String str = keycode_get_string(k->get_scancode()).capitalize(); + if (k->get_metakey()) + str = TTR("Meta+") + str; + if (k->get_shift()) + str = TTR("Shift+") + str; + if (k->get_alt()) + str = TTR("Alt+") + str; + if (k->get_control()) + str = TTR("Control+") + str; + + action->set_text(0, str); + action->set_icon(0, get_icon("Keyboard", "EditorIcons")); + } + + Ref<InputEventJoypadButton> jb = ie; + + if (jb.is_valid()) { + + String str = TTR("Device") + " " + itos(jb->get_device()) + ", " + TTR("Button") + " " + itos(jb->get_button_index()); + if (jb->get_button_index() >= 0 && jb->get_button_index() < JOY_BUTTON_MAX) + str += String() + " (" + _button_names[jb->get_button_index()] + ")."; + else + str += "."; + + action->set_text(0, str); + action->set_icon(0, get_icon("JoyButton", "EditorIcons")); + } + + Ref<InputEventMouseButton> mb = ie; + + if (mb.is_valid()) { + String str = TTR("Device") + " " + itos(mb->get_device()) + ", "; + switch (mb->get_button_index()) { + case BUTTON_LEFT: str += TTR("Left Button."); break; + case BUTTON_RIGHT: str += TTR("Right Button."); break; + case BUTTON_MIDDLE: str += TTR("Middle Button."); break; + case BUTTON_WHEEL_UP: str += TTR("Wheel Up."); break; + case BUTTON_WHEEL_DOWN: str += TTR("Wheel Down."); break; + default: str += TTR("Button") + " " + itos(mb->get_button_index()) + "."; + } + + action->set_text(0, str); + action->set_icon(0, get_icon("Mouse", "EditorIcons")); + } + + Ref<InputEventJoypadMotion> jm = ie; + + if (jm.is_valid()) { + + int ax = jm->get_axis(); + int n = 2 * ax + (jm->get_axis_value() < 0 ? 0 : 1); + String desc = _axis_names[n]; + String str = TTR("Device") + " " + itos(jm->get_device()) + ", " + TTR("Axis") + " " + itos(ax) + " " + (jm->get_axis_value() < 0 ? "-" : "+") + desc + "."; + action->set_text(0, str); + action->set_icon(0, get_icon("JoyAxis", "EditorIcons")); } - action->add_button(0, get_icon("Remove", "EditorIcons"), 2); + action->add_button(0, get_icon("Remove", "EditorIcons"), 2, false, TTR("Remove")); action->set_metadata(0, i); action->set_meta("__input", ie); } @@ -1012,7 +1048,7 @@ void ProjectSettings::_update_translations() { t->set_text(0, translations[i].replace_first("res://", "")); t->set_tooltip(0, translations[i]); t->set_metadata(0, i); - t->add_button(0, get_icon("Del", "EditorIcons"), 0); + t->add_button(0, get_icon("Del", "EditorIcons"), 0, false, TTR("Remove")); } } @@ -1058,7 +1094,7 @@ void ProjectSettings::_update_translations() { t->set_text(0, keys[i].replace_first("res://", "")); t->set_tooltip(0, keys[i]); t->set_metadata(0, keys[i]); - t->add_button(0, get_icon("Del", "EditorIcons"), 0); + t->add_button(0, get_icon("Del", "EditorIcons"), 0, false, TTR("Remove")); if (keys[i] == remap_selected) { t->select(0); translation_res_option_add_button->set_disabled(false); @@ -1076,7 +1112,7 @@ void ProjectSettings::_update_translations() { t2->set_text(0, path.replace_first("res://", "")); t2->set_tooltip(0, path); t2->set_metadata(0, j); - t2->add_button(0, get_icon("Del", "EditorIcons"), 0); + t2->add_button(0, get_icon("Del", "EditorIcons"), 0, false, TTR("Remove")); t2->set_cell_mode(1, TreeItem::CELL_MODE_RANGE); t2->set_text(1, langnames); t2->set_editable(1, true); @@ -1168,12 +1204,13 @@ void ProjectSettings::_bind_methods() { ProjectSettings::ProjectSettings(EditorData *p_data) { singleton = this; - set_title(TTR("Project Settings (godot.cfg)")); + set_title(TTR("Project Settings (project.godot)")); set_resizable(true); undo_redo = &p_data->get_undo_redo(); data = p_data; tab_container = memnew(TabContainer); + tab_container->set_tab_align(TabContainer::ALIGN_LEFT); add_child(tab_container); //set_child_rect(tab_container); @@ -1264,7 +1301,6 @@ ProjectSettings::ProjectSettings(EditorData *p_data) { //globals_editor->hide_top_label(); globals_editor->set_v_size_flags(Control::SIZE_EXPAND_FILL); globals_editor->get_property_editor()->register_text_enter(search_box); - globals_editor->get_property_editor()->set_capitalize_paths(false); globals_editor->get_property_editor()->get_scene_tree()->connect("cell_selected", this, "_item_selected"); globals_editor->get_property_editor()->connect("property_toggled", this, "_item_checked", varray(), CONNECT_DEFERRED); globals_editor->get_property_editor()->connect("property_edited", this, "_settings_prop_edited"); @@ -1416,6 +1452,7 @@ ProjectSettings::ProjectSettings(EditorData *p_data) { //translations TabContainer *translations = memnew(TabContainer); + translations->set_tab_align(TabContainer::ALIGN_LEFT); translations->set_name(TTR("Localization")); tab_container->add_child(translations); diff --git a/editor/project_settings.h b/editor/project_settings.h index a5a9e04250..47fb45cf8e 100644 --- a/editor/project_settings.h +++ b/editor/project_settings.h @@ -43,10 +43,17 @@ class ProjectSettings : public AcceptDialog { GDCLASS(ProjectSettings, AcceptDialog); + enum InputType { + INPUT_KEY, + INPUT_JOY_BUTTON, + INPUT_JOY_MOTION, + INPUT_MOUSE_BUTTON + }; + TabContainer *tab_container; Timer *timer; - InputEvent::Type add_type; + InputType add_type; String add_at; EditorData *data; @@ -77,7 +84,7 @@ class ProjectSettings : public AcceptDialog { bool setting; bool updating_translations; - InputEvent last_wait_for_key; + Ref<InputEventKey> last_wait_for_key; EditorFileDialog *translation_file_open; Tree *translation_list; @@ -108,9 +115,9 @@ class ProjectSettings : public AcceptDialog { void _action_selected(); void _action_edited(); void _action_button_pressed(Object *p_obj, int p_column, int p_id); - void _wait_for_key(const InputEvent &p_event); + void _wait_for_key(const Ref<InputEvent> &p_event); void _press_a_key_confirm(); - void _show_last_added(const InputEvent &p_event, const String &p_name); + void _show_last_added(const Ref<InputEvent> &p_event, const String &p_name); void _settings_prop_edited(const String &p_name); void _settings_changed(); diff --git a/editor/property_editor.cpp b/editor/property_editor.cpp index 86136fa78b..da26c84e45 100644 --- a/editor/property_editor.cpp +++ b/editor/property_editor.cpp @@ -65,6 +65,9 @@ void CustomPropertyEditor::_notification(int p_what) { VisualServer::get_singleton()->canvas_item_add_rect(ci, Rect2( 10,10,60, get_size().height-20 ), v ); }*/ } + if (p_what == MainLoop::NOTIFICATION_WM_QUIT_REQUEST) { + hide(); + } } void CustomPropertyEditor::_menu_option(int p_which) { @@ -116,7 +119,6 @@ void CustomPropertyEditor::_menu_option(int p_which) { Set<String> valid_extensions; for (List<String>::Element *E = extensions.front(); E; E = E->next()) { - print_line("found: " + E->get()); valid_extensions.insert(E->get()); } @@ -324,7 +326,7 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: c->show(); checks20gc->set_size(checks20gc->get_minimum_size()); - set_size(checks20gc->get_position() + checks20gc->get_size() + Vector2(4, 4) * EDSCALE); + set_size(checks20gc->get_position() + checks20gc->get_size() + c->get_size() + Vector2(4, 4) * EDSCALE); } break; case Variant::INT: @@ -610,12 +612,9 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: type = Variant::Type(Variant::Type(i)); } } - InputEvent::Type iet = InputEvent::NONE; - if (hint_text.find(".") != -1) { - iet = InputEvent::Type(int(hint_text.get_slice(".", 1).to_int())); - } + if (type) - property_select->select_property_from_basic_type(type, iet, v); + property_select->select_property_from_basic_type(type, v); updating = false; return false; @@ -682,8 +681,8 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: field_names.push_back("h"); config_value_editors(4, 4, 10, field_names); Rect2 r = v; - value_editor[0]->set_text(String::num(r.pos.x)); - value_editor[1]->set_text(String::num(r.pos.y)); + value_editor[0]->set_text(String::num(r.position.x)); + value_editor[1]->set_text(String::num(r.position.y)); value_editor[2]->set_text(String::num(r.size.x)); value_editor[3]->set_text(String::num(r.size.y)); } break; @@ -737,9 +736,9 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: config_value_editors(6, 3, 16, field_names); Rect3 aabb = v; - value_editor[0]->set_text(String::num(aabb.pos.x)); - value_editor[1]->set_text(String::num(aabb.pos.y)); - value_editor[2]->set_text(String::num(aabb.pos.z)); + value_editor[0]->set_text(String::num(aabb.position.x)); + value_editor[1]->set_text(String::num(aabb.position.y)); + value_editor[2]->set_text(String::num(aabb.position.z)); value_editor[3]->set_text(String::num(aabb.size.x)); value_editor[4]->set_text(String::num(aabb.size.y)); value_editor[5]->set_text(String::num(aabb.size.z)); @@ -862,15 +861,7 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: */ } break; - case Variant::IMAGE: { - - List<String> names; - names.push_back(TTR("New")); - names.push_back(TTR("Load")); - names.push_back(TTR("Clear")); - config_action_buttons(names); - } break; case Variant::NODE_PATH: { List<String> names; @@ -988,9 +979,6 @@ bool CustomPropertyEditor::edit(Object *p_owner, const String &p_name, Variant:: return false; } break; - case Variant::INPUT_EVENT: { - - } break; case Variant::DICTIONARY: { } break; @@ -1062,16 +1050,6 @@ void CustomPropertyEditor::_file_selected(String p_file) { emit_signal("variant_changed"); hide(); } break; - case Variant::IMAGE: { - - Image image; - Error err = ImageLoader::load_image(p_file, &image); - ERR_EXPLAIN(TTR("Couldn't load image")); - ERR_FAIL_COND(err); - v = image; - emit_signal("variant_changed"); - hide(); - } break; default: {} } } @@ -1388,36 +1366,7 @@ void CustomPropertyEditor::_action_pressed(int p_which) { } } break; - case Variant::IMAGE: { - - if (p_which == 0) { - //new image too difficult - ERR_PRINT("New Image Unimplemented"); - - } else if (p_which == 1) { - - file->set_access(EditorFileDialog::ACCESS_RESOURCES); - file->set_mode(EditorFileDialog::MODE_OPEN_FILE); - List<String> extensions; - ImageLoader::get_recognized_extensions(&extensions); - - file->clear_filters(); - - for (List<String>::Element *E = extensions.front(); E; E = E->next()) { - - file->add_filter("*." + E->get() + " ; " + E->get().to_upper()); - } - file->popup_centered_ratio(); - - } else if (p_which == 2) { - - v = Image(); - emit_signal("variant_changed"); - hide(); - } - - } break; default: {}; } } @@ -1449,11 +1398,13 @@ void CustomPropertyEditor::_scroll_modified(double p_value) { */ } -void CustomPropertyEditor::_drag_easing(const InputEvent &p_ev) { +void CustomPropertyEditor::_drag_easing(const Ref<InputEvent> &p_ev) { + + Ref<InputEventMouseMotion> mm = p_ev; - if (p_ev.type == InputEvent::MOUSE_MOTION && p_ev.mouse_motion.button_mask & BUTTON_MASK_LEFT) { + if (mm.is_valid() && mm->get_button_mask() & BUTTON_MASK_LEFT) { - float rel = p_ev.mouse_motion.relative_x; + float rel = mm->get_relative().x; if (rel == 0) return; @@ -1482,8 +1433,8 @@ void CustomPropertyEditor::_drag_easing(const InputEvent &p_ev) { //emit_signal("variant_changed"); emit_signal("variant_changed"); } - if (p_ev.type == InputEvent::MOUSE_BUTTON && p_ev.mouse_button.button_index == BUTTON_LEFT) { - } + // if (p_ev.type == Ref<InputEvent>::MOUSE_BUTTON && p_ev->get_button_index() == BUTTON_LEFT) { + // } } void CustomPropertyEditor::_draw_easing() { @@ -1591,13 +1542,13 @@ void CustomPropertyEditor::_modified(String p_string) { Rect2 r2; if (evaluator) { - r2.pos.x = evaluator->eval(value_editor[0]->get_text()); - r2.pos.y = evaluator->eval(value_editor[1]->get_text()); + r2.position.x = evaluator->eval(value_editor[0]->get_text()); + r2.position.y = evaluator->eval(value_editor[1]->get_text()); r2.size.x = evaluator->eval(value_editor[2]->get_text()); r2.size.y = evaluator->eval(value_editor[3]->get_text()); } else { - r2.pos.x = value_editor[0]->get_text().to_double(); - r2.pos.y = value_editor[1]->get_text().to_double(); + r2.position.x = value_editor[0]->get_text().to_double(); + r2.position.y = value_editor[1]->get_text().to_double(); r2.size.x = value_editor[2]->get_text().to_double(); r2.size.y = value_editor[3]->get_text().to_double(); } @@ -1757,17 +1708,12 @@ void CustomPropertyEditor::_modified(String p_string) { emit_signal("variant_changed"); */ } break; - case Variant::IMAGE: { - } break; case Variant::NODE_PATH: { v = NodePath(value_editor[0]->get_text()); emit_signal("variant_changed"); } break; - case Variant::INPUT_EVENT: { - - } break; case Variant::DICTIONARY: { } break; @@ -2358,15 +2304,6 @@ void PropertyEditor::set_item_text(TreeItem *p_item, int p_type, const String &p //p_item->set_text(1,obj->get(p_name)); } break; - case Variant::IMAGE: { - - Image img = obj->get(p_name); - if (img.empty()) - p_item->set_text(1, "[Image (empty)]"); - else - p_item->set_text(1, "[Image " + itos(img.get_width()) + "x" + itos(img.get_height()) + "-" + String(Image::get_format_name(img.get_format())) + "]"); - - } break; case Variant::NODE_PATH: { p_item->set_text(1, obj->get(p_name)); @@ -2376,6 +2313,7 @@ void PropertyEditor::set_item_text(TreeItem *p_item, int p_type, const String &p if (obj->get(p_name).get_type() == Variant::NIL || obj->get(p_name).operator RefPtr().is_null()) { p_item->set_text(1, "<null>"); p_item->set_icon(1, Ref<Texture>()); + p_item->set_custom_as_button(1, false); Dictionary d = p_item->get_metadata(0); int hint = d.has("hint") ? d["hint"].operator int() : -1; @@ -2385,9 +2323,14 @@ void PropertyEditor::set_item_text(TreeItem *p_item, int p_type, const String &p } } else { + p_item->set_custom_as_button(1, true); RES res = obj->get(p_name).operator RefPtr(); if (res->is_class("Texture")) { int tw = EditorSettings::get_singleton()->get("docks/property_editor/texture_preview_width"); + Vector2 size(res->call("get_width"), res->call("get_height")); + if (size.width < size.height) { + tw = MAX((size.width / size.height) * tw, 1); + } p_item->set_icon_max_width(1, tw); p_item->set_icon(1, res); p_item->set_text(1, ""); @@ -2427,7 +2370,9 @@ void PropertyEditor::set_item_text(TreeItem *p_item, int p_type, const String &p } } - if (!res->is_class("Texture")) { + if (res->is_class("Script")) { + p_item->set_text(1, res->get_path().get_file()); + } else if (!res->is_class("Texture")) { //texture already previews via itself EditorResourcePreview::get_singleton()->queue_edited_resource_preview(res, this, "_resource_preview_done", p_item->get_instance_ID()); } @@ -2745,6 +2690,10 @@ void PropertyEditor::_notification(int p_what) { changing = false; } + + if (p_what == EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED) { + update_tree(); + } } TreeItem *PropertyEditor::get_parent_node(String p_path, HashMap<String, TreeItem *> &item_paths, TreeItem *root) { @@ -2764,10 +2713,7 @@ TreeItem *PropertyEditor::get_parent_node(String p_path, HashMap<String, TreeIte item = tree->create_item(parent); String name = (p_path.find("/") != -1) ? p_path.right(p_path.find_last("/") + 1) : p_path; - if (capitalize_paths) - item->set_text(0, name.capitalize()); - else - item->set_text(0, name); + item->set_text(0, capitalize_paths ? name.capitalize() : name); item->set_tooltip(0, p_path); if (item->get_parent() != root) { item->set_icon(0, get_icon("Folder", "EditorIcons")); @@ -3400,6 +3346,13 @@ void PropertyEditor::update_tree() { item->set_icon(0, get_icon("ArrayData", "EditorIcons")); } break; + case Variant::DICTIONARY: { + + item->set_cell_mode(1, TreeItem::CELL_MODE_STRING); + item->set_editable(1, false); + item->set_text(1, obj->get(p.name).operator String()); + + } break; case Variant::POOL_INT_ARRAY: { @@ -3579,19 +3532,7 @@ void PropertyEditor::update_tree() { item->set_icon(0, get_icon("Color", "EditorIcons")); } break; - case Variant::IMAGE: { - - item->set_cell_mode(1, TreeItem::CELL_MODE_CUSTOM); - item->set_editable(1, !read_only); - Image img = obj->get(p.name); - if (img.empty()) - item->set_text(1, "[Image (empty)]"); - else - item->set_text(1, "[Image " + itos(img.get_width()) + "x" + itos(img.get_height()) + "-" + String(Image::get_format_name(img.get_format())) + "]"); - if (show_type_icons) - item->set_icon(0, get_icon("Image", "EditorIcons")); - } break; case Variant::NODE_PATH: { item->set_cell_mode(1, TreeItem::CELL_MODE_STRING); @@ -3604,20 +3545,28 @@ void PropertyEditor::update_tree() { item->set_cell_mode(1, TreeItem::CELL_MODE_CUSTOM); item->set_editable(1, !read_only); - item->add_button(1, get_icon("EditResource", "EditorIcons")); + //item->add_button(1, get_icon("EditResource", "EditorIcons")); String type; if (p.hint == PROPERTY_HINT_RESOURCE_TYPE) type = p.hint_string; - if (obj->get(p.name).get_type() == Variant::NIL || obj->get(p.name).operator RefPtr().is_null()) { + RES res = obj->get(p.name).operator RefPtr(); + + if (obj->get(p.name).get_type() == Variant::NIL || res.is_null()) { item->set_text(1, "<null>"); item->set_icon(1, Ref<Texture>()); + item->set_custom_as_button(1, false); - } else { - RES res = obj->get(p.name).operator RefPtr(); + } else if (res.is_valid()) { + + item->set_custom_as_button(1, true); if (res->is_class("Texture")) { int tw = EditorSettings::get_singleton()->get("docks/property_editor/texture_preview_width"); + Vector2 size(res->call("get_width"), res->call("get_height")); + if (size.width < size.height) { + tw = MAX((size.width / size.height) * tw, 1); + } item->set_icon_max_width(1, tw); item->set_icon(1, res); item->set_text(1, ""); @@ -3641,7 +3590,9 @@ void PropertyEditor::update_tree() { } else if (res.is_valid()) { item->set_tooltip(1, res->get_name() + " (" + res->get_class() + ")"); } - if (!res->is_class("Texture")) { + if (res->is_class("Script")) { + item->set_text(1, res->get_path().get_file()); + } else if (!res->is_class("Texture")) { //texture already previews via itself EditorResourcePreview::get_singleton()->queue_edited_resource_preview(res, this, "_resource_preview_done", item->get_instance_ID()); } @@ -3726,7 +3677,7 @@ void PropertyEditor::_draw_transparency(Object *t, const Rect2 &p_rect) { // make a little space between consecutive color fields Rect2 area = p_rect; - area.pos.y += 1; + area.position.y += 1; area.size.height -= 2; area.size.width -= arrow->get_size().width + 5; tree->draw_texture_rect(get_icon("Transparent", "EditorIcons"), area, true); @@ -3907,17 +3858,22 @@ void PropertyEditor::_item_edited() { case Variant::COLOR: { //_edit_set(name,item->get_custom_bg_color(0)); } break; - case Variant::IMAGE: { - } break; case Variant::NODE_PATH: { _edit_set(name, NodePath(item->get_text(1)), refresh_all); } break; + case Variant::OBJECT: { + if (!item->is_custom_set_as_button(1)) + break; - case Variant::INPUT_EVENT: { + RES res = obj->get(name); + if (res.is_valid()) { + emit_signal("resource_selected", res.get_ref_ptr(), name); + } } break; + case Variant::DICTIONARY: { } break; @@ -3989,7 +3945,7 @@ void PropertyEditor::_custom_editor_request(bool p_arrow) { int hint = d.has("hint") ? d["hint"].operator int() : -1; String hint_text = d.has("hint_text") ? d["hint_text"] : ""; Rect2 where = tree->get_custom_popup_rect(); - custom_editor->set_position(where.pos); + custom_editor->set_position(where.position); if (custom_editor->edit(obj, name, type, v, hint, hint_text)) { custom_editor->popup(); @@ -4096,9 +4052,9 @@ void PropertyEditor::_edit_button(Object *p_item, int p_column, int p_button) { Variant v = obj->get(n); custom_editor->edit(obj, n, (Variant::Type)t, v, h, ht); Rect2 where = tree->get_item_rect(ti, 1); - where.pos -= tree->get_scroll(); - where.pos += tree->get_global_position(); - custom_editor->set_position(where.pos); + where.position -= tree->get_scroll(); + where.position += tree->get_global_position(); + custom_editor->set_position(where.position); custom_editor->popup(); } else if (t == Variant::STRING) { @@ -4109,9 +4065,9 @@ void PropertyEditor::_edit_button(Object *p_item, int p_column, int p_button) { if (h == PROPERTY_HINT_FILE || h == PROPERTY_HINT_DIR || h == PROPERTY_HINT_GLOBAL_DIR || h == PROPERTY_HINT_GLOBAL_FILE) { Rect2 where = tree->get_item_rect(ti, 1); - where.pos -= tree->get_scroll(); - where.pos += tree->get_global_position(); - custom_editor->set_position(where.pos); + where.position -= tree->get_scroll(); + where.position += tree->get_global_position(); + custom_editor->set_position(where.position); custom_editor->popup(); } else { custom_editor->popup_centered_ratio(); @@ -4187,7 +4143,7 @@ void PropertyEditor::_draw_flags(Object *t, const Rect2 &p_rect) { if (i == 1) ofs.y += bsize + 1; - ofs += p_rect.pos; + ofs += p_rect.position; for (int j = 0; j < 10; j++) { Point2 o = ofs + Point2(j * (bsize + 1), 0); @@ -4287,9 +4243,15 @@ String PropertyEditor::get_selected_path() const { return ""; } -void PropertyEditor::set_capitalize_paths(bool p_capitalize) { +bool PropertyEditor::is_capitalize_paths_enabled() const { + + return capitalize_paths; +} + +void PropertyEditor::set_enable_capitalize_paths(bool p_capitalize) { capitalize_paths = p_capitalize; + update_tree_pending = true; } void PropertyEditor::set_autoclear(bool p_enable) { @@ -4389,6 +4351,7 @@ PropertyEditor::PropertyEditor() { capitalize_paths = true; autoclear = false; tree->set_column_titles_visible(false); + tree->add_constant_override("button_margin", 0); keying = false; read_only = false; diff --git a/editor/property_editor.h b/editor/property_editor.h index 3b68e80ac3..c02c301acf 100644 --- a/editor/property_editor.h +++ b/editor/property_editor.h @@ -134,7 +134,7 @@ class CustomPropertyEditor : public Popup { void _draw_easing(); void _menu_option(int p_which); - void _drag_easing(const InputEvent &p_ev); + void _drag_easing(const Ref<InputEvent> &p_ev); void _node_path_selected(NodePath p_path); void show_value_editors(int p_amount); @@ -272,7 +272,8 @@ public: custom_editor->set_read_only(p_read_only); } - void set_capitalize_paths(bool p_capitalize); + bool is_capitalize_paths_enabled() const; + void set_enable_capitalize_paths(bool p_capitalize); void set_autoclear(bool p_enable); void set_show_categories(bool p_show); diff --git a/editor/property_selector.cpp b/editor/property_selector.cpp index 565d25e0e5..47e5994e3f 100644 --- a/editor/property_selector.cpp +++ b/editor/property_selector.cpp @@ -37,17 +37,19 @@ void PropertySelector::_text_changed(const String &p_newtext) { _update_search(); } -void PropertySelector::_sbox_input(const InputEvent &p_ie) { +void PropertySelector::_sbox_input(const Ref<InputEvent> &p_ie) { - if (p_ie.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_ie; - switch (p_ie.key.scancode) { + if (k.is_valid()) { + + switch (k->get_scancode()) { case KEY_UP: case KEY_DOWN: case KEY_PAGEUP: case KEY_PAGEDOWN: { - search_options->call("_gui_input", p_ie); + search_options->call("_gui_input", k); search_box->accept_event(); TreeItem *root = search_options->get_root(); @@ -89,14 +91,8 @@ void PropertySelector::_update_search() { instance->get_property_list(&props, true); } else if (type != Variant::NIL) { Variant v; - if (type == Variant::INPUT_EVENT) { - InputEvent ie; - ie.type = event_type; - v = ie; - } else { - Variant::CallError ce; - v = Variant::construct(type, NULL, 0, ce); - } + Variant::CallError ce; + v = Variant::construct(type, NULL, 0, ce); v.get_property_list(&props); } else { @@ -136,11 +132,9 @@ void PropertySelector::_update_search() { Control::get_icon("MiniMatrix3", "EditorIcons"), Control::get_icon("MiniTransform", "EditorIcons"), Control::get_icon("MiniColor", "EditorIcons"), - Control::get_icon("MiniImage", "EditorIcons"), Control::get_icon("MiniPath", "EditorIcons"), Control::get_icon("MiniRid", "EditorIcons"), Control::get_icon("MiniObject", "EditorIcons"), - Control::get_icon("MiniInput", "EditorIcons"), Control::get_icon("MiniDictionary", "EditorIcons"), Control::get_icon("MiniArray", "EditorIcons"), Control::get_icon("MiniRawArray", "EditorIcons"), @@ -326,22 +320,7 @@ void PropertySelector::_item_selected() { String name = item->get_metadata(0); String class_type; - if (properties && type == Variant::INPUT_EVENT) { - - switch (event_type) { - case InputEvent::NONE: class_type = "InputEvent"; break; - case InputEvent::KEY: class_type = "InputEventKey"; break; - case InputEvent::MOUSE_MOTION: class_type = "InputEventMouseMotion"; break; - case InputEvent::MOUSE_BUTTON: class_type = "InputEventMouseButton"; break; - case InputEvent::JOYPAD_MOTION: class_type = "InputEventJoypadMotion"; break; - case InputEvent::JOYPAD_BUTTON: class_type = "InputEventJoypadButton"; break; - case InputEvent::SCREEN_TOUCH: class_type = "InputEventScreenTouch"; break; - case InputEvent::SCREEN_DRAG: class_type = "InputEventScreenDrag"; break; - case InputEvent::ACTION: class_type = "InputEventAction"; break; - default: {} - } - - } else if (type) { + if (type) { class_type = Variant::get_type_name(type); } else { @@ -515,13 +494,12 @@ void PropertySelector::select_property_from_script(const Ref<Script> &p_script, search_box->grab_focus(); _update_search(); } -void PropertySelector::select_property_from_basic_type(Variant::Type p_type, InputEvent::Type p_event_type, const String &p_current) { +void PropertySelector::select_property_from_basic_type(Variant::Type p_type, const String &p_current) { ERR_FAIL_COND(p_type == Variant::NIL); base_type = ""; selected = p_current; type = p_type; - event_type = p_event_type; script = 0; properties = true; instance = NULL; diff --git a/editor/property_selector.h b/editor/property_selector.h index 6dc2592176..def791a3fd 100644 --- a/editor/property_selector.h +++ b/editor/property_selector.h @@ -42,7 +42,7 @@ class PropertySelector : public ConfirmationDialog { void _update_search(); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _confirmed(); void _text_changed(const String &p_newtext); @@ -52,7 +52,6 @@ class PropertySelector : public ConfirmationDialog { bool properties; String selected; Variant::Type type; - InputEvent::Type event_type; String base_type; ObjectID script; Object *instance; @@ -71,7 +70,7 @@ public: void select_property_from_base_type(const String &p_base, const String &p_current = ""); void select_property_from_script(const Ref<Script> &p_script, const String &p_current = ""); - void select_property_from_basic_type(Variant::Type p_type, InputEvent::Type p_event_type, const String &p_current = ""); + void select_property_from_basic_type(Variant::Type p_type, const String &p_current = ""); void select_property_from_instance(Object *p_instance, const String &p_current = ""); PropertySelector(); diff --git a/editor/pvrtc_compress.cpp b/editor/pvrtc_compress.cpp index 6edcd60188..ef875bbead 100644 --- a/editor/pvrtc_compress.cpp +++ b/editor/pvrtc_compress.cpp @@ -89,7 +89,7 @@ static void _compress_image(Image::CompressMode p_mode, Image *p_image) { args.push_back("-m"); Ref<ImageTexture> t = memnew(ImageTexture); - t->create_from_image(*p_image, 0); + t->create_from_image(Ref<Image>(p_image), 0); ResourceSaver::save(src_img, t); Error err = OS::get_singleton()->execute(ttpath, args, true); @@ -101,7 +101,7 @@ static void _compress_image(Image::CompressMode p_mode, Image *p_image) { ERR_EXPLAIN(TTR("Can't load back converted image using PVRTC tool:") + " " + dst_img); ERR_FAIL_COND(t.is_null()); - *p_image = t->get_data(); + p_image->copy_internals_from(t->get_data()); } static void _compress_pvrtc2(Image *p_image) { diff --git a/editor/quick_open.cpp b/editor/quick_open.cpp index 7fce485f3a..7fb9666afb 100644 --- a/editor/quick_open.cpp +++ b/editor/quick_open.cpp @@ -77,17 +77,18 @@ void EditorQuickOpen::_text_changed(const String &p_newtext) { _update_search(); } -void EditorQuickOpen::_sbox_input(const InputEvent &p_ie) { +void EditorQuickOpen::_sbox_input(const Ref<InputEvent> &p_ie) { - if (p_ie.type == InputEvent::KEY) { + Ref<InputEventKey> k = p_ie; + if (k.is_valid()) { - switch (p_ie.key.scancode) { + switch (k->get_scancode()) { case KEY_UP: case KEY_DOWN: case KEY_PAGEUP: case KEY_PAGEDOWN: { - search_options->call("_gui_input", p_ie); + search_options->call("_gui_input", k); search_box->accept_event(); TreeItem *root = search_options->get_root(); diff --git a/editor/quick_open.h b/editor/quick_open.h index 0e5766033f..44f8c025e6 100644 --- a/editor/quick_open.h +++ b/editor/quick_open.h @@ -47,7 +47,7 @@ class EditorQuickOpen : public ConfirmationDialog { void _update_search(); - void _sbox_input(const InputEvent &p_ie); + void _sbox_input(const Ref<InputEvent> &p_ie); void _parse_fs(EditorFileSystemDirectory *efsd, Vector<Pair<String, Ref<Texture> > > &list); float _path_cmp(String search, String path) const; diff --git a/editor/scene_tree_dock.cpp b/editor/scene_tree_dock.cpp index 69b8723431..da2d22b900 100644 --- a/editor/scene_tree_dock.cpp +++ b/editor/scene_tree_dock.cpp @@ -52,19 +52,21 @@ void SceneTreeDock::_nodes_drag_begin() { } } -void SceneTreeDock::_input(InputEvent p_event) { +void SceneTreeDock::_input(Ref<InputEvent> p_event) { - if (p_event.type == InputEvent::MOUSE_BUTTON && !p_event.mouse_button.pressed && p_event.mouse_button.button_index == BUTTON_LEFT) { + Ref<InputEventMouseButton> mb = p_event; + + if (mb.is_valid() && !mb->is_pressed() && mb->get_button_index() == BUTTON_LEFT) { restore_script_editor_on_drag = false; //lost chance } } -void SceneTreeDock::_unhandled_key_input(InputEvent p_event) { +void SceneTreeDock::_unhandled_key_input(Ref<InputEvent> p_event) { if (get_viewport()->get_modal_stack_top()) return; //ignore because of modal window - if (!p_event.key.pressed || p_event.key.echo) + if (!p_event->is_pressed() || p_event->is_echo()) return; if (ED_IS_SHORTCUT("scene_tree/add_child_node", p_event)) { @@ -362,8 +364,7 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) { else { String path = selected->get_filename(); script_create_dialog->config(selected->get_class(), path); - script_create_dialog->popup_centered(Size2(300, 290)); - //script_create_dialog->popup_centered_minsize(); + script_create_dialog->popup_centered(); } } break; @@ -657,6 +658,21 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) { } } } break; + + default: { + + if (p_tool >= EDIT_SUBRESOURCE_BASE) { + + int idx = p_tool - EDIT_SUBRESOURCE_BASE; + + ERR_FAIL_INDEX(idx, subresources.size()); + + Object *obj = ObjectDB::get_instance(subresources[idx]); + ERR_FAIL_COND(!obj); + + editor->push_item(obj); + } + } } } @@ -681,7 +697,7 @@ void SceneTreeDock::_notification(int p_what) { button_create_script->set_icon(get_icon("ScriptCreate", "EditorIcons")); button_clear_script->set_icon(get_icon("ScriptRemove", "EditorIcons")); - filter_icon->set_texture(get_icon("Zoom", "EditorIcons")); + filter_icon->set_texture(get_icon("Search", "EditorIcons")); EditorNode::get_singleton()->get_editor_selection()->connect("selection_changed", this, "_selection_changed"); @@ -1661,6 +1677,47 @@ void SceneTreeDock::_nodes_dragged(Array p_nodes, NodePath p_to, int p_type) { _do_reparent(to_node, to_pos, nodes, true); } +void SceneTreeDock::_add_children_to_popup(Object *p_obj, int p_depth) { + + if (p_depth > 8) + return; + + List<PropertyInfo> pinfo; + p_obj->get_property_list(&pinfo); + for (List<PropertyInfo>::Element *E = pinfo.front(); E; E = E->next()) { + + if (!(E->get().usage & PROPERTY_USAGE_EDITOR)) + continue; + if (E->get().hint != PROPERTY_HINT_RESOURCE_TYPE) + continue; + + Variant value = p_obj->get(E->get().name); + if (value.get_type() != Variant::OBJECT) + continue; + Object *obj = value; + if (!obj) + continue; + + Ref<Texture> icon; + + if (has_icon(obj->get_class(), "EditorIcons")) + icon = get_icon(obj->get_class(), "EditorIcons"); + else + icon = get_icon("Object", "EditorIcons"); + + if (menu->get_item_count() == 0) { + menu->add_item(TTR("Sub-Resources:")); + menu->set_item_disabled(0, true); + } + int index = menu->get_item_count(); + menu->add_icon_item(icon, E->get().name.capitalize(), EDIT_SUBRESOURCE_BASE + subresources.size()); + menu->set_item_h_offset(index, p_depth * 10 * EDSCALE); + subresources.push_back(obj->get_instance_ID()); + + _add_children_to_popup(obj, p_depth + 1); + } +} + void SceneTreeDock::_tree_rmb(const Vector2 &p_menu_pos) { if (!EditorNode::get_singleton()->get_edited_scene()) { @@ -1682,6 +1739,12 @@ void SceneTreeDock::_tree_rmb(const Vector2 &p_menu_pos) { menu->clear(); if (selection.size() == 1) { + + subresources.clear(); + _add_children_to_popup(selection.front()->get(), 0); + if (menu->get_item_count() > 0) + menu->add_separator(); + menu->add_icon_shortcut(get_icon("Add", "EditorIcons"), ED_GET_SHORTCUT("scene_tree/add_child_node"), TOOL_NEW); menu->add_icon_shortcut(get_icon("Instance", "EditorIcons"), ED_GET_SHORTCUT("scene_tree/instance_scene"), TOOL_INSTANCE); menu->add_separator(); @@ -1791,6 +1854,7 @@ SceneTreeDock::SceneTreeDock(EditorNode *p_editor, Node *p_scene_root, EditorSel VBoxContainer *vbc = this; HBoxContainer *filter_hbc = memnew(HBoxContainer); + filter_hbc->add_constant_override("separate", 0); ToolButton *tb; ED_SHORTCUT("scene_tree/add_child_node", TTR("Add Child Node"), KEY_MASK_CMD | KEY_A); @@ -1827,6 +1891,7 @@ SceneTreeDock::SceneTreeDock(EditorNode *p_editor, Node *p_scene_root, EditorSel filter->set_h_size_flags(SIZE_EXPAND_FILL); filter_hbc->add_child(filter); filter_icon = memnew(TextureRect); + filter_icon->set_custom_minimum_size(Size2(24 * EDSCALE, 0)); filter_hbc->add_child(filter_icon); filter_icon->set_stretch_mode(TextureRect::STRETCH_KEEP_CENTERED); filter->connect("text_changed", this, "_filter_changed"); diff --git a/editor/scene_tree_dock.h b/editor/scene_tree_dock.h index de6b81d44a..79e01e7571 100644 --- a/editor/scene_tree_dock.h +++ b/editor/scene_tree_dock.h @@ -73,6 +73,12 @@ class SceneTreeDock : public VBoxContainer { TOOL_BUTTON_MAX }; + enum { + EDIT_SUBRESOURCE_BASE = 100 + }; + + Vector<ObjectID> subresources; + bool restore_script_editor_on_drag; int current_option; @@ -114,6 +120,8 @@ class SceneTreeDock : public VBoxContainer { Node *edited_scene; EditorNode *editor; + void _add_children_to_popup(Object *p_obj, int p_depth); + Node *_duplicate(Node *p_node, Map<Node *, Node *> &duplimap); void _node_reparent(NodePath p_path, bool p_keep_global_xform); void _do_reparent(Node *p_new_parent, int p_position_in_parent, Vector<Node *> p_nodes, bool p_keep_global_xform); @@ -133,8 +141,8 @@ class SceneTreeDock : public VBoxContainer { void _node_prerenamed(Node *p_node, const String &p_new_name); void _nodes_drag_begin(); - void _input(InputEvent p_event); - void _unhandled_key_input(InputEvent p_event); + void _input(Ref<InputEvent> p_event); + void _unhandled_key_input(Ref<InputEvent> p_event); void _import_subscene(); diff --git a/editor/scene_tree_editor.cpp b/editor/scene_tree_editor.cpp index 8fd0d13b32..d4e5714c0d 100644 --- a/editor/scene_tree_editor.cpp +++ b/editor/scene_tree_editor.cpp @@ -161,17 +161,17 @@ void SceneTreeEditor::_cell_button_pressed(Object *p_item, int p_column, int p_i if (p_id == BUTTON_SUBSCENE) { //open scene request Rect2 item_rect = tree->get_item_rect(item, 0); - item_rect.pos.y -= tree->get_scroll().y; - item_rect.pos += tree->get_global_position(); + item_rect.position.y -= tree->get_scroll().y; + item_rect.position += tree->get_global_position(); if (n == get_scene_node()) { - inheritance_menu->set_position(item_rect.pos + Vector2(0, item_rect.size.y)); + inheritance_menu->set_position(item_rect.position + Vector2(0, item_rect.size.y)); inheritance_menu->set_size(Vector2(item_rect.size.x, 0)); inheritance_menu->popup(); instance_node = n->get_instance_ID(); } else { - instance_menu->set_position(item_rect.pos + Vector2(0, item_rect.size.y)); + instance_menu->set_position(item_rect.position + Vector2(0, item_rect.size.y)); instance_menu->set_size(Vector2(item_rect.size.x, 0)); if (EditorNode::get_singleton()->get_edited_scene()->is_editable_instance(n)) instance_menu->set_item_checked(0, true); @@ -337,27 +337,27 @@ bool SceneTreeEditor::_add_nodes(Node *p_node, TreeItem *p_parent) { String warning = p_node->get_configuration_warning(); if (warning != String()) { - item->add_button(0, get_icon("NodeWarning", "EditorIcons"), BUTTON_WARNING); + item->add_button(0, get_icon("NodeWarning", "EditorIcons"), BUTTON_WARNING, false, TTR("Node configuration warning:") + "\n" + p_node->get_configuration_warning()); } bool has_connections = p_node->has_persistent_signal_connections(); bool has_groups = p_node->has_persistent_groups(); if (has_connections && has_groups) { - item->add_button(0, get_icon("ConnectionAndGroups", "EditorIcons"), BUTTON_SIGNALS); + item->add_button(0, get_icon("ConnectionAndGroups", "EditorIcons"), BUTTON_SIGNALS, false, TTR("Node has connection(s) and group(s)\nClick to show signals dock.")); } else if (has_connections) { - item->add_button(0, get_icon("Connect", "EditorIcons"), BUTTON_SIGNALS); + item->add_button(0, get_icon("Connect", "EditorIcons"), BUTTON_SIGNALS, false, TTR("Node has connections.\nClick to show signals dock.")); } else if (has_groups) { - item->add_button(0, get_icon("Groups", "EditorIcons"), BUTTON_GROUPS); + item->add_button(0, get_icon("Groups", "EditorIcons"), BUTTON_GROUPS, false, TTR("Node is in group(s).\nClick to show groups dock.")); } } if (p_node == get_scene_node() && p_node->get_scene_inherited_state().is_valid()) { - item->add_button(0, get_icon("InstanceOptions", "EditorIcons"), BUTTON_SUBSCENE); + item->add_button(0, get_icon("InstanceOptions", "EditorIcons"), BUTTON_SUBSCENE, false, TTR("Subscene options")); item->set_tooltip(0, TTR("Inherits:") + " " + p_node->get_scene_inherited_state()->get_path() + "\n" + TTR("Type:") + " " + p_node->get_class()); } else if (p_node != get_scene_node() && p_node->get_filename() != "" && can_open_instance) { - item->add_button(0, get_icon("InstanceOptions", "EditorIcons"), BUTTON_SUBSCENE); + item->add_button(0, get_icon("InstanceOptions", "EditorIcons"), BUTTON_SUBSCENE, false, TTR("Subscene options")); item->set_tooltip(0, TTR("Instance:") + " " + p_node->get_filename() + "\n" + TTR("Type:") + " " + p_node->get_class()); } else { item->set_tooltip(0, String(p_node->get_name()) + "\n" + TTR("Type:") + " " + p_node->get_class()); @@ -370,24 +370,24 @@ bool SceneTreeEditor::_add_nodes(Node *p_node, TreeItem *p_parent) { if (!p_node->get_script().is_null()) { - item->add_button(0, get_icon("Script", "EditorIcons"), BUTTON_SCRIPT); + item->add_button(0, get_icon("Script", "EditorIcons"), BUTTON_SCRIPT, false, TTR("Open script")); } if (p_node->is_class("CanvasItem")) { bool is_locked = p_node->has_meta("_edit_lock_"); //_edit_group_ if (is_locked) - item->add_button(0, get_icon("Lock", "EditorIcons"), BUTTON_LOCK); + item->add_button(0, get_icon("Lock", "EditorIcons"), BUTTON_LOCK, false, TTR("Node is locked.\nClick to unlock")); bool is_grouped = p_node->has_meta("_edit_group_"); if (is_grouped) - item->add_button(0, get_icon("Group", "EditorIcons"), BUTTON_GROUP); + item->add_button(0, get_icon("Group", "EditorIcons"), BUTTON_GROUP, false, TTR("Children are not selectable.\nClick to make selectable")); bool v = p_node->call("is_visible"); if (v) - item->add_button(0, get_icon("Visible", "EditorIcons"), BUTTON_VISIBILITY); + item->add_button(0, get_icon("Visible", "EditorIcons"), BUTTON_VISIBILITY, false, TTR("Toggle Visibility")); else - item->add_button(0, get_icon("Hidden", "EditorIcons"), BUTTON_VISIBILITY); + item->add_button(0, get_icon("Hidden", "EditorIcons"), BUTTON_VISIBILITY, false, TTR("Toggle Visibility")); if (!p_node->is_connected("visibility_changed", this, "_node_visibility_changed")) p_node->connect("visibility_changed", this, "_node_visibility_changed", varray(p_node)); @@ -397,9 +397,9 @@ bool SceneTreeEditor::_add_nodes(Node *p_node, TreeItem *p_parent) { bool v = p_node->call("is_visible"); if (v) - item->add_button(0, get_icon("Visible", "EditorIcons"), BUTTON_VISIBILITY); + item->add_button(0, get_icon("Visible", "EditorIcons"), BUTTON_VISIBILITY, false, TTR("Toggle Visibility")); else - item->add_button(0, get_icon("Hidden", "EditorIcons"), BUTTON_VISIBILITY); + item->add_button(0, get_icon("Hidden", "EditorIcons"), BUTTON_VISIBILITY, false, TTR("Toggle Visibility")); if (!p_node->is_connected("visibility_changed", this, "_node_visibility_changed")) p_node->connect("visibility_changed", this, "_node_visibility_changed", varray(p_node)); diff --git a/editor/script_create_dialog.cpp b/editor/script_create_dialog.cpp index 7808cae0cd..dbd0758256 100644 --- a/editor/script_create_dialog.cpp +++ b/editor/script_create_dialog.cpp @@ -29,12 +29,23 @@ /*************************************************************************/ #include "script_create_dialog.h" +#include "editor/editor_scale.h" #include "editor_file_system.h" #include "global_config.h" #include "io/resource_saver.h" #include "os/file_access.h" #include "script_language.h" +void ScriptCreateDialog::_notification(int p_what) { + + switch (p_what) { + case NOTIFICATION_ENTER_TREE: { + path_button->set_icon(get_icon("Folder", "EditorIcons")); + parent_browse_button->set_icon(get_icon("Folder", "EditorIcons")); + } + } +} + void ScriptCreateDialog::config(const String &p_base_name, const String &p_base_path) { class_name->set_text(""); @@ -46,6 +57,8 @@ void ScriptCreateDialog::config(const String &p_base_name, const String &p_base_ initial_bp = ""; file_path->set_text(""); } + _lang_changed(current_language); + _parent_name_changed(parent_name->get_text()); _class_name_changed(""); _path_changed(file_path->get_text()); } @@ -55,6 +68,8 @@ bool ScriptCreateDialog::_validate(const String &p_string) { if (p_string.length() == 0) return false; + String path_chars = "\"res://"; + bool is_val_path = ScriptServer::get_language(language_menu->get_selected())->can_inherit_from_file(); for (int i = 0; i < p_string.length(); i++) { if (i == 0) { @@ -62,7 +77,17 @@ bool ScriptCreateDialog::_validate(const String &p_string) { return false; // no start with number plz } - bool valid_char = (p_string[i] >= '0' && p_string[i] <= '9') || (p_string[i] >= 'a' && p_string[i] <= 'z') || (p_string[i] >= 'A' && p_string[i] <= 'Z') || p_string[i] == '_'; + if (i == p_string.length() - 1 && is_val_path) + return p_string[i] == '\"'; + + if (is_val_path && i < path_chars.length()) { + if (p_string[i] != path_chars[i]) + is_val_path = false; + else + continue; + } + + bool valid_char = (p_string[i] >= '0' && p_string[i] <= '9') || (p_string[i] >= 'a' && p_string[i] <= 'z') || (p_string[i] >= 'A' && p_string[i] <= 'Z') || p_string[i] == '_' || (is_val_path && (p_string[i] == '/' || p_string[i] == '.')); if (!valid_char) return false; @@ -73,57 +98,61 @@ bool ScriptCreateDialog::_validate(const String &p_string) { void ScriptCreateDialog::_class_name_changed(const String &p_name) { - if (!_validate(parent_name->get_text())) { - error_label->set_text(TTR("Invalid parent class name")); - error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); - } else if (class_name->is_editable()) { - if (class_name->get_text() == "") { - error_label->set_text(TTR("Valid chars:") + " a-z A-Z 0-9 _"); - error_label->add_color_override("font_color", Color(1, 1, 1, 0.6)); - } else if (!_validate(class_name->get_text())) { - error_label->set_text(TTR("Invalid class name")); - error_label->add_color_override("font_color", Color(1, 0.2, 0.2, 0.8)); - } else { - error_label->set_text(TTR("Valid name")); - error_label->add_color_override("font_color", Color(0, 1.0, 0.8, 0.8)); - } + if (_validate(class_name->get_text())) { + is_class_name_valid = true; } else { + is_class_name_valid = false; + } + _update_dialog(); +} - error_label->set_text(TTR("N/A")); - error_label->add_color_override("font_color", Color(0, 1.0, 0.8, 0.8)); +void ScriptCreateDialog::_parent_name_changed(const String &p_parent) { + + if (_validate(parent_name->get_text())) { + is_parent_name_valid = true; + } else { + is_parent_name_valid = false; } + _update_dialog(); +} + +void ScriptCreateDialog::_template_changed(int p_template) { + + if (p_template == 0) { + //default + script_template = ""; + return; + } + String ext = ScriptServer::get_language(language_menu->get_selected())->get_extension(); + String name = template_menu->get_item_text(p_template) + "." + ext; + script_template = EditorSettings::get_singleton()->get_settings_path() + "/script_templates/" + name; } void ScriptCreateDialog::ok_pressed() { - if (create_new) { + if (is_new_script_created) { _create_new(); } else { _load_exist(); } - create_new = true; - _update_controls(); + is_new_script_created = true; + _update_dialog(); } void ScriptCreateDialog::_create_new() { - if (class_name->is_editable() && !_validate(class_name->get_text())) { - alert->set_text(TTR("Class name is invalid!")); - alert->popup_centered_minsize(); - return; - } - if (!_validate(parent_name->get_text())) { - alert->set_text(TTR("Parent class name is invalid!")); - alert->popup_centered_minsize(); - return; - } - String cname; - if (class_name->is_editable()) + if (has_named_classes) cname = class_name->get_text(); - Ref<Script> scr = ScriptServer::get_language(language_menu->get_selected())->get_template(cname, parent_name->get_text()); + Ref<Script> scr; + if (script_template != "") { + scr = ResourceLoader::load(script_template)->duplicate(); + ScriptServer::get_language(language_menu->get_selected())->make_template(cname, parent_name->get_text(), scr); + } else { + scr = ScriptServer::get_language(language_menu->get_selected())->get_template(cname, parent_name->get_text()); + } String selected_language = language_menu->get_item_text(language_menu->get_selected()); editor_settings->set_project_metadata("script_setup", "last_selected_language", selected_language); @@ -131,18 +160,13 @@ void ScriptCreateDialog::_create_new() { if (cname != "") scr->set_name(cname); - if (!internal->is_pressed()) { + if (!is_built_in) { String lpath = GlobalConfig::get_singleton()->localize_path(file_path->get_text()); scr->set_path(lpath); - if (!path_valid) { - alert->set_text(TTR("Invalid path!")); - alert->popup_centered_minsize(); - return; - } Error err = ResourceSaver::save(lpath, scr, ResourceSaver::FLAG_CHANGE_PATH); if (err != OK) { - alert->set_text(TTR("Could not create script in filesystem.")); - alert->popup_centered_minsize(); + alert->set_text(TTR("Error - Could not create script in filesystem.")); + alert->popup_centered(); return; } } @@ -156,9 +180,9 @@ void ScriptCreateDialog::_load_exist() { String path = file_path->get_text(); RES p_script = ResourceLoader::load(path, "Script"); if (p_script.is_null()) { - alert->get_ok()->set_text(TTR("Ugh")); + alert->get_ok()->set_text(TTR("OK")); alert->set_text(vformat(TTR("Error loading script from %s"), path)); - alert->popup_centered_minsize(); + alert->popup_centered(); return; } @@ -169,53 +193,78 @@ void ScriptCreateDialog::_load_exist() { void ScriptCreateDialog::_lang_changed(int l) { l = language_menu->get_selected(); - if (ScriptServer::get_language(l)->has_named_classes()) { - class_name->set_editable(true); + ScriptLanguage *language = ScriptServer::get_language(l); + if (language->has_named_classes()) { + has_named_classes = true; } else { - class_name->set_editable(false); + has_named_classes = false; } - String selected_ext = "." + ScriptServer::get_language(l)->get_extension(); - String path = file_path->get_text(); - String extension = ""; - if (path.find(".") >= 0) { - extension = path.get_extension(); + if (ScriptServer::get_language(l)->can_inherit_from_file()) { + can_inherit_from_file = true; + } else { + can_inherit_from_file = false; } - if (extension.length() == 0) { - // add extension if none - path += selected_ext; - _path_changed(path); - } else { - // change extension by selected language - List<String> extensions; - // get all possible extensions for script - for (int l = 0; l < language_menu->get_item_count(); l++) { - ScriptServer::get_language(l)->get_recognized_extensions(&extensions); + String selected_ext = "." + language->get_extension(); + String path = file_path->get_text(); + String extension = ""; + if (path != "") { + if (path.find(".") >= 0) { + extension = path.get_extension(); } - for (List<String>::Element *E = extensions.front(); E; E = E->next()) { - if (E->get().nocasecmp_to(extension) == 0) { - path = path.get_basename() + selected_ext; - _path_changed(path); - break; + if (extension.length() == 0) { + // add extension if none + path += selected_ext; + _path_changed(path); + } else { + // change extension by selected language + List<String> extensions; + // get all possible extensions for script + for (int l = 0; l < language_menu->get_item_count(); l++) { + language->get_recognized_extensions(&extensions); + } + + for (List<String>::Element *E = extensions.front(); E; E = E->next()) { + if (E->get().nocasecmp_to(extension) == 0) { + path = path.get_basename() + selected_ext; + _path_changed(path); + break; + } } } + file_path->set_text(path); + } + + bool use_templates = language->is_using_templates(); + template_menu->set_disabled(!use_templates); + if (use_templates) { + Vector<String> template_list = EditorSettings::get_singleton()->get_script_templates(language->get_extension()); + + template_menu->clear(); + template_menu->add_item(TTR("Default")); + for (int i = 0; i < template_list.size(); i++) { + template_menu->add_item(template_list[i]); + } } - file_path->set_text(path); - _class_name_changed(class_name->get_text()); + + _update_dialog(); } void ScriptCreateDialog::_built_in_pressed() { if (internal->is_pressed()) { - path_vb->hide(); + is_built_in = true; } else { - path_vb->show(); + is_built_in = false; } + _update_dialog(); } -void ScriptCreateDialog::_browse_path() { +void ScriptCreateDialog::_browse_path(bool browse_parent) { + + is_browsing_parent = browse_parent; file_browse->set_mode(EditorFileDialog::MODE_SAVE_FILE); file_browse->set_disable_overwrite_warning(true); @@ -238,46 +287,56 @@ void ScriptCreateDialog::_browse_path() { void ScriptCreateDialog::_file_selected(const String &p_file) { String p = GlobalConfig::get_singleton()->localize_path(p_file); - file_path->set_text(p); - _path_changed(p); + if (is_browsing_parent) { + parent_name->set_text("\"" + p + "\""); + _class_name_changed("\"" + p + "\""); + } else { + file_path->set_text(p); + _path_changed(p); + } } void ScriptCreateDialog::_path_changed(const String &p_path) { - path_valid = false; + is_path_valid = false; + is_new_script_created = true; String p = p_path; if (p == "") { - - path_error_label->set_text(TTR("Path is empty")); - path_error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); + _msg_path_valid(false, TTR("Path is empty")); + _update_dialog(); return; } p = GlobalConfig::get_singleton()->localize_path(p); if (!p.begins_with("res://")) { - - path_error_label->set_text(TTR("Path is not local")); - path_error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); + _msg_path_valid(false, TTR("Path is not local")); + _update_dialog(); return; } if (p.find("/") || p.find("\\")) { DirAccess *d = DirAccess::create(DirAccess::ACCESS_RESOURCES); - if (d->change_dir(p.get_base_dir()) != OK) { - - path_error_label->set_text(TTR("Invalid base path")); - path_error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); + _msg_path_valid(false, TTR("Invalid base path")); memdelete(d); + _update_dialog(); return; } memdelete(d); } - FileAccess *f = FileAccess::create(FileAccess::ACCESS_RESOURCES); - create_new = !f->file_exists(p); + /* Does file already exist */ + + DirAccess *f = DirAccess::create(DirAccess::ACCESS_RESOURCES); + if (f->file_exists(p) && !(f->current_is_dir())) { + is_new_script_created = false; + is_path_valid = true; + } memdelete(f); + _update_dialog(); + + /* Check file extension */ String extension = p.get_extension(); List<String> extensions; @@ -288,77 +347,263 @@ void ScriptCreateDialog::_path_changed(const String &p_path) { } bool found = false; + bool match = false; int index = 0; for (List<String>::Element *E = extensions.front(); E; E = E->next()) { if (E->get().nocasecmp_to(extension) == 0) { - language_menu->select(index); // change Language option by extension + //FIXME (?) - changing language this way doesn't update controls, needs rework + //language_menu->select(index); // change Language option by extension found = true; + if (E->get() == ScriptServer::get_language(language_menu->get_selected())->get_extension()) { + match = true; + } break; } index++; } if (!found) { - path_error_label->set_text(TTR("Invalid extension")); - path_error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); + _msg_path_valid(false, TTR("Invalid extension")); + _update_dialog(); + return; + } + + if (!match) { + _msg_path_valid(false, TTR("Wrong extension chosen")); + _update_dialog(); return; } - _update_controls(); + /* All checks passed */ + + is_path_valid = true; + _update_dialog(); +} + +void ScriptCreateDialog::_msg_script_valid(bool valid, const String &p_msg) { + + error_label->set_text(TTR(p_msg)); + if (valid) { + error_label->add_color_override("font_color", Color(0, 1.0, 0.8, 0.8)); + } else { + error_label->add_color_override("font_color", Color(1, 0.2, 0.2, 0.8)); + } +} - path_error_label->add_color_override("font_color", Color(0, 1.0, 0.8, 0.8)); +void ScriptCreateDialog::_msg_path_valid(bool valid, const String &p_msg) { - path_valid = true; + path_error_label->set_text(TTR(p_msg)); + if (valid) { + path_error_label->add_color_override("font_color", Color(0, 1.0, 0.8, 0.8)); + } else { + path_error_label->add_color_override("font_color", Color(1, 0.4, 0.0, 0.8)); + } } -void ScriptCreateDialog::_update_controls() { +void ScriptCreateDialog::_update_dialog() { + + bool script_ok = true; + + /* "Add Script Dialog" gui logic and script checks */ + + // Is Script Valid (order from top to bottom) + get_ok()->set_disabled(true); + if (!is_built_in) { + if (!is_path_valid) { + _msg_script_valid(false, TTR("Invalid Path")); + script_ok = false; + } + } + if (has_named_classes && (!is_class_name_valid)) { + _msg_script_valid(false, TTR("Invalid class name")); + script_ok = false; + } + if (!is_parent_name_valid) { + _msg_script_valid(false, TTR("Invalid inherited parent name or path")); + script_ok = false; + } + if (script_ok) { + _msg_script_valid(true, TTR("Script valid")); + get_ok()->set_disabled(false); + } + + /* Does script have named classes */ + + if (has_named_classes) { + if (is_new_script_created) { + class_name->set_editable(true); + class_name->set_placeholder(TTR("Allowed: a-z, A-Z, 0-9 and _")); + class_name->set_placeholder_alpha(0.3); + } else { + class_name->set_editable(false); + } + } else { + class_name->set_editable(false); + class_name->set_placeholder(TTR("N/A")); + class_name->set_placeholder_alpha(1); + } - if (create_new) { - path_error_label->set_text(TTR("Create new script")); + /* Can script inherit from a file */ + + if (can_inherit_from_file) { + parent_browse_button->set_disabled(false); + } else { + parent_browse_button->set_disabled(true); + } + + /* Is script Built-in */ + + if (is_built_in) { + file_path->set_editable(false); + path_button->set_disabled(true); + re_check_path = true; + } else { + file_path->set_editable(true); + path_button->set_disabled(false); + if (re_check_path) { + re_check_path = false; + _path_changed(file_path->get_text()); + } + } + + /* Is Script created or loaded from existing file */ + + if (is_new_script_created) { + // New Script Created get_ok()->set_text(TTR("Create")); + parent_name->set_editable(true); + parent_browse_button->set_disabled(false); + internal->set_disabled(false); + if (is_built_in) { + _msg_path_valid(true, TTR("Built-in script (into scene file)")); + } else { + if (script_ok) { + _msg_path_valid(true, TTR("Create new script file")); + } + } } else { - path_error_label->set_text(TTR("Load existing script")); + // Script Loaded get_ok()->set_text(TTR("Load")); + parent_name->set_editable(false); + parent_browse_button->set_disabled(true); + internal->set_disabled(true); + if (script_ok) { + _msg_path_valid(true, TTR("Load existing script file")); + } } - parent_name->set_editable(create_new); - internal->set_disabled(!create_new); } void ScriptCreateDialog::_bind_methods() { ClassDB::bind_method("_class_name_changed", &ScriptCreateDialog::_class_name_changed); + ClassDB::bind_method("_parent_name_changed", &ScriptCreateDialog::_parent_name_changed); ClassDB::bind_method("_lang_changed", &ScriptCreateDialog::_lang_changed); ClassDB::bind_method("_built_in_pressed", &ScriptCreateDialog::_built_in_pressed); ClassDB::bind_method("_browse_path", &ScriptCreateDialog::_browse_path); ClassDB::bind_method("_file_selected", &ScriptCreateDialog::_file_selected); ClassDB::bind_method("_path_changed", &ScriptCreateDialog::_path_changed); + ClassDB::bind_method("_template_changed", &ScriptCreateDialog::_template_changed); ADD_SIGNAL(MethodInfo("script_created", PropertyInfo(Variant::OBJECT, "script", PROPERTY_HINT_RESOURCE_TYPE, "Script"))); } ScriptCreateDialog::ScriptCreateDialog() { - /* SNAP DIALOG */ + editor_settings = EditorSettings::get_singleton(); + GridContainer *gc = memnew(GridContainer); VBoxContainer *vb = memnew(VBoxContainer); - add_child(vb); - //set_child_rect(vb); + HBoxContainer *hb = memnew(HBoxContainer); + Label *l = memnew(Label); + Control *empty = memnew(Control); + Control *empty_h = memnew(Control); + Control *empty_v = memnew(Control); + PanelContainer *pc = memnew(PanelContainer); - class_name = memnew(LineEdit); - VBoxContainer *vb2 = memnew(VBoxContainer); - vb2->add_child(class_name); - class_name->connect("text_changed", this, "_class_name_changed"); - error_label = memnew(Label); - error_label->set_text("valid chars: a-z A-Z 0-9 _"); - error_label->set_align(Label::ALIGN_CENTER); - vb2->add_child(error_label); - vb->add_margin_child(TTR("Class Name:"), vb2); + /* DIALOG */ - parent_name = memnew(LineEdit); - vb->add_margin_child(TTR("Inherits:"), parent_name); - parent_name->connect("text_changed", this, "_class_name_changed"); + /* Main Controls */ + + gc = memnew(GridContainer); + gc->set_columns(2); + + /* Error Stylebox Background */ + + StyleBoxFlat *sb = memnew(StyleBoxFlat); + sb->set_bg_color(Color(0, 0, 0, 0.05)); + sb->set_light_color(Color(1, 1, 1, 0.05)); + sb->set_dark_color(Color(1, 1, 1, 0.05)); + sb->set_border_blend(false); + sb->set_border_size(1); + sb->set_default_margin(MARGIN_TOP, 10.0 * EDSCALE); + sb->set_default_margin(MARGIN_BOTTOM, 10.0 * EDSCALE); + sb->set_default_margin(MARGIN_LEFT, 10.0 * EDSCALE); + sb->set_default_margin(MARGIN_RIGHT, 10.0 * EDSCALE); + + /* Error Messages Field */ + + vb = memnew(VBoxContainer); + + hb = memnew(HBoxContainer); + l = memnew(Label); + l->set_text(" - "); + hb->add_child(l); + error_label = memnew(Label); + error_label->set_text(TTR("Error!")); + error_label->set_align(Label::ALIGN_LEFT); + hb->add_child(error_label); + vb->add_child(hb); + + hb = memnew(HBoxContainer); + l = memnew(Label); + l->set_text(" - "); + hb->add_child(l); + path_error_label = memnew(Label); + path_error_label->set_text(TTR("Error!")); + path_error_label->set_align(Label::ALIGN_LEFT); + hb->add_child(path_error_label); + vb->add_child(hb); + + pc = memnew(PanelContainer); + pc->set_h_size_flags(Control::SIZE_FILL); + pc->add_style_override("panel", sb); + pc->add_child(vb); + + /* Margins */ + + empty_h = memnew(Control); + empty_h->set_name("empty_h"); //duplicate() doesn't like nodes without a name + empty_h->set_h_size_flags(Control::SIZE_EXPAND_FILL); + empty_h->set_v_size_flags(Control::SIZE_EXPAND_FILL); + empty_h->set_custom_minimum_size(Size2(0, 10 * EDSCALE)); + empty_v = memnew(Control); + empty_v->set_name("empty_v"); + empty_v->set_h_size_flags(Control::SIZE_EXPAND_FILL); + empty_v->set_v_size_flags(Control::SIZE_EXPAND_FILL); + empty_v->set_custom_minimum_size(Size2(10, 0 * EDSCALE)); + + vb = memnew(VBoxContainer); + vb->add_child(empty_h->duplicate()); + vb->add_child(gc); + vb->add_child(empty_h->duplicate()); + vb->add_child(pc); + vb->add_child(empty_h->duplicate()); + hb = memnew(HBoxContainer); + hb->add_child(empty_v->duplicate()); + hb->add_child(vb); + hb->add_child(empty_v->duplicate()); + + add_child(hb); + + /* Language */ language_menu = memnew(OptionButton); - vb->add_margin_child(TTR("Language"), language_menu); + language_menu->set_custom_minimum_size(Size2(250, 0) * EDSCALE); + language_menu->set_h_size_flags(SIZE_EXPAND_FILL); + l = memnew(Label); + l->set_text(TTR("Language")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(language_menu); int default_lang = 0; for (int i = 0; i < ScriptServer::get_language_count(); i++) { @@ -370,60 +615,118 @@ ScriptCreateDialog::ScriptCreateDialog() { } } - editor_settings = EditorSettings::get_singleton(); String last_selected_language = editor_settings->get_project_metadata("script_setup", "last_selected_language", ""); if (last_selected_language != "") { for (int i = 0; i < language_menu->get_item_count(); i++) { if (language_menu->get_item_text(i) == last_selected_language) { language_menu->select(i); + current_language = i; break; } } } else { language_menu->select(default_lang); + current_language = default_lang; } language_menu->connect("item_selected", this, "_lang_changed"); - //parent_name->set_text(); + /* Inherits */ - vb2 = memnew(VBoxContainer); - path_vb = memnew(VBoxContainer); - vb2->add_child(path_vb); + hb = memnew(HBoxContainer); + hb->set_h_size_flags(SIZE_EXPAND_FILL); + parent_name = memnew(LineEdit); + parent_name->connect("text_changed", this, "_parent_name_changed"); + parent_name->set_h_size_flags(SIZE_EXPAND_FILL); + hb->add_child(parent_name); + parent_browse_button = memnew(Button); + parent_browse_button->set_flat(true); + parent_browse_button->connect("pressed", this, "_browse_path", varray(true)); + hb->add_child(parent_browse_button); + l = memnew(Label); + l->set_text(TTR("Inherits")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(hb); + is_browsing_parent = false; + + /* Class Name */ - HBoxContainer *hbc = memnew(HBoxContainer); - file_path = memnew(LineEdit); - file_path->connect("text_changed", this, "_path_changed"); - hbc->add_child(file_path); - file_path->set_h_size_flags(SIZE_EXPAND_FILL); - Button *b = memnew(Button); - b->set_text(" .. "); - b->connect("pressed", this, "_browse_path"); - hbc->add_child(b); - path_vb->add_child(hbc); - path_error_label = memnew(Label); - path_vb->add_child(path_error_label); - path_error_label->set_text(TTR("Error!")); - path_error_label->set_align(Label::ALIGN_CENTER); + class_name = memnew(LineEdit); + class_name->connect("text_changed", this, "_class_name_changed"); + class_name->set_h_size_flags(SIZE_EXPAND_FILL); + l = memnew(Label); + l->set_text(TTR("Class Name")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(class_name); - internal = memnew(CheckButton); - internal->set_text(TTR("Built-In Script")); - vb2->add_child(internal); - internal->connect("pressed", this, "_built_in_pressed"); + /* Templates */ - vb->add_margin_child(TTR("Path:"), vb2); + template_menu = memnew(OptionButton); + l = memnew(Label); + l->set_text(TTR("Template")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(template_menu); + template_menu->connect("item_selected", this, "_template_changed"); - set_size(Size2(200, 150)); - set_hide_on_ok(false); - set_title(TTR("Attach Node Script")); + /* Built-in Script */ + + internal = memnew(CheckButton); + internal->connect("pressed", this, "_built_in_pressed"); + hb = memnew(HBoxContainer); + empty = memnew(Control); + hb->add_child(internal); + hb->add_child(empty); + l = memnew(Label); + l->set_text(TTR("Built-in Script")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(hb); + + /* Path */ + + hb = memnew(HBoxContainer); + file_path = memnew(LineEdit); + file_path->connect("text_changed", this, "_path_changed"); + file_path->set_h_size_flags(SIZE_EXPAND_FILL); + hb->add_child(file_path); + path_button = memnew(Button); + path_button->set_flat(true); + path_button->connect("pressed", this, "_browse_path", varray(false)); + hb->add_child(path_button); + l = memnew(Label); + l->set_text(TTR("Path")); + l->set_align(Label::ALIGN_RIGHT); + gc->add_child(l); + gc->add_child(hb); + + /* Dialog Setup */ file_browse = memnew(EditorFileDialog); file_browse->connect("file_selected", this, "_file_selected"); add_child(file_browse); get_ok()->set_text(TTR("Create")); alert = memnew(AcceptDialog); + alert->set_as_minsize(); + alert->get_label()->set_autowrap(true); + alert->get_label()->set_align(Label::ALIGN_CENTER); + alert->get_label()->set_valign(Label::VALIGN_CENTER); + alert->get_label()->set_custom_minimum_size(Size2(325, 60) * EDSCALE); add_child(alert); - _lang_changed(0); - create_new = true; + set_as_minsize(); + set_hide_on_ok(false); + set_title(TTR("Attach Node Script")); + + is_parent_name_valid = false; + is_class_name_valid = false; + is_path_valid = false; + + has_named_classes = false; + can_inherit_from_file = false; + is_built_in = false; + + is_new_script_created = true; } diff --git a/editor/script_create_dialog.h b/editor/script_create_dialog.h index 499886facd..1adbfe3f7d 100644 --- a/editor/script_create_dialog.h +++ b/editor/script_create_dialog.h @@ -34,8 +34,10 @@ #include "editor/editor_settings.h" #include "scene/gui/check_button.h" #include "scene/gui/dialogs.h" +#include "scene/gui/grid_container.h" #include "scene/gui/line_edit.h" #include "scene/gui/option_button.h" +#include "scene/gui/panel_container.h" class ScriptCreateDialog : public ConfirmationDialog { GDCLASS(ScriptCreateDialog, ConfirmationDialog); @@ -44,30 +46,49 @@ class ScriptCreateDialog : public ConfirmationDialog { Label *error_label; Label *path_error_label; LineEdit *parent_name; + Button *parent_browse_button; OptionButton *language_menu; + OptionButton *template_menu; LineEdit *file_path; + Button *path_button; EditorFileDialog *file_browse; CheckButton *internal; VBoxContainer *path_vb; AcceptDialog *alert; bool path_valid; bool create_new; + bool is_browsing_parent; String initial_bp; EditorSettings *editor_settings; + bool is_new_script_created; + bool is_path_valid; + bool has_named_classes; + bool can_inherit_from_file; + bool is_parent_name_valid; + bool is_class_name_valid; + bool is_built_in; + int current_language; + bool re_check_path; + String script_template; void _path_changed(const String &p_path = String()); void _lang_changed(int l = 0); void _built_in_pressed(); bool _validate(const String &p_strin); void _class_name_changed(const String &p_name); - void _browse_path(); + void _parent_name_changed(const String &p_parent); + void _template_changed(int p_template = 0); + void _browse_path(bool browse_parent); void _file_selected(const String &p_file); virtual void ok_pressed(); void _create_new(); void _load_exist(); - void _update_controls(); + void _msg_script_valid(bool valid, const String &p_msg = String()); + void _msg_path_valid(bool valid, const String &p_msg = String()); + void _update_dialog(); protected: + void _notification(int p_what); static void _bind_methods(); public: diff --git a/editor/script_editor_debugger.cpp b/editor/script_editor_debugger.cpp index 38cb8d654e..6d22935dcb 100644 --- a/editor/script_editor_debugger.cpp +++ b/editor/script_editor_debugger.cpp @@ -90,11 +90,13 @@ public: return ""; } - void add_property(const String &p_name, const Variant &p_value) { + void add_property(const String &p_name, const Variant &p_value, const PropertyHint &p_hint, const String p_hint_string) { PropertyInfo pinfo; pinfo.name = p_name; pinfo.type = p_value.get_type(); + pinfo.hint = p_hint; + pinfo.hint_string = p_hint_string; props.push_back(pinfo); values[p_name] = p_value; } @@ -437,7 +439,11 @@ void ScriptEditorDebugger::_parse_message(const String &p_msg, const Array &p_da inspected_object->last_edited_id = id; - inspect_properties->edit(inspected_object); + if (tabs->get_current_tab() == 2) { + inspect_properties->edit(inspected_object); + } else { + editor->push_item(inspected_object); + } } else if (p_msg == "message:video_mem") { @@ -499,13 +505,20 @@ void ScriptEditorDebugger::_parse_message(const String &p_msg, const Array &p_da String n = p_data[ofs + i * 2 + 0]; Variant v = p_data[ofs + i * 2 + 1]; + PropertyHint h = PROPERTY_HINT_NONE; + String hs = String(); if (n.begins_with("*")) { n = n.substr(1, n.length()); + h = PROPERTY_HINT_OBJECT_ID; + String s = v; + s = s.replace("[", ""); + hs = s.get_slice(":", 0); + v = s.get_slice(":", 1).to_int(); } - variables->add_property("members/" + n, v); + variables->add_property("members/" + n, v, h, hs); } ofs += mcount * 2; @@ -516,13 +529,20 @@ void ScriptEditorDebugger::_parse_message(const String &p_msg, const Array &p_da String n = p_data[ofs + i * 2 + 0]; Variant v = p_data[ofs + i * 2 + 1]; + PropertyHint h = PROPERTY_HINT_NONE; + String hs = String(); if (n.begins_with("*")) { n = n.substr(1, n.length()); + h = PROPERTY_HINT_OBJECT_ID; + String s = v; + s = s.replace("[", ""); + hs = s.get_slice(":", 0); + v = s.get_slice(":", 1).to_int(); } - variables->add_property("locals/" + n, v); + variables->add_property("locals/" + n, v, h, hs); } variables->update(); @@ -770,19 +790,19 @@ void ScriptEditorDebugger::_performance_draw() { Point2i p(i % cols, i / cols); Rect2i r(p * s, s); - r.pos += Point2(margin, margin); + r.position += Point2(margin, margin); r.size -= Point2(margin, margin) * 2.0; perf_draw->draw_style_box(graph_sb, r); - r.pos += graph_sb->get_offset(); + r.position += graph_sb->get_offset(); r.size -= graph_sb->get_minimum_size(); int pi = which[i]; Color c = Color(0.7, 0.9, 0.5); c.set_hsv(Math::fmod(c.get_h() + pi * 0.7654, 1), c.get_s(), c.get_v()); c.a = 0.8; - perf_draw->draw_string(graph_font, r.pos + Point2(0, graph_font->get_ascent()), perf_items[pi]->get_text(0), c, r.size.x); + perf_draw->draw_string(graph_font, r.position + Point2(0, graph_font->get_ascent()), perf_items[pi]->get_text(0), c, r.size.x); c.a = 0.6; - perf_draw->draw_string(graph_font, r.pos + Point2(graph_font->get_char_size('X').width, graph_font->get_ascent() + graph_font->get_height()), perf_items[pi]->get_text(1), c, r.size.y); + perf_draw->draw_string(graph_font, r.position + Point2(graph_font->get_char_size('X').width, graph_font->get_ascent() + graph_font->get_height()), perf_items[pi]->get_text(1), c, r.size.y); float spacing = point_sep / float(cols); float from = r.size.width; @@ -799,7 +819,7 @@ void ScriptEditorDebugger::_performance_draw() { c.a = 0.7; if (E != perf_history.front()) - perf_draw->draw_line(r.pos + Point2(from, h), r.pos + Point2(from + spacing, prev), c, 2.0); + perf_draw->draw_line(r.position + Point2(from, h), r.position + Point2(from + spacing, prev), c, 2.0); prev = h; E = E->next(); from -= spacing; @@ -999,6 +1019,11 @@ void ScriptEditorDebugger::_notification(int p_what) { } } break; + case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: { + tabs->add_style_override("panel", editor->get_gui_base()->get_stylebox("DebuggerPanel", "EditorStyles")); + tabs->add_style_override("tab_fg", editor->get_gui_base()->get_stylebox("DebuggerTabFG", "EditorStyles")); + tabs->add_style_override("tab_bg", editor->get_gui_base()->get_stylebox("DebuggerTabBG", "EditorStyles")); + } break; } } @@ -1010,14 +1035,17 @@ void ScriptEditorDebugger::start() { EditorNode::get_singleton()->make_bottom_panel_item_visible(this); } - uint16_t port = GLOBAL_GET("network/debug/remote_port"); perf_history.clear(); for (int i = 0; i < Performance::MONITOR_MAX; i++) { perf_max[i] = 0; } - server->listen(port); + int remote_port = (int)EditorSettings::get_singleton()->get("network/debug/remote_port"); + if (server->listen(remote_port) != OK) { + EditorNode::get_log()->add_message(String("** Error listening on port ") + itos(remote_port) + String(" **")); + return; + } set_process(true); } @@ -1056,6 +1084,9 @@ void ScriptEditorDebugger::stop() { EditorNode::get_singleton()->get_pause_button()->set_pressed(false); EditorNode::get_singleton()->get_pause_button()->set_disabled(true); + //avoid confusion when stopped debugging but an object is still edited + EditorNode::get_singleton()->push_item(NULL); + if (hide_on_stop) { if (is_visible_in_tree()) EditorNode::get_singleton()->hide_bottom_panel(); @@ -1551,6 +1582,10 @@ ScriptEditorDebugger::ScriptEditorDebugger(EditorNode *p_editor) { editor = p_editor; tabs = memnew(TabContainer); + tabs->set_tab_align(TabContainer::ALIGN_LEFT); + tabs->add_style_override("panel", editor->get_gui_base()->get_stylebox("DebuggerPanel", "EditorStyles")); + tabs->add_style_override("tab_fg", editor->get_gui_base()->get_stylebox("DebuggerTabFG", "EditorStyles")); + tabs->add_style_override("tab_bg", editor->get_gui_base()->get_stylebox("DebuggerTabBG", "EditorStyles")); tabs->set_v_size_flags(SIZE_EXPAND_FILL); tabs->set_area_as_parent_rect(); add_child(tabs); @@ -1625,8 +1660,9 @@ ScriptEditorDebugger::ScriptEditorDebugger(EditorNode *p_editor) { inspector->set_h_size_flags(SIZE_EXPAND_FILL); inspector->hide_top_label(); inspector->get_scene_tree()->set_column_title(0, TTR("Variable")); - inspector->set_capitalize_paths(false); + inspector->set_enable_capitalize_paths(false); inspector->set_read_only(true); + inspector->connect("object_id_selected", this, "_scene_tree_property_select_object"); sc->add_child(inspector); server = TCP_Server::create_ref(); diff --git a/editor/settings_config_dialog.cpp b/editor/settings_config_dialog.cpp index 8c87857944..563de78415 100644 --- a/editor/settings_config_dialog.cpp +++ b/editor/settings_config_dialog.cpp @@ -148,7 +148,7 @@ void EditorSettingsDialog::_update_shortcuts() { if (!sc->has_meta("original")) continue; - InputEvent original = sc->get_meta("original"); + Ref<InputEvent> original = sc->get_meta("original"); String section_name = E->get().get_slice("/", 0); @@ -170,7 +170,7 @@ void EditorSettingsDialog::_update_shortcuts() { item->set_text(0, sc->get_name()); item->set_text(1, sc->get_as_text()); - if (!sc->is_shortcut(original) && !(sc->get_shortcut().type == InputEvent::NONE && original.type == InputEvent::NONE)) { + if (!sc->is_shortcut(original) && !(sc->get_shortcut().is_null() && original.is_null())) { item->add_button(1, get_icon("Reload", "EditorIcons"), 2); } item->add_button(1, get_icon("Edit", "EditorIcons"), 0); @@ -199,7 +199,7 @@ void EditorSettingsDialog::_shortcut_button_pressed(Object *p_item, int p_column if (p_idx == 0) { press_a_key_label->set_text(TTR("Press a Key..")); - last_wait_for_key = InputEvent(); + last_wait_for_key = Ref<InputEventKey>(); press_a_key->popup_centered(Size2(250, 80) * EDSCALE); press_a_key->grab_focus(); press_a_key->get_ok()->set_focus_mode(FOCUS_NONE); @@ -212,7 +212,7 @@ void EditorSettingsDialog::_shortcut_button_pressed(Object *p_item, int p_column UndoRedo *ur = EditorNode::get_singleton()->get_undo_redo(); ur->create_action("Erase Shortcut"); - ur->add_do_method(sc.ptr(), "set_shortcut", InputEvent()); + ur->add_do_method(sc.ptr(), "set_shortcut", Ref<InputEvent>()); ur->add_undo_method(sc.ptr(), "set_shortcut", sc->get_shortcut()); ur->add_do_method(this, "_update_shortcuts"); ur->add_undo_method(this, "_update_shortcuts"); @@ -223,7 +223,7 @@ void EditorSettingsDialog::_shortcut_button_pressed(Object *p_item, int p_column if (!sc.is_valid()) return; //pointless, there is nothing - InputEvent original = sc->get_meta("original"); + Ref<InputEvent> original = sc->get_meta("original"); UndoRedo *ur = EditorNode::get_singleton()->get_undo_redo(); ur->create_action("Restore Shortcut"); @@ -237,19 +237,21 @@ void EditorSettingsDialog::_shortcut_button_pressed(Object *p_item, int p_column } } -void EditorSettingsDialog::_wait_for_key(const InputEvent &p_event) { +void EditorSettingsDialog::_wait_for_key(const Ref<InputEvent> &p_event) { - if (p_event.type == InputEvent::KEY && p_event.key.pressed && p_event.key.scancode != 0) { + Ref<InputEventKey> k = p_event; - last_wait_for_key = p_event; - String str = keycode_get_string(p_event.key.scancode).capitalize(); - if (p_event.key.mod.meta) + if (k.is_valid() && k->is_pressed() && k->get_scancode() != 0) { + + last_wait_for_key = k; + String str = keycode_get_string(k->get_scancode()).capitalize(); + if (k->get_metakey()) str = TTR("Meta+") + str; - if (p_event.key.mod.shift) + if (k->get_shift()) str = TTR("Shift+") + str; - if (p_event.key.mod.alt) + if (k->get_alt()) str = TTR("Alt+") + str; - if (p_event.key.mod.control) + if (k->get_control()) str = TTR("Control+") + str; press_a_key_label->set_text(str); @@ -259,13 +261,16 @@ void EditorSettingsDialog::_wait_for_key(const InputEvent &p_event) { void EditorSettingsDialog::_press_a_key_confirm() { - if (last_wait_for_key.type != InputEvent::KEY) + if (last_wait_for_key.is_null()) return; - InputEvent ie; - ie.type = InputEvent::KEY; - ie.key.scancode = last_wait_for_key.key.scancode; - ie.key.mod = last_wait_for_key.key.mod; + Ref<InputEventKey> ie; + ie.instance(); + ie->set_scancode(last_wait_for_key->get_scancode()); + ie->set_shift(last_wait_for_key->get_shift()); + ie->set_control(last_wait_for_key->get_control()); + ie->set_alt(last_wait_for_key->get_alt()); + ie->set_metakey(last_wait_for_key->get_metakey()); Ref<ShortCut> sc = EditorSettings::get_singleton()->get_shortcut(shortcut_configured); @@ -300,6 +305,7 @@ EditorSettingsDialog::EditorSettingsDialog() { set_resizable(true); tabs = memnew(TabContainer); + tabs->set_tab_align(TabContainer::ALIGN_LEFT); add_child(tabs); //set_child_rect(tabs); diff --git a/editor/settings_config_dialog.h b/editor/settings_config_dialog.h index 7b6e8862dc..cda191ac36 100644 --- a/editor/settings_config_dialog.h +++ b/editor/settings_config_dialog.h @@ -54,7 +54,7 @@ class EditorSettingsDialog : public AcceptDialog { ConfirmationDialog *press_a_key; Label *press_a_key_label; - InputEvent last_wait_for_key; + Ref<InputEventKey> last_wait_for_key; String shortcut_configured; String shortcut_filter; @@ -68,7 +68,7 @@ class EditorSettingsDialog : public AcceptDialog { void _notification(int p_what); void _press_a_key_confirm(); - void _wait_for_key(const InputEvent &p_event); + void _wait_for_key(const Ref<InputEvent> &p_event); void _clear_shortcut_search_box(); void _clear_search_box(); diff --git a/editor/spatial_editor_gizmos.cpp b/editor/spatial_editor_gizmos.cpp index 4781bb6a3b..76df9eb1ff 100644 --- a/editor/spatial_editor_gizmos.cpp +++ b/editor/spatial_editor_gizmos.cpp @@ -79,7 +79,7 @@ void EditorSpatialGizmo::Instance::create_instance(Spatial *p_base) { VS::get_singleton()->instance_set_layer_mask(instance, 1 << SpatialEditorViewport::GIZMO_EDIT_LAYER); //gizmos are 26 } -void EditorSpatialGizmo::add_mesh(const Ref<Mesh> &p_mesh, bool p_billboard, const RID &p_skeleton) { +void EditorSpatialGizmo::add_mesh(const Ref<ArrayMesh> &p_mesh, bool p_billboard, const RID &p_skeleton) { ERR_FAIL_COND(!spatial_node); Instance ins; @@ -100,7 +100,7 @@ void EditorSpatialGizmo::add_lines(const Vector<Vector3> &p_lines, const Ref<Mat ERR_FAIL_COND(!spatial_node); Instance ins; - Ref<Mesh> mesh = memnew(Mesh); + Ref<ArrayMesh> mesh = memnew(ArrayMesh); Array a; a.resize(Mesh::ARRAY_MAX); @@ -162,7 +162,7 @@ void EditorSpatialGizmo::add_unscaled_billboard(const Ref<Material> &p_material, uv.push_back(Vector2(0, 1)); uv.push_back(Vector2(1, 1)); - Ref<Mesh> mesh = memnew(Mesh); + Ref<ArrayMesh> mesh = memnew(ArrayMesh); Array a; a.resize(Mesh::ARRAY_MAX); a[Mesh::ARRAY_VERTEX] = vs; @@ -219,7 +219,7 @@ void EditorSpatialGizmo::add_handles(const Vector<Vector3> &p_handles, bool p_bi ERR_FAIL_COND(!spatial_node); Instance ins; - Ref<Mesh> mesh = memnew(Mesh); + Ref<ArrayMesh> mesh = memnew(ArrayMesh); #if 1 Array a; @@ -1029,7 +1029,7 @@ CameraSpatialGizmo::CameraSpatialGizmo(Camera *p_camera) { void MeshInstanceSpatialGizmo::redraw() { - Ref<Mesh> m = mesh->get_mesh(); + Ref<ArrayMesh> m = mesh->get_mesh(); if (!m.is_valid()) return; //none @@ -1248,7 +1248,7 @@ void SkeletonSpatialGizmo::redraw() { */ } - Ref<Mesh> m = surface_tool->commit(); + Ref<ArrayMesh> m = surface_tool->commit(); add_mesh(m, false, skel->get_skeleton()); } @@ -1439,20 +1439,6 @@ VehicleWheelSpatialGizmo::VehicleWheelSpatialGizmo(VehicleWheel *p_car_wheel) { car_wheel = p_car_wheel; } -/// - -void TestCubeSpatialGizmo::redraw() { - - clear(); - add_collision_triangles(SpatialEditorGizmos::singleton->test_cube_tm); -} - -TestCubeSpatialGizmo::TestCubeSpatialGizmo(TestCube *p_tc) { - - tc = p_tc; - set_spatial_node(p_tc); -} - /////////// String CollisionShapeSpatialGizmo::get_handle_name(int p_idx) const { @@ -1722,8 +1708,8 @@ void CollisionShapeSpatialGizmo::redraw() { Ref<BoxShape> bs = s; Vector<Vector3> lines; Rect3 aabb; - aabb.pos = -bs->get_extents(); - aabb.size = aabb.pos * -2; + aabb.position = -bs->get_extents(); + aabb.size = aabb.position * -2; for (int i = 0; i < 12; i++) { Vector3 a, b; @@ -1953,7 +1939,7 @@ void VisibilityNotifierGizmo::set_handle(int p_idx, Camera *p_camera, const Poin Vector3 ray_dir = p_camera->project_ray_normal(p_point); Vector3 sg[2] = { gi.xform(ray_from), gi.xform(ray_from + ray_dir * 4096) }; - Vector3 ofs = aabb.pos + aabb.size * 0.5; + Vector3 ofs = aabb.position + aabb.size * 0.5; Vector3 axis; axis[p_idx] = 1.0; @@ -1964,7 +1950,7 @@ void VisibilityNotifierGizmo::set_handle(int p_idx, Camera *p_camera, const Poin if (d < 0.001) d = 0.001; - aabb.pos[p_idx] = (aabb.pos[p_idx] + aabb.size[p_idx] * 0.5) - d; + aabb.position[p_idx] = (aabb.position[p_idx] + aabb.size[p_idx] * 0.5) - d; aabb.size[p_idx] = d * 2; notifier->set_aabb(aabb); } @@ -2002,7 +1988,7 @@ void VisibilityNotifierGizmo::redraw() { for (int i = 0; i < 3; i++) { Vector3 ax; - ax[i] = aabb.pos[i] + aabb.size[i]; + ax[i] = aabb.position[i] + aabb.size[i]; handles.push_back(ax); } @@ -2053,7 +2039,7 @@ void ParticlesGizmo::set_handle(int p_idx, Camera *p_camera, const Point2 &p_poi Vector3 sg[2] = { gi.xform(ray_from), gi.xform(ray_from + ray_dir * 4096) }; - Vector3 ofs = aabb.pos + aabb.size * 0.5; + Vector3 ofs = aabb.position + aabb.size * 0.5; Vector3 axis; axis[p_idx] = 1.0; @@ -2065,7 +2051,7 @@ void ParticlesGizmo::set_handle(int p_idx, Camera *p_camera, const Point2 &p_poi float d = ra[p_idx]; - aabb.pos[p_idx] = d - 1.0 - aabb.size[p_idx] * 0.5; + aabb.position[p_idx] = d - 1.0 - aabb.size[p_idx] * 0.5; particles->set_visibility_aabb(aabb); } else { @@ -2076,7 +2062,7 @@ void ParticlesGizmo::set_handle(int p_idx, Camera *p_camera, const Point2 &p_poi if (d < 0.001) d = 0.001; //resize - aabb.pos[p_idx] = (aabb.pos[p_idx] + aabb.size[p_idx] * 0.5) - d; + aabb.position[p_idx] = (aabb.position[p_idx] + aabb.size[p_idx] * 0.5) - d; aabb.size[p_idx] = d * 2; particles->set_visibility_aabb(aabb); } @@ -2115,13 +2101,13 @@ void ParticlesGizmo::redraw() { for (int i = 0; i < 3; i++) { Vector3 ax; - ax[i] = aabb.pos[i] + aabb.size[i]; - ax[(i + 1) % 3] = aabb.pos[(i + 1) % 3] + aabb.size[(i + 1) % 3] * 0.5; - ax[(i + 2) % 3] = aabb.pos[(i + 2) % 3] + aabb.size[(i + 2) % 3] * 0.5; + ax[i] = aabb.position[i] + aabb.size[i]; + ax[(i + 1) % 3] = aabb.position[(i + 1) % 3] + aabb.size[(i + 1) % 3] * 0.5; + ax[(i + 2) % 3] = aabb.position[(i + 2) % 3] + aabb.size[(i + 2) % 3] * 0.5; handles.push_back(ax); } - Vector3 center = aabb.pos + aabb.size * 0.5; + Vector3 center = aabb.position + aabb.size * 0.5; for (int i = 0; i < 3; i++) { Vector3 ax; @@ -2218,7 +2204,7 @@ void ReflectionProbeGizmo::commit_handle(int p_idx, const Variant &p_restore, bo Rect3 restore = p_restore; if (p_cancel) { - probe->set_extents(restore.pos); + probe->set_extents(restore.position); probe->set_origin_offset(restore.size); return; } @@ -2227,7 +2213,7 @@ void ReflectionProbeGizmo::commit_handle(int p_idx, const Variant &p_restore, bo ur->create_action(TTR("Change Probe Extents")); ur->add_do_method(probe, "set_extents", probe->get_extents()); ur->add_do_method(probe, "set_origin_offset", probe->get_origin_offset()); - ur->add_undo_method(probe, "set_extents", restore.pos); + ur->add_undo_method(probe, "set_extents", restore.position); ur->add_undo_method(probe, "set_origin_offset", restore.size); ur->commit_action(); } @@ -2241,7 +2227,7 @@ void ReflectionProbeGizmo::redraw() { Vector3 extents = probe->get_extents(); Rect3 aabb; - aabb.pos = -extents; + aabb.position = -extents; aabb.size = extents * 2; for (int i = 0; i < 12; i++) { @@ -2262,7 +2248,7 @@ void ReflectionProbeGizmo::redraw() { for (int i = 0; i < 3; i++) { Vector3 ax; - ax[i] = aabb.pos[i] + aabb.size[i]; + ax[i] = aabb.position[i] + aabb.size[i]; handles.push_back(ax); } @@ -2392,7 +2378,7 @@ void GIProbeGizmo::redraw() { for (int k = 0; k < 4; k++) { - Vector3 from = aabb.pos, to = aabb.pos; + Vector3 from = aabb.position, to = aabb.position; from[j] += cell_size * i; to[j] += cell_size * i; @@ -2421,7 +2407,7 @@ void GIProbeGizmo::redraw() { for (int i = 0; i < 3; i++) { Vector3 ax; - ax[i] = aabb.pos[i] + aabb.size[i]; + ax[i] = aabb.position[i] + aabb.size[i]; handles.push_back(ax); } @@ -2511,7 +2497,7 @@ void NavigationMeshSpatialGizmo::redraw() { if (lines.size()) add_lines(lines, navmesh->is_enabled() ? SpatialEditorGizmos::singleton->navmesh_edge_material : SpatialEditorGizmos::singleton->navmesh_edge_material_disabled); add_collision_triangles(tmesh); - Ref<Mesh> m = memnew(Mesh); + Ref<ArrayMesh> m = memnew(ArrayMesh); Array a; a.resize(Mesh::ARRAY_MAX); a[0] = tmeshfaces; @@ -3045,12 +3031,6 @@ Ref<SpatialEditorGizmo> SpatialEditorGizmos::get_gizmo(Spatial *p_spatial) { return misg; } - if (p_spatial->cast_to<TestCube>()) { - - Ref<TestCubeSpatialGizmo> misg = memnew(TestCubeSpatialGizmo(p_spatial->cast_to<TestCube>())); - return misg; - } - if (p_spatial->cast_to<CollisionShape>()) { Ref<CollisionShapeSpatialGizmo> misg = memnew(CollisionShapeSpatialGizmo(p_spatial->cast_to<CollisionShape>())); @@ -3213,7 +3193,7 @@ SpatialEditorGizmos::SpatialEditorGizmos() { //position 3D Shared mesh - pos3d_mesh = Ref<Mesh>(memnew(Mesh)); + pos3d_mesh = Ref<ArrayMesh>(memnew(ArrayMesh)); { PoolVector<Vector3> cursor_points; @@ -3246,7 +3226,7 @@ SpatialEditorGizmos::SpatialEditorGizmos() { pos3d_mesh->surface_set_material(0, mat); } - listener_line_mesh = Ref<Mesh>(memnew(Mesh)); + listener_line_mesh = Ref<ArrayMesh>(memnew(ArrayMesh)); { PoolVector<Vector3> cursor_points; diff --git a/editor/spatial_editor_gizmos.h b/editor/spatial_editor_gizmos.h index 095586ab91..a8ace87530 100644 --- a/editor/spatial_editor_gizmos.h +++ b/editor/spatial_editor_gizmos.h @@ -46,7 +46,6 @@ #include "scene/3d/ray_cast.h" #include "scene/3d/reflection_probe.h" #include "scene/3d/room_instance.h" -#include "scene/3d/test_cube.h" #include "scene/3d/vehicle_body.h" #include "scene/3d/visibility_notifier.h" @@ -59,7 +58,7 @@ class EditorSpatialGizmo : public SpatialEditorGizmo { struct Instance { RID instance; - Ref<Mesh> mesh; + Ref<ArrayMesh> mesh; RID skeleton; bool billboard; bool unscaled; @@ -97,7 +96,7 @@ class EditorSpatialGizmo : public SpatialEditorGizmo { protected: void add_lines(const Vector<Vector3> &p_lines, const Ref<Material> &p_material, bool p_billboard = false); - void add_mesh(const Ref<Mesh> &p_mesh, bool p_billboard = false, const RID &p_skeleton = RID()); + void add_mesh(const Ref<ArrayMesh> &p_mesh, bool p_billboard = false, const RID &p_skeleton = RID()); void add_collision_segments(const Vector<Vector3> &p_lines); void add_collision_triangles(const Ref<TriangleMesh> &p_tmesh); void add_unscaled_billboard(const Ref<Material> &p_material, float p_scale = 1); @@ -187,17 +186,6 @@ public: SkeletonSpatialGizmo(Skeleton *p_skel = NULL); }; -class TestCubeSpatialGizmo : public EditorSpatialGizmo { - - GDCLASS(TestCubeSpatialGizmo, EditorSpatialGizmo); - - TestCube *tc; - -public: - void redraw(); - TestCubeSpatialGizmo(TestCube *p_tc = NULL); -}; - class RoomSpatialGizmo : public EditorSpatialGizmo { GDCLASS(RoomSpatialGizmo, EditorSpatialGizmo); @@ -454,8 +442,8 @@ public: Ref<SpatialMaterial> shape_material; Ref<Texture> handle_t; - Ref<Mesh> pos3d_mesh; - Ref<Mesh> listener_line_mesh; + Ref<ArrayMesh> pos3d_mesh; + Ref<ArrayMesh> listener_line_mesh; static SpatialEditorGizmos *singleton; Ref<TriangleMesh> test_cube_tm; diff --git a/editor/translations/ar.po b/editor/translations/ar.po index 48d015ec07..867302b657 100644 --- a/editor/translations/ar.po +++ b/editor/translations/ar.po @@ -1,5 +1,6 @@ # Arabic translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # athomield <athomield@hotmail.com>, 2017. @@ -358,6 +359,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +534,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -378,10 +570,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "الموقع:" @@ -413,20 +601,6 @@ msgstr "" msgid "Call" msgstr "نداء" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -476,13 +650,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -632,11 +799,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1111,10 +1273,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1479,21 +1637,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1762,10 +1905,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3736,6 +3875,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3783,6 +3926,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4232,6 +4383,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5088,11 +5247,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5104,7 +5263,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5140,10 +5299,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5202,6 +5357,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5385,7 +5544,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5452,10 +5611,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6057,6 +6212,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6616,6 +6775,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/bg.po b/editor/translations/bg.po index fe15509a62..f884b33773 100644 --- a/editor/translations/bg.po +++ b/editor/translations/bg.po @@ -1,5 +1,6 @@ # Bulgarian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Bojidar Marinov <bojidar.marinov.bg@gmail.com>, 2016. @@ -356,6 +357,176 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Файл:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Имаше грешка при зареждане на сцената." + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +534,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Внасяне" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Приставки" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +570,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -411,20 +601,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +650,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +799,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1110,10 +1274,6 @@ msgstr "" msgid "Clear" msgstr "Изчистване" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1478,21 +1638,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Внасяне на обекти в проекта." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Внасяне" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1761,10 +1906,6 @@ msgid "Installed Plugins:" msgstr "Инсталирани приставки:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3744,6 +3885,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3791,6 +3936,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4241,6 +4394,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5101,11 +5262,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5117,7 +5278,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5153,10 +5314,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5215,6 +5372,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5399,7 +5560,7 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "Настройки на проекта" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5466,10 +5627,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Приставки" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6079,6 +6236,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6664,6 +6825,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6732,6 +6904,13 @@ msgid "" "texture to some node for display." msgstr "" +#~ msgid "Import assets to the project." +#~ msgstr "Внасяне на обекти в проекта." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Настройки на проекта" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/bn.po b/editor/translations/bn.po index d4184dfe2b..3e4dec7656 100644 --- a/editor/translations/bn.po +++ b/editor/translations/bn.po @@ -1,5 +1,6 @@ # Bengali translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Abu Md. Maruf Sarker <maruf.webdev@gmail.com>, 2016-2017. @@ -358,6 +359,184 @@ msgstr "শ্রেণীবিন্যাস/সারির মানের msgid "Change Array Value" msgstr "শ্রেণীবিন্যাস/সারির মান পরিবর্তন করুন" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "সংস্করণ:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "ধ্রুবকসমূহ:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "ফাইল" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "বর্ণনা:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "ইন্সটল" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "বন্ধ করুন" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "সংযোগ.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "নোডের সাথে সংযুক্ত করুন:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "আবেদনকৃত ফাইল ফরম্যাট/ধরণ অজানা:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "সংরক্ষিত হচ্ছে.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "সংযোগ.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "পরীক্ষামূলক উৎস" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "রিসোর্স সংরক্ষণে সমস্যা হয়েছে!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "নীচে" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "সকল" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +544,29 @@ msgstr "শ্রেণীবিন্যাস/সারির মান পর msgid "Search:" msgstr "অনুসন্ধান করুন:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "অনুসন্ধান করুন" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "ইম্পোর্ট" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "প্লাগইন-সমূহ" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "সাজান:" @@ -378,10 +580,6 @@ msgid "Category:" msgstr "বিভাগ:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "সকল" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "ওয়েবসাইট:" @@ -413,20 +611,6 @@ msgstr "'%s' এর জন্য মেথডের তালিকা:" msgid "Call" msgstr "ডাকুন (Call)" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "বন্ধ করুন" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "মেথডের তালিকা:" @@ -477,13 +661,6 @@ msgid "Selection Only" msgstr "শুধুমাত্র নির্বাচিতসমূহ" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "অনুসন্ধান করুন" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "সন্ধান করুন" @@ -635,11 +812,6 @@ msgstr "সাম্প্রতিক:" msgid "Matches:" msgstr "মিলসমূহ:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "বর্ণনা:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "এর জন্য প্রতিস্থাপকের অনুসন্ধান করুন:" @@ -1128,10 +1300,6 @@ msgstr " আউটপুট/ফলাফল:" msgid "Clear" msgstr "পরিস্কার করুন/ক্লীয়ার" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "দৃশ্য হতে নোড" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1514,21 +1682,6 @@ msgid "Distraction Free Mode" msgstr "বিক্ষেপ-হীন মোড" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "উপাদানসমূহ প্রকল্পে ইম্পোর্ট করুন।" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "ইম্পোর্ট" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "প্রকল্প অথবা দৃশ্যে-ব্যাপী বিবিধ সরঞ্জাম-সমূহ।" @@ -1818,10 +1971,6 @@ msgid "Installed Plugins:" msgstr "ইন্সটল-কৃত প্লাগইন-সমূহ:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "সংস্করণ:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "লেখক:" @@ -3830,6 +3979,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "AABB উৎপন্ন করুন" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "পৃষ্ঠসমূহ কোনো আকার নেই!" @@ -3882,6 +4036,16 @@ msgstr "আয়তন" msgid "Emission Source: " msgstr "Emission পূরণ:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "AABB উৎপন্ন করুন" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "গড় সময় (সেঃ)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "বক্ররেখা হতে বিন্দু অপসারণ করুন" @@ -4334,6 +4498,14 @@ msgid "Trim Trailing Whitespace" msgstr "শেষের হোয়াইটস্পেস ছেঁটে ফেলুন" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "স্বয়ংক্রিয়ভাবে মাত্রা দিন" @@ -5207,12 +5379,12 @@ msgstr "অকার্যকর প্রকল্পের পথ, পথট #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "অকার্যকর প্রকল্পের পথ, engine.cfg অবশ্যই অনুপস্থিত হতে হবে।" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "অকার্যকর প্রকল্পের পথ, engine.cfg অবশ্যই উপস্থিত হতে হবে।" #: editor/project_manager.cpp @@ -5225,7 +5397,7 @@ msgstr "অকার্যকর প্রকল্পের পথ (কোন #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "প্রকল্পের পথে engine.cfg তৈরি করা সম্ভব হয়নি।" #: editor/project_manager.cpp @@ -5261,10 +5433,6 @@ msgid "Install Project:" msgstr "প্রকল্প ইন্সটল করুন:" #: editor/project_manager.cpp -msgid "Install" -msgstr "ইন্সটল" - -#: editor/project_manager.cpp msgid "Browse" msgstr "ব্রাউস" @@ -5325,6 +5493,11 @@ msgid "New Project" msgstr "নতুন প্রকল্প" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "বস্তু অপসারণ করুন" + +#: editor/project_manager.cpp msgid "Exit" msgstr "প্রস্থান করুন" @@ -5511,8 +5684,8 @@ msgstr "রিসোর্সের পুনঃ-নকশার সিদ্ধ #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "প্রকল্পের সেটিংস (engine.cfg)" +msgid "Project Settings " +msgstr "প্রকল্পের সেটিংস" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5578,10 +5751,6 @@ msgstr "ঘটনাস্থল" msgid "AutoLoad" msgstr "স্বয়ংক্রিয়-লোড" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "প্লাগইন-সমূহ" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6191,6 +6360,10 @@ msgid "Change Notifier Extents" msgstr "Notifier এর সীমা পরিবর্তন করুন" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "প্রোবের (Probe) পরিব্যাপ্তি পরিবর্তন করুন" @@ -6792,6 +6965,17 @@ msgstr "" "NavigationMeshInstance-কে অবশ্যই Navigation-এর অংশ অথবা অংশের অংশ হতে হবে। " "এটা শুধুমাত্র ন্যাভিগেশনের তথ্য প্রদান করে।" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "Path এর দিক অবশ্যই একটি কার্যকর Spatial নোডের এর দিকে নির্দেশ করাতে হবে।" @@ -6868,6 +7052,16 @@ msgstr "" "আকার ধারণ করতে পারে। অন্যথায়, এটিকে একটি RenderTarget করুন এবং এর অভ্যন্তরীণ " "দৃশ্যাবলিকে (texture) দৃশ্যমান করতে কোনো নোডে হস্তান্তর করুন।" +#~ msgid "Node From Scene" +#~ msgstr "দৃশ্য হতে নোড" + +#~ msgid "Import assets to the project." +#~ msgstr "উপাদানসমূহ প্রকল্পে ইম্পোর্ট করুন।" + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "প্রকল্পের সেটিংস (engine.cfg)" + #~ msgid "Surface" #~ msgstr "পৃষ্ঠতল" diff --git a/editor/translations/ca.po b/editor/translations/ca.po index b125b6582f..6d7b245e58 100644 --- a/editor/translations/ca.po +++ b/editor/translations/ca.po @@ -1,5 +1,6 @@ # Catalan translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Roger BR <drai_kin@hotmail.com>, 2016. @@ -358,6 +359,184 @@ msgstr "Canvia Tipus de la Matriu" msgid "Change Array Value" msgstr "Canvia Valor de la Matriu" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Versió:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constants:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Fitxer:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Descripció:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Tanca" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Connecta.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Connecta al Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Format de fitxer desconegut:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Desant..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Connecta.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Provant" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Error en desar recurs!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Errors de Càrrega" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Tot" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +544,29 @@ msgstr "Canvia Valor de la Matriu" msgid "Search:" msgstr "Cerca:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Cerca" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importa" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ordena:" @@ -378,10 +580,6 @@ msgid "Category:" msgstr "Categoria:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Tot" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Lloc:" @@ -413,20 +611,6 @@ msgstr "Llista de mètodes de '%s':" msgid "Call" msgstr "Crida" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Tanca" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Llista de mètodes:" @@ -477,13 +661,6 @@ msgid "Selection Only" msgstr "Selecció Només" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Cerca" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Troba" @@ -634,11 +811,6 @@ msgstr "Recents:" msgid "Matches:" msgstr "Coincidències:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Descripció:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Cerca Reemplaçant per a:" @@ -1123,10 +1295,6 @@ msgstr " Sortida:" msgid "Clear" msgstr "Neteja" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Node de l'Escena" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1510,21 +1678,6 @@ msgid "Distraction Free Mode" msgstr "Mode Lliure de Distraccions" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importa actius al projecte." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importa" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Eines vàries o d'escena." @@ -1815,10 +1968,6 @@ msgid "Installed Plugins:" msgstr "Connectors Instal·lats:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Versió:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3815,6 +3964,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3863,6 +4016,15 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Temps Mitjà (s)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4314,6 +4476,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5179,12 +5349,12 @@ msgstr "" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "El camí de Destinació ha d'existir." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "El camí de Destinació ha d'existir." #: editor/project_manager.cpp @@ -5196,7 +5366,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5232,10 +5402,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5294,6 +5460,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Treu la Selecció" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5478,8 +5649,8 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Configuració del Projecte (engine.cfg)" +msgid "Project Settings " +msgstr "Configuració del Projecte" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5545,10 +5716,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6161,6 +6328,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6784,6 +6955,17 @@ msgstr "" "NavigationMeshInstance ha de ser fill o nét d'un node Navigation. Només " "proporciona dades de navegació." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6862,6 +7044,16 @@ msgstr "" "forma per tal d'obtenir-ne la mida. Altrament, establiu-la com a Destinació " "de Renderització i assigneu-ne la textura interna a algun node." +#~ msgid "Node From Scene" +#~ msgstr "Node de l'Escena" + +#~ msgid "Import assets to the project." +#~ msgstr "Importa actius al projecte." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Configuració del Projecte (engine.cfg)" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/cs.po b/editor/translations/cs.po index 08982fd7e4..4643a9ac21 100644 --- a/editor/translations/cs.po +++ b/editor/translations/cs.po @@ -1,5 +1,6 @@ # Czech translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Jan 'spl!te' Kondelík <j.kondelik@centrum.cz>, 2016. @@ -358,6 +359,181 @@ msgstr "Změnit typ hodnot pole" msgid "Change Array Value" msgstr "Změnit hodnotu pole" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Spojité" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Soubor:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Zavřít" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Připojit.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Připojit k uzlu:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Připojit.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testované" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Chyba nahrávání fontu." + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Všechny" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +541,29 @@ msgstr "Změnit hodnotu pole" msgid "Search:" msgstr "Hledat:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Hledat" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Řadit:" @@ -378,10 +577,6 @@ msgid "Category:" msgstr "Kategorie:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Všechny" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Web:" @@ -413,20 +608,6 @@ msgstr "Seznam metod '%s':" msgid "Call" msgstr "Zavolat" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Zavřít" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Seznam metod:" @@ -477,13 +658,6 @@ msgid "Selection Only" msgstr "Pouze výběr" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Hledat" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Najít" @@ -633,11 +807,6 @@ msgstr "" msgid "Matches:" msgstr "Shody:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Hledat náhradu za:" @@ -1120,10 +1289,6 @@ msgstr "" msgid "Clear" msgstr "Vyčistit" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1488,21 +1653,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1772,10 +1922,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3753,6 +3899,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3800,6 +3950,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4251,6 +4409,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5111,11 +5277,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5127,7 +5293,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5163,10 +5329,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5225,6 +5387,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Odstranit výběr" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5409,7 +5576,7 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "Nastavení projektu" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5476,10 +5643,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6087,6 +6250,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6695,6 +6862,17 @@ msgstr "" "NavigationMeshInstance musí být dítětem nebo vnoučetem uzlu Navigation. " "Poskytuje pouze data pro navigaci." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6774,6 +6952,10 @@ msgstr "" "mohl získat velikost. Jinak ho nastavte jako render target a přiřaďte jeho " "vnitřní texturu nějakému uzlu k zobrazení." +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Nastavení projektu" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/da.po b/editor/translations/da.po index 49b26f6ed2..ba9d018e5a 100644 --- a/editor/translations/da.po +++ b/editor/translations/da.po @@ -1,5 +1,6 @@ # Danish translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # David Lamhauge <davidlamhauge@gmail.com>, 2016. @@ -356,6 +357,181 @@ msgstr "Skift Array værditype" msgid "Change Array Value" msgstr "Ændre Array-værdi" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Kontinuerlig" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Fil:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Luk" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Forbind..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Opret forbindelse til Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Forbind..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Tester" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Error loading skrifttype." + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Alle" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +539,29 @@ msgstr "Ændre Array-værdi" msgid "Search:" msgstr "Søgning:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Søg" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sorter:" @@ -376,10 +575,6 @@ msgid "Category:" msgstr "Kategori:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Alle" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Websted:" @@ -411,20 +606,6 @@ msgstr "Metode liste For '%s':" msgid "Call" msgstr "Kald" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Luk" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Metode liste:" @@ -475,13 +656,6 @@ msgid "Selection Only" msgstr "Kun Valgte" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Søg" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Find" @@ -631,11 +805,6 @@ msgstr "" msgid "Matches:" msgstr "Matches:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Søg erstatning For:" @@ -1114,10 +1283,6 @@ msgstr "" msgid "Clear" msgstr "Clear" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1482,21 +1647,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1765,10 +1915,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3744,6 +3890,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3791,6 +3941,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4242,6 +4400,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5099,11 +5265,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5115,7 +5281,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5151,10 +5317,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5213,6 +5375,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Fjern markering" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5396,7 +5563,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5463,10 +5630,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6072,6 +6235,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6672,6 +6839,17 @@ msgstr "" "NavigationMeshInstance skal være et barn eller barnebarn til en Navigation " "node. Det giver kun navigationsdata." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." diff --git a/editor/translations/de.po b/editor/translations/de.po index ac615e885b..a10eaefa29 100644 --- a/editor/translations/de.po +++ b/editor/translations/de.po @@ -1,5 +1,6 @@ # German translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Alexander Mahr <alex.mahr@gmail.com>, 2016. @@ -375,6 +376,184 @@ msgstr "Wertetyp des Arrays ändern" msgid "Change Array Value" msgstr "Array-Wert ändern" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Version:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Konstanten:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Datei" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Beschreibung:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Installieren" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Schließen" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Verbinde.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Verbinde mit Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Angefordertes Dateiformat unbekannt:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Speichere.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Verbinde.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testphase" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Fehler beim speichern der Ressource!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Herunter" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Alle" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -382,6 +561,29 @@ msgstr "Array-Wert ändern" msgid "Search:" msgstr "Suche:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Suche" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Import" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Erweiterungen" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sortiere:" @@ -395,10 +597,6 @@ msgid "Category:" msgstr "Kategorie:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Alle" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Seite:" @@ -430,20 +628,6 @@ msgstr "Methodenliste für '%s':" msgid "Call" msgstr "Aufruf" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Schließen" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Methodenliste:" @@ -494,13 +678,6 @@ msgid "Selection Only" msgstr "Nur Auswahl" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Suche" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Finde" @@ -652,11 +829,6 @@ msgstr "Kürzlich:" msgid "Matches:" msgstr "Treffer:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Beschreibung:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Suche Ersatz für:" @@ -1145,10 +1317,6 @@ msgstr " Ausgabe:" msgid "Clear" msgstr "Löschen" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Node aus Szene" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1533,21 +1701,6 @@ msgid "Distraction Free Mode" msgstr "Ablenkungsfreier Modus" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importiere Medieninhalte ins Projekt." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Import" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Sonstiges Projekt oder szenenübergreifende Werkzeuge." @@ -1837,10 +1990,6 @@ msgid "Installed Plugins:" msgstr "Installierte Erweiterungen:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Version:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3852,6 +4001,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Erzeuge AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Flächen enthalten keinen Bereich!" @@ -3904,6 +4058,16 @@ msgstr "Volumen" msgid "Emission Source: " msgstr "Emissionsfüllung:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Erzeuge AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Durchschnittszeit (Sek)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Punkt von Kurve entfernen" @@ -4358,6 +4522,14 @@ msgid "Trim Trailing Whitespace" msgstr "kürze Leerraum am Zeilenende" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Automatische Einrückung" @@ -5232,12 +5404,12 @@ msgstr "Ungültiger Projektpfad, der Pfad muss existieren!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Ungültiger Projektpfad, engine.cfg darf nicht existieren." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Ungültiger Projektpfad, engine.cfg muss existieren." #: editor/project_manager.cpp @@ -5250,7 +5422,7 @@ msgstr "Ungültiger Projektpfad (etwas geändert?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Konnte engine.cfg in Projektpfad nicht erzeugen." #: editor/project_manager.cpp @@ -5286,10 +5458,6 @@ msgid "Install Project:" msgstr "Installiere Projekt:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Installieren" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Durchstöbern" @@ -5350,6 +5518,11 @@ msgid "New Project" msgstr "Neues Projekt" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Entferne Element" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Verlassen" @@ -5536,8 +5709,8 @@ msgstr "Ressourcen-Remap-Option entfernen" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Projekteinstellungen (engine.cfg)" +msgid "Project Settings " +msgstr "Projekteinstellungen" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5603,10 +5776,6 @@ msgstr "Lokalisierung" msgid "AutoLoad" msgstr "Autoload" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Erweiterungen" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6220,6 +6389,10 @@ msgid "Change Notifier Extents" msgstr "Ändere Ausmaße des Benachrichtigers" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "Ändere Ausmaße des Benachrichtigers" @@ -6842,6 +7015,17 @@ msgstr "" "Eine NavigationMesh-Instanz muss ein Unterobjekt erster oder höherer Ordnung " "eines Navigation-Nodes sein. Es liefert nur Navigationsdaten." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "Die Pfad-Eigenschaft muss auf ein gültiges Spatial-Node verweisen." @@ -6920,6 +7104,16 @@ msgstr "" "Eigenschaft ‚Render Target‘ des Viewports aktiviert und seine Textur " "irgendeinem Node zum Anzeigen zugewiesen werden." +#~ msgid "Node From Scene" +#~ msgstr "Node aus Szene" + +#~ msgid "Import assets to the project." +#~ msgstr "Importiere Medieninhalte ins Projekt." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Projekteinstellungen (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Oberfläche" diff --git a/editor/translations/de_CH.po b/editor/translations/de_CH.po index ae6d433e54..183f09e9a6 100644 --- a/editor/translations/de_CH.po +++ b/editor/translations/de_CH.po @@ -1,5 +1,6 @@ # Swiss High German translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Christian Fisch <christian.fiesel@gmail.com>, 2016. @@ -355,6 +356,178 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Datei(en) öffnen" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Verbindung zu Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Connections editieren" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Szene kann nicht gespeichert werden." + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -362,6 +535,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -375,10 +571,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -410,20 +602,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -473,13 +651,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +801,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1108,10 +1274,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Node von Szene" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1477,21 +1639,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Assets zum Projekt importieren." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Verschiedene Projekte oder Szenenweite Werkzeuge." @@ -1764,10 +1911,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3758,6 +3901,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Flächen enthalten keinen Bereich!" @@ -3807,6 +3954,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4256,6 +4411,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5116,12 +5279,12 @@ msgstr "Ungültiger Projektpfad, Pfad existiert nicht!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Ungültiger Projektpfad, engine.cfg vorhanden!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Ungültiger Projektpfad, engine.cfg nicht vorhanden!" #: editor/project_manager.cpp @@ -5134,7 +5297,7 @@ msgstr "Ungültiger Projektpfad, (wurde was geändert?)!" #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Die engine.cfg kann im Projektverzeichnis nicht erstellt werden." #: editor/project_manager.cpp @@ -5170,10 +5333,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5232,6 +5391,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Ungültige Bilder löschen" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5416,7 +5580,7 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "Projekteinstellungen" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5483,10 +5647,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6095,6 +6255,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6669,6 +6833,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6735,6 +6910,16 @@ msgid "" "texture to some node for display." msgstr "" +#~ msgid "Node From Scene" +#~ msgstr "Node von Szene" + +#~ msgid "Import assets to the project." +#~ msgstr "Assets zum Projekt importieren." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Projekteinstellungen" + #~ msgid "Surface" #~ msgstr "Oberfläche" diff --git a/editor/translations/editor.pot b/editor/translations/editor.pot index 276662dbed..5f50c159b8 100644 --- a/editor/translations/editor.pot +++ b/editor/translations/editor.pot @@ -1,5 +1,6 @@ # LANGUAGE translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. @@ -349,6 +350,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -356,6 +525,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -369,10 +561,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -404,20 +592,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -467,13 +641,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -623,11 +790,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1101,10 +1263,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1469,21 +1627,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1752,10 +1895,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3725,6 +3864,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3772,6 +3915,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4221,6 +4372,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5077,11 +5236,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5093,7 +5252,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5129,10 +5288,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5191,6 +5346,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5374,7 +5533,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5441,10 +5600,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6044,6 +6199,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6584,6 +6743,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/el.po b/editor/translations/el.po index 357112ce0c..0879b693ff 100644 --- a/editor/translations/el.po +++ b/editor/translations/el.po @@ -1,5 +1,6 @@ # Greek translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # gtsiam <gtsiam@windowslive.com>, 2017. @@ -358,6 +359,182 @@ msgstr "Αλλαγή τύπου τιμής πίνακα" msgid "Change Array Value" msgstr "Αλλαγή τιμής πίνακα" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Σταθερές:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Αρχείο:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Περιγραφή:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Κλείσιμο" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Σύνδεση.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Σύνδεση στον κόμβο:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Ζητήθηκε άγνωστη μορφή αρχείου:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Σύνδεση.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Δοκιμιμαστικά" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Σφάλμα κατά την αποθήκευση πόρου!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Όλα" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +542,29 @@ msgstr "Αλλαγή τιμής πίνακα" msgid "Search:" msgstr "Αναζήτηση:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Αναζήτηση" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Εισαγωγή" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ταξινόμηση:" @@ -378,10 +578,6 @@ msgid "Category:" msgstr "Κατηγορία:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Όλα" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Διεύθυνση:" @@ -413,20 +609,6 @@ msgstr "Λίστα συναρτήσεων για '%s':" msgid "Call" msgstr "Κλήση" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Κλείσιμο" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Λίστα συναρτήσεων:" @@ -477,13 +659,6 @@ msgid "Selection Only" msgstr "Μόνο στην επιλογή" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Αναζήτηση" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Εύρεση" @@ -635,11 +810,6 @@ msgstr "Πρόσφατα:" msgid "Matches:" msgstr "Αντιστοιχίες:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Περιγραφή:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Αναζήτηση αντικατάστασης για:" @@ -1125,10 +1295,6 @@ msgstr " Έξοδος:" msgid "Clear" msgstr "Εκκαθάριση" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Κόμβος από σκηνή" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1517,21 +1683,6 @@ msgid "Distraction Free Mode" msgstr "Λειτουργία χωρίς διάσπαση προσοχής" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Εισαγωγή πόρων στο έργο." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Εισαγωγή" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Λοιπά έργα ή εργαλεία για όλη τη σκηνή." @@ -1821,10 +1972,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3804,6 +3951,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3851,6 +4002,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4301,6 +4460,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5163,11 +5330,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5179,7 +5346,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5215,10 +5382,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5277,6 +5440,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Αφαίρεση επιλογής" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5461,7 +5629,7 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "Ρυθμίσεις έργου" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5528,10 +5696,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6134,6 +6298,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6758,6 +6926,17 @@ msgstr "" "Ένας κόμβος NavigationMeshInstance πρέπει να κληρονομεί έναν κόμβο τύπου " "Navigation, διότι διαθέτει μόνο δεδομένα πλοήγησης." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6836,6 +7015,16 @@ msgstr "" "μέγεθος. Αλλιώς, κάντε το ένα RenderTarget και ορίστε το internal texture σε " "έναν κόμβο για απεικόνιση." +#~ msgid "Node From Scene" +#~ msgstr "Κόμβος από σκηνή" + +#~ msgid "Import assets to the project." +#~ msgstr "Εισαγωγή πόρων στο έργο." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Ρυθμίσεις έργου" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/es.po b/editor/translations/es.po index 6c9c54d88e..f01c84718b 100644 --- a/editor/translations/es.po +++ b/editor/translations/es.po @@ -1,5 +1,6 @@ # Spanish translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Alejandro Alvarez <eliluminado00@gmail.com>, 2017. @@ -366,6 +367,184 @@ msgstr "Cambiar tipo de valor del «array»" msgid "Change Array Value" msgstr "Cambiar valor del «array»" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Versión:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constantes:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Archivo" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Descripción:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Instalar" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Cerrar" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Conectar.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Conectar a nodo:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Formato de archivo desconocido:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Guardando…" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Conectar.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Prueba" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "¡Hubo un error al guardar el recurso!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Abajo" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Todos" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -373,6 +552,29 @@ msgstr "Cambiar valor del «array»" msgid "Search:" msgstr "Buscar:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Buscar" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importar" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Plugins" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ordenar:" @@ -386,10 +588,6 @@ msgid "Category:" msgstr "Categoría:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Todos" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Sitio:" @@ -421,20 +619,6 @@ msgstr "Lista de métodos Para '%s':" msgid "Call" msgstr "Llamada" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Cerrar" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Lista de métodos:" @@ -485,13 +669,6 @@ msgid "Selection Only" msgstr "Sólo selección" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Buscar" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Búsqueda" @@ -645,11 +822,6 @@ msgstr "Recientes:" msgid "Matches:" msgstr "Coincidencias:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Descripción:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Buscar reemplazo para:" @@ -1141,10 +1313,6 @@ msgstr " Salida:" msgid "Clear" msgstr "Borrar todo" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Nodo desde escena" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1529,21 +1697,6 @@ msgid "Distraction Free Mode" msgstr "Modo sin distracciones" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importar elementos al proyecto." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importar" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Herramientas varias o de escenas." @@ -1834,10 +1987,6 @@ msgid "Installed Plugins:" msgstr "Plugins instalados:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Versión:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3868,6 +4017,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Generar AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "¡Las caras no contienen área!" @@ -3920,6 +4074,16 @@ msgstr "Volumen" msgid "Emission Source: " msgstr "Relleno de emisión:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Generar AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Tiempo promedio (seg)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Borrar punto de curva" @@ -4377,6 +4541,14 @@ msgid "Trim Trailing Whitespace" msgstr "Borrar espacios sobrantes al final" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Autoindentar" @@ -5255,12 +5427,12 @@ msgstr "¡La ruta del proyecto no es correcta, tiene que existir!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "La ruta del proyecto no es correcta, engine.cfg no debe existir." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "¡La ruta del proyecto no es correcta, engine.cfg debe existir." #: editor/project_manager.cpp @@ -5273,7 +5445,7 @@ msgstr "La ruta del proyecto no es correcta (¿has cambiado algo?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "No se pudo crear engine.cfg en la ruta de proyecto." #: editor/project_manager.cpp @@ -5309,10 +5481,6 @@ msgid "Install Project:" msgstr "Instalar proyecto:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Instalar" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Examinar" @@ -5375,6 +5543,11 @@ msgid "New Project" msgstr "Proyecto nuevo" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Remover Item" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Salir" @@ -5561,8 +5734,8 @@ msgstr "Quitar opción de remapeo de recursos" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Ajustes de proyecto (engine.cfg)" +msgid "Project Settings " +msgstr "Ajustes del proyecto" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5628,10 +5801,6 @@ msgstr "Idioma" msgid "AutoLoad" msgstr "AutoLoad" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Plugins" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6254,6 +6423,10 @@ msgid "Change Notifier Extents" msgstr "Cambiar Alcances de Notificadores" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "Cambiar Alcances de Notificadores" @@ -6899,6 +7072,17 @@ msgstr "" "NavigationMeshInstance debe ser un hijo o nieto de un nodo Navigation. Ya " "que sólo proporciona los datos de navegación." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6977,6 +7161,16 @@ msgstr "" "que pueda obtener un tamaño. Alternativamente, hacelo un RenderTarget y " "asigná su textura interna a algún otro nodo para mostrar." +#~ msgid "Node From Scene" +#~ msgstr "Nodo desde escena" + +#~ msgid "Import assets to the project." +#~ msgstr "Importar elementos al proyecto." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Ajustes de proyecto (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Superficie" diff --git a/editor/translations/es_AR.po b/editor/translations/es_AR.po index 502b043378..f826517b27 100644 --- a/editor/translations/es_AR.po +++ b/editor/translations/es_AR.po @@ -1,5 +1,6 @@ # Spanish (Argentina) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Lisandro Lorea <lisandrolorea@gmail.com>, 2016-2017. @@ -361,6 +362,184 @@ msgstr "Cambiar Tipo de Valor del Array" msgid "Change Array Value" msgstr "Cambiar Valor del Array" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Version:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constantes:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Archivo" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Descripción:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Instalar" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Cerrar" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Conectar.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Conectar a Nodo:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Formato requerido de archivo desconocido:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Guardando.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Conectar.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testeo" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Error al guardar el recurso!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Abajo" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Todos" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -368,6 +547,29 @@ msgstr "Cambiar Valor del Array" msgid "Search:" msgstr "Buscar:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Buscar" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importar" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Plugins" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ordenar:" @@ -381,10 +583,6 @@ msgid "Category:" msgstr "Categoría:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Todos" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Sitio:" @@ -416,20 +614,6 @@ msgstr "Lista de Métodos Para '%s':" msgid "Call" msgstr "Llamar" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Cerrar" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Lista de Métodos:" @@ -480,13 +664,6 @@ msgid "Selection Only" msgstr "Solo Selección" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Buscar" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Encontrar" @@ -638,11 +815,6 @@ msgstr "Recientes:" msgid "Matches:" msgstr "Coincidencias:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Descripción:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Buscar Reemplazo Para:" @@ -1130,10 +1302,6 @@ msgstr " Salida:" msgid "Clear" msgstr "Limpiar" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Nodo desde Escena" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1515,21 +1683,6 @@ msgid "Distraction Free Mode" msgstr "Modo Sin Distracciones" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importar assets al proyecto." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importar" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Herramientas misceláneas a nivel proyecto o escena." @@ -1819,10 +1972,6 @@ msgid "Installed Plugins:" msgstr "Plugins Instalados:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Version:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3837,6 +3986,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Generar AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Las caras no contienen area!" @@ -3889,6 +4043,16 @@ msgstr "Volumen" msgid "Emission Source: " msgstr "Relleno de Emisión:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Generar AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Tiempo Promedio (seg)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Remover Punto de Curva" @@ -4343,6 +4507,14 @@ msgid "Trim Trailing Whitespace" msgstr "Eliminar Espacios Sobrantes al Final" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Auto Indentar" @@ -5217,12 +5389,12 @@ msgstr "Ruta de proyecto inválida, la ruta debe existir!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Ruta de proyecto inválida, engine.cfg no debe existir." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Ruta de proyecto inválida, engine.cfg debe existir." #: editor/project_manager.cpp @@ -5235,7 +5407,7 @@ msgstr "Ruta de proyecto inválida (cambiaste algo?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "No se pudo crear engine.cfg en la ruta de proyecto." #: editor/project_manager.cpp @@ -5271,10 +5443,6 @@ msgid "Install Project:" msgstr "Instalar Proyecto:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Instalar" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Examinar" @@ -5337,6 +5505,11 @@ msgid "New Project" msgstr "Proyecto Nuevo" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Remover Item" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Salir" @@ -5523,8 +5696,8 @@ msgstr "Remover Opción de Remapeo de Recursos" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Ajustes de Proyecto (engine.cfg)" +msgid "Project Settings " +msgstr "Configuración de Proyecto" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5590,10 +5763,6 @@ msgstr "Locale" msgid "AutoLoad" msgstr "AutoLoad" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Plugins" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6205,6 +6374,10 @@ msgid "Change Notifier Extents" msgstr "Cambiar Alcances de Notificadores" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "Cambiar Extensión de Sonda" @@ -6825,6 +6998,17 @@ msgstr "" "NavigationMeshInstance debe ser un hijo o nieto de un nodo Navigation. Solo " "provee datos de navegación." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6902,6 +7086,16 @@ msgstr "" "que pueda obtener un tamaño. Alternativamente, hacelo un RenderTarget y " "asigná su textura interna a algún otro nodo para mostrar." +#~ msgid "Node From Scene" +#~ msgstr "Nodo desde Escena" + +#~ msgid "Import assets to the project." +#~ msgstr "Importar assets al proyecto." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Ajustes de Proyecto (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Superficie" diff --git a/editor/translations/extract.py b/editor/translations/extract.py index 616fec17a0..5e6c894936 100755 --- a/editor/translations/extract.py +++ b/editor/translations/extract.py @@ -38,7 +38,8 @@ unique_str = [] unique_loc = {} main_po = """ # LANGUAGE translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. diff --git a/editor/translations/fa.po b/editor/translations/fa.po index 2cfd69f3bd..e8402fcb25 100644 --- a/editor/translations/fa.po +++ b/editor/translations/fa.po @@ -1,5 +1,6 @@ # Persian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # alabd14313 <alabd14313@yahoo.com>, 2016. @@ -360,6 +361,182 @@ msgstr "نوع مقدار آرایه را تغییر بده" msgid "Change Array Value" msgstr "مقدار آرایه را تغییر بده" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "نسخه:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "مستمر" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "پرونده:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "توضیح:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "بستن" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "در حال اتصال..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "اتصال به گره:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "در حال اتصال..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "آزمودن" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "خطای بارگذاری قلم." + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "خطاهای بارگذاری" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "همه" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -367,6 +544,29 @@ msgstr "مقدار آرایه را تغییر بده" msgid "Search:" msgstr "جستجو:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "جستجو" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "مرتبسازی:" @@ -380,10 +580,6 @@ msgid "Category:" msgstr "طبقهبندی:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "همه" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "تارنما:" @@ -415,20 +611,6 @@ msgstr "لیست متد برای 's%' :" msgid "Call" msgstr "فراخوانی" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "بستن" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "فهرست متدها:" @@ -479,13 +661,6 @@ msgid "Selection Only" msgstr "تنها در قسمت انتخاب شده" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "جستجو" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "یافتن" @@ -636,11 +811,6 @@ msgstr "" msgid "Matches:" msgstr "تطبیقها:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "توضیح:" - #: editor/dependency_editor.cpp #, fuzzy msgid "Search Replacement For:" @@ -1125,10 +1295,6 @@ msgstr " خروجی:" msgid "Clear" msgstr "پاک کردن" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1493,21 +1659,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1777,10 +1928,6 @@ msgid "Installed Plugins:" msgstr "افزونه های نصب شده:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "نسخه:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "خالق:" @@ -3762,6 +3909,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3809,6 +3960,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4260,6 +4419,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5119,11 +5286,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5135,7 +5302,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5171,10 +5338,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5235,6 +5398,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "برداشتن انتخاب شده" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5418,8 +5586,9 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" -msgstr "" +#, fuzzy +msgid "Project Settings " +msgstr "ترجیحات" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5485,10 +5654,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6097,6 +6262,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6711,6 +6880,17 @@ msgstr "" "NavigationMeshInstance باید یک فرزند یا نوهی یک گره Navigation باشد. این " "تنها دادهی پیمایش را فراهم میکند." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." diff --git a/editor/translations/fr.po b/editor/translations/fr.po index 5b0076400c..8db0cf2555 100644 --- a/editor/translations/fr.po +++ b/editor/translations/fr.po @@ -1,5 +1,6 @@ # French translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Brice <bbric@free.fr>, 2016. @@ -372,6 +373,184 @@ msgstr "Modifier type de valeur du tableau" msgid "Change Array Value" msgstr "Modifier valeur du tableau" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Version :" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constantes :" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Fichier" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Description :" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Installer" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Fermer" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Connecter…" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Connecter au nœud :" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Format de fichier demandé inconnu :" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Enregistrement…" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Connecter…" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "En test" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Erreur d'enregistrement de la ressource !" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Bas" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Tout" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -379,6 +558,29 @@ msgstr "Modifier valeur du tableau" msgid "Search:" msgstr "Rechercher :" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Rechercher" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importer" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Extensions" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Trier :" @@ -392,10 +594,6 @@ msgid "Category:" msgstr "Catégorie :" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Tout" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Site :" @@ -427,20 +625,6 @@ msgstr "Liste des méthodes pour « %s » :" msgid "Call" msgstr "Appel" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Fermer" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Liste des méthodes :" @@ -491,13 +675,6 @@ msgid "Selection Only" msgstr "Sélection uniquement" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Rechercher" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Trouver" @@ -649,11 +826,6 @@ msgstr "Récents :" msgid "Matches:" msgstr "Correspondances :" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Description :" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Rechercher un remplacement pour :" @@ -1146,10 +1318,6 @@ msgstr " Sortie :" msgid "Clear" msgstr "Effacer" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Nœud à partir d'une scène" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1535,21 +1703,6 @@ msgid "Distraction Free Mode" msgstr "Mode sans distraction" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importer des ressources dans le projet." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importer" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Outils divers liés au projet ou à la scène." @@ -1842,10 +1995,6 @@ msgid "Installed Plugins:" msgstr "Extensions installées :" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Version :" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Auteur :" @@ -3878,6 +4027,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Générer un AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Les faces n'ont pas de surface !" @@ -3930,6 +4084,16 @@ msgstr "Volume" msgid "Emission Source: " msgstr "Remplissage d'émission :" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Générer un AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Temps moyen (seconde)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Supprimer le point d'une courbe" @@ -4385,6 +4549,14 @@ msgid "Trim Trailing Whitespace" msgstr "Supprimer les espaces de fin de ligne" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Indentation automatique" @@ -5260,12 +5432,12 @@ msgstr "Chemin de projet invalide, le chemin doit exister !" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Chemin de projet invalide, engine.cfg ne doit pas exister." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Chemin de projet invalide, engine.cfg doit exister." #: editor/project_manager.cpp @@ -5278,7 +5450,7 @@ msgstr "Chemin de projet non valide (avez-vous changé quelque chose ?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" "Impossible de créer le fichier engine.cfg dans le répertoire du projet." @@ -5319,10 +5491,6 @@ msgid "Install Project:" msgstr "Projets récents :" #: editor/project_manager.cpp -msgid "Install" -msgstr "Installer" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Parcourir" @@ -5386,6 +5554,11 @@ msgid "New Project" msgstr "Nouveau projet" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Supprimer l'item" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Quitter" @@ -5572,8 +5745,8 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Paramètres du projet (engine.cfg)" +msgid "Project Settings " +msgstr "Paramètres du projet" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5639,10 +5812,6 @@ msgstr "Langue" msgid "AutoLoad" msgstr "AutoLoad" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Extensions" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6261,6 +6430,10 @@ msgid "Change Notifier Extents" msgstr "Changer les extents d'un notificateur" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "Changer les extents d'un notificateur" @@ -6885,6 +7058,17 @@ msgstr "" "Un NavigationMeshInstance doit être enfant ou sous-enfant d'un nœud de type " "Navigation. Il fournit uniquement des données de navigation." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6963,6 +7147,16 @@ msgstr "" "nœud de type Control afin qu'il en obtienne une taille. Sinon, faites-en une " "RenderTarget et assignez sa texture à un nœud pouvant l'afficher." +#~ msgid "Node From Scene" +#~ msgstr "Nœud à partir d'une scène" + +#~ msgid "Import assets to the project." +#~ msgstr "Importer des ressources dans le projet." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Paramètres du projet (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Surface" diff --git a/editor/translations/hu.po b/editor/translations/hu.po index b26c92257f..2d1b36d2ea 100644 --- a/editor/translations/hu.po +++ b/editor/translations/hu.po @@ -1,5 +1,6 @@ # Hungarian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Varga Dániel <danikah.danikah@gmail.com>, 2016. @@ -355,6 +356,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -362,6 +531,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -375,10 +567,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -410,20 +598,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -473,13 +647,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -629,11 +796,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1107,10 +1269,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1475,21 +1633,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1758,10 +1901,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3731,6 +3870,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3778,6 +3921,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4227,6 +4378,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5083,11 +5242,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5099,7 +5258,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5135,10 +5294,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5197,6 +5352,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5380,7 +5539,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5447,10 +5606,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6050,6 +6205,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6590,6 +6749,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/id.po b/editor/translations/id.po index 8151c3208c..2abf4090c8 100644 --- a/editor/translations/id.po +++ b/editor/translations/id.po @@ -1,5 +1,6 @@ # Indonesian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Abdul Aziz Muslim Alqudsy <abdul.aziz.muslim.alqudsy@gmail.com>, 2016. @@ -380,6 +381,182 @@ msgstr "Ubah Tipe Nilai Array" msgid "Change Array Value" msgstr "Ubah Nilai Array" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Konstanta:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "File:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Deskripsi:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Tutup" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Menyambungkan.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Sambungkan Ke Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Format file yang diminta tidak diketahui:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Menyambungkan.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Menguji" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Error menyimpan resource!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Semua" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -387,6 +564,29 @@ msgstr "Ubah Nilai Array" msgid "Search:" msgstr "Cari:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Cari" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sortir:" @@ -400,10 +600,6 @@ msgid "Category:" msgstr "Kategori:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Semua" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Situs:" @@ -435,20 +631,6 @@ msgstr "Daftar Fungsi Untuk '%s':" msgid "Call" msgstr "Panggil" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Tutup" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Daftar Fungsi:" @@ -500,13 +682,6 @@ msgid "Selection Only" msgstr "Hanya yang Dipilih" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Cari" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Cari" @@ -659,11 +834,6 @@ msgstr "Saat ini:" msgid "Matches:" msgstr "Kecocokan:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Deskripsi:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Cari Ganti Untuk:" @@ -1158,10 +1328,6 @@ msgstr " Keluaran:" msgid "Clear" msgstr "Bersihkan" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Node Dari Scene" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1545,21 +1711,6 @@ msgid "Distraction Free Mode" msgstr "Mode Tanpa Gangguan" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1830,10 +1981,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3815,6 +3962,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3862,6 +4013,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4313,6 +4472,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5174,11 +5341,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5190,7 +5357,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5226,10 +5393,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5288,6 +5451,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Hapus Pilihan" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5473,7 +5641,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5540,10 +5708,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6156,6 +6320,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6772,6 +6940,17 @@ msgstr "" "NavigationMeshInstance harus menjadi child atau grandchild untuk sebuah node " "Navigation. Ini hanya menyediakan data navigasi." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6853,6 +7032,9 @@ msgstr "" "sebuah RenderTarget dan tetapkannya tekstur internal untuk beberapa node " "untuk ditampilkan." +#~ msgid "Node From Scene" +#~ msgstr "Node Dari Scene" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/it.po b/editor/translations/it.po index affd0dfdc1..08d04d296b 100644 --- a/editor/translations/it.po +++ b/editor/translations/it.po @@ -1,5 +1,6 @@ # Italian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Dario Bonfanti <bonfi.96@hotmail.it>, 2016-2017. @@ -360,6 +361,184 @@ msgstr "Cambia Tipo del Valore Array" msgid "Change Array Value" msgstr "Cambia Valore Array" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Versione:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Costanti:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "File" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Descrizione:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Installa" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Chiudi" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Connetti.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Connetti A Nodo:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Formato file richiesto sconosciuto:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Salvataggio.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Connetti.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testing" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Errore salvando la Risorsa!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Giù" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Tutti" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -367,6 +546,29 @@ msgstr "Cambia Valore Array" msgid "Search:" msgstr "Cerca:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Cerca" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importa" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Plugins" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ordina:" @@ -380,10 +582,6 @@ msgid "Category:" msgstr "Categoria:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Tutti" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Sito:" @@ -415,20 +613,6 @@ msgstr "Lista Metodi Per '%s':" msgid "Call" msgstr "Chiama" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Chiudi" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Lista Metodi:" @@ -479,13 +663,6 @@ msgid "Selection Only" msgstr "Solo Selezione" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Cerca" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Trova" @@ -637,11 +814,6 @@ msgstr "Recenti:" msgid "Matches:" msgstr "Corrispondenze:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Descrizione:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Cerca Rimpiazzo Per:" @@ -1130,10 +1302,6 @@ msgstr " Output:" msgid "Clear" msgstr "Rimuovi" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Nodo Da Scena" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1517,21 +1685,6 @@ msgid "Distraction Free Mode" msgstr "Modalità Senza Distrazioni" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importa asset nel progetto." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importa" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Strumenti di progetto o scena vari." @@ -1820,10 +1973,6 @@ msgid "Installed Plugins:" msgstr "Plugins Installati:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Versione:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autore:" @@ -3838,6 +3987,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Genera AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Le facce non contengono area!" @@ -3890,6 +4044,16 @@ msgstr "Volume" msgid "Emission Source: " msgstr "Riempimento Emissione:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Genera AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Tempo Medio (sec)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Rimuovi Punto da Curva" @@ -4344,6 +4508,14 @@ msgid "Trim Trailing Whitespace" msgstr "Taglia Spazi in Coda" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Auto Indenta" @@ -5218,12 +5390,12 @@ msgstr "Percorso di progetto invalido, il percorso deve esistere!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Percorso di progetto invalido, engine.cfg non deve esistere." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Percorso di progetto invalido, engine.cfg deve esistere." #: editor/project_manager.cpp @@ -5236,7 +5408,7 @@ msgstr "Percorso di progetto invalido (cambiato qualcosa?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Impossibile creare engine.cfg nel percorso di progetto." #: editor/project_manager.cpp @@ -5272,10 +5444,6 @@ msgid "Install Project:" msgstr "Installa Progetto:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Installa" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Sfoglia" @@ -5336,6 +5504,11 @@ msgid "New Project" msgstr "Nuovo Progetto" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Rimuovi Elemento" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Esci" @@ -5522,8 +5695,8 @@ msgstr "Rimuovi Opzione di Remap Rimorse" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Impostazioni Progetto (engine.cfg)" +msgid "Project Settings " +msgstr "Impostazioni Progetto" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5589,10 +5762,6 @@ msgstr "Locale" msgid "AutoLoad" msgstr "AutoLoad" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Plugins" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6202,6 +6371,10 @@ msgid "Change Notifier Extents" msgstr "Cambia Estensione di Notifier" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "Cambia Estensione Probe" @@ -6833,6 +7006,17 @@ msgstr "" "NavigationMeshInstance deve essere un figlio o nipote di un nodo Navigation. " "Fornisce solamente dati per la navigazione." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6911,6 +7095,16 @@ msgstr "" "Control, in modo che possa ottenere una dimensione. Altrimenti, renderlo un " "RenderTarget e assegnare alla sua texture interna qualche nodo da mostrare." +#~ msgid "Node From Scene" +#~ msgstr "Nodo Da Scena" + +#~ msgid "Import assets to the project." +#~ msgstr "Importa asset nel progetto." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Impostazioni Progetto (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Superficie" diff --git a/editor/translations/ja.po b/editor/translations/ja.po index 7f0f01ff07..beeaf264a2 100644 --- a/editor/translations/ja.po +++ b/editor/translations/ja.po @@ -1,5 +1,6 @@ # Japanese translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # akirakido <achts.y@gmail.com>, 2016. @@ -358,6 +359,181 @@ msgstr "配列の値の種類の変更" msgid "Change Array Value" msgstr "配列の値を変更" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "継続的" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "ファイル:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "閉じる" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "接続" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "ノードに接続します。" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "接続" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "テスト中" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "フォント読み込みエラー。" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "すべて" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +541,29 @@ msgstr "配列の値を変更" msgid "Search:" msgstr "検索:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "検索" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "並べ替え:" @@ -378,10 +577,6 @@ msgid "Category:" msgstr "カテゴリー:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "すべて" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "サイト:" @@ -413,20 +608,6 @@ msgstr "'%s' のメソッド一覧:" msgid "Call" msgstr "呼び出し" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "閉じる" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "メソッド一覧:" @@ -477,13 +658,6 @@ msgid "Selection Only" msgstr "選択範囲のみ" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "検索" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "検索" @@ -634,11 +808,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1114,11 +1283,6 @@ msgstr "" msgid "Clear" msgstr "削除" -#: editor/editor_node.cpp -#, fuzzy -msgid "Node From Scene" -msgstr "シーンからのノード" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1494,21 +1658,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1777,10 +1926,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3758,6 +3903,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3805,6 +3954,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4257,6 +4414,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5114,11 +5279,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5130,7 +5295,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5166,10 +5331,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5228,6 +5389,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "選択しているものを削除" + +#: editor/project_manager.cpp msgid "Exit" msgstr "終了" @@ -5411,7 +5577,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5478,10 +5644,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6087,6 +6249,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6698,6 +6864,17 @@ msgstr "" "NavigationMeshInstance は、ナビゲーションノードの子や孫である必要があります。" "これはナビゲーションデータのみ提供します。" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6778,6 +6955,10 @@ msgstr "" "くります。それ以外の場合、レンダー ターゲットし、その内部のテクスチャ表示のい" "くつかのノードに割り当てます。" +#, fuzzy +#~ msgid "Node From Scene" +#~ msgstr "シーンからのノード" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/ko.po b/editor/translations/ko.po index 02d7385927..08b10d2f7a 100644 --- a/editor/translations/ko.po +++ b/editor/translations/ko.po @@ -1,5 +1,6 @@ # Korean translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # 박한얼 (volzhs) <volzhs@gmail.com>, 2016-2017. @@ -358,6 +359,184 @@ msgstr "배열 값 타입 변경" msgid "Change Array Value" msgstr "배열 값 변경" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "버전:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "상수:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "파일" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "설명:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "설치" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "닫기" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "연결하기.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "연결할 노드:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "요청한 파일 형식을 알 수 없음:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "저장 중.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "연결하기.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "테스팅" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "리소스 저장 중 에러!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "아래" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "모두" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -365,6 +544,29 @@ msgstr "배열 값 변경" msgid "Search:" msgstr "검색:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "검색" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "가져오기" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "플러그인" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "정렬:" @@ -378,10 +580,6 @@ msgid "Category:" msgstr "카테고리:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "모두" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "사이트:" @@ -413,20 +611,6 @@ msgstr "'%s' 함수 목록:" msgid "Call" msgstr "호출" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "닫기" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "함수 목록:" @@ -477,13 +661,6 @@ msgid "Selection Only" msgstr "선택영역만" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "검색" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "찾기" @@ -635,11 +812,6 @@ msgstr "최근:" msgid "Matches:" msgstr "일치:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "설명:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "대체할 대상 찾기:" @@ -1123,10 +1295,6 @@ msgstr " 출력:" msgid "Clear" msgstr "지우기" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "씬으로부터 노드 가져오기" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1503,21 +1671,6 @@ msgid "Distraction Free Mode" msgstr "초집중 모드" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "프로젝트로 에셋 가져오기." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "가져오기" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "프로젝트 또는 씬 관련 여러가지 도구들." @@ -1807,10 +1960,6 @@ msgid "Installed Plugins:" msgstr "설치된 플러그인:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "버전:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "저자:" @@ -3815,6 +3964,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "AABB 생성" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "페이스가 영역을 가지고 있지 않습니다!" @@ -3867,6 +4021,16 @@ msgstr "배출량" msgid "Emission Source: " msgstr "에미션 채움:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "AABB 생성" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "평균 시간 (초)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "커브에서 포인트 삭제" @@ -4319,6 +4483,14 @@ msgid "Trim Trailing Whitespace" msgstr "후행 공백 문자 제거" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "자동 들여쓰기" @@ -5189,12 +5361,12 @@ msgstr "프로젝트 경로가 유효하지 않습니다. 경로가 반드시 #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "프로젝트 경로가 유효하지 않습니다. engine.cfg가 있으면 안됩니다." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "프로젝트 경로가 유효하지 않습니다. engine.cfg가 존재해야합니다." #: editor/project_manager.cpp @@ -5207,7 +5379,7 @@ msgstr "유효하지 않은 프로젝트 경로 (뭔가 변경하신 거라도?) #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "프로젝트 경로에 engine.cfg를 생성할 수 없습니다." #: editor/project_manager.cpp @@ -5243,10 +5415,6 @@ msgid "Install Project:" msgstr "프로젝트 설치:" #: editor/project_manager.cpp -msgid "Install" -msgstr "설치" - -#: editor/project_manager.cpp msgid "Browse" msgstr "찾아보기" @@ -5306,6 +5474,11 @@ msgid "New Project" msgstr "새 프로젝트" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "아이템 삭제" + +#: editor/project_manager.cpp msgid "Exit" msgstr "종료" @@ -5492,8 +5665,8 @@ msgstr "리소스 리맵핑 옵션 제거" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "프로젝트 설정 (engine.cfg)" +msgid "Project Settings " +msgstr "프로젝트 설정" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5559,10 +5732,6 @@ msgstr "지역" msgid "AutoLoad" msgstr "자동 로드" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "플러그인" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6168,6 +6337,10 @@ msgid "Change Notifier Extents" msgstr "Notifier 범위 변경" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "프로브 범위 변경" @@ -6755,6 +6928,17 @@ msgstr "" "NavigationMeshInstance은 Navigation 노드의 하위에 있어야 합니다. 이것은 네비" "게이션 데이타만을 제공합니다." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "Path 속성은 유효한 Spatial 노드를 가리켜야 합니다." @@ -6828,6 +7012,16 @@ msgstr "" "합니다. 그렇지 않을 경우, 화면에 표시하기 위해서는 Render target으로 설정하" "고 내부적인 텍스쳐를 다른 노드에 할당해야 합니다." +#~ msgid "Node From Scene" +#~ msgstr "씬으로부터 노드 가져오기" + +#~ msgid "Import assets to the project." +#~ msgstr "프로젝트로 에셋 가져오기." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "프로젝트 설정 (engine.cfg)" + #~ msgid "Surface" #~ msgstr "출사면" diff --git a/editor/translations/nb.po b/editor/translations/nb.po index e452e85cd9..7ce577ebfa 100644 --- a/editor/translations/nb.po +++ b/editor/translations/nb.po @@ -1,5 +1,6 @@ # Norwegian Bokmål translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Anonymous <GentleSaucepan@protonmail.com>, 2017. @@ -356,6 +357,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Lukk" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +532,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +568,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -411,20 +599,6 @@ msgstr "" msgid "Call" msgstr "Ring" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Lukk" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +648,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +797,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1108,10 +1270,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1476,21 +1634,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1759,10 +1902,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3732,6 +3871,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3779,6 +3922,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4228,6 +4379,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5084,11 +5243,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5100,7 +5259,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5136,10 +5295,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5198,6 +5353,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5381,7 +5540,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5448,10 +5607,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6053,6 +6208,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6598,6 +6757,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/nl.po b/editor/translations/nl.po index 74d75c0a01..f0d54ebd9d 100644 --- a/editor/translations/nl.po +++ b/editor/translations/nl.po @@ -1,5 +1,6 @@ # Dutch translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Aram Nap <xyphex.aram@gmail.com>, 2017 @@ -357,6 +358,182 @@ msgstr "Wijzig Array Waarde Type" msgid "Change Array Value" msgstr "Wijzig Array Waarde" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constanten:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Bestand:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Omschrijving:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Sluiten" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Verbind.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Verbind Aan Node:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Opgevraagde bestandsformaat onbekend:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Verbind.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testen" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Error bij het opslaan van resource!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Alle" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -364,6 +541,29 @@ msgstr "Wijzig Array Waarde" msgid "Search:" msgstr "Zoeken:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Zoeken" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sorteren:" @@ -377,10 +577,6 @@ msgid "Category:" msgstr "Categorie:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Alle" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Site:" @@ -413,20 +609,6 @@ msgstr "Methode Lijst Voor '%s':" msgid "Call" msgstr "Aanroep" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Sluiten" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Methode Lijst:" @@ -477,13 +659,6 @@ msgid "Selection Only" msgstr "Alleen Selectie" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Zoeken" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Zoeken" @@ -636,11 +811,6 @@ msgstr "Recente:" msgid "Matches:" msgstr "Matches:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Omschrijving:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Zoek Vervanging Voor:" @@ -1130,10 +1300,6 @@ msgstr " Uitvoer:" msgid "Clear" msgstr "Leegmaken" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Node Uit Scene" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1501,21 +1667,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1784,10 +1935,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3765,6 +3912,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3812,6 +3963,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4262,6 +4421,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5122,11 +5289,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5138,7 +5305,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5174,10 +5341,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5236,6 +5399,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Verwijder Selectie" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5419,7 +5587,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5486,10 +5654,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6091,6 +6255,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6712,6 +6880,17 @@ msgstr "" "NavigationMeshInstance moet een kind of kleinkind zijn van een Navigation " "node. Het biedt alleen navigatie data." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6789,6 +6968,9 @@ msgstr "" "inhoud direct op het scherm te weergeven. Anders, maak er een RenderTarget " "van en wijs zijn interne texture toe aan een node om te tonen." +#~ msgid "Node From Scene" +#~ msgstr "Node Uit Scene" + #~ msgid "" #~ "A SampleLibrary resource must be created or set in the 'samples' property " #~ "in order for SamplePlayer to play sound." diff --git a/editor/translations/pl.po b/editor/translations/pl.po index 2149564c42..ccee170c57 100644 --- a/editor/translations/pl.po +++ b/editor/translations/pl.po @@ -1,5 +1,6 @@ # Polish translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # 8-bit Pixel <dawdejw@gmail.com>, 2016. @@ -367,6 +368,184 @@ msgstr "Zmień Typ Tablicy" msgid "Change Array Value" msgstr "Zmień Wartość Tablicy" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Wersja:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Stałe:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Plik" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Opis:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Instaluj" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Zamknij" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Połącz.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Podłączanie Do Węzła:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Nieznany format pliku:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Zapisywanie.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Połącz.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Testowanie" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Błąd podczas zapisu zasobu!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Wczytaj błędy" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Wszystko" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -374,6 +553,29 @@ msgstr "Zmień Wartość Tablicy" msgid "Search:" msgstr "Szukaj:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Szukaj" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importuj" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Wtyczki" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sortuj:" @@ -387,10 +589,6 @@ msgid "Category:" msgstr "Kategoria:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Wszystko" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Źródło:" @@ -422,20 +620,6 @@ msgstr "Lista metod '%s':" msgid "Call" msgstr "Wywołanie" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Zamknij" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Lista metod:" @@ -486,13 +670,6 @@ msgid "Selection Only" msgstr "Tylko zaznaczenie" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Szukaj" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Szukaj" @@ -643,11 +820,6 @@ msgstr "Ostatnie:" msgid "Matches:" msgstr "Pasujące:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Opis:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Znajdź i zamień:" @@ -1127,10 +1299,6 @@ msgstr " Konsola:" msgid "Clear" msgstr "Wyczyść" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Węzeł ze Sceny" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1513,21 +1681,6 @@ msgid "Distraction Free Mode" msgstr "Tryb bez rozproszeń" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importuj zasoby do projektu." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importuj" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1814,10 +1967,6 @@ msgid "Installed Plugins:" msgstr "Zainstalowane wtyczki:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Wersja:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3828,6 +3977,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Generuj AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3876,6 +4030,16 @@ msgstr "Głośność" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Generuj AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Średni Czas (sek)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4328,6 +4492,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5195,12 +5367,12 @@ msgstr "Niepoprawna ścieżka projektu, ścieżka musi istnieć!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Niepoprawna ścieżka projektu, engine.cfg nie może istnieć." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Niepoprawna ścieżka projektu, engine.cfg musi istnieć." #: editor/project_manager.cpp @@ -5213,7 +5385,7 @@ msgstr "Niepoprawna ścieżka projektu (zmienić cokolwiek?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Nie można było utworzyć engine.cfg w ścieżce projektu." #: editor/project_manager.cpp @@ -5249,10 +5421,6 @@ msgid "Install Project:" msgstr "Zainstaluj projekt:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Instaluj" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Szukaj" @@ -5311,6 +5479,11 @@ msgid "New Project" msgstr "Nowy projekt" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Usuń element" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Wyjdź" @@ -5497,8 +5670,8 @@ msgstr "" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Ustawienia projektu (engine.cfg)" +msgid "Project Settings " +msgstr "Ustawienia projektu" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5564,10 +5737,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Wtyczki" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6186,6 +6355,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "Zmień rozmiar Box Shape" @@ -6794,6 +6967,17 @@ msgstr "" "NavigationMeshInstance musi być dzieckiem lub wnukiem węzła typu Navigation. " "Udostępnia on tylko dane nawigacyjne." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6872,6 +7056,16 @@ msgstr "" "otrzymał jakiś rozmiar. W przeciwnym wypadku ustawi opcję RenderTarget i " "przyporządkuj jego teksturę dla któregoś węzła." +#~ msgid "Node From Scene" +#~ msgstr "Węzeł ze Sceny" + +#~ msgid "Import assets to the project." +#~ msgstr "Importuj zasoby do projektu." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Ustawienia projektu (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Powierzchnia" diff --git a/editor/translations/pr.po b/editor/translations/pr.po index 3a8f795eb9..4629c24f45 100644 --- a/editor/translations/pr.po +++ b/editor/translations/pr.po @@ -1,5 +1,6 @@ # Pirate translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Zion Nimchuk <zionnimchuk@gmail.com>, 2016-2017. @@ -355,6 +356,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Close" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -362,6 +531,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -375,10 +567,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -410,20 +598,6 @@ msgstr "" msgid "Call" msgstr "Call" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Close" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -473,13 +647,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -629,11 +796,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1107,10 +1269,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1475,21 +1633,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1758,10 +1901,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3733,6 +3872,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3780,6 +3923,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4229,6 +4380,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5085,11 +5244,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5101,7 +5260,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5137,10 +5296,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5199,6 +5354,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Discharge ye' Variable" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5382,7 +5542,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5449,10 +5609,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6054,6 +6210,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6618,6 +6778,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/pt_BR.po b/editor/translations/pt_BR.po index 6962fb5db7..25055a0b7b 100644 --- a/editor/translations/pt_BR.po +++ b/editor/translations/pt_BR.po @@ -1,5 +1,6 @@ # Portuguese (Brazil) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Allyson Souza <allyson_as@outlook.com>, 2017. @@ -363,6 +364,184 @@ msgstr "Alterar Tipo de Valor do Vetor" msgid "Change Array Value" msgstr "Alterar Valor do Vetor" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Versão:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Constantes:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Arquivo" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Descrição:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Instalar" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Fechar" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Conectar..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Conectar ao Nó:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Formato de arquivo requisitado desconhecido:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Salvando..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Conectar..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Em teste" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Erro ao salvar Recurso!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Abaixo" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Todos" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -370,6 +549,29 @@ msgstr "Alterar Valor do Vetor" msgid "Search:" msgstr "Pesquisar:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Pesquisar" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Importar" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Plugins" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Ordenar:" @@ -383,10 +585,6 @@ msgid "Category:" msgstr "Categoria:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Todos" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Site:" @@ -418,20 +616,6 @@ msgstr "Lista de Métodos para \"%s\":" msgid "Call" msgstr "Chamar" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Fechar" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Lista de Métodos:" @@ -482,13 +666,6 @@ msgid "Selection Only" msgstr "Apenas na Seleção" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Pesquisar" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Localizar" @@ -638,11 +815,6 @@ msgstr "Recente:" msgid "Matches:" msgstr "Combinações:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Descrição:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Buscar Substituição Para:" @@ -1129,10 +1301,6 @@ msgstr " Saída:" msgid "Clear" msgstr "Limpar" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Nó a Partir de Cena" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1513,21 +1681,6 @@ msgid "Distraction Free Mode" msgstr "Modo Sem Distrações" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Importar assets ao projeto." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Importar" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Ferramentas diversas atuantes no projeto ou cena." @@ -1817,10 +1970,6 @@ msgid "Installed Plugins:" msgstr "Plugins Instalados:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Versão:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Autor:" @@ -3839,6 +3988,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Gerar AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "As faces não têm área!" @@ -3891,6 +4045,16 @@ msgstr "Volume" msgid "Emission Source: " msgstr "Preenchimento de Emissão:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Gerar AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Tempo Médio (seg)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Remover Ponto da Curva" @@ -4347,6 +4511,14 @@ msgid "Trim Trailing Whitespace" msgstr "Apagar Espaços em Branco" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Auto Recuar" @@ -5223,12 +5395,12 @@ msgstr "Caminho de projeto inválido, o caminho deve existir!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Caminho de projeto inválido, engine.cfg não deve existir." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Caminho de projeto inválido, engine.cfg deve existir." #: editor/project_manager.cpp @@ -5241,7 +5413,7 @@ msgstr "Caminho de projeto inválido (mudou alguma coisa?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Não se pôde criar engine.cfg no caminho do projeto." #: editor/project_manager.cpp @@ -5277,10 +5449,6 @@ msgid "Install Project:" msgstr "Instalar Projeto:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Instalar" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Navegar" @@ -5342,6 +5510,11 @@ msgid "New Project" msgstr "Novo Projeto" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Remover Item" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Sair" @@ -5528,8 +5701,8 @@ msgstr "Remover Opção de Remapeamento de Recurso" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Configurações do Projeto (engine.cfg)" +msgid "Project Settings " +msgstr "Configurações do Projeto" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5595,10 +5768,6 @@ msgstr "Localidade" msgid "AutoLoad" msgstr "AutoLoad" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Plugins" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6220,6 +6389,10 @@ msgid "Change Notifier Extents" msgstr "Alterar a Extensão do Notificador" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "Alterar a Extensão do Notificador" @@ -6825,6 +6998,17 @@ msgstr "" "NavigationMeshInstance deve ser filho ou neto de um nó Navigation. Ele " "apenas fornece dados de navegação." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -6902,6 +7086,16 @@ msgstr "" "para que ele possa ter um tamanho. Caso contrário, defina-o como destino de " "render e atribua sua textura interna a algum nó para exibir." +#~ msgid "Node From Scene" +#~ msgstr "Nó a Partir de Cena" + +#~ msgid "Import assets to the project." +#~ msgstr "Importar assets ao projeto." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Configurações do Projeto (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Superfície" diff --git a/editor/translations/pt_PT.po b/editor/translations/pt_PT.po index 329ec9c053..fa4629c5c1 100644 --- a/editor/translations/pt_PT.po +++ b/editor/translations/pt_PT.po @@ -1,5 +1,6 @@ # Portuguese (Portugal) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # António Sarmento <antonio.luis.sarmento@gmail.com>, 2016. @@ -355,6 +356,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Fechar" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -362,6 +531,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -375,10 +567,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -410,20 +598,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Fechar" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -473,13 +647,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -629,11 +796,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1107,10 +1269,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1475,21 +1633,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1758,10 +1901,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3732,6 +3871,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3779,6 +3922,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4229,6 +4380,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5085,11 +5244,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5101,7 +5260,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5137,10 +5296,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5199,6 +5354,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Remover Variável" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5382,7 +5542,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5449,10 +5609,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6053,6 +6209,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6606,6 +6766,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/ru.po b/editor/translations/ru.po index 576261f8df..0c4a29fb63 100644 --- a/editor/translations/ru.po +++ b/editor/translations/ru.po @@ -1,5 +1,6 @@ # Russian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # DimOkGamer <dimokgamer@gmail.com>, 2016-2017. @@ -361,6 +362,184 @@ msgstr "Изменение типа значения массива" msgid "Change Array Value" msgstr "Изменить значение массива" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Версия:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Константы:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Файл" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Описание:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Установить" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Закрыть" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Присоединить.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Присоединить к узлу:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "Неизвестный формат запрашиваемого файла:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Сохранение.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Присоединить.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Тестируемые" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Ошибка при сохранении ресурса!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Вниз" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Все" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -368,6 +547,29 @@ msgstr "Изменить значение массива" msgid "Search:" msgstr "Поиск:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Поиск" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "Импорт" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Плагины" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Сортировать:" @@ -381,10 +583,6 @@ msgid "Category:" msgstr "Категория:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Все" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Сайт:" @@ -416,20 +614,6 @@ msgstr "Список способ для '%s':" msgid "Call" msgstr "Вызов" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Закрыть" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Список методов:" @@ -480,13 +664,6 @@ msgid "Selection Only" msgstr "Только выделять" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Поиск" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Найти" @@ -638,11 +815,6 @@ msgstr "Недавнее:" msgid "Matches:" msgstr "Совпадения:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Описание:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Поиск замены для:" @@ -1130,10 +1302,6 @@ msgstr " Вывод:" msgid "Clear" msgstr "Очистить" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Узел со сцены" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1515,21 +1683,6 @@ msgid "Distraction Free Mode" msgstr "Свободный режим" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Импортировать ассеты в проект." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "Импорт" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Прочие инструменты." @@ -1818,10 +1971,6 @@ msgid "Installed Plugins:" msgstr "Установленные плагины:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Версия:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Автор:" @@ -3836,6 +3985,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "Сгенерировать AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Грани не содержат зоны!" @@ -3888,6 +4042,16 @@ msgstr "Объём" msgid "Emission Source: " msgstr "Заполнение излучателя:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "Сгенерировать AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Среднее время (сек.)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Удалена точка с кривой" @@ -4342,6 +4506,14 @@ msgid "Trim Trailing Whitespace" msgstr "Удаление пробелов в конце строк" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Автоотступ" @@ -5214,12 +5386,12 @@ msgstr "Неверный путь к проекту, путь должен су #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Недопустимый путь к проекту, engine.cfg не должен существовать." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Недопустимый путь к проекту, engine.cfg должен существовать." #: editor/project_manager.cpp @@ -5232,7 +5404,7 @@ msgstr "Неверный путь к проекту (Что-то изменил #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "Не могу создать engine.cfg в папке проекта." #: editor/project_manager.cpp @@ -5268,10 +5440,6 @@ msgid "Install Project:" msgstr "Установить проект:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Установить" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Обзор" @@ -5332,6 +5500,11 @@ msgid "New Project" msgstr "Новый проект" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Удалить элемент" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Выход" @@ -5518,8 +5691,8 @@ msgstr "Удалён параметр ресурса перенаправлен #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Настройки проекта (engine.cfg)" +msgid "Project Settings " +msgstr "Параметры проекта" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5585,10 +5758,6 @@ msgstr "Язык" msgid "AutoLoad" msgstr "Автозагрузка" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Плагины" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6200,6 +6369,10 @@ msgid "Change Notifier Extents" msgstr "Изменены границы уведомителя" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "Изменены Probe Extents" @@ -6808,6 +6981,17 @@ msgstr "" "NavigationMeshInstance должен быть дочерним или под-дочерним узлом " "Navigation. Он предоставляет только навигационные данные." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "Свойство Path должно указывать на действительный Spatial узел." @@ -6885,6 +7069,16 @@ msgstr "" "сделайте его целью рендеринга и передайте его внутренние текстуры какому-то " "другому узлу для отображения." +#~ msgid "Node From Scene" +#~ msgstr "Узел со сцены" + +#~ msgid "Import assets to the project." +#~ msgstr "Импортировать ассеты в проект." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Настройки проекта (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Поверхность" diff --git a/editor/translations/sk.po b/editor/translations/sk.po index 9dc83e0cd3..b0bee6aa6f 100644 --- a/editor/translations/sk.po +++ b/editor/translations/sk.po @@ -1,5 +1,6 @@ # Slovak translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # J08nY <johnenter@gmail.com>, 2016. @@ -356,6 +357,176 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Konštanty:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Súbor:" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Popis:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +534,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +570,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Stránka:" @@ -411,20 +601,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +650,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +799,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Popis:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1109,10 +1273,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1478,21 +1638,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1761,10 +1906,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3736,6 +3877,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3783,6 +3928,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4233,6 +4386,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5092,11 +5253,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5108,7 +5269,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5144,10 +5305,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5206,6 +5363,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Všetky vybrané" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5389,7 +5551,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5456,10 +5618,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6066,6 +6224,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6619,6 +6781,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/sl.po b/editor/translations/sl.po index a90a691f44..ea634658ce 100644 --- a/editor/translations/sl.po +++ b/editor/translations/sl.po @@ -1,5 +1,6 @@ # Slovenian translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # matevž lapajne <sivar.lapajne@gmail.com>, 2016. @@ -356,6 +357,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Zapri" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +532,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +568,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -411,20 +599,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Zapri" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +648,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +797,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1108,10 +1270,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1476,21 +1634,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1759,10 +1902,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3733,6 +3872,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3780,6 +3923,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4230,6 +4381,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5086,11 +5245,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5102,7 +5261,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5138,10 +5297,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5200,6 +5355,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Odstrani Spremenljivko" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5383,7 +5543,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5450,10 +5610,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6054,6 +6210,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6618,6 +6778,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/th.po b/editor/translations/th.po index 883c024ff3..b31532f3bf 100644 --- a/editor/translations/th.po +++ b/editor/translations/th.po @@ -1,5 +1,6 @@ # Thai translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Poommetee Ketson <poommetee@protonmail.com>, 2017. @@ -366,6 +367,186 @@ msgstr "แก้ไขชนิดตัวแปรในอาร์เรย msgid "Change Array Value" msgstr "แก้ไขค่าในอาร์เรย์" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "รุ่น:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "ค่าคงที่:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "ไฟล์" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +#, fuzzy +msgid "Description:" +msgstr "รายละเอียด:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "ติดตั้ง" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "ปิด" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "เชื่อมโยง.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "เชื่อมโยงกับโหนด:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "ไม่ทราบรูปแบบไฟล์ที่ร้องขอ:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "กำลังบันทึก.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "เชื่อมโยง.." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "ทดสอบ" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "บันทึกรีซอร์สผิดพลาด!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "ลง" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "All" +msgstr "ทั้งหมด" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -374,6 +555,30 @@ msgstr "แก้ไขค่าในอาร์เรย์" msgid "Search:" msgstr "ค้นหา:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "ค้นหา" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +#, fuzzy +msgid "Import" +msgstr "นำเข้า" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "ปลั๊กอิน" + #: editor/asset_library_editor_plugin.cpp #, fuzzy msgid "Sort:" @@ -390,11 +595,6 @@ msgstr "ประเภท:" #: editor/asset_library_editor_plugin.cpp #, fuzzy -msgid "All" -msgstr "ทั้งหมด" - -#: editor/asset_library_editor_plugin.cpp -#, fuzzy msgid "Site:" msgstr "ไซต์:" @@ -431,20 +631,6 @@ msgstr "รายชื่อเมท็อดของ '%s':" msgid "Call" msgstr "เรียก" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "ปิด" - #: editor/call_dialog.cpp #, fuzzy msgid "Method List:" @@ -506,13 +692,6 @@ msgid "Selection Only" msgstr "เฉพาะที่เลือกไว้" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "ค้นหา" - -#: editor/code_editor.cpp editor/editor_help.cpp #, fuzzy msgid "Find" msgstr "ค้นหา" @@ -692,12 +871,6 @@ msgstr "ล่าสุด:" msgid "Matches:" msgstr "พบ:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -#, fuzzy -msgid "Description:" -msgstr "รายละเอียด:" - #: editor/dependency_editor.cpp #, fuzzy msgid "Search Replacement For:" @@ -1231,10 +1404,6 @@ msgstr " เอาท์พุต:" msgid "Clear" msgstr "ลบทั้งหมด" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "โหนดจากฉาก" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1634,22 +1803,6 @@ msgid "Distraction Free Mode" msgstr "โหมดไร้สิ่งรบกวน" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "นำเข้าไฟล์มายังโปรเจกต์" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -#, fuzzy -msgid "Import" -msgstr "นำเข้า" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1932,10 +2085,6 @@ msgid "Installed Plugins:" msgstr "ปลั๊กอินที่ติดตั้งแล้ว:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "รุ่น:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "โดย:" @@ -3943,6 +4092,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "สร้าง AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "หน้าไม่มีพื้นที่!" @@ -3992,6 +4146,16 @@ msgstr "ปริมาตร" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "สร้าง AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "เวลาเฉลี่ย (วินาที)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "ลบจุดในเส้นโค้ง" @@ -4446,6 +4610,14 @@ msgid "Trim Trailing Whitespace" msgstr "ลบตัวอักษรที่มองไม่เห็น" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "ย่อหน้าอัตโนมัติ" @@ -5317,12 +5489,12 @@ msgstr "ที่อยู่โปรเจกต์ผิดพลาด ต #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "ที่อยู่โปรเจกต์ผิดพลาด ต้องไม่มี engine.cfg" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "ที่อยู่โปรเจกต์ผิดพลาด ต้องมี engine.cfg" #: editor/project_manager.cpp @@ -5335,7 +5507,7 @@ msgstr "" #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "สร้างไฟล์ engine.cfg ไม่ได้" #: editor/project_manager.cpp @@ -5371,10 +5543,6 @@ msgid "Install Project:" msgstr "ติดตั้งโปรเจกต์:" #: editor/project_manager.cpp -msgid "Install" -msgstr "ติดตั้ง" - -#: editor/project_manager.cpp msgid "Browse" msgstr "เลือก" @@ -5433,6 +5601,11 @@ msgid "New Project" msgstr "โปรเจกต์ใหม่" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "ลบไอเทม" + +#: editor/project_manager.cpp msgid "Exit" msgstr "ออก" @@ -5628,8 +5801,8 @@ msgstr "ลบการแทนที่" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "ตัวเลือกโปรเจกต์ (engine.cfg)" +msgid "Project Settings " +msgstr "ตัวเลือกโปรเจกต์" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5695,10 +5868,6 @@ msgstr "ท้องถิ่น" msgid "AutoLoad" msgstr "ออโต้โหลด" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "ปลั๊กอิน" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6304,6 +6473,10 @@ msgid "Change Notifier Extents" msgstr "ปรับขนาด Notifier" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "ปรับขนาด Probe" @@ -6954,6 +7127,17 @@ msgstr "" "NavigationMeshInstance ต้องเป็นโหนดลูก/หลานของโหนด Navigation " "โหนดนี้ใช้เพื่อเป็นข้อมูลในการนำทางเท่านั้น" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp #, fuzzy msgid "Path property must point to a valid Spatial node to work." @@ -7034,6 +7218,16 @@ msgstr "" "ให้แก้ไขโหนดนี้ให้เป็นโหนดลูกของ Control แต่ถ้าไม่ ให้ปรับเป็น render target และนำไปใช้เป็น " "texture ของโหนดอื่น" +#~ msgid "Node From Scene" +#~ msgstr "โหนดจากฉาก" + +#~ msgid "Import assets to the project." +#~ msgstr "นำเข้าไฟล์มายังโปรเจกต์" + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "ตัวเลือกโปรเจกต์ (engine.cfg)" + #~ msgid "Surface" #~ msgstr "พื้นผิว" diff --git a/editor/translations/tr.po b/editor/translations/tr.po index 9228cf5818..b4d8975649 100644 --- a/editor/translations/tr.po +++ b/editor/translations/tr.po @@ -1,5 +1,6 @@ # Turkish translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Aprın Çor Tigin <kabusturk38@gmail.com>, 2016-2017. @@ -362,6 +363,184 @@ msgstr "Dizinin türünü degistir" msgid "Change Array Value" msgstr "Dizi Değerini Değiştir" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "Sürüm:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "Sabitler:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "Dizeç" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "Açıklama:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "Kur" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "Kapat" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "Bağlan..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "Düğüme Bağlan:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "İstenilen dizeç formatı bilinmiyor:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "Kaydediliyor..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "Bağlan..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "Deneme" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "Kaynak kaydedilirken sorun!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "Aşağı" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "Hepsi" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -369,6 +548,29 @@ msgstr "Dizi Değerini Değiştir" msgid "Search:" msgstr "Ara:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "Ara" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "İçe Aktar" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "Eklentiler" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "Sırala:" @@ -382,10 +584,6 @@ msgid "Category:" msgstr "Katman:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "Hepsi" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "Yer:" @@ -417,20 +615,6 @@ msgstr "'%s' İçin Yöntem Dizelgesi:" msgid "Call" msgstr "Çağır" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "Kapat" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "Yöntem Dizelgesi:" @@ -481,13 +665,6 @@ msgid "Selection Only" msgstr "Yalnızca Seçim" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "Ara" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "Bul" @@ -639,11 +816,6 @@ msgstr "Yakın zamanda:" msgid "Matches:" msgstr "Eşleşmeler:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "Açıklama:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "Şunun İçin Değişikliği Ara:" @@ -1125,10 +1297,6 @@ msgstr " Çıktı:" msgid "Clear" msgstr "Temizle" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "Sahneden Düğüm(node)" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1508,21 +1676,6 @@ msgid "Distraction Free Mode" msgstr "Dikkat Dağıtmayan Biçim" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "Varlıkları tasarının içine aktar." - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "İçe Aktar" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "Türlü tasarı ya da sahne genişliğinde araçlar." @@ -1811,10 +1964,6 @@ msgid "Installed Plugins:" msgstr "Yüklü Eklentiler:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "Sürüm:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "Yazar:" @@ -3824,6 +3973,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "AABB Üret" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "Yüzler alan içermez!" @@ -3876,6 +4030,16 @@ msgstr "Oylum" msgid "Emission Source: " msgstr "Yayma Dolumu:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "AABB Üret" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "Ortalama Zaman (sn)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "Noktayı Eğriden Kaldır" @@ -4330,6 +4494,14 @@ msgid "Trim Trailing Whitespace" msgstr "İzleyenin Boşluklarını Kırp" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "Kendinden Girintili" @@ -5204,12 +5376,12 @@ msgstr "Geçersiz tasarı yolu, yolun var olması gerekir!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "Geçersiz tasarı yolu, engine.cfg var olmaması gerekir." #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "Geçersiz tasarı yolu, engine.cfg var olması gerekir." #: editor/project_manager.cpp @@ -5222,7 +5394,7 @@ msgstr "Geçersiz tasarı yolu (bir şey değişti mi?)." #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "engine.cfg tasarı yolunda oluşturulamadı." #: editor/project_manager.cpp @@ -5258,10 +5430,6 @@ msgid "Install Project:" msgstr "Tasarıyı Kur:" #: editor/project_manager.cpp -msgid "Install" -msgstr "Kur" - -#: editor/project_manager.cpp msgid "Browse" msgstr "Gözat" @@ -5323,6 +5491,11 @@ msgid "New Project" msgstr "Yeni Tasarı" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "Öğeyi Kaldır" + +#: editor/project_manager.cpp msgid "Exit" msgstr "Çık" @@ -5509,8 +5682,8 @@ msgstr "Kaynak Yeniden Eşle Seçeneğini Kaldır" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "Tasarı Ayarları (engine.cfg)" +msgid "Project Settings " +msgstr "Tasarı Ayarları" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5576,10 +5749,6 @@ msgstr "Yerel" msgid "AutoLoad" msgstr "KendindenYükle" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "Eklentiler" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6188,6 +6357,10 @@ msgid "Change Notifier Extents" msgstr "Bildirim Kapsamını Değiştir" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "Deşme Genişlemesini Değiştir" @@ -6796,6 +6969,17 @@ msgstr "" "NavigationMeshInstance, bir Navigation düğümünün çocuğu ya da torunu " "olmalıdır. O yalnızca yönlendirme verisi sağlar." +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" @@ -6873,6 +7057,16 @@ msgstr "" "bir boyut elde edin. Ya da, onu bir RenderTarget yapın ve iç dokusunu " "görüntülemesi için bir düğüme atayın." +#~ msgid "Node From Scene" +#~ msgstr "Sahneden Düğüm(node)" + +#~ msgid "Import assets to the project." +#~ msgstr "Varlıkları tasarının içine aktar." + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "Tasarı Ayarları (engine.cfg)" + #~ msgid "Surface" #~ msgstr "Yüzey" diff --git a/editor/translations/ur_PK.po b/editor/translations/ur_PK.po index c8fb79d1c0..ef3e3b30ca 100644 --- a/editor/translations/ur_PK.po +++ b/editor/translations/ur_PK.po @@ -1,5 +1,6 @@ # Urdu (Pakistan) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Muhammad Ali <ali@codeonion.com>, 2016. @@ -356,6 +357,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +532,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +568,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "سائٹ:" @@ -411,20 +599,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +648,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +797,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1112,10 +1274,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1481,21 +1639,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1764,10 +1907,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3739,6 +3878,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3786,6 +3929,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4236,6 +4387,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5094,11 +5253,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5110,7 +5269,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5146,10 +5305,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5208,6 +5363,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr ".تمام کا انتخاب" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5391,7 +5551,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5458,10 +5618,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6067,6 +6223,10 @@ msgid "Change Notifier Extents" msgstr ".نوٹفئر کے اکسٹنٹ کو تبدیل کیجیۓ" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr ".نوٹفئر کے اکسٹنٹ کو تبدیل کیجیۓ" @@ -6612,6 +6772,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/zh_CN.po b/editor/translations/zh_CN.po index d2380c0a48..f3afcab79d 100644 --- a/editor/translations/zh_CN.po +++ b/editor/translations/zh_CN.po @@ -1,5 +1,6 @@ # Chinese (China) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # 纯洁的坏蛋 <tqj.zyy@gmail.com>, 2016. @@ -366,6 +367,184 @@ msgstr "修改数组类型" msgid "Change Array Value" msgstr "修改数组值" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "版本:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Contents:" +msgstr "常量:" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "文件" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "描述:" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "安装" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "关闭" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "连接事件。" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "连接到节点:" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Request failed, return code:" +msgstr "未知的文件类型请求:" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Resolving.." +msgstr "保存中..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "连接事件。" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "测试" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "保存资源出错!" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Download Error" +msgstr "向下" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "全部" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -373,6 +552,29 @@ msgstr "修改数组值" msgid "Search:" msgstr "搜索:" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "搜索" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "导入" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "插件" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "排序:" @@ -386,10 +588,6 @@ msgid "Category:" msgstr "分类:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "全部" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "站点:" @@ -421,20 +619,6 @@ msgstr "'%s'的方法列表:" msgid "Call" msgstr "调用到" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "关闭" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "方法列表:" @@ -485,13 +669,6 @@ msgid "Selection Only" msgstr "仅选中" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "搜索" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "查找" @@ -641,11 +818,6 @@ msgstr "最近文件:" msgid "Matches:" msgstr "匹配项:" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "描述:" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "搜索替换:" @@ -1121,10 +1293,6 @@ msgstr " 输出:" msgid "Clear" msgstr "清除" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "从场景导入节点" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1499,21 +1667,6 @@ msgid "Distraction Free Mode" msgstr "无干扰模式" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "导入资源。" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "导入" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "其他工程或全场景工具。" @@ -1792,10 +1945,6 @@ msgid "Installed Plugins:" msgstr "已安装插件:" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "版本:" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "作者:" @@ -3796,6 +3945,11 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generating AABB" +msgstr "生成AABB" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "面不含有区域!" @@ -3848,6 +4002,16 @@ msgstr "体积" msgid "Emission Source: " msgstr "发射填充:" +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generate Visibility AABB" +msgstr "生成AABB" + +#: editor/plugins/particles_editor_plugin.cpp +#, fuzzy +msgid "Generation Time (sec):" +msgstr "平均帧时间(秒)" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "从曲线中移除顶点" @@ -4300,6 +4464,14 @@ msgid "Trim Trailing Whitespace" msgstr "修剪行后空白" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "自动缩进" @@ -5170,12 +5342,12 @@ msgstr "项目目录不存在!" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "项目目录下必须包含engin.cfg文件。" #: editor/project_manager.cpp #, fuzzy -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "项目目录下必须包含engin.cfg文件。" #: editor/project_manager.cpp @@ -5188,7 +5360,7 @@ msgstr "项目路径非法(被外部修改?)。" #: editor/project_manager.cpp #, fuzzy -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "无法在项目目录下创建engine.cfg文件。" #: editor/project_manager.cpp @@ -5224,10 +5396,6 @@ msgid "Install Project:" msgstr "安装项目:" #: editor/project_manager.cpp -msgid "Install" -msgstr "安装" - -#: editor/project_manager.cpp msgid "Browse" msgstr "浏览" @@ -5286,6 +5454,11 @@ msgid "New Project" msgstr "新建" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "移除项目" + +#: editor/project_manager.cpp msgid "Exit" msgstr "退出" @@ -5472,8 +5645,8 @@ msgstr "移除资源重定向选项" #: editor/project_settings.cpp #, fuzzy -msgid "Project Settings (godot.cfg)" -msgstr "项目设置(engine.cfg)" +msgid "Project Settings " +msgstr "项目设置" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5539,10 +5712,6 @@ msgstr "地区" msgid "AutoLoad" msgstr "自动加载(AutoLoad)" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "插件" - #: editor/property_editor.cpp #, fuzzy msgid "Pick a Viewport" @@ -6146,6 +6315,10 @@ msgid "Change Notifier Extents" msgstr "更改通知器级别" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "更改探针(Probe)范围" @@ -6716,6 +6889,17 @@ msgid "" msgstr "" "NavigationMeshInstance类型节点必须作为Navigation节点的子孙才能提供导航数据。" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "path属性必须指向一个合法的Spatial节点才能正常工作。" @@ -6788,6 +6972,16 @@ msgstr "" "使其成为子控件的所以它可以有一个尺寸大小值。否则请设置为Render target,并将其" "内部纹理分配给一些节点以显示。" +#~ msgid "Node From Scene" +#~ msgstr "从场景导入节点" + +#~ msgid "Import assets to the project." +#~ msgstr "导入资源。" + +#, fuzzy +#~ msgid "Project Settings (godot.cfg)" +#~ msgstr "项目设置(engine.cfg)" + #~ msgid "Surface" #~ msgstr "表面" diff --git a/editor/translations/zh_HK.po b/editor/translations/zh_HK.po index 7c06087fd2..e49582e901 100644 --- a/editor/translations/zh_HK.po +++ b/editor/translations/zh_HK.po @@ -1,5 +1,6 @@ # Chinese (Honk Kong) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # Wesley (zx-wt) <ZX_WT@ymail.com>, 2016. @@ -359,6 +360,180 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "View Files" +msgstr "檔案" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "關閉" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect." +msgstr "連到..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Can't connect to host:" +msgstr "連到" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Connecting.." +msgstr "連到..." + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Requesting.." +msgstr "測試" + +#: editor/asset_library_editor_plugin.cpp +#, fuzzy +msgid "Error making request" +msgstr "載入字形出現錯誤" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "全部" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -366,6 +541,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "搜尋" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "導入" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "插件" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -379,10 +577,6 @@ msgid "Category:" msgstr "分類:" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "全部" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "地址:" @@ -414,20 +608,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "關閉" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -477,13 +657,6 @@ msgid "Selection Only" msgstr "只限選中" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "搜尋" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "查找" @@ -636,11 +809,6 @@ msgstr "最近:" msgid "Matches:" msgstr "吻合" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1119,10 +1287,6 @@ msgstr "" msgid "Clear" msgstr "清空" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1491,21 +1655,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "導入" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1774,10 +1923,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3753,6 +3898,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3800,6 +3949,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4252,6 +4409,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5114,11 +5279,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5130,7 +5295,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5166,10 +5331,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "瀏覽" @@ -5228,6 +5389,11 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +#, fuzzy +msgid "Templates" +msgstr "移除選項" + +#: editor/project_manager.cpp msgid "Exit" msgstr "離開" @@ -5412,8 +5578,9 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" -msgstr "" +#, fuzzy +msgid "Project Settings " +msgstr "設定" #: editor/project_settings.cpp editor/settings_config_dialog.cpp msgid "General" @@ -5479,10 +5646,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "插件" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6094,6 +6257,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp msgid "Change Probe Extents" msgstr "" @@ -6649,6 +6816,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" diff --git a/editor/translations/zh_TW.po b/editor/translations/zh_TW.po index 34943b9eb4..7836cd2f76 100644 --- a/editor/translations/zh_TW.po +++ b/editor/translations/zh_TW.po @@ -1,5 +1,6 @@ # Chinese (Taiwan) translation of the Godot Engine editor -# Copyright (C) 2016-2017 Juan Linietsky, Ariel Manzur and the Godot community +# Copyright (C) 2007-2017 Juan Linietsky, Ariel Manzur +# Copyright (C) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) # This file is distributed under the same license as the Godot source code. # # popcade <popcade@gmail.com>, 2016. @@ -356,6 +357,174 @@ msgstr "" msgid "Change Array Value" msgstr "" +#: editor/asset_library_editor_plugin.cpp +msgid "Free" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_plugin_settings.cpp +msgid "Version:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Contents:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "View Files" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp +#: editor/editor_help.cpp editor/property_selector.cpp +#: editor/script_editor_debugger.cpp +msgid "Description:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_manager.cpp +msgid "Install" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/call_dialog.cpp +#: editor/connections_dialog.cpp editor/export_template_manager.cpp +#: editor/plugins/animation_player_editor_plugin.cpp +#: editor/plugins/canvas_item_editor_plugin.cpp +#: editor/plugins/resource_preloader_editor_plugin.cpp +#: editor/plugins/sample_library_editor_plugin.cpp +#: editor/plugins/script_editor_plugin.cpp +#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp +#: editor/property_editor.cpp editor/run_settings_dialog.cpp +#: editor/settings_config_dialog.cpp +#: modules/visual_script/visual_script_editor.cpp +msgid "Close" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve hostname:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't resolve." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connection error, please try again." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Can't connect to host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response from host:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "No response." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, return code:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Req. Failed." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Request failed, too many redirects" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Redirect Loop." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Bad download hash, assuming file has been tampered with." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Expected:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Got:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Failed sha256 hash check" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Asset Download Error:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Success!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Fetching:" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Resolving.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Connecting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Requesting.." +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Error making request" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Idle" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Retry" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download Error" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "Download for this asset is already in progress!" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "first" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "prev" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "next" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "last" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp +msgid "All" +msgstr "" + #: editor/asset_library_editor_plugin.cpp editor/create_dialog.cpp #: editor/editor_help.cpp editor/editor_node.cpp #: editor/plugins/script_editor_plugin.cpp editor/property_selector.cpp @@ -363,6 +532,29 @@ msgstr "" msgid "Search:" msgstr "" +#: editor/asset_library_editor_plugin.cpp editor/code_editor.cpp +#: editor/editor_help.cpp editor/plugins/script_editor_plugin.cpp +#: editor/plugins/script_text_editor.cpp +#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp +msgid "Search" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/editor_node.cpp +#: editor/io_plugins/editor_bitmask_import_plugin.cpp +#: editor/io_plugins/editor_font_import_plugin.cpp +#: editor/io_plugins/editor_mesh_import_plugin.cpp +#: editor/io_plugins/editor_sample_import_plugin.cpp +#: editor/io_plugins/editor_scene_import_plugin.cpp +#: editor/io_plugins/editor_texture_import_plugin.cpp +#: editor/io_plugins/editor_translation_import_plugin.cpp +#: editor/project_manager.cpp +msgid "Import" +msgstr "" + +#: editor/asset_library_editor_plugin.cpp editor/project_settings.cpp +msgid "Plugins" +msgstr "" + #: editor/asset_library_editor_plugin.cpp msgid "Sort:" msgstr "" @@ -376,10 +568,6 @@ msgid "Category:" msgstr "" #: editor/asset_library_editor_plugin.cpp -msgid "All" -msgstr "" - -#: editor/asset_library_editor_plugin.cpp msgid "Site:" msgstr "" @@ -411,20 +599,6 @@ msgstr "" msgid "Call" msgstr "" -#: editor/call_dialog.cpp editor/connections_dialog.cpp -#: editor/export_template_manager.cpp -#: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp -#: editor/plugins/resource_preloader_editor_plugin.cpp -#: editor/plugins/sample_library_editor_plugin.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/sprite_frames_editor_plugin.cpp editor/project_settings.cpp -#: editor/property_editor.cpp editor/run_settings_dialog.cpp -#: editor/settings_config_dialog.cpp -#: modules/visual_script/visual_script_editor.cpp -msgid "Close" -msgstr "" - #: editor/call_dialog.cpp msgid "Method List:" msgstr "" @@ -474,13 +648,6 @@ msgid "Selection Only" msgstr "" #: editor/code_editor.cpp editor/editor_help.cpp -#: editor/plugins/script_editor_plugin.cpp -#: editor/plugins/script_text_editor.cpp -#: editor/plugins/shader_editor_plugin.cpp editor/project_settings.cpp -msgid "Search" -msgstr "" - -#: editor/code_editor.cpp editor/editor_help.cpp msgid "Find" msgstr "" @@ -630,11 +797,6 @@ msgstr "" msgid "Matches:" msgstr "" -#: editor/create_dialog.cpp editor/editor_help.cpp editor/property_selector.cpp -#: editor/script_editor_debugger.cpp -msgid "Description:" -msgstr "" - #: editor/dependency_editor.cpp msgid "Search Replacement For:" msgstr "" @@ -1108,10 +1270,6 @@ msgstr "" msgid "Clear" msgstr "" -#: editor/editor_node.cpp -msgid "Node From Scene" -msgstr "" - #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp #: editor/resources_dock.cpp msgid "Error saving resource!" @@ -1476,21 +1634,6 @@ msgid "Distraction Free Mode" msgstr "" #: editor/editor_node.cpp -msgid "Import assets to the project." -msgstr "" - -#: editor/editor_node.cpp editor/io_plugins/editor_bitmask_import_plugin.cpp -#: editor/io_plugins/editor_font_import_plugin.cpp -#: editor/io_plugins/editor_mesh_import_plugin.cpp -#: editor/io_plugins/editor_sample_import_plugin.cpp -#: editor/io_plugins/editor_scene_import_plugin.cpp -#: editor/io_plugins/editor_texture_import_plugin.cpp -#: editor/io_plugins/editor_translation_import_plugin.cpp -#: editor/project_manager.cpp -msgid "Import" -msgstr "" - -#: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." msgstr "" @@ -1759,10 +1902,6 @@ msgid "Installed Plugins:" msgstr "" #: editor/editor_plugin_settings.cpp -msgid "Version:" -msgstr "" - -#: editor/editor_plugin_settings.cpp msgid "Author:" msgstr "" @@ -3732,6 +3871,10 @@ msgid "A processor material of type 'ParticlesMaterial' is required." msgstr "" #: editor/plugins/particles_editor_plugin.cpp +msgid "Generating AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp msgid "Faces contain no area!" msgstr "" @@ -3779,6 +3922,14 @@ msgstr "" msgid "Emission Source: " msgstr "" +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generate Visibility AABB" +msgstr "" + +#: editor/plugins/particles_editor_plugin.cpp +msgid "Generation Time (sec):" +msgstr "" + #: editor/plugins/path_2d_editor_plugin.cpp msgid "Remove Point from Curve" msgstr "" @@ -4228,6 +4379,14 @@ msgid "Trim Trailing Whitespace" msgstr "" #: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Spaces" +msgstr "" + +#: editor/plugins/script_text_editor.cpp +msgid "Convert Indent To Tabs" +msgstr "" + +#: editor/plugins/script_text_editor.cpp msgid "Auto Indent" msgstr "" @@ -5085,11 +5244,11 @@ msgid "Invalid project path, the path must exist!" msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must not exist." +msgid "Invalid project path, *.godot must not exist." msgstr "" #: editor/project_manager.cpp -msgid "Invalid project path, godot.cfg must exist." +msgid "Invalid project path, *.godot must exist." msgstr "" #: editor/project_manager.cpp @@ -5101,7 +5260,7 @@ msgid "Invalid project path (changed anything?)." msgstr "" #: editor/project_manager.cpp -msgid "Couldn't create godot.cfg in project path." +msgid "Couldn't create *.godot project file in project path." msgstr "" #: editor/project_manager.cpp @@ -5137,10 +5296,6 @@ msgid "Install Project:" msgstr "" #: editor/project_manager.cpp -msgid "Install" -msgstr "" - -#: editor/project_manager.cpp msgid "Browse" msgstr "" @@ -5199,6 +5354,10 @@ msgid "New Project" msgstr "" #: editor/project_manager.cpp +msgid "Templates" +msgstr "" + +#: editor/project_manager.cpp msgid "Exit" msgstr "" @@ -5382,7 +5541,7 @@ msgid "Remove Resource Remap Option" msgstr "" #: editor/project_settings.cpp -msgid "Project Settings (godot.cfg)" +msgid "Project Settings " msgstr "" #: editor/project_settings.cpp editor/settings_config_dialog.cpp @@ -5449,10 +5608,6 @@ msgstr "" msgid "AutoLoad" msgstr "" -#: editor/project_settings.cpp -msgid "Plugins" -msgstr "" - #: editor/property_editor.cpp msgid "Pick a Viewport" msgstr "" @@ -6056,6 +6211,10 @@ msgid "Change Notifier Extents" msgstr "" #: editor/spatial_editor_gizmos.cpp +msgid "Change Particles AABB" +msgstr "" + +#: editor/spatial_editor_gizmos.cpp #, fuzzy msgid "Change Probe Extents" msgstr "變更框型範圍" @@ -6610,6 +6769,17 @@ msgid "" "It only provides navigation data." msgstr "" +#: scene/3d/particles.cpp +msgid "" +"Nothing is visible because meshes have not been assigned to draw passes." +msgstr "" + +#: scene/3d/particles.cpp +msgid "" +"A material to process the particles is not assigned, so no behavior is " +"imprinted." +msgstr "" + #: scene/3d/remote_transform.cpp msgid "Path property must point to a valid Spatial node to work." msgstr "" |