Please note that this procedure no longer applies since version 5 of memoQ, which allows to open, translate and export TXML files directly.
(Updated on 2010-09-24 with some corrections, new filters and procedures for pretranslated files, and simplified procedure)
We sometimes receive files that have been processed using the latest version of WordFast Pro. These are recognizable from the .txml extension.
This format is just a specific XML structure, and as such it should be possible to translate the files using MemoQ after formatting them properly. Here is a simple workflow that will allow you to process the files in memoQ.
1. Copy the source segments to the target column
There are three possible situations:
|1.a. There are only a few files in the project and you do not need to preserve any 100% pretranslated segments found in the source Wordfast files||1.b. No matter how many files are in the project, you want to preserve any 100% translated segments contained in the Wordfast files by masking them out in memoQ||1.c. For projects including many files, perform a batch search/replace (caveat: you will lose any 100% translated segments contained in your Wordfast files)|
|In this case, open each file in Wordfast and use the keyboard shortcut ctrl-shift-insto copy the source segments to the target column by overwriting all target segments, no matter what their status is.
If there are any translated segments in the file, they will be overwritten. Save and close the files, and proceed to step 2.
|In this case you will have to open every file and confirm every segment with Wordfast’s shortcut ALT-down arrow. There are some prerequisites:
In the Wordfast preferences, go to Translation Memory and enable Copy source on no match.
To prevent Wordfast’s sluggish UI from slowing you down, make sure the outline is off (Window > Show view > Outline)
Once you have completed the prerequisites above, place the cursor in the first segment of your Wordfast file and press and hold ALT-down arrow until you have scrolled through the whole file. Save and close the files, and proceed to step 2.
|Open the .txml file using the jEdit text editor. Click here to go to the download page. It is important to use this editor because it allows for a very simple search/replace syntax that takes care of “greedy” wildcards. You can obtain the same results using a different editor, but the syntax to use might be different.
After opening the file in JEdit, place the cursor at the top and choose Search > Find…
In the Search for field, insert the string below (be careful not to add superfluous spaces if copying from this page):
In the Replace with field, insert the following string:
Click on Replace All, save the file and quit jEdit. Proceed to step 2.
2. Open the modified file in memoQ
- First perform a quick check by opening the file you just saved with Wordfast. Now the target column should be identical to the source column, tags included. The total number of segments should be identical to the value you saw when you first opened the file in Wordfast. After checking this, you can open the file in memoQ.
- Add the .xml extension to the file name (e.g. filename.txml.xml), since memoQ likes this better.
- Open memoQ and create a new project. Call it for instance “Wordfast”, so you can re-use it easily for subsequent projects that involve translating WordFast files.
- Go to Translations > Add document as…
- Select the file with .XML extension and open it.
- The Document import settings window is displayed.
If you followed procedure 1.a or 1.c (no preservation of pretranslated material) download this MemoQ XML definition file (right click, Save As).
If you followed procedure 1.b above (preservation of pretranslated material) download this MemoQ XML definition file (right click, Save As).
- Click on the … on top to import the file downloaded in sub-step 6 above.
- Click OK at the bottom of the window. The window closes and the file is imported.
- Open the file in memoQ. memoQ should have inserted the any tags in the correct positions corresponding to the tags contained in WordFast. If you followed procedure 1.b (preservation of pretranslated material), the 100% translated segments contained in the original Wordfast files are hidden. They should however be restored when exporting from memoQ.
- Translate the file normally.
- When ready, export it with Export (dialog)
3. Check the translated file in Wordfast
- Restore the .txml extension and open the translated file in Wordfast. You should get no error messages. Check that the total number of segments is identical to the original files, check the tag positions, etc.
- Make one simple modification in the file with Wordfast (e.g. add and delete a space), and save the file. This step will rewrite some specific Wordfast headers and guarantees compatibility.