(FILECREATED "22-Jan-86 12:40:29" {QV}<NOTECARDS>1.3K>FGHPATCH015.;2 3641   

      changes to:  (FNS NC.SetUpNoteFileInterface)
		   (VARS FGHPATCH015COMS)

      previous date: "22-Jan-86 12:38:30" {QV}<NOTECARDS>1.3K>FGHPATCH015.;1)


(* Copyright (c) 1986 by Xerox Corporation. All rights reserved.)

(PRETTYCOMPRINT FGHPATCH015COMS)

(RPAQQ FGHPATCH015COMS ((* * From NCDATABASE to fix wire box positioning of NF menu)
			  (FNS NC.SetUpNoteFileInterface)))
(* * From NCDATABASE to fix wire box positioning of NF menu)

(DEFINEQ

(NC.SetUpNoteFileInterface
  (LAMBDA (NoteFile)                                         (* fgh: "22-Jan-86 12:40")

          (* * Create the NoteCards control menu for a NoteFile)



          (* * kirk 13Jan85 Decreased the size of the NoteFile Menu)



          (* * fgh 1/22/86 Fixed the ghost box size when position menu.)


    (LET ((Font (FONTCREATE (QUOTE HELVETICA)
			      10
			      (QUOTE BOLD)))
	  (TitleFont (FONTCREATE (QUOTE HELVETICA)
				   12
				   (QUOTE BOLD)))
	  NoteFileMenuWindow NoteFileMenu FullFileName)      (* Main Menu)
         (SETQ FullFileName (fetch (NoteFile FullFileName) of NoteFile))
         (if (SETQ NoteFileMenu (fetch (NoteFile Menu) of NoteFile))
	   else (PROGN (SETQ NoteFileMenu (create MENU
							  ITEMS ←(QUOTE ((NewCards NIL 
		       "Create a new Text card (left button) or other card type (middle button).")
									    (TopBoxes NIL 
							"Bring up one of the standard FileBoxes.")))
							  WHENSELECTEDFN ←(FUNCTION 
							    NC.NoteFileMenuWhenSelectedFn)
							  CENTERFLG ← T
							  MENUBORDERSIZE ← 1
							  MENUOUTLINESIZE ← 2
							  MENUCOLUMNS ← 2
							  MENUFONT ← Font
							  TITLE ←(FILENAMEFIELD FullFileName
										  (QUOTE NAME))
							  ITEMHEIGHT ←(IPLUS 6 (FONTPROP
										 Font
										 (QUOTE HEIGHT)))
							  ITEMWIDTH ←(IPLUS (STRINGWIDTH
										(QUOTE NewCards)
										Font)
									      10)
							  MENUTITLEFONT ← TitleFont))
			   (replace (MENU MENUPOSITION) of NoteFileMenu
			      with (GETBOXPOSITION (fetch (MENU IMAGEWIDTH) of NoteFileMenu)
						       (fetch (MENU IMAGEHEIGHT) of 
										     NoteFileMenu)
						       NIL NIL NIL 
					    "Please indicate location for NoteFile control menu."))))
         (if (WINDOWP (SETQ NoteFileMenuWindow (WFROMMENU NoteFileMenu)))
	     then (FLASHW NoteFileMenuWindow)
	   else (SETQ NoteFileMenuWindow (ADDMENU NoteFileMenu NIL (GETMENUPROP NoteFileMenu
											(QUOTE
											  OldPosition)
											))))
         (WINDOWPROP NoteFileMenuWindow (QUOTE NoteFile)
		       NoteFile)
         (replace (NoteFile Menu) of NoteFile with NoteFileMenu)
         (WINDOWPROP NoteFileMenuWindow (QUOTE RESHAPEFN)
		       (QUOTE DON'T))
         (WINDOWPROP NoteFileMenuWindow (QUOTE BUTTONEVENTFN)
		       (FUNCTION NC.NoteFileIconButtonEventFn))
         (WINDOWPROP NoteFileMenuWindow (QUOTE SHRINKFN)
		       (QUOTE DON'T))
         (WINDOWADDPROP NoteFileMenuWindow (QUOTE CLOSEFN)
			  (FUNCTION (LAMBDA (Window)
			      (PUTMENUPROP (CAR (WINDOWPROP Window (QUOTE MENU)))
					     (QUOTE OldPosition)
					     (WINDOWPOSITION Window)))))
         (NC.MoveWindowOntoScreen NoteFileMenuWindow))))
)
(PUTPROPS FGHPATCH015 COPYRIGHT ("Xerox Corporation" 1986))
(DECLARE: DONTCOPY
  (FILEMAP (NIL (540 3559 (NC.SetUpNoteFileInterface 550 . 3557)))))
STOP