home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.0 / NeXTSTEP3.0.iso / NextDeveloper / Examples / AppKit / CompositeLab / CompositeView.h < prev    next >
Encoding:
Text File  |  1992-05-28  |  1.4 KB  |  58 lines

  1. #import <appkit/View.h>
  2. #import <appkit/color.h>
  3.  
  4. @interface CompositeView:View
  5. {
  6.     id source, destination, result, customImage;
  7.     NXRect sRect, dRect, rRect;
  8.     int operator, sourcePicture;
  9.     NXColor sourceColor, destColor, backgroundColor;
  10.  
  11.     // Outlets...
  12.     id sourceColorWell;
  13.     id destColorWell;
  14.     id backColorWell;
  15.     id sourcePictureMatrix;
  16. }
  17.  
  18. -initFrame:(const NXRect *)rect;
  19. -free;
  20.  
  21. // Target-action methods
  22. -setSourcePicture:sender;
  23. -setOperator:sender;
  24. -changeCustomImage:sender;
  25. -changeSourceColor:sender;
  26. -changeDestColor:sender;
  27. -changeBackgroundColor:sender;
  28.  
  29. // Outlet-setting methods (we need these to set the initial colors)
  30. - setSourceColorWell:anObject;
  31. - setDestColorWell:anObject;
  32. - setBackColorWell:anObject;
  33.  
  34. // These methods change the colors and display
  35. - (void)changeSourceColorTo:(NXColor)color andDisplay:(BOOL)flag;
  36. - (void)changeDestColorTo:(NXColor)color andDisplay:(BOOL)flag;
  37. - (void)changeBackgroundColorTo:(NXColor)color andDisplay:(BOOL)flag;
  38. - (BOOL)changeCustomImageTo:newImage;
  39.  
  40. // Other methods (some internal)
  41. -drawSource:image;
  42. -drawDestination:image;
  43. -drawResult:image;
  44. -drawSelf:(NXRect *)r :(int)count;
  45. -speedyDraw;
  46. -(int)operator;
  47.  
  48. - (NXDragOperation)draggingEntered:(id <NXDraggingInfo>)sender;
  49. - (NXDragOperation)draggingUpdated:(id <NXDraggingInfo>)sender;
  50. - draggingExited:sender;
  51. - (BOOL)performDragOperation:(id <NXDraggingInfo>)sender;
  52. - (void)doColorDrag:(id <NXDraggingInfo>)sender;
  53.  
  54. @end
  55.  
  56.  
  57.  
  58.