Closed
Bug 1302687
Opened 9 years ago
Closed 9 years ago
r + dot (Example: USt-IdNr.)
Categories
(Core :: Graphics: Text, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: dale_grime, Unassigned)
Details
Attachments
(4 files)
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:48.0) Gecko/20100101 Firefox/48.0
Build ID: 20160824215626
Steps to reproduce:
You can see the issue on my website http://der-webworker.com on last line
where i write my UST-IDNr. Screenshot attached.
Actual results:
The combination of the letter r and the char dot "." do show a crypt icon.
Expected results:
Simple show a r + dot :) "r."
Comment 2•9 years ago
|
||
which font is used for the text on your case?
you can check by opening context menu on the text and choose "inspect",
and in "Developer tools - Inspector", choose "Fonts" tab.
also, which linux distro are you using?
Flags: needinfo?(dale_grime)
Comment 3•9 years ago
|
||
I'm virtually certain this will turn out to be a font bug.
Whatever font your Linux distro (or Firefox prefs) uses as the default 'sans-serif', or has configured as a substitute for Helvetica, has an OpenType feature that is trying to be too clever, automatically changing "Nr." to "Nº" as an abbreviation for "number". Bad idea; something like that should only be done if the author specifically enables it, not as a default behavior.
(Notice that the problem only happens in the specific context of "Nr."; it doesn't happen in "der-webworker.com" even though the same "r." pair occurs there. It's a contextual OpenType feature, but still, it should not have been implemented as a default-enabled feature in the font.)
Thanks for your replies!
I use Archlinux in case and the font in the inspector/Fonts-Tab shows "DejaVu Sans system" and the second
is "NimbusSans Regular system".
In other web browsers it looks fine.
(In reply to Tooru Fujisawa [:arai] from comment #2)
> which font is used for the text on your case?
> you can check by opening context menu on the text and choose "inspect",
> and in "Developer tools - Inspector", choose "Fonts" tab.
>
> also, which linux distro are you using?
Thanks for your replies!
I use Archlinux in case and the font in the inspector/Fonts-Tab shows "DejaVu Sans system" and the second
is "NimbusSans Regular system".
In other web browsers it looks fine.
Comment 6•9 years ago
|
||
Other web browsers may not always apply OpenType features, unless there's something in the CSS to specifically trigger them. Or they may not be using the same font, if they don't interpret fontconfig settings in the same way. (I think Blink-based browsers tend not to handle fontconfig substitution rules the way Firefox does.)
The text in the screenshot doesn't look like DejaVu Sans, so I'm guessing it's the NimbusSans font that is configured (via fontconfig) as a substitute for Helvetica, which is named in the CSS.
Let's take a closer look... it may depend on the exact version that's present. Could you try running
fc-match -v "NimbusSans"
and show us the results, so we can see more details of the specific font that's installed.
Even better, please attach the font file here. The file you want can be identified by running
fc-match NimbusSans file
in a terminal, and see what path it reports. (Probably somewhere under /usr/share/fonts/....., I guess.)
Comment on attachment 8791595 [details]
NimbusSans-Regular.otf
Here the font file.
Comment on attachment 8791595 [details]
NimbusSans-Regular.otf
EDIT:
You're right. I've try the font in libreoffice writer and have the same result.
Is this an os problem or a firefox config problem?
Comment 10•9 years ago
|
||
Thanks. I opened that .otf file with fontforge, and looked at the OpenType features present. And sure enough, there's a rule "Nr." -> "№" included in the 'liga' (Standard Ligatures) feature, as shown here.
So, because Firefox automatically applies standard ligatures, that's how it appears.
You could work around the issue by explicitly *disabling* ligatures in your CSS, e.g. by adding "font-variant-ligatures: none;" to the style. Or you could revise the font-family property so as to prefer DejaVu Sans (for example), which I don't believe will exhibit this problem, over NimbusSans (which I suspect is aliased to Helvetica).
Also, I'd encourage you to report the problem to the NimbusSans font developers and/or package maintainers, as the real fix is for this bad rule to be removed from the font (or at least moved to an _optional_ feature that will only apply when specifically requested, rather than a default-enabled feature like 'liga').
Flags: needinfo?(dale_grime)
Comment 11•9 years ago
|
||
(In reply to Daniel K. from comment #9)
> Comment on attachment 8791595 [details]
> NimbusSans-Regular.otf
>
> EDIT:
>
> You're right. I've try the font in libreoffice writer and have the same
> result.
> Is this an os problem or a firefox config problem?
Neither one, it's a font problem. Though if the font ships as part of the OS, I suppose that makes it an OS problem too.
You could possibly avoid the issue by modifying the fontconfig setup (probably a bunch of config files found under /etc/fonts/ or something like that, I don't know exactly how ArchLinux has things arranged) so that it doesn't use NimbusSans as a replacement for Helvetica, which is how the font is currently getting selected (I think). Maybe you can uninstall the Nimbus fonts altogether, unless some other package makes them a requirement. Or you can modify the page styles so that a different font is chosen.
The real fix, though, is to remove the bad ligature rule from the font. In principle you could do this yourself if you have the expertise with font-editing tools, but it'd be better to get it fixed upstream so that everyone can benefit.
Anyhow, I think we can close the issue here; it's not a Firefox bug, just a buggy font.
Status: UNCONFIRMED → RESOLVED
Closed: 9 years ago
Resolution: --- → INVALID
| Reporter | ||
Comment 12•9 years ago
|
||
(In reply to Jonathan Kew (:jfkthame) from comment #11)
> (In reply to Daniel K. from comment #9)
> > Comment on attachment 8791595 [details]
> > NimbusSans-Regular.otf
> >
> > EDIT:
> >
> > You're right. I've try the font in libreoffice writer and have the same
> > result.
> > Is this an os problem or a firefox config problem?
>
> Neither one, it's a font problem. Though if the font ships as part of the
> OS, I suppose that makes it an OS problem too.
>
> You could possibly avoid the issue by modifying the fontconfig setup
> (probably a bunch of config files found under /etc/fonts/ or something like
> that, I don't know exactly how ArchLinux has things arranged) so that it
> doesn't use NimbusSans as a replacement for Helvetica, which is how the font
> is currently getting selected (I think). Maybe you can uninstall the Nimbus
> fonts altogether, unless some other package makes them a requirement. Or you
> can modify the page styles so that a different font is chosen.
>
> The real fix, though, is to remove the bad ligature rule from the font. In
> principle you could do this yourself if you have the expertise with
> font-editing tools, but it'd be better to get it fixed upstream so that
> everyone can benefit.
>
> Anyhow, I think we can close the issue here; it's not a Firefox bug, just a
> buggy font.
Yes, you're absolutly right!
I've add the css rule to the stylesheet on the webpage and it's looks great!
Thank you for your time!
You need to log in
before you can comment on or make changes to this bug.
Description
•