Bug 393740 - Title bar doesn’t handle soft hyphens – rendered as spaces
Summary: Title bar doesn’t handle soft hyphens – rendered as spaces
Status: RESOLVED DUPLICATE of bug 376813
Alias: None
Product: kwin
Classification: Plasma
Component: decorations (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-05-01 18:35 UTC by Karl Ove Hufthammer
Modified: 2018-05-01 18:53 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screenshot showing soft hyphen displayed as a space (129.31 KB, image/png)
2018-05-01 18:35 UTC, Karl Ove Hufthammer
Details
Text file with soft hyphen in filename (51 bytes, application/octet-stream)
2018-05-01 18:38 UTC, Karl Ove Hufthammer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Karl Ove Hufthammer 2018-05-01 18:35:29 UTC
Created attachment 112352 [details]
Screenshot showing soft hyphen displayed as a space

[I’m not sure if this is the right component, or even product, so feel free to reassign.]

Observed behaviour:
If the text in the title bar contains a soft hyphen (i.e. Unicode character U+00AD), this is displayed as a space.

Expected behaviour:
The soft hyphen should be invisible.
(A soft hyphen should always be invisible unless it word is broken over two lines, where it magically turns into an ordinary hyphen).

Use case:
In our (Norwegian Nynorsk) translation of the system settings modules, we have many long (compound) words, and we use soft hyphens to ensure that module names can be displayed properly, i.e. hyphenated over several lines. For example, the module name ‘Skrivebords­effektar’ (‘Desktop Effects’) has a soft hyphen between ‘Skrivebords’ and ‘effektar’, ensuring that it is displayed as

Skrivebords-
effektar

if the word needs to be broken over two lines. This works very well. But the module name is also shown in the title bar, and there the soft hyphen seems to be replaced by a space, ‘Skrivebords effektar’, which is wrong.

I’ll attach a screenshot showing the problem.
Comment 1 Karl Ove Hufthammer 2018-05-01 18:38:24 UTC
Created attachment 112353 [details]
Text file with soft hyphen in filename

Here’s a file to easily reproduce the bug. It’s called ‘skrivebords­effektar.txt’, with a soft hyphen between ‘skrivebords’ and ‘effektar.txt’.

Steps to reproduce bug:

1. Open the file in Kate, Kwrite or another editor that shows the file name in the title bar.
2. Note that the title bar says ‘Skrivebords effektar.txt’ instead of ‘Skrivebordseffektar.txt’.
Comment 2 Karl Ove Hufthammer 2018-05-01 18:42:15 UTC
(Note that downloading the attachment using Chromium doesn’t work, as it replaces the soft hyphen with an underscore. But downloading it using Firefox works fine.)
Comment 3 Martin Flöser 2018-05-01 18:53:03 UTC

*** This bug has been marked as a duplicate of bug 376813 ***