Hello everybody.
My name is Jean-Christophe Helary,
and today I’m going to talk about
Emacs manuals translation and OmegaT.
Thank you for joining the session.
Translation in the free software world
is really a big thing. You already know
that most of the Linux distributions,
most of the software packages,
most of the websites
are translated by dozens of communities
using different processes
and file formats.
Translation and localization
are things we know very well.
It’s a tad different
for the Emacs community.
We do not have a localization process
because it’s quite complex
and because we don’t
have the resources yet.
Still, we could translate the manuals,
and translating the manuals
would probably bring a lot of good
to the Emacs community at large.
So what’s the state of the manuals?
As of today, we have 182 files
coming in .texi and .org format.
We’ve got more than 2 million words.
We’ve got more than
50 million characters.
So that’s quite a lot of work,
and obviously, it’s not a one person job.
When we open .texi files,
what do we have?
Well, we actually have a lot of things
that the translators
shouldn’t have to translate.
Here we can see that only
the very last segment,
the very last sentence
should be translated.
All those meta things
should not be under
the translator’s eyes.
How do we deal with this situation?
For code files, we have
the gettext utility that converts
all the translatable strings
into a translatable format,
which is the .po format.
And that .po format is ubiquitous,
even in the non-free
software translation industry.
For documentation,
we have something different.
It’s called po4a,
which is short for ‘po for all’.
When we use po4a
on those 182 .texi and .org files,
what do we get?
We get something that’s much better.
Now we have three segments.
It’s not perfect because,
as you can see,
the two first segments
should not be translated.
So there’s still
room for improvement.
Now, when we put that file set
into OmegaT, we considerably reduce
the words total.
We now have 50% fewer words
and 23% fewer characters to type,
but that’s still a lot of work.
So let’s talk about OmegaT now
and see where it can help.
OmegaT is a GPL3+ Java8+
Computer Aided Translation tool.
We call them CATs.
CATs are to translators
what IDEs are to programmers.
They leverage the power of computers
to automate our work,
which is, reference searches,
fuzzy matching, automatic insertions,
and things like that.
OmegaT is not really recent.
It will turn 20 next year,
and at this point,
we have about 1.5 million downloads
from the SourceForge site,
which doesn’t mean much
because that includes
files used for localization
and manuals, but still
it’s a pretty big number.
OmegaT is included in
a lot of Linux distributions,
but as you can see here,
it’s mostly downloaded on Windows systems
because translators
mostly work on Windows.
OmegaT comes with a cool logo
and a cool site too,
and I really invite you to visit it.
It’s omegat.org, and you’ll see
all the information you need,
plus downloads to Linux versions,
with or without Java included.
So what does OmegaT bring to the game?
Professional translators have to deliver
fast, consistent,
and quality translations,
and we need to have proper tools
to achieve that.
I wish po-mode was part of the toolbox,
but that’s not the case,
and it’s a pity.
So we have to use those CAT tools.
Let me show you what OmegaT looks like
when I open this project that I created
for this demonstration.
The display is quite a mouthful,
but you can actually modify
all windows as needed.
I just want to show you
everything at once
to give you a quick idea of the thing.
You have various colors, windows,
and all those spaces
have different functions
that help the translator,
and that you’re probably
not familiar with.
I’m going to introduce you
to the interface now.
So first, we have the editor.
The editor comes in two parts:
the current segment,
which is associated to a number,
and all the other segments,
above or below.
At the top of the window,
you can see the first three segments
that were in the .po file.
The last one here, the fourth one, comes
with an automatic fuzzy match insertion.
Such legacy translations are what we
call ‘translation memories’.
OmegaT has inserted this one automatically
because I told it to do so,
and for my security, it comes with
the predefined fuzzy prefix
that I will have to remove
to validate the translation.
Our next feature is the glossary feature.
In this project,
we have a lot of glossary data.
Some is relevant and some is not.
In the segment that I’m translating
at the moment, you can see
underlined items.
This pop-up menu on the right
allows me to enter the terms as I type.
It’s kind of an auto insertion system
that also supports history predictions,
predefined strings, and things like that.
In the part on the right,
we have reference information
that comes directly from
the .po and .texi files.
We also have notes that I can share
with fellow translators,
and we have numbers that tell me
that I still have 143 000 segments more to go
before I complete this translation.
As we see, there are plenty of strings
that we really don’t want to have to type.
For example, those strings
are typical .texi strings
that the translator
should really not have to type.
So we’re going to have to
do something about that.
we’re going to have to create
protected strings
with regular expressions,
so that the strings can be visualized
right away in the source segment,
entered semi-automatically
in the target segment,
and checked for integrity.
The regular expression I came up with
for defining most of the strings
is this one,
and I’m not a regular expression pro
so I’m sure some of you will correct me.
But this expression gives me
a good enough definition
even though it does not yet include
Org mode syntax.
So now we have all those
.texi specific things
that we don’t want to touch
displayed in gray.
Actually, you may have noticed
that I cheated a bit,
because here I added the years
and the Free Software Foundation name
to the previous regular expression
to show you that you can protect
any kind of string, really.
So what we have now
is a way to visualize the strings
that we do not want to touch,
but we still have to enter all of them
in the translation.
For that, we have the pop-up menu
that I used earlier with the glossary,
and we also have items
in the edit menu
that come with shortcuts
for easy insertion of missing tags.
Last, but certainly not least,
we can now validate our input.
Here, OmegaT properly tells me
that I missed 7 protected strings,
I entered only 1998,
but there were five different years,
the copyright string,
and the FSF name string.
With all this almost native
Texinfo support,
we have much less things to type,
and there is a much lower
potential for errors.
But we agree, it’s still a lot of work.
What we’d like now
is to work with fellow translators,
and here we need to know
that OmegaT is actually
a hidden svn/git client,
and team projects can be hosted
on svn/git platforms.
Translators don’t need to
know anything about VCS.
They just need access credentials,
and OmegaT commits for them.
This way we do not have to use
ugly and clumsy web-based
translation interfaces,
and we can use a powerful
offline professional tool.
So this is how it looks
when you look at the platform
where I hosted this project.
The last updates are from
20 days and 30 seconds ago
when I created this slide,
and you can see that I had a partner
who worked with me on the same file set.
Although it looks like
we actually committed the translation
to the platform,
it was not us, but OmegaT.
OmegaT does all the heavy-duty work.
It regularly saves to
and syncs from the servers.
Translators are regularly kept updated
with work from fellow translators,
and when necessary,
OmegaT offers a simple
conflict-resolution dialogue.
Translators never have to do anything
with svn or git ever.
And now we can envision a future
not so far away
where the manuals will be translated
and eventually included
in the distribution,
but that’s a topic
for a different presentation.
So we’ve reached the end of this session.
Thank you very much again for joining it.
There are plenty of topics
I promised I would not address,
and I think I kept my promise.
There will be a Q&A now,
and I also started
a thread about this talk
on Reddit last Saturday.
You can find me on the emacs-help
and emacs-devel lists as well,
so don’t hesitate to send me
questions and remarks.
Thank you again, and see you around.