googlefonts / roboto-2

The Roboto family of fonts
Apache License 2.0
3.85k stars 309 forks source link

Support for German capitalized Eszett #279

Closed kobelobster closed 6 years ago

kobelobster commented 6 years ago

Hi,

the German eszett ß recently got a capitzlied version: which is currently not supported in Roboto, so when you have the text: "Maßlech" and use for example CSS to make this upper case via text-transform: uppercase, the result is: MASSBLECH.

Any idea if will be supported in the near future?

fitojb commented 6 years ago

Hm, Roboto does contain the capital Eszett, and has for a long time (the letter is visible in a Lollipop phone I have). If you have downloaded the font, please make sure you do so from this repository’s “Releases” page; ensure it’s the latest version and make sure it didn’t come from a subsetted web-font version (some web fonts are subsetted to exclude lesser-used characters and speed up webpage load time).

kobelobster commented 6 years ago

@fitojb It contains the lowercase Eszett, ß, but not the upper case . You can check this by going to https://fonts.google.com/specimen/Roboto and entering those two characters. The lowercase get's displayed correctly, but the capitalized version does not exist.

I just downloaded the font from here, put it into my project, wrote Maßblech, used text-transform: uppercase and it still transforms it into MASSBLECH

As a proof, I created a simple html file where you can check this. See attached compressed archive.

roboto-uppercase.tar.gz

moyogo commented 6 years ago

@tzfrs two things:

  1. Google Fonts subsets fonts, so you might have to select a different subset to view the characters you want: <link href="https://fonts.googleapis.com/css?family=Roboto&amp;subset=latin-ext" rel="stylesheet"> may contain . Alternatively you can use the full font that is in this repository.

  2. text-transform: uppercase changes ß into two S regardless of the font. Since the uppercase is recent, text-transform behave as it use to before that character was encoded or before it’s use became official in German.

@davelab6 Which Google Fonts subset contains ?

m4rc1e commented 6 years ago

@moyogo thanks for the explanation.

Which Google Fonts subset contains ẞ?

We've had a recent discussion on this, https://github.com/google/fonts/issues/1346. Its in Latin-ext, https://github.com/m4rc1e/tools/blob/master/encodings/latin-ext_unique-glyphs.nam#L493

kobelobster commented 6 years ago

@moyogo @m4rc1e Thank you for your answers.

You seem to be right, when I write <p>MAẞBLECH</p> it shows me the capitalized version, so it seems to be a problem with the way uppercase is handled.

I found this in Google Fonts

The Latin subset is always included if available and need not be specified. Please note that if a client browser supports unicode-range (http://caniuse.com/#feat=font-unicode-range) the subset parameter is ignored; the browser will select from the subsets supported by the font to get what it needs to render the text.

so I don't actually need to add anything else, as you said, it seems to be because of the browser handling the CSS.

Update: MDN also states that this is the expected behaviour

https://developer.mozilla.org/en-US/docs/Web/CSS/text-transform

In German (de), the ß becomes SS in uppercase.

fitojb commented 6 years ago

Can we close this as it is clearly not a font bug?

kobelobster commented 6 years ago

@fitojb closed it.