Plural localization of decimal numbers

Discuss translation contributions here.
Genhis
Factorio Staff
Factorio Staff
Posts: 592
Joined: Wed Dec 24, 2014 8:19 am
Contact:

Plural localization of decimal numbers

Post by Genhis »

Copied from https://crowdin.com/project/factorio/discussions/228

Hello! I am implementing plural localization support for decimal numbers. I want to add another option to `plural_for_parameter` - `decimal`. If specified, all plurals of decimal numbers would translate to `decimal`; otherwise, to `rest`. This covers translations for languages I know (which is likely not good enough).

Linked bug report: 109521

Proposed usage: `__1__ __plural_for_parameter_1_{1=ton,rest=tons,decimal=tons}` (`decimal` is optional)

Examples:

Code: Select all

 0.01 tons
 0.1  tons
 0.5  tons
 1.5  tons
 2.3  tons
 3.18 tons
12.5  tons
17.4  tons
20.5  tons
Does your language need any special rules? How would you translate the examples? Please let me know if you have any questions.
mmmPI
Smart Inserter
Smart Inserter
Posts: 3617
Joined: Mon Jun 20, 2016 6:10 pm
Contact:

Re: Plural localization of decimal numbers

Post by mmmPI »

One could argue that units shouldn't be plural when quantity is <= 1
Units: Names of units are made plural only when the numerical value that precedes them is more than one. Examples: 0.25 liter (quantity is less than one) and 250 milliliters (quantity is more than one).
https://www.nist.gov/pml/owm/writing-si ... stem-units

I'm not sure this is the best source for arguing.

The official norm for french from France is paywalled but state that instead quantity needs to be >=2 like :

Code: Select all

 0.01 tonne
 0.1  tonne
 0.5  tonne
 1.5  tonne
 2.3  tonnes
 3.18 tonnes
12.5  tonnes
17.4  tonnes
20.5  tonnes
Though not many french would care, it's often 1.99 euro but sometimes people spell it 1.99 euros even if it's technically incorrect.
Tertius
Filter Inserter
Filter Inserter
Posts: 918
Joined: Fri Mar 19, 2021 5:58 pm
Contact:

Re: Plural localization of decimal numbers

Post by Tertius »

For German, the rule is correct. However, you left out an example that should probably be mentioned:

1 Tonne
but
1,0 Tonnen
FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 2768
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: Plural localization of decimal numbers

Post by FuryoftheStars »

Yeah, as mmmPi pointed out, at least for American English, the original standard format of plural did not apply to decimals between -1 and 1. However, it has over time been increasingly informally spoken as plural. (I may even be guilty of this myself.)

Doing some googling around, government and other high level official sources like that I am able to find all say to use (or demonstratively use) singular in this context. The only ones I'm finding that say to use plural are "style guides" and the like that tend to cater to "common" usage, whether it's technically correct or not. Just like so many other words and terms that seem to shift in their meanings over the centuries and even decades at times....
My Mods: Classic Factorio Basic Oil Processing | Sulfur Production from Oils | Wood to Oil Processing | Infinite Resources - Normal Yield | Tree Saplings (Redux) | Alien Biomes Tweaked | Restrictions on Artificial Tiles | New Gear Girl & HR Graphics
Post Reply

Return to “Translations”