0
;; @copyright Copyright (c) 2007 Tim Burks, Neon Design Technology, Inc.
0
+;; these declarations would be unnecessary if Nu is enhanced to read the Apple BridgeSupport files.
0
(global kPDFDisplaySinglePage 0)
0
(global NSDragOperationCopy 1)
0
(global NSPDFPboardType "Apple PDF pasteboard type")
0
(ivar (id) mouseDownEvent)
0
(+ (void) initialize is
0
- (NSLog "(DraggingSourcePDFView +initialize)")
0
(set $dragImage (NSImage imageNamed:"Generic")))
0
(- (id) hitTest:(NSPoint) aPoint is
0
(function isLeftSide (pageNum) (or (eq pageNum 0) (> pageNum 4)))
0
+(function
NSMinX (rect)
0
(set x2 (+ (rect first) (rect third)))
0
(if (< x1 x2) (then x1) (else x2)))
0
+(function
NSMaxX (rect)
0
(set x2 (+ (rect first) (rect third)))
0
(if (> x1 x2) (then x1) (else x2)))
0
+(function
NSMinY (rect)
0
(set y2 (+ (rect second) (rect fourth)))
0
(if (< y1 y2) (then y1) (else y2)))
0
+(function
NSMaxY (rect)
0
(set y2 (+ (rect second) (rect fourth)))
0
(if (> y1 y2) (then y1) (else y2)))
0
(set numberAttributes nil) ;; pseudo-class variable
0
(+ (void) initialize is
0
- (NSLog "(Packerview +initialize)")
0
(set numberAttributes ((NSMutableDictionary alloc) init))
0
(numberAttributes setObject:(NSFont fontWithName:"Helvetica" size:40.0) forKey:NSFontAttributeName)
0
(numberAttributes setObject:(NSColor blueColor) forKey:NSForegroundColorAttributeName))
0
(- (void) prepareBezierPaths is
0
(set bounds (self bounds))
0
- (set left (minX bounds))
0
- (set right (maxX bounds))
0
- (set top (maxY bounds))
0
- (set bottom (minY bounds))
0
+ (set left (NSMinX bounds))
0
+ (set right (NSMaxX bounds))
0
+ (set top (NSMaxY bounds))
0
+ (set bottom (NSMinY bounds))
0
(set lowerH (QuarterY bounds))
0
(set midH (HalfY bounds))
0
(set upperH (ThreeQuarterY bounds))
0
(- (NSRect) fullRectForPage:(int) pageNum is
0
(set bounds (self bounds))
0
(if (isLeftSide pageNum)
0
- (then (set x (
minX bounds)))
0
+ (then (set x (
NSMinX bounds)))
0
(else (set x (HalfX bounds))))
0
(0 (set y (ThreeQuarterY bounds)))
0
(2 (set y (HalfY bounds)))
0
(6 (set y (QuarterY bounds)))
0
(3 (set y (QuarterY bounds)))
0
- (else (set y (
minY bounds))))
0
+ (else (set y (
NSMinY bounds))))
0
(list x y (* 0.5 (bounds third)) (* 0.25 (bounds fourth))))
0
(- (NSRect) imageableRectForPage:(int) pageNum is
0
(if (@packModel pageIsFilled:i)
0
(set fullRect (self fullRectForPage:i))
0
- (- (maxX fullRect) (+ 30 BUTTON_MARGIN))
0
- (+ (minY fullRect) BUTTON_MARGIN)
0
+ (- (NSMaxX fullRect) (+ 30 BUTTON_MARGIN))
0
+ (+ (NSMinY fullRect) BUTTON_MARGIN)
0
(set button ((NSButton alloc) initWithFrame:buttonRect))
0
(button setCell:((RoundCloseButtonCell alloc) init))
0
- (NSLog "(PreferencesController +initialize)")
0
(set factoryDefaults ((NSMutableDictionary alloc) init))
0
(factoryDefaults setObject:(NSNumber numberWithInt:0)
Comments
No one has commented yet.