(FILECREATED " 2-Jul-86 16:27:57" {QV}<NOTECARDS>1.3K>FGHPATCH085.;1 5716 changes to: (VARS FGHPATCH085COMS)) (* Copyright (c) 1986 by Xerox Corporation. All rights reserved.) (PRETTYCOMPRINT FGHPATCH085COMS) (RPAQQ FGHPATCH085COMS ((* * Minor fixes to NF indicator windows.) (FNS NC.AttachNoteFileName))) (* * Minor fixes to NF indicator windows.) (DEFINEQ (NC.AttachNoteFileName (LAMBDA (CardWindow OffFlg) (* fgh: " 2-Jul-86 12:16") (* * Attach an indicator of the NoteFile for this Card to the Card) (* * fgh 5/29/86 Changed collection of old attached windows to prevent NILs in collection result.) (* * fgh 6/13/86 Put detachment and reattachment of previous attached windows into a RESETLST. Added FREEATTACHEDWINDOW as the CLOSEFN of the indicator window. Added code to reset PASSTOMAINWINDOW COMS of the previously attachwed windows. Changed MINSIZE of indicator window to allow small fonts. Added a REPAINTFN to the indicator window.) (* * fgh 7/2/86 Replaced the CLEARW call in the indicator window REPAINTFN with a DSPRESET for two reasons: reset the X coor befre printining and CLEARW is not allowed in REPAINTFNS.) (LET ((Card (NC.CardFromWindow CardWindow)) AttachedWindows FileName Window) (if (NC.CardP Card) then (SETQ AttachedWindows (ATTACHEDWINDOWS CardWindow)) (if OffFlg then (CLOSEW (for window in AttachedWindows thereis (WINDOWPROP window (QUOTE NoteFileIndicator)))) (REPOSITIONATTACHEDWINDOWS CardWindow) else (TOTOPW CardWindow) (if (SETQ Window (for window in AttachedWindows thereis (WINDOWPROP window (QUOTE NoteFileIndicator)))) then (* * There already is an indicator window, open and redisplay it.) (OR (OPENWP Window) (OPENW Window)) (REDISPLAYW Window) else (* * No existing indicator window, make one.) (RESETLST (* * First arrange to have other attached windows removed and then replaced after the indicator window is made.) (RESETSAVE NIL (BQUOTE (, (FUNCTION (LAMBDA (DescriptionList) (* Reattach windows according to information in a description list.) (for windowDescription in DescriptionList do (ATTACHWINDOW (CAR windowDescription) CardWindow (CAADR windowDescription) (CADADR windowDescription)) (WINDOWPROP (CAR windowDescription) (QUOTE PASSTOMAINCOMS) (CADDR windowDescription))))) , (bind WA for window in AttachedWindows when (EQ (QUOTE TOP) (CAR (SETQ WA (WINDOWPROP window (QUOTE WHEREATTACHED))))) collect (* Detach attached windows at the top of the main window and retuirn a list describing their attachment.) (PROG1 (LIST window WA (WINDOWPROP window (QUOTE PASSTOMAINCOMS))) (DETACHWINDOW window)))))) (* * Make the indicator window.) (LET (NoteFile FileName YSize IndicatorWindow) (SETQ NoteFile (fetch (Card NoteFile) of Card)) (SETQ FileName (NC.MakeNoteFileNameIndicator NoteFile)) (SETQ YSize (HEIGHTIFWINDOW (OR (FONTPROP NC.NoteFileIndicatorFont (QUOTE HEIGHT)) 20))) (SETQ IndicatorWindow (CREATEW (CREATEREGION 0 0 100 YSize) NIL T)) (WINDOWPROP IndicatorWindow (QUOTE MAXSIZE) (CONS 1000 YSize)) (WINDOWPROP IndicatorWindow (QUOTE MINSIZE) (CONS 20 YSize)) (ATTACHWINDOW IndicatorWindow CardWindow (QUOTE TOP) (QUOTE JUSTIFY) (QUOTE LOCALCLOSE)) (WINDOWPROP IndicatorWindow (QUOTE BUTTONEVENTFN) (FUNCTION (LAMBDA (window) (INVERTW window) (NC.SetUpNoteFileInterface (fetch (Card NoteFile) of (NC.CardFromWindow (MAINWINDOW window)))) (INVERTW window)))) (WINDOWPROP IndicatorWindow (QUOTE FileName) FileName) (WINDOWADDPROP IndicatorWindow (QUOTE CLOSEFN) (FUNCTION FREEATTACHEDWINDOW) T) (WINDOWPROP IndicatorWindow (QUOTE REPAINTFN) (FUNCTION (LAMBDA (Window Region) (DSPRESET Window) (PRIN1 (WINDOWPROP Window (QUOTE FileName)) Window)))) (DSPFONT NC.NoteFileIndicatorFont IndicatorWindow) (PRIN1 FileName IndicatorWindow) (OPENW IndicatorWindow) (WINDOWPROP IndicatorWindow (QUOTE NoteFileIndicator) (QUOTE Showing)))))))))) ) (PUTPROPS FGHPATCH085 COPYRIGHT ("Xerox Corporation" 1986)) (DECLARE: DONTCOPY (FILEMAP (NIL (385 5634 (NC.AttachNoteFileName 395 . 5632))))) STOP