Question

I would like to use some not-so-common diacritics and maybe some fancy Unicode characters in my Android app, but I could not find a charmap for Roboto.

What glyphs or character sets are included in Roboto Regular, Bold and Condensed fonts?

Était-ce utile?

La solution

After a bit more searching, I've found this reference on the Google API's site

http://commondatastorage.googleapis.com/androiddevelopers/design/Roboto_Specimen_Book_20131031.pdf

The updated reference for the latest version of the font files is here https://github.com/google/roboto/blob/master/res/glyphlist.txt
Note that this may be more recent than the version on your Android IDE or OS!

Autres conseils

Warning: although the answer below was helpful to many people, and I will leave it up as such, it might trick you a bit, because default browser behavior is to use fallback fonts for missing characters and so you might see glyphs from other fonts in the snippet below.


Ended up hacking this script together for a quick and dirty overview:

var content = "";
var max = 65535; // See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCharCode
for (var i = 34; i < max; i++) {
  if (i % 1000 === 0) { content += '<hr>'; }
  content += "<div title='"+i+"'>" + String.fromCharCode(i) + "</div>";
}
document.body.innerHTML = content;
@import url(https://fonts.googleapis.com/css?family=Roboto);
body { font-family: 'Roboto'; font-size: 18px; padding: 5px; }
div { display: inline-block; background: #ddd; color: #111; margin: 4px; width: 1.5em; height: 1.5em; text-align: center; padding: 0.2em 0 0 0; box-sizing: border-box; }
div:hover { cursor: pointer; background: #ccc; }

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top