mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-18 09:09:47 +00:00
Rename "Crop Image" to "Crop to Selection" and "Trim Image" to "Crop to Content"
Same names as the GNU Image Manipulation Program, much more clear as to what each option does.
This commit is contained in:
parent
97a588bfdd
commit
4f54ffc987
|
@ -140,7 +140,7 @@ msgstr ""
|
|||
msgid "Delete Permanently"
|
||||
msgstr ""
|
||||
|
||||
#. When you move something to recycle bin
|
||||
#. Found when requesting to delete a palette or an extension. Refers to when you move something to recycle bin.
|
||||
msgid "Move to Trash"
|
||||
msgstr ""
|
||||
|
||||
|
@ -156,10 +156,12 @@ msgstr ""
|
|||
msgid "Percentage"
|
||||
msgstr ""
|
||||
|
||||
msgid "Crop Image"
|
||||
#. Found in the image menu. Sets the size of the project to be the same as the size of the active selection.
|
||||
msgid "Crop to Selection"
|
||||
msgstr ""
|
||||
|
||||
msgid "Trim Image"
|
||||
#. Found in the image menu. Automatically trims out all the transparent pixels, making the image smaller.
|
||||
msgid "Crop to Content"
|
||||
msgstr ""
|
||||
|
||||
msgid "Resize Canvas"
|
||||
|
|
|
@ -639,11 +639,11 @@ scale_image={
|
|||
"deadzone": 0.5,
|
||||
"events": []
|
||||
}
|
||||
crop_image={
|
||||
crop_to_selection={
|
||||
"deadzone": 0.5,
|
||||
"events": []
|
||||
}
|
||||
trim_image={
|
||||
crop_to_content={
|
||||
"deadzone": 0.5,
|
||||
"events": []
|
||||
}
|
||||
|
|
|
@ -518,7 +518,7 @@ func center(indices: Array) -> void:
|
|||
|
||||
|
||||
## Sets the size of the project to be the same as the size of the active selection.
|
||||
func crop_image() -> void:
|
||||
func crop_to_selection() -> void:
|
||||
if not Global.current_project.has_selection:
|
||||
return
|
||||
Global.canvas.selection.transform_content_confirm()
|
||||
|
@ -537,7 +537,7 @@ func crop_image() -> void:
|
|||
|
||||
## Automatically makes the project smaller by looping through all of the cels and
|
||||
## trimming out the pixels that are transparent in all cels.
|
||||
func trim_image() -> void:
|
||||
func crop_to_content() -> void:
|
||||
Global.canvas.selection.transform_content_confirm()
|
||||
var used_rect := Rect2i()
|
||||
for f in Global.current_project.frames:
|
||||
|
|
|
@ -44,8 +44,8 @@ enum ImageMenu {
|
|||
RESIZE_CANVAS,
|
||||
OFFSET_IMAGE,
|
||||
SCALE_IMAGE,
|
||||
CROP_IMAGE,
|
||||
TRIM_IMAGE,
|
||||
CROP_TO_SELECTION,
|
||||
CROP_TO_CONTENT,
|
||||
FLIP,
|
||||
ROTATE,
|
||||
OUTLINE,
|
||||
|
@ -568,8 +568,8 @@ func _initialize_keychain() -> void:
|
|||
"new_brush": Keychain.InputAction.new("", "Edit menu", true),
|
||||
"preferences": Keychain.InputAction.new("", "Edit menu", true),
|
||||
"scale_image": Keychain.InputAction.new("", "Image menu", true),
|
||||
"crop_image": Keychain.InputAction.new("", "Image menu", true),
|
||||
"trim_image": Keychain.InputAction.new("", "Image menu", true),
|
||||
"crop_to_selection": Keychain.InputAction.new("", "Image menu", true),
|
||||
"crop_to_content": Keychain.InputAction.new("", "Image menu", true),
|
||||
"resize_canvas": Keychain.InputAction.new("", "Image menu", true),
|
||||
"offset_image": Keychain.InputAction.new("", "Image menu", true),
|
||||
"mirror_image": Keychain.InputAction.new("", "Image menu", true),
|
||||
|
|
|
@ -178,7 +178,7 @@ func selection_map_changed() -> void:
|
|||
Global.canvas.selection.marching_ants_outline.texture = image_texture
|
||||
Global.top_menu_container.edit_menu.set_item_disabled(Global.EditMenu.NEW_BRUSH, !has_selection)
|
||||
Global.top_menu_container.image_menu.set_item_disabled(
|
||||
Global.ImageMenu.CROP_IMAGE, !has_selection
|
||||
Global.ImageMenu.CROP_TO_SELECTION, !has_selection
|
||||
)
|
||||
|
||||
|
||||
|
|
|
@ -278,8 +278,8 @@ func _setup_image_menu() -> void:
|
|||
"Resize Canvas": "resize_canvas",
|
||||
"Offset Image": "offset_image",
|
||||
"Scale Image": "scale_image",
|
||||
"Crop Image": "crop_image",
|
||||
"Trim Image": "trim_image",
|
||||
"Crop to Selection": "crop_to_selection",
|
||||
"Crop to Content": "crop_to_content",
|
||||
"Mirror Image": "mirror_image",
|
||||
"Rotate Image": "rotate_image",
|
||||
"Outline": "outline",
|
||||
|
@ -296,7 +296,7 @@ func _setup_image_menu() -> void:
|
|||
for item in image_menu_items:
|
||||
_set_menu_shortcut(image_menu_items[item], image_menu, i, item)
|
||||
i += 1
|
||||
image_menu.set_item_disabled(Global.ImageMenu.CROP_IMAGE, true)
|
||||
image_menu.set_item_disabled(Global.ImageMenu.CROP_TO_SELECTION, true)
|
||||
image_menu.id_pressed.connect(image_menu_id_pressed)
|
||||
|
||||
|
||||
|
@ -682,10 +682,10 @@ func image_menu_id_pressed(id: int) -> void:
|
|||
_popup_dialog(Global.control.get_node("Dialogs/ImageEffects/ScaleImage"))
|
||||
Global.ImageMenu.OFFSET_IMAGE:
|
||||
_popup_dialog(Global.control.get_node("Dialogs/ImageEffects/OffsetImage"))
|
||||
Global.ImageMenu.CROP_IMAGE:
|
||||
DrawingAlgos.crop_image()
|
||||
Global.ImageMenu.TRIM_IMAGE:
|
||||
DrawingAlgos.trim_image()
|
||||
Global.ImageMenu.CROP_TO_SELECTION:
|
||||
DrawingAlgos.crop_to_selection()
|
||||
Global.ImageMenu.CROP_TO_CONTENT:
|
||||
DrawingAlgos.crop_to_content()
|
||||
Global.ImageMenu.RESIZE_CANVAS:
|
||||
_popup_dialog(Global.control.get_node("Dialogs/ImageEffects/ResizeCanvas"))
|
||||
Global.ImageMenu.FLIP:
|
||||
|
|
Loading…
Reference in a new issue