diff options
Diffstat (limited to 'editor')
-rw-r--r-- | editor/editor_atlas_packer.cpp | 4 | ||||
-rw-r--r-- | editor/plugins/gradient_editor_plugin.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/editor/editor_atlas_packer.cpp b/editor/editor_atlas_packer.cpp index 85541c093a..b8eba7e3f8 100644 --- a/editor/editor_atlas_packer.cpp +++ b/editor/editor_atlas_packer.cpp @@ -233,12 +233,12 @@ void EditorAtlasPacker::chart_pack(Vector<Chart> &charts, int &r_width, int &r_h const int *top_heights = bitmaps[i].top_heights.ptr(); const int *bottom_heights = bitmaps[i].bottom_heights.ptr(); - for (int j = 0; j < atlas_w - w; j++) { + for (int j = 0; j <= atlas_w - w; j++) { int height = 0; for (int k = 0; k < w; k++) { int pixmap_h = bottom_heights[k]; - if (pixmap_h == -1) { + if (pixmap_h == 0x7FFFFFFF) { continue; //no pixel here, anything is fine } diff --git a/editor/plugins/gradient_editor_plugin.cpp b/editor/plugins/gradient_editor_plugin.cpp index da050abc02..6f2d950190 100644 --- a/editor/plugins/gradient_editor_plugin.cpp +++ b/editor/plugins/gradient_editor_plugin.cpp @@ -118,6 +118,9 @@ void EditorInspectorPluginGradient::parse_begin(Object *p_object) { editor->set_gradient(g); add_custom_control(editor); + int picker_shape = EDITOR_GET("interface/inspector/default_color_picker_shape"); + editor->get_picker()->set_picker_shape((ColorPicker::PickerShapeType)picker_shape); + reverse_btn = memnew(GradientReverseButton); gradient_tools_hbox = memnew(HBoxContainer); |