IacobIonut01 / Gallery

Light-weight Media Gallery app for Android made with Jetpack Compose
Apache License 2.0
1.4k stars 77 forks source link

[Enhancement] Allow users to crop an image by selecting any side of the cropping interface rather than the corners only #510

Open duck09 opened 3 weeks ago

duck09 commented 3 weeks ago

Is your feature request related to a problem? Please describe. Currently, when I want to crop an image, I need to hold the corner of the cropping interface then crop. If I hold any side of the cropping interface and try to crop, it just moves the image around.

Describe the solution you'd like Simply holding any side of the cropping interface should allow me to crop the image normally as is common on other image editors. As for moving the image, the behaviour can be changed so that the image moves if the user selects any empty space within the cropping interface.

thisisartman commented 1 week ago

Just to help your case, I'm adding a comparison between this Gallery app's cropping tool and the default Markup cropping UI.

Gallery's Cropping UI: https://github.com/user-attachments/assets/d8976b70-7f57-463b-a61f-5a12998beeb1

Markup's Cropping UI: https://github.com/user-attachments/assets/88dfecec-b63d-4169-86f4-034411508c7f

Observations:

mon-jai commented 6 days ago

image

@IacobIonut01 In the first video, when users drag a selection zone wider than the image's maximum width, the app reduces the height of the selection area. This behavior makes it impossible to select the image's maximum width while preserving the original selected height.

A better approach would be to maintain the selection's original height and adjust the width to match the image's maximum width.