Bug 169672 - Make it possible to use WEB_UI_STRING macros to mark translatable strings in glib based ports
Summary: Make it possible to use WEB_UI_STRING macros to mark translatable strings in ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: Gtk
Depends on:
Blocks: 156974
  Show dependency treegraph
 
Reported: 2017-03-15 07:12 PDT by Carlos Garcia Campos
Modified: 2017-03-23 09:23 PDT (History)
4 users (show)

See Also:


Attachments
Patch (77.89 KB, patch)
2017-03-15 07:24 PDT, Carlos Garcia Campos
mcatanzaro: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos Garcia Campos 2017-03-15 07:12:26 PDT
WEB_UI_STRING macros are currently used by Cocoa based ports and Windows port. For other ports it simply returns the given string, but it's not translated. In the GTK+ port we have all translatable strings from LocalizedStrings.cpp copied in LocalizedStringsGtk.cpp to use the glib macros to mark them as translatable. In most of the cases the strings are exactly in the same, in some others (the context menu ones) the string only differs in the mnemonics used by GTK, and only in a few cases the strings are different. We could remove most of that duplication if strings used by WEB_UI_STRING were marked as translatable in glib based ports too.
Comment 1 Carlos Garcia Campos 2017-03-15 07:24:47 PDT
Created attachment 304498 [details]
Patch
Comment 2 Michael Catanzaro 2017-03-15 10:02:47 PDT
Comment on attachment 304498 [details]
Patch

Nice! Let's try it.
Comment 3 Carlos Garcia Campos 2017-03-22 02:56:07 PDT
Committed r214244: <http://trac.webkit.org/changeset/214244>
Comment 4 Piotr Drąg 2017-03-22 18:07:12 PDT
A lot of strings disappeared from the .pot file at https://l10n.gnome.org/module/webkit/ — I just want to make sure that’s intended.
Comment 5 Carlos Garcia Campos 2017-03-22 23:25:20 PDT
(In reply to Piotr Drąg from comment #4)
> A lot of strings disappeared from the .pot file at
> https://l10n.gnome.org/module/webkit/ — I just want to make sure that’s
> intended.

I would expect more, not less. How is that pot file generated? It's not from a webkit build for sure.
Comment 6 Piotr Drąg 2017-03-23 09:23:14 PDT
It’s probably using intltool, but I’m not sure. I’ve files a bug against damned-lies: https://bugzilla.gnome.org/show_bug.cgi?id=780458