From a360d6aa8b61ecc0fe3ad12b996c77a7259a6567 Mon Sep 17 00:00:00 2001 From: Chris Jenkins Date: Fri, 5 Jul 2024 08:20:52 +0100 Subject: [PATCH] Fixed missing imports --- Sources/PDFAuthor/Renderable/ImageRegion.swift | 2 +- Sources/PDFAuthor/Renderable/PDFRegion.swift | 1 + Sources/PDFAuthor/Renderable/StringRegion.swift | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Sources/PDFAuthor/Renderable/ImageRegion.swift b/Sources/PDFAuthor/Renderable/ImageRegion.swift index 90ade44..c546084 100644 --- a/Sources/PDFAuthor/Renderable/ImageRegion.swift +++ b/Sources/PDFAuthor/Renderable/ImageRegion.swift @@ -110,7 +110,7 @@ public final class ImageRegion: PDFRegion { public var blendMode: CGBlendMode? /// :nodoc: - override public func draw(withContext context: CGContext, inRect rect: CGRect) { + override open func draw(withContext context: CGContext, inRect rect: CGRect) { guard bounds.width > 0, bounds.height > 0 else { return } diff --git a/Sources/PDFAuthor/Renderable/PDFRegion.swift b/Sources/PDFAuthor/Renderable/PDFRegion.swift index e35809a..92cd81c 100644 --- a/Sources/PDFAuthor/Renderable/PDFRegion.swift +++ b/Sources/PDFAuthor/Renderable/PDFRegion.swift @@ -24,6 +24,7 @@ import Foundation import Cassowary +import CoreGraphics /// The base class representing a rectangular region in the PDF Document. open class PDFRegion { diff --git a/Sources/PDFAuthor/Renderable/StringRegion.swift b/Sources/PDFAuthor/Renderable/StringRegion.swift index 2891d95..dfd8cd7 100644 --- a/Sources/PDFAuthor/Renderable/StringRegion.swift +++ b/Sources/PDFAuthor/Renderable/StringRegion.swift @@ -128,7 +128,7 @@ public class StringRegion: PDFRegion { // MARK: Drawing /// :nodoc: - public override func draw(withContext context: CGContext, inRect rect: CGRect) { + override open func draw(withContext context: CGContext, inRect rect: CGRect) { guard let str = attributedString else { return }