TextEdit to TMX!!!

I've just adapted my 'Excel to TMX' script so that it works with a number of files opened in TextEdit windows instead.


Use case:

  • you have contents in a number of languages, and the contents are aligned (i.e. each line is a language variation of the lines at the same position in the other files)
  • you want to use all that in OmegaT, or any other TMX supporting tool
  • so you want to glue all that into a nice and simple TMX
  • but you also don't want to use Excel, because it's too cumbersome, or because the data has quotation marks that Excel interprets as


  1. Copy one language content in a file, the other language in another file (in a different window), etc. The documents do not have to be saved or named. Just create new windows as necessary and paste your contents.
  2. Run the script
  3. It will ask you for the language of the contents in the first window, then in the second window, etc.
  4. Use valid TMX language codes there, because the strings you enter will be the ones used in the TMX
  5. The script displays a progression dialog,
    and at the end, boom, the TMX is created on your Desktop with a timely name like this: TextEdit2tmx_20211219T071214Z.tmx

I've run it with ~ 500 segments in 2 windows (2 languages) and it took me about 5 seconds to create the TMX. It does not really seem to matter how many characters there are in the documents. What seems to matter is the number of lines (segments), and windows.

Also, the segmentation is exactly one segment per line. So you just create a TMX from contents that's segmented and you know is aligned.

"OmegaT Code Reading Sessions", Part 4 !

Are you scared of being bored today ?

The "OmegaT Code Reading Sessions" offer an exciting opportunity to spend one hour of your life trying to make sense of OmegaT's Java code…

Today is the 4th session. It will take place somewhere on a Jitsi instance, at 9pm Tokyo Time.

It's nicer (but not required) if:

  • you're interested in OmegaT
  • you're not scared of reading code, even if that does not make any sense to your current self

You still want to join ?

Popular posts (last 30 days):