Skip to content

v3.3.0

Latest

Choose a tag to compare

@TimOliver TimOliver released this 08 Nov 17:04

Added

  • Full support for iPhone Duo, in all rotations and screen states. This is still early days, so any feedback on how or if it can be improved would be appreciated! (#660)
  • TOCropToolbar.reverseVerticalContentLayout, which anchors the Done button to the bottom of a vertical toolbar instead of the top.
  • -[TOCropView performRelayoutForBoundsChange], which lays the crop out again after its content bounds have shifted, carrying any crop the user has made across.

Fixed

  • On iOS 26, apps built with Xcode 16 (the iOS 18 SDK) showed no Done or Cancel buttons, as the toolbar laid itself out for the Liquid Glass design that the older SDK had compiled out. The glass design is now only used when both the SDK and the device support it. (#655)
  • On iOS 26, the aspect ratio picker could appear away from its button: offset sideways on iPhone, and in the wrong place entirely on iPad. (#644, #657)
  • On visionOS, the toolbar used UICornerConfiguration without checking for visionOS 26, which it requires. (#658)
  • Dismissing the crop view controller removed the presenting view controller's view when that controller wasn't full screen (such as a sheet, form sheet or popover), or when the crop view controller itself was presented over full screen. (#661)
  • Clearing transitioningDelegate to opt out of the custom transition had no effect, as it was installed again when the view loaded. (#661)
  • Tapping Done without making any changes, or after resetting, returned an image a few pixels smaller than the original (eg, 4032×3019 for a 4032×3024 photo), and each 90° rotation shaved off more. Crops that reach an edge of the image now include it exactly. (#662)
  • With a locked aspect ratio, each 90° rotation zoomed further into the image, and rotating without animation (including setting angle) left the crop box in the wrong orientation. The crop box now keeps its shape while the image turns underneath it, zooming in only as far as it needs to, and rotating all the way around returns to the original crop. (#663)
  • Switching between aspect ratio presets could slide the crop towards the image's left or top edge instead of keeping it centred. (#663)
  • Very wide or tall locked aspect ratios (such as 1920:190) were distorted by the minimum crop box size, especially after rotating. (#663)
  • With aspectRatioLockDimensionSwapEnabled on, rotating after choosing an aspect ratio could jump to a different part of the image. (#663)
  • At some view sizes, an aspect ratio preset's crop box came out a point narrower than it should, so a square preset didn't produce a square image. (#664)
  • Crops locked to an aspect ratio could be up to 20 pixels away from that ratio in the final image. They now match it to the nearest pixel. (#664)
  • Cropping a photo from the camera (or any other wide color image) produced a 16-bit-per-channel image, using twice the memory it needed and crashing share extensions with large photos. Crops are now drawn in the photo's own 8-bit color format, and crops that aren't rotated or circular reuse the photo's pixels without copying them. (#665)
  • With the toolbar at the top, it could sit under the status bar whenever the crop view controller couldn't hide it, such as on iPhones without a notch when embedded in another view controller or when view controller-based status bar appearance is turned off. (#666)
  • With a title set, a top toolbar was positioned from where the title had been on an earlier layout pass, so it could overlap the title or leave a gap below it. (#666)
  • When embedded as a child view controller, the crop view was sized to the parent's view instead of its own, so any part of it below a shorter frame was hidden. (#666)
  • Tapping Done while the image was being dragged past the crop box, or while it was still bouncing back, committed a smaller crop than the one shown once it came to rest, or even an empty one. The crop is now the one it comes to rest on. (#667)
  • A crop box locked to an aspect ratio could be dragged out of shape: by dragging it out from a corner or edge while it was already up against the edge of the cropping area (such as straight after shrinking it, before it re-centred), and by shrinking a box that isn't square all the way down. The box also briefly went out of shape while being dragged by an edge. It now keeps its ratio throughout, scaling as a whole from the opposite corner or edge, and sliding over when dragged by an edge that has room to grow on only one side. It can also now be enlarged from any corner or edge, where before only the bottom corners and the bottom and right edges could make it bigger. (#668)
  • On iPhones without a notch, dismissing to a view laid out in the safe area (with dismissAnimatedFromParentViewController:withCroppedImage:toView:...) could land the image a few points above that view, and then jump down to it once the transition finished, as the returning status bar moved the safe area. The image now follows the view to wherever it ends up.
  • On iOS 26 and later, on displays with large rounded corners and no safe area along some edges (such as iPhone Duo's unfolded display), the corners of the crop box could poke into the display's own. The crop region now keeps clear of the display's corners along those edges.
  • On displays with a camera gutter down one side, such as iPhone Duo's cover display, turning the device 180° between landscape orientations while the crop view controller was presented full screen meant that dismissing to a view (with dismissAnimatedFromParentViewController:withCroppedImage:toView:...) aimed the image at where that view had been, then snapped it across to the view once the transition finished. The image now lands on the view where it ends up.
  • Setting imageCropFrame once the crop view controller was on screen applied the crop but left the reset button disabled.