1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-01-18 09:09:47 +00:00

Fixed preview camera zooming issues on large images

This commit is contained in:
OverloadedOrama 2019-12-09 00:17:05 +02:00
parent 2a086a41d8
commit 31a67fcbc2
4 changed files with 6 additions and 3 deletions

View file

@ -1241,7 +1241,7 @@ margin_bottom = 70.0
margin_left = 8.0
margin_top = 8.0
margin_right = 192.0
margin_bottom = 106.0
margin_bottom = 33.0
[node name="ImageSize" type="Label" parent="CreateNewImage/VBoxContainer"]
margin_right = 184.0
@ -1452,7 +1452,7 @@ text = "Language:"
margin_left = 61.0
margin_right = 142.0
margin_bottom = 21.0
text = "English"
text = "System Language"
items = [ "System Language", null, false, 0, null, "Greek [el]", null, false, 1, null, "English [en]", null, false, 2, null ]
selected = 0
@ -1523,7 +1523,7 @@ script = ExtResource( 42 )
margin_left = 8.0
margin_top = 8.0
margin_right = 276.0
margin_bottom = 158.0
margin_bottom = 149.0
[node name="Pixelorama" type="Label" parent="AboutDialog/AboutUI"]
margin_right = 268.0

View file

@ -62,9 +62,12 @@ func camera_zoom() -> void:
if zoom_max > Vector2.ONE:
Global.camera.zoom_max = zoom_max
Global.camera2.zoom_max = zoom_max
Global.camera_preview.zoom_max = zoom_max
else:
Global.camera.zoom_max = Vector2.ONE
Global.camera2.zoom_max = Vector2.ONE
Global.camera_preview.zoom_max = Vector2.ONE
Global.camera.zoom = Vector2(bigger, bigger) * 0.002
Global.camera2.zoom = Vector2(bigger, bigger) * 0.002
Global.camera_preview.zoom = Vector2(bigger, bigger) * 0.007