Commit Graph

8 Commits

Author SHA1 Message Date
Pulkit Goyal
6499112aa6 py3: make i18n/posplit use print_function 2016-05-13 03:09:30 +05:30
Pulkit Goyal
91f9f5358d py3: make i18n/posplit use absolute_import 2016-05-13 03:08:46 +05:30
FUJIWARA Katsunori
5a05b076f2 i18n: calculate correct line number in source of messages to be translated
Before this patch, line number in source of the message to be
translated is wrong in hg.pot, if corresponded message is placed after
".. DIRECTIVE::", because number of lines related to such directive
isn't added to variable "delta", which holds number of untranslated
lines in given text.

This patch always adds "2" to "delta", because text block is split
into translation units by "\n\n".
2016-02-11 23:15:34 +09:00
Simon Heimberg
e7e6984967 i18n: leave out entries which contain only rst syntax
This prevents the danger of translating entries like the following ones:

.. container:: verbose

    .. input:: filename1.txt
2014-02-03 21:34:13 +01:00
Simon Heimberg
436dda1a07 i18n: leave out entries which contain only a rst directive
This prevents the danger of translating entries like ".. note::"
2014-02-03 21:33:48 +01:00
Simon Heimberg
0158c849ad i18n: posplit removes the entry "::" from the pot file
We do not gain anything by allowing to translate it.
2013-11-17 20:24:33 +01:00
Simon Heimberg
47121c8b9b i18n: posplit writes a warning for translators before rst directives
rst directives like this one have been translated:
.. note::

To help the translator include a comment before such messages.

An entry containing a rst directive now looks like this:

#. do not translate: .. note::
#: path/to/file:75
msgid = ".. note:: to think about"
msgstr = ...
2014-02-03 21:31:35 +01:00
Wagner Bruna
30ff803184 i18n: script for splitting large messages on .po/.pot files
With fixes and heavy refactoring by Martin Geisler.
2010-06-17 20:10:34 -03:00