After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 548950 - Uses of C++ strings and iostreams not good for translation
Uses of C++ strings and iostreams not good for translation
Status: RESOLVED FIXED
Product: ekiga
Classification: Applications
Component: general
GIT master
Other All
: Normal trivial
: ---
Assigned To: Snark
Ekiga maintainers
Depends on:
Blocks:
 
 
Reported: 2008-08-22 05:10 UTC by Theppitak Karoonboonyanan
Modified: 2008-08-24 16:54 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Theppitak Karoonboonyanan 2008-08-22 05:10:04 UTC
C++ string concatenation and iostream seem to be heavily used in Ekiga trunk. This can cause translation problems due to strictness to English grammar.

For what I have found so far:

(1)

#: lib/engine/addressbook/evolution/evolution-book.cpp:88
#: lib/engine/addressbook/ldap/ldap-book.cpp:591
msgid "user found"
msgid_plural "users found"

source:
  std::stringstream strm;
  strm << nbr;
  status = std::string (strm.str ()) + " " + std::string (ngettext ("user found", "users found", nbr));

This makes it difficult to translate into Thai, for example, where passive voice is considered weird. It needs to be translated like "พบผู้ใช้ %d คน" (literally "found %d user(s)") instead. Using plain C format string should be preferred here.

(2)

#: src/gui/main.cpp:722
msgid "Connected with"

source:
  info << _("Connected with") << " " << call.get_remote_party_name ();

This can be problematic for languages without tenses of verbs like Thai. Certain word needs to be added after the object to indicate tense instead, like "เชื่อมต่อกับ %s แล้ว" (literally "Connected with %s already").

(3)
#: src/gui/main.cpp:1121
msgid "added video input device "

Same problem as (2)

(4)

#: src/gui/main.cpp:1134
msgid "removed video input device "

Same problem as (2)

(5)

#: src/gui/main.cpp:1235
msgid "added audio input device "

Same problem as (2)

(6)

#: src/gui/main.cpp:1251
msgid "removed audio input device "

Same problem as (2)

(7)

#: src/gui/main.cpp:1345
msgid "added audio output device "

Same problem as (2)

(8)

#: src/gui/main.cpp:1360
msgid "removed audio output device "

Same problem as (2)

Note that all problems above can be solved by using C format strings instead.

I'm not sure which version of Ekiga will be shipped with GNOME 2.24. In case it's not trunk, this report may be premature. But it should be good to raise it early, before similar C++ mechanisms are adopted more widely in the project.
Comment 1 Snark 2008-08-22 07:44:11 UTC
The version shipped with gnome 2.24 should be 3.00, which is current trunk, so your report isn't premature.

In fact, a precise report with a list of occurrences of the problem is a great report : thanks!
Comment 2 Theppitak Karoonboonyanan 2008-08-22 08:29:40 UTC
I was not sure about the shipped version because current gnome-2.24 moduleset for jhbuild checks out gnome-2-22 branch, while Damed Lies lists PO from HEAD. So, if 3.00 is to be shipped, should jhbuild be updated?
Comment 3 Damien Sandras 2008-08-22 09:05:10 UTC
Yes, we should make a release soon.

Julien, can you take care of this bug ? Or perhaps Jan ?

I won't have the time.
Comment 4 Snark 2008-08-22 09:46:38 UTC
I assigned it to myself, and I'm almost ready fixing it.
Comment 5 Snark 2008-08-22 10:09:00 UTC
I fixed all reported issues, and found one or two others.
Comment 6 Theppitak Karoonboonyanan 2008-08-23 14:40:16 UTC
Many thanks for fixing them and more. However, case (5) above is still not fixed:

#: src/gui/main.cpp:1366
msgid "added audio output device "

Reopened the bug.
Comment 7 Theppitak Karoonboonyanan 2008-08-23 14:41:44 UTC
(In reply to comment #6)
> Many thanks for fixing them and more. However, case (5) above is still not
> fixed:

Oops, I meaned case (7).
Comment 8 Snark 2008-08-23 16:44:05 UTC
Oh!?
Comment 9 Snark 2008-08-24 16:54:48 UTC
Eh, I missed it because it only does std::string "arithmetic" and not std::stringstream, which I was looking for!

In any case, done. Don't hesitate to open a new bug if you ever find something like this again!