Text Dictionaries

 

RC-WinTrans supports the use of (simple) text files as dictionaries where the format of the content follows a set of given rules, namely the first line is used to specify the dictionary's languages and the subsequent lines contain the dictionary data (see figure below).

 

Formatting

The first line of the text file must contain a tab-separated list of the languages used in the file.  The languages are coded according to ISO-639.  You may either use the short two-letter form, e.g., "en," or a combination of language and country code, e.g., "en-us."

 

Each subsequent line in the file holds a tab-separated list of dictionary items.  The language order must be in the same order as in the first line (languages specification) of the file.

 

Each entry in the file must be written in quotation marks.  This is meant to enhance the software to also work with text files that only use the tab character.

 

 

Figure:  The first six lines of a sample text dictionary combining two languages.  The languages are specified in the first line: "en-uk" for English (UK) and "fr" for French.

"en-uk"              "fr"
"Abort"              "Abandonner"
"About"              "À propos de"
"About..."           "À propos de..."
"Absolute Position"  "Position absolue"
"Accelerator"        "Raccourci"

 

 

Language Pairs

The languages do not need to be stored in any particular order- RC-WinTrans only verifies the existence of a desired language pair in a text dictionary before using it.

 

 

Saving Data to a Text File

When saving or exporting translations to a text file, the translations will be appended to the file. However, if RC-WinTrans finds that the file already contains a line with exactly the same combination of texts, that translation will not be exported.  This is done to avoid double entries.

 

 

Technical Requirements

Text files that are to be used as dictionaries in RC-WinTrans need to match the following technical conditions:

·

The file must be encoded either as ANSI or Unicode UTF-16-LE.

·

Each entry must be set in quotation marks ("...").  If an item contains quotation marks itself, each single quotation mark of the original text must appear as two consecutive quotation marks in the text file.

 

 

Related topics...