Skip to content

Commit 3e97129

Browse files
authored
Readds margins
1 parent 5cee63c commit 3e97129

File tree

1 file changed

+17
-10
lines changed

1 file changed

+17
-10
lines changed

addons/block_code/ui/block_canvas/block_canvas.tscn

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,7 @@ grow_horizontal = 0
4444
grow_vertical = 0
4545
mouse_filter = 2
4646

47-
[node name="ZoomButtons" type="HBoxContainer" parent="WindowContainer/Overlay"]
48-
unique_name_in_owner = true
49-
visible = false
47+
[node name="MarginContainer" type="MarginContainer" parent="WindowContainer/Overlay"]
5048
layout_mode = 1
5149
anchors_preset = 3
5250
anchor_left = 1.0
@@ -58,24 +56,33 @@ offset_top = -40.0
5856
grow_horizontal = 0
5957
grow_vertical = 0
6058
mouse_filter = 2
59+
theme_override_constants/margin_left = 4
60+
theme_override_constants/margin_top = 4
61+
theme_override_constants/margin_right = 4
62+
theme_override_constants/margin_bottom = 4
63+
64+
[node name="ZoomButtons" type="HBoxContainer" parent="WindowContainer/Overlay/MarginContainer"]
65+
unique_name_in_owner = true
66+
visible = false
67+
layout_mode = 2
6168

62-
[node name="ZoomOutButton" type="Button" parent="WindowContainer/Overlay/ZoomButtons"]
69+
[node name="ZoomOutButton" type="Button" parent="WindowContainer/Overlay/MarginContainer/ZoomButtons"]
6370
modulate = Color(1, 1, 1, 0.470588)
6471
custom_minimum_size = Vector2(25, 0)
6572
layout_mode = 2
6673
focus_mode = 0
6774
theme_override_font_sizes/font_size = 24
6875
text = "-"
6976

70-
[node name="ZoomButton" type="Button" parent="WindowContainer/Overlay/ZoomButtons"]
77+
[node name="ZoomButton" type="Button" parent="WindowContainer/Overlay/MarginContainer/ZoomButtons"]
7178
unique_name_in_owner = true
7279
modulate = Color(1, 1, 1, 0.470588)
7380
layout_mode = 2
7481
focus_mode = 0
7582
theme_override_font_sizes/font_size = 24
7683
text = "1.0x"
7784

78-
[node name="ZoomInButton" type="Button" parent="WindowContainer/Overlay/ZoomButtons"]
85+
[node name="ZoomInButton" type="Button" parent="WindowContainer/Overlay/MarginContainer/ZoomButtons"]
7986
modulate = Color(1, 1, 1, 0.470588)
8087
custom_minimum_size = Vector2(25, 0)
8188
layout_mode = 2
@@ -107,7 +114,7 @@ size_flags_vertical = 4
107114
[node name="Label" type="Label" parent="SelectedNodeBox"]
108115
custom_minimum_size = Vector2(200, 0)
109116
layout_mode = 2
110-
text = "Use block coding to create custom behavior and game mechanics for \"ZoomOutButton\"."
117+
text = "Use block coding to create custom behavior and game mechanics for \"ZoomInButton\"."
111118
horizontal_alignment = 1
112119
autowrap_mode = 2
113120

@@ -157,9 +164,9 @@ disabled = true
157164
text = "Override Block Code"
158165
icon = ExtResource("2_710vn")
159166

160-
[connection signal="pressed" from="WindowContainer/Overlay/ZoomButtons/ZoomOutButton" to="." method="_on_zoom_out_button_pressed"]
161-
[connection signal="pressed" from="WindowContainer/Overlay/ZoomButtons/ZoomButton" to="." method="_on_zoom_button_pressed"]
162-
[connection signal="pressed" from="WindowContainer/Overlay/ZoomButtons/ZoomInButton" to="." method="_on_zoom_in_button_pressed"]
167+
[connection signal="pressed" from="WindowContainer/Overlay/MarginContainer/ZoomButtons/ZoomOutButton" to="." method="_on_zoom_button_pressed"]
168+
[connection signal="pressed" from="WindowContainer/Overlay/MarginContainer/ZoomButtons/ZoomButton" to="." method="_on_zoom_button_pressed"]
169+
[connection signal="pressed" from="WindowContainer/Overlay/MarginContainer/ZoomButtons/ZoomInButton" to="." method="_on_zoom_button_pressed"]
163170
[connection signal="pressed" from="SelectedNodeBox/ButtonsBox/AddBlockCodeButton" to="." method="_on_add_block_code_button_pressed"]
164171
[connection signal="pressed" from="SelectedNodeWithBlockCodeBox/ButtonsBox/OpenSceneButton" to="." method="_on_open_scene_button_pressed"]
165172
[connection signal="pressed" from="SelectedNodeWithBlockCodeBox/ButtonsBox/ReplaceBlockCodeButton" to="." method="_on_replace_block_code_button_pressed"]

0 commit comments

Comments
 (0)