#include "gw_wintools.h"#include "MALLOC.h"Include dependency graph for intOEMconvert.c:

Go to the source code of this file.
Functions | |
| int | C2F (sci_oemtochar) |
| int | C2F (sci_chartooem) |
| int C2F | ( | sci_chartooem | ) |
Definition at line 56 of file intOEMconvert.c.
References C2F, CheckLhs, CheckRhs, CreateVarFromPtr, cstk, FREE, GetRhsVar, GetType, IsWindowInterface(), LhsVar, m1, MALLOC, n1, NULL, putlhsvar(), and sci_strings.
00057 { 00058 static int l1,n1,m1; 00059 char *Output=NULL; 00060 00061 CheckRhs(1,1); 00062 CheckLhs(0,1); 00063 00064 if (GetType(1) == sci_strings) 00065 { 00066 char *Charstring=NULL; 00067 00068 GetRhsVar(1,"c",&m1,&n1,&l1); 00069 Charstring=cstk(l1); 00070 00071 Output=(char*)MALLOC((strlen(Charstring)+1)*sizeof(char)); 00072 #ifdef _MSC_VER 00073 if (IsWindowInterface()) 00074 { 00075 CharToOem(Charstring,Output); 00076 } 00077 else 00078 { 00079 wsprintf(Output,"%s",Charstring); 00080 } 00081 #else 00082 sprintf(Output,"%s",Charstring); 00083 #endif 00084 } 00085 else 00086 { 00087 Scierror(999,"parameter must be a string."); 00088 return 0; 00089 } 00090 00091 n1=1; 00092 CreateVarFromPtr( 1, "c",(m1=(int)strlen(Output), &m1),&n1,&Output); 00093 LhsVar(1) = 1; 00094 C2F(putlhsvar)(); 00095 if (Output) {FREE(Output);Output=NULL;} 00096 return 0; 00097 }
Here is the call graph for this function:

| int C2F | ( | sci_oemtochar | ) |
Definition at line 13 of file intOEMconvert.c.
References C2F, CheckLhs, CheckRhs, CreateVarFromPtr, cstk, FREE, GetRhsVar, GetType, IsWindowInterface(), LhsVar, m1, MALLOC, n1, NULL, putlhsvar(), and sci_strings.
00014 { 00015 static int l1,n1,m1; 00016 char *Output=NULL; 00017 00018 CheckRhs(1,1); 00019 CheckLhs(0,1); 00020 00021 if (GetType(1) == sci_strings) 00022 { 00023 char *OEMstring=NULL; 00024 00025 GetRhsVar(1,"c",&m1,&n1,&l1); 00026 OEMstring=cstk(l1); 00027 00028 Output=(char*)MALLOC((strlen(OEMstring)+1)*sizeof(char)); 00029 #ifdef _MSC_VER 00030 if (IsWindowInterface()) 00031 { 00032 OemToChar(OEMstring,Output); 00033 } 00034 else 00035 { 00036 wsprintf(Output,"%s",OEMstring); 00037 } 00038 #else 00039 sprintf(Output,"%s",OEMstring); 00040 #endif 00041 } 00042 else 00043 { 00044 Scierror(999,"parameter must be a string."); 00045 return 0; 00046 } 00047 00048 n1=1; 00049 CreateVarFromPtr( 1, "c",(m1=(int)strlen(Output), &m1),&n1,&Output); 00050 LhsVar(1) = 1; 00051 C2F(putlhsvar)(); 00052 if (Output) {FREE(Output);Output=NULL;} 00053 return 0; 00054 }
Here is the call graph for this function:

1.5.1