Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: non-printing characters #269

Open
meskobalazs opened this issue Apr 25, 2016 · 6 comments
Open

Feature request: non-printing characters #269

meskobalazs opened this issue Apr 25, 2016 · 6 comments

Comments

@meskobalazs
Copy link

I have encountered translation files, which use non-printing characters in the translation strings. Namely optional hyphenations. I shows fine in the string list, but in the original text and translation text boxes they are invisible. AFAIK Lokalize shows these with specially coloured background.

@vslavik
Copy link
Owner

vslavik commented Apr 25, 2016

Please always include essential basics, such as platform, Poedit version etc. When you’re creating an issue that in any way relates to a specific file, please always attach said specific file.

AFAIK Lokalize shows these with specially coloured background.

You contradict yourself: an invisible character, i.e. one with zero width, can hardly have coloured background, when it has no background area...

@meskobalazs
Copy link
Author

The affected version is 1.8.7 (the latest), on Windows.
I added a POT file, e.g. string #730 or #943 show the problem.

My problem is that there should be an option to make non-printable characters visible in the editor.

@Artoria2e5
Copy link

Artoria2e5 commented Apr 29, 2016

Just FYI, gettext feature request filed at https://savannah.gnu.org/bugs/index.php?47801.

@bhaible
Copy link

bhaible commented Apr 30, 2016

Indeed the attached POT file contains soft hyphens in the following lines / strings:
158:msgid "Back­ground"
208:msgid "Blue­tooth"
829:msgid "Co­lor"
1210:msgid "Dis­plays"
1354:msgid "De­tails"
1676:msgid "Key­board"
1772:msgid "Mouse & Touch­pad"
2500:msgid "Net­work"
3486:msgid "No­ti­fi­ca­tions"
3577:msgid "On­line Accounts"
3871:msgid "Po­wer"
4157:msgid "Prin­ters"
4630:msgid "Pri­va­cy"
4843:msgid "Re­gion & Lan­guage"
5071:msgid "Sha­ring"
5411:msgid "Uni­ver­sal Access"
6762:msgid "Wa­com Tab­let"

Two questions:

  1. What is the purpose of having soft hyphens in a POT file?
  2. Why would the translator want to see them?

A soft hyphen, here, is a place where rendering software could insert a hyphen+line break combination.

My opinion is:

  1. These soft hyphens cannot help the translator, therefore they should best be filtered out when generating the POT file.
  2. These soft hyphens cannot help the translator, therefore even if present in the POT file, they should remain invisible.

@vslavik
Copy link
Owner

vslavik commented Apr 30, 2016

My opinion is:

I think I agree, soft hyphens are indeed pretty useless in localisation strings (or at best, very very low priority).

BTW, Poedit already highlights important non-printable characters such as \n or \t...

@meskobalazs
Copy link
Author

The purpose of the hyphens is to separate the syllables, so the word can be correctly broken up into multiple lines, this is not something which can be done automatically in every case. Very much like the optional hyphenations in LaTeX.

I do agree, that this is a low priority thing. However, it does help the translator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants