Skip to content

standardize the word wrapping for gettext entries by adding whitespace at the end of the line

discussion about the issue on https://phabricator.kde.org/D10009

Rebase the patch by Azamat H. Hackimov, from https://bugs.kde.org/show_bug.cgi?id=380007, which produces the expected result:

"Old algorithm works not right as expected - if text have unintended newlines, lokalize wraps them as required, and result goes not identical as vanilla gettext. This produce some noise when committing PO catalogs into git.

  • Fix issue when whitespace appears as leading character in next string instead of trailing in previous.
  • New algorithm removes all newlines and then add them where they are really needed, after that goes standard word wrapping with nice max 78-wide lines."

Merge request reports