Annotation of Examples/AppKit/Lines/LinesView.h, revision 1.1.1.1

1.1       root        1: // LinesView.h, a small sample view for showing timed entries & userpaths.
                      2: // Author: Ali T. Ozer, NeXT Computer, Inc.
                      3: // Written March 19, 1989.
                      4: // Updated for 2.0 and integrated with UserPath.[hm] by Jayson Adams,
                      5: // NeXT Developer Support Team, October 16, 1990
                      6: //
                      7: // You may freely copy, distribute and reuse the code in this example.
                      8: // NeXT disclaims any warranty of any kind, expressed or implied, as to its
                      9: // fitness for any particular use.
                     10: //
                     11: 
                     12: #import <appkit/View.h>
                     13: #import "UserPath.h"
                     14: 
                     15: #define MINNUMCORNERS 2
                     16: #define MAXNUMCORNERS 20
                     17: 
                     18: @interface LinesView : View
                     19: {
                     20:     BOOL running;                 // Whether we are animating or not.
                     21:     DPSTimedEntry linesTimedEntry;
                     22:     struct cornerStruct {
                     23:        int xLoc, yLoc;
                     24:        int xVel, yVel;
                     25:     } corners[MAXNUMCORNERS];     // Corners and velocities for our polygon
                     26:     int numCorners;               // Number of corners we actually have
                     27:     UserPath   *userPath;
                     28: }
                     29: 
                     30: /* instance methods */
                     31: - initFrame:(NXRect *)rect;
                     32: - free;
                     33: - toggleRun:sender;
                     34: - setNumberOfCorners:sender;
                     35: - animate;
                     36: 
                     37: @end

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.