TOCropViewController icon indicating copy to clipboard operation
TOCropViewController copied to clipboard

Disabling vertical or horizontal cropping

Open simonsmiley64 opened this issue 10 years ago • 1 comments

Hi Tim

First of all fantastic library, I have used a few cropping libraries and this one is by far the best. Great job!

I was wondering if it is possible to restrict the cropping to either horizontal or vertical? I want all my images to be the width of the image and users only able to increase or decrease the height of the image.

Any help would be very appreciated.

Simon Smiley-Andrews

simonsmiley64 avatar Dec 17 '15 04:12 simonsmiley64

Hi Simon!

Thanks a lot! Haha yeah, I think I went through about 4 of them on CocoaControls myself before I decided it might be worth building my own.

Sadly, at the moment, it doesn't support locking the crop box to only rescale along certain axes. That being said, given the aspect ratio code in there, I don't think it would be too hard to add.

I'm sadly a bit too busy to take on adding feature requests for now, but if you feel like giving it a try and submitting a PR, please let me know! :)

TimOliver avatar Dec 19 '15 16:12 TimOliver