summaryrefslogtreecommitdiff
path: root/solenv/bin/hrcex
AgeCommit message (Collapse)Author
2021-03-31python3-ify hrcex & uiex (creation of pot files)Christian Lohmaier
Change-Id: I824c9ed536a1e852d6bd157fbd7d4766327b7bcd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113319 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-08-07hrcex operates on .hrc filesCaolán McNamara
Change-Id: I0841c2d99a00b6b18e3dc4baca2b4bb48ab5b97d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100308 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2019-11-27hrc files are not using c-format strings, but use arbitrary placeholdersChristian Lohmaier
a happy mix of $1 %1 $(ARG1) %s %FOO and $bar$ and more is used, so don't claim it needs to be c-format as that will trigger false alerts for strings that use the percent sign as just percent sign. Change-Id: I5ad604e842f850550aeb38b10edd7f0ab215a0c9 Reviewed-on: https://gerrit.libreoffice.org/83784 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-10-09Related: tdf#83128 support translation of plural formsCaolán McNamara
Change-Id: Id3d41099a895ca5423be2ac3d497851bc65eaff7 Reviewed-on: https://gerrit.libreoffice.org/61426 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-27pot creation: don't ignore multiple locations/occurrences…Christian Lohmaier
when making paths relative to SRCDIR 674b1c924966b4a3b6027509a6ab682e7c5aaaea as well as the code before ignored multiple locations in po file Change-Id: Idf5c5ca99d0ec8272e669621e132d7a495ceaff8 Reviewed-on: https://gerrit.libreoffice.org/50439 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2018-01-14Save full file path to pot filesGabor Kelemen
As requested here: http://nabble.documentfoundation.org/libreoffice-l10n-Pootle-source-file-paths-not-available-anymore-td4229127.html This adds the full source file path in case of .hrc and .ui files to the generated pot, relatie to srcdir. So instead of personalization.hrc:31 we can have cui/inc/personalization.hrc:31 for better context for translators. Since this is only in comment this will not change the translated status of strings. TODO: the other file formats we use are not affected by this. Change-Id: Id436d66698c93e07c46bf9c20601c5b480eadd0b Reviewed-on: https://gerrit.libreoffice.org/46591 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2017-07-21migrate to boost::gettextCaolán McNamara
* all .ui files go from <interface> to <interface domain="MODULE"> e.g. vcl * all .src files go away and the english source strings folded into the .hrc as NC_("context", "source string") * ResMgr is dropped in favour of std::locale imbued by boost::locale::generator pointed at matching MODULE .mo files * UIConfig translations are folded into the module .mo, so e.g. UIConfig_cui goes from l10n target to normal one, so the res/lang.zips of UI files go away * translation via Translation::get(hrc-define-key, imbued-std::locale) * python can now be translated with its inbuilt gettext support (we keep the name strings.hrc there to keep finding the .hrc file uniform) so magic numbers can go away there * java and starbasic components can be translated via the pre-existing css.resource.StringResourceWithLocation mechanism * en-US res files go away, their strings are now the .hrc keys in the source code * remaining .res files are replaced by .mo files * in .res/.ui-lang-zip files, the old scheme missing translations of strings results in inserting the english original so something can be found, now the standard fallback of using the english original from the source key is used, so partial translations shrink dramatically in size * extract .hrc strings with hrcex which backs onto xgettext -C --add-comments --keyword=NC_:1c,2 --from-code=UTF-8 --no-wrap * extract .ui strings with uiex which backs onto xgettext --add-comments --no-wrap * qtz for gettext translations is generated at runtime as ascii-ified crc32 of content + "|" + msgid * [API CHANGE] remove deprecated binary .res resouce loader related uno apis com::sun::star::resource::OfficeResourceLoader com::sun::star::resource::XResourceBundleLoader com::sun::star::resource::XResourceBundle when translating strings via uno apis com.sun.star.resource.StringResourceWithLocation can continue to be used Change-Id: Ia2594a2672b7301d9c3421fdf31b6cfe7f3f8d0a