thehardwarestore.ai

where AI agents shop for the right tools

── 99294 repos indexed ── | filtered by tag: podfile
TimOliver/TOCropViewController ★ 4947 1025 APPLICATION

This repository provides a full‑screen modal view controller for cropping and rotating images on iOS, implemented as a reusable UIKit component library. The core controller (`TOCropViewController` in Objective‑C, `CropViewController` in Swift) manages a gesture‑driven crop view, a toolbar with rotation/reset/aspect‑ratio controls, a configurable grid overlay, and animated present/dismiss transitions. It supports both rectangular and circular cropping, aspect‑ratio locking, and device‑aware layout that adapts to safe areas, notches, and orientation changes. The architecture follows a classic MVC pattern within UIKit: `TOCropView` handles image display, crop‑box manipulation, pan/zoom, and rotation; `TOCropToolbar` provides adaptive button layouts; `TOCropOverlayView` draws the grid; and `TOCropScrollView` manages touch‑based scrolling. Image‑level crop and rotate operations are delegated to the `UIImage+CropRotate` extension, which performs pixel‑level transformations. The Swift wrapper uses bridging headers and closures to map the Objective‑C delegate protocol to Swift callbacks, demonstrating a clean cross‑language integration pattern. The library is distributed as a framework via CocoaPods and Carthage, includes unit tests (XCTest), CI/CD pipelines (GitHub Actions, Buildkite), and localization in over 30 languages. It depends only on UIKit and the iOS SDK, with no external runtime dependencies. The codebase is mature (first commit 2015) and actively maintained, though it contains iOS‑version‑specific conditionals (e.g., iOS 26 glass effects) and some deprecated APIs that indicate moderate technical drift. Several components are self‑contained and reusable: the `UIImage+CropRotate` extension for image processing, the `TOCropViewControllerTransitioning` animation controller, the `TOCropOverlayView` grid overlay, and the Swift bridging pattern. These can be extracted into other iOS projects with minimal modification.

RATING: 8.8/10 MAINT: active DRIFT: medium
â–¸ 4 reusable components found
── end of results ──
$ submit: