mirror of
https://github.com/darlinghq/darling-cocotron.git
synced 2025-02-17 10:08:46 +00:00
48 lines
1.1 KiB
Objective-C
48 lines
1.1 KiB
Objective-C
#import <Foundation/NSObject.h>
|
|
#import <Foundation/NSGeometry.h>
|
|
#import <ApplicationServices/ApplicationServices.h>
|
|
|
|
@class PDFDocument;
|
|
|
|
typedef enum {
|
|
kPDFDisplayBoxMediaBox=kCGPDFMediaBox,
|
|
kPDFDisplayBoxCropBox=kCGPDFCropBox,
|
|
kPDFDisplayBoxBleedBox=kCGPDFBleedBox,
|
|
kPDFDisplayBoxTrimBox=kCGPDFTrimBox,
|
|
kPDFDisplayBoxArtBox=kCGPDFArtBox,
|
|
} PDFDisplayBox;
|
|
|
|
@interface PDFPage : NSObject {
|
|
PDFDocument *_document;
|
|
CGPDFPageRef _pageRef;
|
|
NSString *_label;
|
|
|
|
BOOL _hasBeenDistilled;
|
|
NSInteger _capacityOfCharacters;
|
|
NSInteger _numberOfCharacters;
|
|
unichar *_characters;
|
|
NSRect *_characterRects;
|
|
}
|
|
|
|
-(PDFDocument *)document;
|
|
-(CGPDFPageRef)pageRef;
|
|
-(NSString *)label;
|
|
|
|
-(NSUInteger)numberOfCharacters;
|
|
-(NSString *)string;
|
|
|
|
-(NSRect)boundsForBox:(PDFDisplayBox)box;
|
|
|
|
-(void)transformContextForBox:(PDFDisplayBox)box;
|
|
|
|
-(void)drawWithBox:(PDFDisplayBox)box;
|
|
|
|
@end
|
|
|
|
@interface PDFPage(private)
|
|
-(void)_getRects:(NSRect *)rects range:(NSRange)range;
|
|
-(void)setPageRef:(CGPDFPageRef)pageRef;
|
|
-(void)setDocument:(PDFDocument *)document;
|
|
-(void)setLabel:(NSString *)value;
|
|
@end
|