#include "rldefine.h"
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <windows.h>
#include "rlinifile.h"
#include "rlcutil.h"
Go to the source code of this file.
|
int | rlSetTranslator (const char *language, const char *inifile) |
|
static const char * | fixquote (const char *text, char **mytext) |
|
const char * | rltranslate (const char *txt, char **mytext) |
|
const char * | rltranslate2 (const char *section, const char *txt, char **mytext) |
|
static const char* fixquote |
( |
const char * |
text, |
|
|
char ** |
mytext |
|
) |
| |
|
static |
Definition at line 519 of file rlinifile.cpp.
{
if(strchr(text,'\\') == NULL) return text;
int len = strlen(text);
if(*mytext != NULL) delete [] *mytext;
*mytext = new char[len+1];
char *temp = *mytext;
int i2 = 0;
for(int i=0; i<len; i++)
{
if (text[i] == '\\' && text[i+1] == '=') { temp[i2] = '='; i++; }
else if(text[i] == '\\' && text[i+1] == 'n') { temp[i2] = '\n'; i++; }
else if(text[i] == '\\' && text[i+1] == 't') { temp[i2] = '\t'; i++; }
else if(text[i] == '\\' && text[i+1] == '\\') { temp[i2] = '\\'; i++; }
else { temp[i2] = text[i]; }
i2++;
}
temp[i2] = '\0';
return temp;
}
int rlSetTranslator |
( |
const char * |
language, |
|
|
const char * |
inifile |
|
) |
| |
Definition at line 508 of file rlinifile.cpp.
{
if(inifile != NULL)
{
}
return 0;
}
const char* rltranslate |
( |
const char * |
txt, |
|
|
char ** |
mytext |
|
) |
| |
const char* rltranslate2 |
( |
const char * |
section, |
|
|
const char * |
txt, |
|
|
char ** |
mytext |
|
) |
| |
const char null_string[] = "" |
|
static |