Missing space in formatting of percents in Calc

Hi all,

for most locales, formatting code for the "Percent" category in Calc is a number followed by the percent sign without any space. However, a non-breaking space is usually put after the number in some languages. Thanks to Eike, this has been fixed for Finnish and Czech (see the bug [1]).

I believe that more locales need to be corrected - please check the percentage format in your locale and if the space is missing, report it by replying to this thread - Eike will go through the replies.

Thank you,
Stanislav

[1] https://bugs.documentfoundation.org/show_bug.cgi?id=63272

Hi, Eike!

for most locales, formatting code for the "Percent" category in Calc
is a number followed by the percent sign without any space. However,
a non-breaking space is usually put after the number in some
languages. Thanks to Eike, this has been fixed for Finnish and Czech
(see the bug [1]).

I believe that more locales need to be corrected - please check the
percentage format in your locale and if the space is missing, report
it by replying to this thread - Eike will go through the replies.

For German a non-breaking space between number and percent sign as well
as units is required, too.

Thanks,
Christian.

When you enter 5% in cell which is formatted as NUMBER (GENERAL), does it automatically convert to 5,00 % (for new Czech and Finnish setup)?

Mihovil

01.06.2016 u 21:25, Stanislav Horáček je napisao/la:

02.06.2016 u 07:15, Christian Kühl je napisao/la:

Hi, Eike!

for most locales, formatting code for the "Percent" category in Calc
is a number followed by the percent sign without any space. However,
a non-breaking space is usually put after the number in some
languages. Thanks to Eike, this has been fixed for Finnish and Czech
(see the bug [1]).

I believe that more locales need to be corrected - please check the
percentage format in your locale and if the space is missing, report
it by replying to this thread - Eike will go through the replies.

For German a non-breaking space between number and percent sign as well
as units is required, too.

Thanks,
Christian.

Same for Croatian: 1 m; 62,5 %; 0,5 ‰; 3 kg; 2 m; 220 V; 60 W; 50 m/s...

And then 5 °C but 180^o 20′ 50″.

Is it possible to use non-braking space in AutoCorretion? Is there some html-like notation or something?

Kruno

No please don't for now. Kruno and I will first talk before we make this decision.

Mihovil

02.06.2016 u 09:23, Kruno je napisao/la:

Well, we can talk, but there's nothing to be talked about...

See here: http://pravopis.hr/pravilo/bjelina/54/

It's not controversial topic in Croatian orthography. Personal preferences and that "I used to" really should not be an argument here. If we have Croatian local, then this is what we must do.

You can always switch to English local for some special usage or cases.

Having regular space would be a bad idea, and even I would appose, but having a non-breaking space is exactly what we need.

I'll let Mihovil to decide and not interfere, but it's plain simple...

Kruno

02.06.2016 u 09:27, Mihovil Stanić je napisao/la:

Hi,

No space is needed for Turkish, but the place of the percent sign is wrong; it should be placed before the number (like %5 rather than 5%)[0] and I have sent a patch to fix that.[1] (btw It also affects the tables added in lo writer)

I don't know how we didn't realize this before. Thank you for bringing this to our attention.

Thanks,
Muhammet

[0] http://www.tdk.gov.tr/index.php?option=com_content&view=article&id=182:Sayilarin-
[1] https://gerrit.libreoffice.org/#/c/25805/

Although, if it's not fixable in all mentioned cases (without braking something somewhere else), maybe better to let alone.

No point having 5 % and 5kn...

Kruno

02.06.2016 u 09:35, Kruno je napisao/la:

Hi,

Dne 2.6.2016 v 09:18 Mihovil Stanić napsal(a):

When you enter 5% in cell which is formatted as NUMBER (GENERAL), does
it automatically convert to 5,00 % (for new Czech and Finnish setup)?

Mihovil

yes, the entered 5% (or 5 % with the space) is converted to 5,00 % for the new setup (and to 5,00% for the old one).

Stanislav

Sorry for list noise, but since Stanislav confirmed that it won't change funcionality, I'm ok with adding space between number and % (for HR) as Kruno suggested.

Mihovil

02.06.2016 u 09:23, Kruno je napisao/la:

Den 01.06.2016 21:25, Stanislav Horáček skreiv:

Hi all,

for most locales, formatting code for the "Percent" category in Calc is a number followed by the percent sign without any space. However, a non-breaking space is usually put after the number in some languages. Thanks to Eike, this has been fixed for Finnish and Czech (see the bug [1]).

I believe that more locales need to be corrected - please check the percentage format in your locale and if the space is missing, report it by replying to this thread - Eike will go through the replies.

Thank you,
Stanislav

[1] https://bugs.documentfoundation.org/show_bug.cgi?id=63272

Also in Norwegian (nb and nn) there should be a non-breaking space between the value and the unit:
4 %; 2 kg; 1 m; etc. Also in 21 °C, but 180° (angle).
Thank you doing for this.
Kolbjørn

Ditto for Spanish, which follows the same rules as Norwegian and
Croatian, as mentioned in this thread.

