Files
ichmagmaus111andClaude Opus 5.5 0622057a4f Ghostgram: open-source release
Ghostgram for iOS, rebuilt from scratch on Telegram iOS 13.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 17:57:09 +01:00

33 lines
718 B
Swift

#if canImport(CoreGraphics)
import CoreGraphics
#else
import Foundation
#endif
public extension Rect {
/// Initialize a `Rect` using the provided `CGRect` values.
init(_ rect: CGRect) {
self.init(
origin: Point(rect.origin),
size: Size(rect.size)
)
}
@available(*, deprecated, renamed: "CGRect(_:)", message: "Use CGRect initializer directly")
var cgRect: CGRect {
CGRect(self)
}
}
public extension CGRect {
/// Initialize a `CGRect` using the provided `Rect` values.
init(_ rect: Rect) {
self.init(
x: rect.x,
y: rect.y,
width: rect.width,
height: rect.height
)
}
}