GT4T knowledge base

File Translator Advanced Options

Jump to Section

Under the File Translator screen, click Options-> Advanced Options to open the advanced options config file.

On the File Translator Options page, click Advanced options in the lower right corner to open the Advanced Settings file.

Advanced Options

The advanced settings file is in json format. Supported parameters are.

Parameter names Value types Default value Sample Explanation
FTSaveSummary Boolean false "FTSaveSummary": true, Whether to record information such as the number of translated characters in the file, the record file is C:\Users\windows userName\AppData\Local\gt4t.net\User Data\Default\summary.json
FTCopyToFolder Object {"replace": "", "with": ""} "FTCopyToFolder": {"replace": "/en/", "with": "/zh-cn/"} Copy the translated file to the specified directory, e.g. if the original file is in the d:\en\files\directory, the translated file will be copied to the d:\zh-cn\files\directory
FTUntranslatedFolder String "" "FTUntranslatedFolder","zh-cn" Do not translate files in ‘zh-cn’ folder when translating folders
FTExtensions Array [] "FTExtensions": [".docx", ".md", ".sdlxliff"] When translating folders, only the files with the specified file extension are translated
FTAutoClose Boolean false "FTAutoClose": true Automatically close the file translator after files are translated
FTIncludeFilter Regular Expression "" "FTIncludeFilter":"en-(gb|us)" Folder translation only translates files in paths containing en-gbor en-us
FTExcludeFilter Regular Expression "" "FTExcludeFilter":"en-(gb|us)" Folder translation does not translate files in paths containing en-gbor en-us
FTFolderRecursive Boolean true "FTFolderRecursive": true ‘true’ translates files in subfolders.
FTDoNotTranslate An array of regular expressions [{"exp": "", "flag":""}] [{"exp": "^.*?-", "flag":"gm"}, {"exp": "^.*?#", "flag":"gm"}] Do not translate matching content, e.g. do not translate lines starting with ‘-’ or ‘#’
FTTxtTranslateOnly An array of regular expressions [{"exp": "", "flag":""}] [{"exp": "label \\= '(?<content>.*?)'", "flag":"mg"}, {"exp": "label \\= \"(?<content>.*?)\"", "flag":"mg"}] When translating plain text files, only the captured group named “content” is translated. For the example, if a .lua file contains label = "Visual Upgrades" or label = 'License Plate', Visual Upgrades and License Plate will be translated.
FTCountOnly Boolean false "FTCountOnly": true ‘true’: count chars of a file only without actual translation

Attention If an escape is needed in a regular expression, then \\ should be used. Special symbols such as . must be escaped to represent the symbol itself. For example, to represent .markdown, the regular expression needs to be written as \\.markdown.

Confused? No problem, if you have special needs, please contact me, I will help you to write the configuration.