18 #include <sys/types.h> 27 #define RADTODEG 57.29577951 287 "Symbol%d",SymbolNum);
322 Long1 = time((time_t *)
NULL);
323 sprintf(
TypeOut,
" Creation Date: %.24s ",
ctime((time_t *)&Long1));
333 struct prpty PrptyCopy;
405 fprintf(stderr,
"DD %d;\n",SymbolNum);
410 fprintf(stderr,
"Definition Delete of Symbol %d - ignored\n",SymbolNum);
417 fprintf(stderr,
";\n");
433 struct prpty PrptyCopy;
453 fprintf(stderr,
" T:%c %ld %ld",
Type,
X,
Y);
501 fprintf(stderr,
"C %d ",SymbolNum);
528 sprintf(
TypeOut,
" Symbol%d",SymbolNum);
589 if(Pair->
pY < Bottom)
596 if(NumVertices == 4){
597 if((Path->pX == Path->pSucc->pX
And 598 Path->pSucc->pY == Path->pSucc->pSucc->pY
And 599 Path->pSucc->pSucc->pX == Path->pSucc->pSucc->pSucc->pX
And 600 Path->pY == Path->pSucc->pSucc->pSucc->pY)
602 (Path->pY == Path->pSucc->pY
And 603 Path->pSucc->pX == Path->pSucc->pSucc->pX
And 604 Path->pSucc->pSucc->pY == Path->pSucc->pSucc->pSucc->pY
And 605 Path->pX == Path->pSucc->pSucc->pSucc->pX))
607 return(
ABox(Right-Left,Top-Bottom,Left+((Right-Left)/2),
608 Bottom+((Top-Bottom)/2),1,0));
629 struct prpty PrptyCopy;
673 struct prpty PrptyCopy;
688 ABox(Length,Width,
X,
Y,XDirection,YDirection)
689 long Length,Width,
X,
Y;
690 int XDirection,YDirection;
693 GenBox(stderr,Length,Width,X,Y,XDirection,YDirection);
702 if(XDirection == 1
And YDirection == 0){
705 XDirection,YDirection);
708 XDirection,YDirection);
716 struct p *Path,*Pair;
718 Left = X-(Length >> 1);
719 Right = X+(Length >> 1);
720 Bottom = Y-(Width >> 1);
721 Top = Y+(Width >> 1);
722 C = sqrt((
double)(XDirection*XDirection+YDirection*YDirection));
725 Pair->
pX = (Left*XDirection-Bottom*YDirection-
726 XDirection*X+YDirection*
Y)/C+X;
727 Pair->
pY = (Left*YDirection+Bottom*XDirection-
728 YDirection*X-XDirection*
Y)/C+Y;
731 Pair->
pX = (Left*XDirection-Top*YDirection-
732 XDirection*X+YDirection*
Y)/C+X;
733 Pair->
pY = (Left*YDirection+Top*XDirection-
734 YDirection*X-XDirection*
Y)/C+Y;
737 Pair->
pX = (Right*XDirection-Top*YDirection-
738 XDirection*X+YDirection*
Y)/C+X;
739 Pair->
pY = (Right*YDirection+Top*XDirection-
740 YDirection*X-XDirection*
Y)/C+Y;
743 Pair->
pX = (Right*XDirection-Bottom*YDirection-
744 XDirection*X+YDirection*
Y)/C+X;
745 Pair->
pY = (Right*YDirection+Bottom*XDirection-
746 YDirection*X-XDirection*
Y)/C+Y;
761 struct prpty PrptyCopy;
779 struct p *Path, *NewPath;
808 struct prpty PrptyCopy;
824 char Technology,Mask[];
841 if(
CDLayer[Layer].lTechnology == Technology
And 844 CDLayer[Layer].lMask[2] == Mask[2]){
856 if(
CDLayer[Layer].lTechnology ==
' ') {
890 if(sscanf(&(Text[1]),
"%s%ld%ld%s",Label,&X,&Y,
TypeOut) < 4)
898 sscanf(&(Text[1]),
"%s%ld%ld",Label,&X,&Y);
899 sprintf(
TypeOut,
"4 %s %d %d",Label,
907 elif(Text[0] ==
'2'){
908 sscanf(&(Text[1]),
"%s%ld%ld%d",Label,&X,&Y,&Layer);
914 sprintf(
TypeOut,
"4 %s %d %d",Label,
933 elif(Digit ==
'5' And (Text[0] <
'0' Or Text[0] >
'9')){
950 sscanf(&(Text[1]),
"%s%ld%ld%d",Label,&X,&Y,&Xform);
954 fprintf(stderr,
"Making label on layer %d\n",
CurrentLayer);
960 struct prpty PrptyCopy;
971 elif(Text[0] <
'0' Or Text[0] >
'9'){
974 while(Text[X] <=
' ') ++
X;
978 elif(Digit ==
'1' And (Text[0] <
'0' Or Text[0] >
'9')){
981 if(strcmp(
TypeOut,
"Array") == 0){
986 elif(Digit ==
'5' And (Text[0] <
'0' Or Text[0] >
'9')){
998 while((Text[i] <
'0' Or Text[i] >
'9')
And Text[i] !=
'\0') ++i;
1000 while(Text[i] >=
'0' And Text[i] <=
'9') ++i;
1002 while(Text[i] <=
' ' And Text[i] !=
'\0') ++i;
1003 size = strlen(&(Text[i])) + 2;
struct l CDLayer[CDNUMLAYERS+1]
int AWire(long Width, struct p *Path)
int ABeginCall(int SymbolNum)
#define PSTRIPWHITESPACE1
char(* dSymTabNames)[FILENAMESIZE]
int APolygon(struct p *Path)
int ABeginSymbol(int SymbolNum, long A, long B)
void ADeleteSymbol(int SymbolNum)
int ABox(long Length, long Width, long X, long Y, int XDirection, int YDirection)
char dSymbolName[FILENAMESIZE]
struct prpty * prpty_Succ
int ARoundFlash(long Width, long X, long Y)
int ALayer(char Technology, Mask)
void AComment(char *Text)
struct prpty * dPrptyList
int AUserExtension(char Digit, char *Text)