Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Font choice #35

Open
Munter opened this issue Sep 24, 2012 · 2 comments
Open

Font choice #35

Munter opened this issue Sep 24, 2012 · 2 comments

Comments

@Munter
Copy link
Collaborator

Munter commented Sep 24, 2012

Currently there is an inconsistent rendering of charcodes across platforms.

If there is a webfont available with a wide range of supported unicode chars, then that might be a better choice to give a more pleasant experience for all users.

We might even be able to switch fonts for certain blocks where there is missing support in our preferred font.

@msiebuhr
Copy link
Owner

AFAIK, rendering libraries must cycle through all their fonts until they either find one that has the given codepoint or run out of fonts.

But adding a webfont to the mix, might help them along.

(An aside: I'm still toying with an idea about having browsers rendering codepoints on a hidden canvas, check if it's a square (= missing codepoint) and report the result + browser/OS to us, somehow). Then we'd might get a fairly good idea about what's supported where.)

@bramstein
Copy link
Contributor

You could do it without the canvas tag by choosing a fallback font with
known dimensions. You can construct a special font that supports the whole
unicode range and falls back to a single character with an extremely large
(and known) width (or advance.) That way, you can insert a character into
the DOM, monitor its size, and if it becomes very large you know there is
no support for it in the fonts you have on your machine.

I'm doing something similar in my webfont loader:
https://github.com/bramstein/fonzie

On Mon, Sep 24, 2012 at 11:42 AM, Morten Siebuhr
[email protected]:

AFAIK, rendering libraries must cycle through all their fonts until they
either find one that has the given codepoint or run out of fonts.

But adding a webfont to the mix, might help them along.

(An aside: I'm still toying with an idea about having browsers rendering
codepoints on a hidden canvas, check if it's a square (= missing codepoint)
and report the result + browser/OS to us, somehow). Then we'd might get a
fairly good idea about what's supported where.)


Reply to this email directly or view it on GitHubhttps://github.com//issues/35#issuecomment-8812048.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants