This is AbsPoly.m in view mode; [Download] [Up]
/* Generated by Interface Builder */ #import "AbsPoly.h" #import <objc/List.h> #import "miscutil.h" #import "CmdBgnpoly.h" #import "CmdVertex.h" #import "CmdEndpoly.h" @implementation AbsPoly - init { [super init]; vertexList=[[List alloc] init]; command="Polygon"; return self; } - addCommand:aCmd { [vertexList addObject:aCmd]; return self; } - commandList { return vertexList; } - free { [vertexList free]; return self; } - doCmd { [theBitmap cmdDrawPoly:[vertexList copy]]; return self; } - (char *)emitCmd { int i, max=[vertexList count]; char tCmd[8192]; strcpy(tCmd, [[vertexList objectAt:0] emitCmd]); for(i=1;i<max;i++) strcat(tCmd,[[vertexList objectAt:i] emitCmd]); return strdup(tCmd); } @end
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.