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 307756 - fix internationalization of gimppropwidgets
fix internationalization of gimppropwidgets
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: Internationalisation
git master
Other Linux
: Normal normal
: 2.4
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2005-06-15 12:05 UTC by Jean-Luc Coulon
Modified: 2005-06-26 18:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch to implement the simple solution (32.98 KB, patch)
2005-06-16 13:05 UTC, Sven Neumann
none Details | Review

Description Jean-Luc Coulon 2005-06-15 12:05:41 UTC
Distribution/Version: Debian Sid

Select the preference dialog
Select an entry where there is a checkbox
(i.e. pictures window == "Fenêtre d'images" in French)
Move the mouse over an iter
(i.e. Resize the window after a zoom == "Redimensionner la fenêtre après un zoom")

The tootip: "When enabled, the image window..." is displayed in ENglish language
even if it is translated in the fr.po file

Regards

Jean-Luc
Comment 1 Sven Neumann 2005-06-16 08:52:25 UTC
Yes, this still needs to be fixed after the move of gimppropwidgets.c to
libgimpwidgets. In libgimpwidgets gettext() is redefined to dgettext. So we are
looking up the strings in the wrong translation domain.
Comment 2 Sven Neumann 2005-06-16 12:34:02 UTC
The easiest way to change this is to change N_() to _() in
app/config/gimprc-blurbs.h and to remove the calls to gettext() from
gimppropwidgets.c. The problem with this approach is that we want the
autogenerated gimprc manpage and the automatically documented systemwide gimprc
file to be in english, no matter what locale was used when compiling gimp. It
should be trivial to ensure that, we just need to fiddle with the locale when
creating these files.

Any better suggestions, anyone?
Comment 3 Michael Natterer 2005-06-16 12:54:50 UTC
A general solution for the propwidgets would be to attach the translation
domain to the object the properties belong to, we could even use the
existing gimp_type_set_translation_domain() API from libgimpbase.
Comment 4 Sven Neumann 2005-06-16 13:05:57 UTC
Created attachment 47856 [details] [review]
patch to implement the simple solution
Comment 5 Sven Neumann 2005-06-18 12:45:27 UTC
Adding gimp_type_set_translation_domain (type, GETTEXT_PACKAGE); for each and
every type that registers a paramspec with translatable blurb seems rather
error-prone since it is easy to forget. Could this be automated somehow? Perhaps
by changing the GIMP_CONFIG_INSTALL_PROP macros?
Comment 6 Sven Neumann 2005-06-26 18:09:51 UTC
Actually, it isn't all that complicated. Mitch and me had the idea on how to fix
this last night over a few beers...

2005-06-26  Sven Neumann  <sven@gimp.org>

	* libgimpwidgets/gimppropwidgets.c: use dgettext() instead of
	gettext() and try to obtain the translation domain from the type.
	Fixes i18n of tooltips on property widgets (bug #307756).

	* libgimpconfig/gimpcolorconfig.c: set a translation domain.