home *** CD-ROM | disk | FTP | other *** search
/ Nebula 1995 August / NEBULA.mdf / Apps / DevTools / ManPagesFromHeaders / Source / InfoView.m < prev    next >
Encoding:
Text File  |  1993-05-11  |  1.1 KB  |  69 lines

  1. /*
  2.  * Written by Guy Roberts of Object Skills Ltd, drifting
  3.  * in cyberspace without a domain or email address right 
  4.  * now. 
  5.  * May 7 1993. You can use this as a base for a better application
  6.  * as long as it is made publically available.
  7.  */
  8.  
  9. #import "InfoView.h"
  10.  
  11. @implementation InfoView
  12.  
  13. - fadeAway: sender
  14. {
  15.     id    face = [NXImage findImageNamed: "Author.tiff"];
  16.     id    blankSpace = [NXImage findImageNamed: "Blank.tiff"];
  17.     NXPoint     myPoint;
  18.     float         grey;
  19.  
  20.     [self lockFocus];
  21.  
  22.     myPoint.x = 0.0;
  23.     myPoint.y = 0.0;
  24.     
  25.     for (grey = 0.0; grey <= 1.0; grey += 0.05) {
  26.         if (NXUserAborted() ) {
  27.             grey = 1.0;
  28.         }
  29.         [face dissolve:grey toPoint: &myPoint];
  30.  
  31.         [self    display];
  32.     }
  33.     
  34.     for (grey = 0.0; grey <= 1.0; grey += 0.1) {
  35.         if (NXUserAborted() ) {
  36.             grey = 0.0;
  37.         }
  38.         [blankSpace dissolve:grey toPoint: &myPoint];
  39.         [self    display];
  40.     }
  41.  
  42.     [self unlockFocus];
  43.     
  44.     [self    display];
  45.     
  46.     return self;
  47. }
  48.  
  49. - drawSelf: (const NXRect *) rects :(int) rectCount
  50. {
  51.     return self;
  52.     
  53.     PSsetgray(NX_WHITE);
  54.     NXRectFill(&bounds);
  55.     
  56.     return self;
  57. }
  58.  
  59. #ifdef LETS_GET_MODEST_HERE
  60. - mouseDown: (NXEvent *) event
  61. {
  62.     [self    fadeAway: self];
  63.     
  64.     return self;
  65. }
  66. #endif
  67.  
  68. @end
  69.