/usr/share/doc/preview.app/Developers is in preview.app 0.8.5-9build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | Preview is a Document based application.
See Apple documentation for more informations.
Important files :
* GNUmakefile : See [2] writing GNUstep Makefiles.
* main.m : main file
* Main.gorm : Main model nib file.
It is the Preview menu.
* Document.m : the NSDocument subclass.
Methods :
** windowNibName : overriden method. return @"Preview" (see Preview.gorm)
** windowControllerDidLoadNib: overriden method.
1- set the window frame:
window origin is set to (120,100) == (WINDOW_ORIGIN_X,WINDOW_ORIGIN_Y)
the windowSize have a Minsize (set in Preview.gorm)
the window size is not bigger than the NSScreen:visibleFrame (-origin)
2- set _image into imageView
** loadDataRepresentation: overriden method
This will create a new document.
if the _image is succesfully loaded it keep the image's size.
** zoomImage: Action method call from View submenu (Zoom in & Zoom out)
The zoom factor is set to 0.1
** resize: Action method call from View submenu (100%/200%/400%/800%/50%/Fit width/Fit Window) popUp (100%/200%/400%/800%/50%) matrix of buttonCell (FitWindow/FitWidth)
** windowDidResize: Window delegate method. This method is used to refresh the horizontalScroller width
** windowDidMiniaturize: window delegate method. Generate mini icon
[1] http://developer.apple.com/documentation/Cocoa/Conceptual/Documents/index.html#//apple_ref/doc/uid/10000006i
[2] http://www.gnustep.it/nicola/Tutorials/WritingMakefiles/
|