Spanish is consistent with ISO 31-0/ISO 80000-1 standards and uses a
no-break space between a value and its unit symbol, unless it stands
above the baseline (degrees and primes). There is, however, a general
lack of education w.r.t. typographical syntax among Hispanophones, so
you can see it both spaced and unspaced, as in English. But at least
in formal or carefully-edited writing, it will be spaced.

Thanks

Hi Christian,

For German a non-breaking space between number and percent sign as well
as units is required, too.

Actually only for Germany, Austria and others, but not for Suisse or
Liechtenstein.

  Eike

Hi Kruno,

See here: http://pravopis.hr/pravilo/bjelina/54/

It's not controversial topic in Croatian orthography. Personal preferences
and that "I used to" really should not be an argument here. If we have
Croatian local, then this is what we must do.

If in doubt consult the CLDR, see
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

The CLDR has a vetting system and they change things only after having
investigated given references.

I don't see ·hr· being listed for the percent format, so it should fall
under {#,##0%} ·all·others·, i.e. no space between number and percent
sign.

  Eike

Hi,

If in doubt consult the CLDR, see
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

The CLDR has a vetting system and they change things only after having
investigated given references.

Interesting.
If I interpret that correct, Dutch should be "#,##0%"
However, "Taalunie" (language 'authority') says, based on ISO, that for
Dutch a space before percent is official, although without space is
acceptable in non technical use.
See

http://taaladvies.net/taal/advies/tekst/114/wel_of_geen_spaties_voor_en_na_leestekens_en_symbolen_algemeen/#10

@Winfried: you're more in technical use that I am. What would be your
take here?

Ciao
Cor

Hi,

So I did this for our locales that match
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

bas· ·be· ·br· ·ce· ·cs· ·cu· ·da· ·de· ·dsb· ·dua· ·en_AT· ·en_DE·
·en_DK· ·en_FI· ·en_SE· ·es· ·fi· ·fo· ·fr· ·gsw· ·hsb· ·ka· ·kl· ·ksh·
·lb· ·lt· ·nb· ·nn· ·qu· ·rm· ·rn· ·ro· ·ru· ·se· ·sk· ·sv· ·tk· ·zgh·

but not
·de_CH· ·de_LI· ·eo· ·es_CO· ·es_DO· ·es_MX· ·fr_CH· ·mt· ·prg· ·ta_MY·
·ta_SG·

(hopefully didn't miss to exclude one of those).

See
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=d5146c0e3ca7459db4fdc3b348cec4012555ea35

I'll also cherry-pick that to the 5-2 branch.

So there's no need anymore to ping here if your locale has the required
change.

  Eike

My personal view (based on experiences with the use of percents) is that
between value and the percent character a space is optional and no space
is more common.

Same here.

But as I cannot offer any references, let alone standards, supporting my
view, don't give too much weight to my view.

Since we have the shared idea that 'no-space' is more common, lets
simply keep it that way. And in case some technical authority might
start nagging us, we know how&where to change.

Thanks,
Cor

Hi,

If in doubt consult the CLDR, see
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

[...]

Interesting.
If I interpret that correct, Dutch should be "#,##0%"
However, "Taalunie" (language 'authority') says, based on ISO, that for
Dutch a space before percent is official, although without space is
acceptable in non technical use.

[...]

@Winfried: you're more in technical use that I am. What would be your
take here?

My personal view (based on experiences with the use of percents) is that between value and the percent character a space is optional and no space is more common.
But as I cannot offer any references, let alone standards, supporting my view, don't give too much weight to my view.

Winfried

06.06.2016 u 12:24, Eike Rathke je napisao/la:

Hi Kruno,

See here: http://pravopis.hr/pravilo/bjelina/54/

It's not controversial topic in Croatian orthography. Personal preferences
and that "I used to" really should not be an argument here. If we have
Croatian local, then this is what we must do.

If in doubt consult the CLDR, see
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

The CLDR has a vetting system and they change things only after having
investigated given references.

I don't see ·hr· being listed for the percent format, so it should fall
under {#,##0%} ·all·others·, i.e. no space between number and percent
sign.

   Eike

I'm not in doubt but not perusing this ether. Leave it (for now). :slight_smile:

Kruno

Hi,

Hi,

So I did this for our locales that match
http://www.unicode.org/cldr/charts/29/by_type/numbers.number_formatting_patterns.html#17acd127f9139476

bas· ·be· ·br· ·ce· ·cs· ·cu· ·da· ·de· ·dsb· ·dua· ·en_AT· ·en_DE·
·en_DK· ·en_FI· ·en_SE· ·es· ·fi· ·fo· ·fr· ·gsw· ·hsb· ·ka· ·kl· ·ksh·
·lb· ·lt· ·nb· ·nn· ·qu· ·rm· ·rn· ·ro· ·ru· ·se· ·sk· ·sv· ·tk· ·zgh·

Revert it for ru (Russian), please.
We do not use space between number and "%". It may be an half space
but not nbsp.

http://orfogrammka.ru/типографика/знаки_номер_процент_параграф_градус_с_пробелом/