version 1.3, 1999/11/18 23:57:19 |
version 1.5, 2000/01/25 05:07:11 |
|
|
/*$OpenXM$*/ |
/*$OpenXM: OpenXM/src/kan96xx/plugin/cmo.c,v 1.4 1999/11/27 01:41:11 takayama Exp $*/ |
#include <stdio.h> |
#include <stdio.h> |
#include <string.h> |
#include <string.h> |
/* #include <netinet/in.h> */ |
/* #include <netinet/in.h> */ |
Line 37 int CmoClientMode = 1; /* This flag is used to transl |
|
Line 37 int CmoClientMode = 1; /* This flag is used to transl |
|
**************************************************************************/ |
**************************************************************************/ |
/* If you change the format of mathcap, do the follows. |
/* If you change the format of mathcap, do the follows. |
Mofify cmoCheckMathCap in oxmisc2.c, |
Mofify cmoCheckMathCap in oxmisc2.c, |
oxReq, SM_setMathCap:, and |
oxSendMathCap in oxmisc.c, |
|
newMathCap in cmo.c, |
|
oxReq, SM_setMathCap: in oxmisc2.c, and |
grep mathCap and make all modifications. |
grep mathCap and make all modifications. |
*/ |
*/ |
|
|
Line 1318 struct object newMathCap(struct mathCap *mathcap){ |
|
Line 1320 struct object newMathCap(struct mathCap *mathcap){ |
|
struct object ob3; |
struct object ob3; |
struct object obOx; |
struct object obOx; |
struct object obSm; |
struct object obSm; |
|
struct object ob3tmp; |
struct object *obp; |
struct object *obp; |
int i; |
int i,j; |
struct object mathinfo; |
struct object mathinfo; |
|
|
rob = newObjectArray(3); |
rob = newObjectArray(3); |
Line 1329 struct object newMathCap(struct mathCap *mathcap){ |
|
Line 1332 struct object newMathCap(struct mathCap *mathcap){ |
|
for (i=0; i<getoaSize(mathinfo); i++) { |
for (i=0; i<getoaSize(mathinfo); i++) { |
putoa(ob1,i,getoa(mathinfo,i)); |
putoa(ob1,i,getoa(mathinfo,i)); |
} |
} |
ob2 = newObjectArray(mathcap->n); |
ob3 = newObjectArray(mathcap->oxSize); |
for (i=0; i<mathcap->n; i++) { |
|
putoa(ob2,i,KpoInteger((mathcap->cmo)[i])); |
|
} |
|
obOx = newObjectArray(mathcap->oxSize); |
|
for (i=0; i<mathcap->oxSize; i++) { |
for (i=0; i<mathcap->oxSize; i++) { |
putoa(obOx,i,KpoInteger((mathcap->ox)[i])); |
ob3tmp = newObjectArray(2); |
|
putoa(ob3tmp,0,KpoInteger((mathcap->ox)[i])); |
|
ob2 = newObjectArray(mathcap->n); |
|
for (j=0; j<mathcap->n; j++) { |
|
putoa(ob2,j,KpoInteger((mathcap->cmo)[j])); |
|
} |
|
putoa(ob3tmp,1,ob2); |
|
putoa(ob3,i,ob3tmp); |
} |
} |
ob3 = newObjectArray(2); |
|
putoa(ob3,0,obOx); |
|
putoa(ob3,1,ob2); |
|
|
|
obSm = newObjectArray(mathcap->smSize); |
obSm = newObjectArray(mathcap->smSize); |
for (i=0; i<mathcap->smSize; i++) { |
for (i=0; i<mathcap->smSize; i++) { |
Line 1386 void *KSmathCapByStruct(void) |
|
Line 1389 void *KSmathCapByStruct(void) |
|
putoa(ob,1,KpoString(sys)); |
putoa(ob,1,KpoString(sys)); |
putoa(ob,2,KpoString(sysVersion)); |
putoa(ob,2,KpoString(sysVersion)); |
s1 = getenv("HOSTTYPE"); |
s1 = getenv("HOSTTYPE"); |
|
if (s1 == NULL) s1="unknown"; |
s2 = (char *)sGC_malloc(strlen(s1)+2+strlen("HOSTTYPE=")); |
s2 = (char *)sGC_malloc(strlen(s1)+2+strlen("HOSTTYPE=")); |
strcpy(s2,"HOSTTYPE="); |
strcpy(s2,"HOSTTYPE="); |
strcat(s2,s1); |
strcat(s2,s1); |