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/