On Thu, 2017-07-13 at 12:54 +0300, Mihkel Tõnnov wrote: > Hi Caolán, *, > > 2017-07-13 12:43 GMT+03:00 Caolán McNamara <caol...@redhat.com>: > > > [snip] > > In our code I've autogenerated matching initial contexts for the > > matching .ui and .hrc source strings. > > > > Could you clarify what do you mean by that?
I'll take a pair of real examples: Currently a .hrc/.src entry of SV_APP_CPUTHREADS //in vcl/inc/svids.hrc #define SV_APP_CPUTHREADS 10800 //in vcl/source/src/app.src String SV_APP_CPUTHREADS { Text [en-US] = "CPU threads: "; }; corresponding .po entry where the msgctxt is currently autogenerated on extraction from .src to .po msgctxt "" "app.src\n" "SV_APP_CPUTHREADS\n" "string.text" msgid "CPU threads: " msgstr "something or other" turns into //in our source where the 1st arg is the context and all existing //entries contexts are simply derived from the define name #define SV_APP_CPUTHREADS NC_("SV_APP_CPUTHREADS", "CPU threads: ") corresponding .po entry msgctxt "SV_APP_CPUTHREADS" msgid "CPU threads: " msgstr "something or other" and the msgctxt is no longer generated on export to .po just taken from the source entry The other case is .ui entries, they go from e.g. //vcl/uiconfig/ui/printdialog.ui <property name="label" translatable="yes">Options</property> with a .po entry of msgctxt "" "printdialog.ui\n" "label21\n" "label\n" "string.text" msgid "Options" msgstr "Optionen" where the msgctxt is similarly autogenerated on export to .po to... //vcl/uiconfig/ui/printdialog.ui <property name="label" translatable="yes" context="printdialog|label21">Options</property> where the context/msgctxt for existing strings has been one-time derived from the .ui filename and widget/object the string belong to with a corresponding .po entry of msgctxt "printdialog|label21" msgid "Options" msgstr "Optionen" _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice