Bug 63272 - [FORMATTING] Space missing between number and percentage sign in locales that use it
Summary: [FORMATTING] Space missing between number and percentage sign in locales that...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.0.2.2 release
Hardware: All All
: low enhancement
Assignee: Eike Rathke
URL:
Whiteboard: target:5.3.0 target:5.2.0.1 target:5....
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-08 15:50 UTC by Simo Sutela
Modified: 2016-10-25 18:54 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot (from version 3.6.5.2, Fedora) (23.38 KB, image/png)
2013-04-08 16:47 UTC, Simo Sutela
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Simo Sutela 2013-04-08 15:50:18 UTC
Steps to reproduce:
1. Set document language to Finnish.
2. Type a percentage number to a cell and press enter.

There should be a non-breaking space between the number and the percentage sign, but Calc forces the sign next to the numebr. I haven't found a way to achieve the correct formatting.

There isn't any official regulating body for the Finnish language, but authoritative manuals and recommendations agree that there should be a space before the percentage sign. One rationale is that the sign replaces a word.
Comment 1 Thomas van der Meulen [retired] 2013-04-08 16:34:05 UTC
Hello Simo, Thank you for your bug report, I don't realy understand what you mean. Can you pleaes add an screenshot.

I will set it to "Needinfo" if you addited a screenshot please set it to 'Unconfiremed'
Comment 2 Simo Sutela 2013-04-08 16:47:17 UTC
Created attachment 77615 [details]
Screenshot (from version 3.6.5.2, Fedora)
Comment 3 Thomas van der Meulen [retired] 2013-04-08 17:12:20 UTC
I can't reproduce this bug running LibreOffice 4.0.2.2 on Ubuntu 12.10
Comment 4 Jorendc 2013-04-08 17:38:44 UTC
I think this'll solve your problem:

* Open calc
* Enter some percentages
* Select cells
* Right click > Format Cells...
* 'Number'-tab
* Category 'Percent'
* On the bottom of the dialog enter a space between the digit and the '%' sign.
* OK

Does this solve the problem?
I don't think these % signs or the space between them are localized.

Kind regards,
Joren
Comment 5 Simo Sutela 2013-04-08 20:18:35 UTC
Thomas, I installed the latest binaries from ppa:libreoffice/libreoffice-4-0 on Ubuntu 12.10 and could reproduce the bug as I described. Would you care to post a screenshot of your working installation, as a counter-example?

Joren, that solution came to my mind also; however it doesn't help. If you just add a space there "100%" becomes "0,10%" for some reason.

Yours,
Simo
Comment 6 Simo Sutela 2013-04-09 05:34:16 UTC
A small correction to the steps to reproduce the bug: this should probably be controlled by the "Locale setting", not the "Default language for documents".
Comment 7 Jacques Guilleron 2013-04-09 14:45:56 UTC
Hello Simo,

We had an opposite talk on French lists about percent sign in Calc. Issue was our Autocorrect Options which placed automatically the missing nonbreaking space. In this case, Calc consider the cell content as text, so it is unusable for calculation and in most cases, it's not what is expected.

Have a nice day,

Jacques Guilleron
Comment 8 Jacques Guilleron 2013-05-10 21:56:57 UTC
Hi Simo,

Solution found in user-lists: Create a user-defined format with: 0,00" %". That allows a quick input and calculus. Does it work for ou too?

Have a nice day,

Jacques Guilleron
Comment 9 sophie 2013-11-06 15:45:29 UTC
Set it on New and Low Enhancement - Sophie
Comment 10 Stanislav Horacek 2015-01-29 15:46:33 UTC
This affects all locales that use space between number and percent sign -> summary changed.

