=================================================================== RCS file: /home/cvs/OpenXM/src/kxx/ox_texmacs.c,v retrieving revision 1.38 retrieving revision 1.40 diff -u -p -r1.38 -r1.40 --- OpenXM/src/kxx/ox_texmacs.c 2015/10/10 11:29:46 1.38 +++ OpenXM/src/kxx/ox_texmacs.c 2016/08/24 22:38:12 1.40 @@ -1,4 +1,4 @@ -/* $OpenXM: OpenXM/src/kxx/ox_texmacs.c,v 1.37 2015/10/08 11:49:38 takayama Exp $ */ +/* $OpenXM: OpenXM/src/kxx/ox_texmacs.c,v 1.39 2016/03/31 05:27:34 takayama Exp $ */ #include #include @@ -28,32 +28,38 @@ #define GENERIC 0 /* DEBUG, xml */ #define V_TEXMACS 1 #define V_CFEP 2 +#define V_QFEP 3 int View = V_TEXMACS ; char *Data_begin_v[] = { "", "\002verbatim:", "\002", + "" }; char *Data_begin_l[] = { "", "\002latex:", - "\002latex:" + "\002latex:", + "" }; char *Data_begin_p[] = { "", "\002prompt:", - "\002prompt:" + "\002prompt:", + "" }; char *Data_begin_ps[] = { "", "\002ps:", - "\002ps:" + "\002ps:", + "" }; char *Data_end[] = { "", "\005", - "\n\005" /* \n is not a part of the protocol. */ + "\n\005", /* \n is not a part of the protocol. */ + "" }; /* todo: start_of_input */ @@ -61,7 +67,8 @@ char *Data_end[] = { char End_of_input[] = { 0x5, /* Use ^E and Return to end the input. */ '\n', /* TEXMACS_END_OF_INPUT. 0xd should be used for multiple lines. */ - 0x5 /* CFEP_END_OF_INPUT */ + 0x5, /* CFEP_END_OF_INPUT */ + 0x5 }; /* Table for the engine type. */ @@ -155,6 +162,8 @@ main(int argc,char *argv[]) { View = V_TEXMACS; }else if (strcmp(argv[i],"cfep")==0) { View = V_CFEP; setDefaultParameterForCfep(); + }else if (strcmp(argv[i],"qfep")==0) { + View = V_QFEP; setDefaultParameterForCfep(); }else{ View = GENERIC; /* printv("Unknown view type.\n"); */ @@ -216,8 +225,8 @@ main(int argc,char *argv[]) { if (LanguageResource != NULL) KSexecuteString(LanguageResource); startEngine(TM_Engine," "); - if (signal(SIGINT,SIG_IGN) != SIG_IGN) { - signal(SIGINT,ctrlC); + if (mysignal(SIGINT,SIG_IGN) != SIG_IGN) { + mysignal(SIGINT,ctrlC); } irt = 0; @@ -230,8 +239,8 @@ main(int argc,char *argv[]) { RestrictedMode = RestrictedMode_saved; } Calling_ctrlC_hook = 0; - if (signal(SIGINT,SIG_IGN) != SIG_IGN) { - signal(SIGINT,ctrlC); + if (mysignal(SIGINT,SIG_IGN) != SIG_IGN) { + mysignal(SIGINT,ctrlC); } irt = 1; continue;