Web font icons don't always show

Support and discussions for the x86/x64 Linux version of Pale Moon.

Moderators: trava90, satrow

User avatar
gnomiik
Newbie
Newbie
Posts: 3
Joined: 2019-07-02, 19:25

Web font icons don't always show

Unread post by gnomiik » 2019-07-02, 19:29

When deselecting "Allow pages to choose their own fonts, instead of my selections above" some pages don't show all the icon fonts. For example https://www.washingtonpost.com, there should be a magnifying glass instead of "fl"
snapshot-0.png

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23958
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Web font icons don't always show

Unread post by Moonchild » 2019-07-02, 20:54

That *is* the result of not allowing web pages to choose their own fonts (or disabling downloadable fonts).
You get what you ask for. Icon fonts are determined by the web site, and you have to allow the fonts determined by the website to get them.
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

User avatar
gnomiik
Newbie
Newbie
Posts: 3
Joined: 2019-07-02, 19:25

Re: Web font icons don't always show

Unread post by gnomiik » 2019-07-17, 14:28

I fixed my own problem using Guerilla Script. End result is all non icon fonts will be replaced with Arial

Code: Select all

// ==UserScript==
// @name         Arial Forced
// @namespace    https://arial.forced.com
// @version      1.0.0
// @description  Change all fonts to Arial and keep web fonts
// @include      *//*
// @grant        none
// ==/UserScript==
(function() 
{
    var all = document.all;
    for (var i=0; i<all.length; i++) 
    {

        var font = 'Arial';
        var fonts = window.getComputedStyle(all[i]).getPropertyValue('font-family');
        var cl = all[i].getAttribute("class");

		 // Prevent some stuff from being replaced
        if (
               /fa-search/.test(cl) == false
            && /monospace/.test(fonts) == false
        )
        {
            all[i].style.fontFamily = '"' + font + '", ' + fonts;
        }
    }
})();

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5608
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Web font icons don't always show

Unread post by New Tobin Paradigm » 2019-07-17, 14:37

Not really fixing anything.. More of a workaround for a poor decision. But hey, good for you dude.
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

User avatar
gnomiik
Newbie
Newbie
Posts: 3
Joined: 2019-07-02, 19:25

Re: Web font icons don't always show

Unread post by gnomiik » 2019-07-18, 15:25

Thanks for your useless comment which provides 0% value for anyone except wasting their time reading it. FYI, not everyone likes anti aliased fonts. But you're probably a millennial that grew up sucking on an iphone instead of a pacifier so you wouldn't know that there was a time before anti aliased fonts and people that actually grew up during that time might want their fonts that way when browsing the web.

yami_
Lunatic
Lunatic
Posts: 494
Joined: 2018-04-26, 11:05

Re: Web font icons don't always show

Unread post by yami_ » 2019-07-18, 15:45

Font anti-aliasing has nothing to do with disallowing web pages to choose their own fonts.
cat came back from Berkeley waving flags -- rob pike

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5608
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Web font icons don't always show

Unread post by New Tobin Paradigm » 2019-07-18, 15:52

gnomiik wrote:
2019-07-18, 15:25
Thanks for your useless comment which provides 0% value for anyone except wasting their time reading it.
Much like reading threads about non-issues caused by the software doing exactly what you asked it to. Have a nice day!
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23958
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Web font icons don't always show

Unread post by Moonchild » 2019-07-18, 18:27

Antialiasing of fonts has absolutely nothing to do with this issue. You can have aliased fonts if you insist while still allowing the page to determine what fonts to use.
Off-topic:
Also, your venomous response has netted you a one-and-only warning.
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5608
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Web font icons don't always show

Unread post by New Tobin Paradigm » 2019-07-18, 19:09

Heh, he doesn't know me very well does he?
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

Post Reply