The workaround with user-defined works nicely.
Comment 11 Eike Rathke 2016-05-31 12:53:37 UTC
(In reply to Jacques Guilleron from comment #8)
> Solution found in user-lists: Create a user-defined format with: 0,00" %".

Do NOT use 0,00" %" with quotes, instead use 0,00 %
Otherwise it is just a number with a string appended and not recognized as percent format, effectively displaying 1 as "1 %" instead of "100 %", also editing the number will not offer the percentage value.
Comment 12 Eike Rathke 2016-05-31 14:23:30 UTC
Humm.. actually there's a problem with using a space between number and % in this case because space is also the group separator in a fi-FI locale, and a trailing group separator behind a number by definition divides the number by 1000, so 1 formatted with {0 %} leads to 0% being displayed which is rather unexpected ;-)  In an en-US locale you can observe this with a {0,%} format.

Not sure at the moment how to solve this. We treat an ordinary space the same as the defined U+00A0 NO-BREAK SPACE separator because we can't expect from a user to enter the no-break space whenever s/he wants to use a group separator.
Comment 13 Eike Rathke 2016-05-31 14:30:02 UTC
Got it, this works: {0" "%}
The space can be an ordinary space or a no-break space.
Comment 14 Commit Notification 2016-05-31 14:45:21 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=5868d927bccfc9594c4f791d0800337a0ce60c18

Resolves: tdf#63272 [fi-FI] percentage format with no-break space

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 15 Commit Notification 2016-05-31 14:50:23 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=04892d061398b235e8d4f276a7d2a5669f5ffe58&h=libreoffice-5-2

Resolves: tdf#63272 [fi-FI] percentage format with no-break space

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 16 Eike Rathke 2016-05-31 18:32:48 UTC
Pending review https://gerrit.libreoffice.org/25738 for 5-1
Comment 17 Commit Notification 2016-05-31 19:35:05 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2518935003b879fdfe30cf278b46f4e3a00f3576&h=libreoffice-5-1

Resolves: tdf#63272 [fi-FI] percentage format with no-break space

It will be available in 5.1.4.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 18 Stanislav Horacek 2016-06-01 08:18:28 UTC
Could this be changed also for other languages which require a space between number and percent sign? I can make a patch for the Czech language (cs-CZ, the same case as Finnish), but maybe there is more of them - what about sending a question to the l10n mailing list?
Comment 19 Eike Rathke 2016-06-01 12:51:44 UTC
(In reply to Stanislav Horacek from comment #18)
> Could this be changed also for other languages which require a space between
> number and percent sign?

Sure, why not.

> I can make a patch for the Czech language (cs-CZ,
> the same case as Finnish),

I'm just pushing such.

> but maybe there is more of them - what about
> sending a question to the l10n mailing list?

Go ahead please :-)  I usually skim the l10n list from time to time so likely will notice replies there.
Comment 20 Commit Notification 2016-06-01 12:53:48 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=c5c2181a14c6ca9ed47729e6d8dbda2cc3552221

percentage format with no-break space, tdf#63272

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 21 Commit Notification 2016-06-01 13:02:05 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=d144681a738f1a833cc199de9b6d504b7d772f7e&h=libreoffice-5-2

tdf#63272 [cs-CZ] percentage format with no-break space

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 22 Commit Notification 2016-06-02 10:27:27 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=eee5256e6649c5ccbd26f30b53351c808f6c56e4

tdf#63272 Fix location of percent sign for Turkish

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 23 Commit Notification 2016-06-02 10:39:44 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=91768f3f8314a3570146a28e041fdb1aef3b9df0&h=libreoffice-5-1

tdf#63272 [cs-CZ] percentage format with no-break space

It will be available in 5.1.5.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 24 Commit Notification 2016-06-02 15:36:58 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6e7992e916fe014670ccb8cc9242bfd7913ac98b&h=libreoffice-5-2

tdf#63272 Fix location of percent sign for Turkish

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 25 Commit Notification 2016-06-02 15:38:17 UTC
Muhammet Kara committed a patch related to this issue.
It has been pushed to "libreoffice-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=aa406b4195460a8f7fc235c6de76834910f8d44e&h=libreoffice-5-1

tdf#63272 Fix location of percent sign for Turkish

It will be available in 5.1.5.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 26 Commit Notification 2016-06-06 10:53:59 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=d5146c0e3ca7459db4fdc3b348cec4012555ea35

no-break space between number and percent sign, tdf#63272

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 27 Commit Notification 2016-06-06 11:14:35 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6eb7dbe4d18098ccebf5c942c0de928bc4c49689&h=libreoffice-5-2

no-break space between number and percent sign, tdf#63272

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 28 Commit Notification 2016-06-13 09:09:11 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=ff1edd625709dd8e140e31609158c59a6413f72e

remove the correct but unwanted no-break space in percentage, tdf#63272

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 29 Commit Notification 2016-06-13 09:12:43 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=fd99a87a42a79169e55f36044c24a75c6345d241&h=libreoffice-5-2

remove the correct but unwanted no-break space in percentage, tdf#63272

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 30 Commit Notification 2016-06-16 10:59:40 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=cfc22e4614499de3987fcf4ca178e6349666c9af

no-break space between number and percent sign, tdf#63272

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 31 Commit Notification 2016-06-16 11:03:16 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=976377ef41b4911b7c0c19e3e7481d42f86b050a&h=libreoffice-5-2

no-break space between number and percent sign, tdf#63272

It will be available in 5.2.0.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.