0
Я перехожу к методу drawLayer, чтобы нарисовать конкретную страницу pdf. Как я могу скопировать часть страницы и показать ее.Закрепить часть страницы PDF при рисовании в iOS
- (void)drawLayer:(CATiledLayer *)layer inContext:(CGContextRef)context
{
CGContextSetRGBFillColor(context, 1.0f, 1.0f, 1.0f, 1.0f); // White
CGContextFillRect(context, CGContextGetClipBoundingBox(context)); // Fill
CGContextTranslateCTM(context, 0.0f, self.bounds.size.height); CGContextScaleCTM(context, 1.0f, -1.0f);
CGContextConcatCTM(context, CGPDFPageGetDrawingTransform(_PDFPageRef, kCGPDFCropBox, self.bounds, 0, true));
CGContextDrawPDFPage(context, _PDFPageRef);
}