18

Normally I use Firefox with the option "allow pages to choose their own fonts" UNselected, but now and again there's a site I'd like to view using their fonts instead of mine... Is it possible to set this option on a per-domain basis? A plugin maybe?

4 Answers 4

1

There are two Firefox add-ons that are open-source and can be used to solve the problem in another way than setting "Allow pages to choose their own fonts":

Both add-ons allow to override the CSS styles of websites, and both support @-moz-document rules, which allow regex specifications for overridden websites, including negative look-ahead.

These examples come from the article Applying styles to specific sites:

An example of matching all sites with a certain exception:

@-moz-document regexp('(?!http://www\\.example\\.com).*') {
  /*
      the code in here applies to all URLs except those that start with 
      http://www.example.com
  */
}

An example of matching all except a specific section of a site:

@-moz-document regexp('http://www\\.example\\.com/(?!members).*') {
  /*
      the code in here applies to all URLs on http://www.example.com, except
      those under http://www.example.com/members
  */
}
4

I've found a bug in the Bugzilla of Mozilla. If you still interested in this problem, you can add a comment with your requests.

https://bugzilla.mozilla.org/show_bug.cgi?id=568794

3

I had a similar problem and found this plug-in:

https://addons.mozilla.org/en-US/firefox/addon/document-font-toggle/?src=api

It allows to toggle between choosing your own fonts and use the ones set by the site. It also has pre-sets for "always allow" and "always deny" by domain so you don't have to manually toggle.

Hope this is helpful.

2
  • How should this be implemented on a per domain level? Looking at the source code it does not look like that there is this functionality. The issue is that browser.display.use_document_fonts is a global setting for all sites. Commented Oct 24, 2018 at 1:54
  • 1
    The addon has been deleted.
    – user198350
    Commented Apr 22, 2019 at 20:51
0

It looks like this might be what you're looking for: https://addons.mozilla.org/en-US/firefox/addon/stylish/

1
  • Sadly here userstyles.org/help/coding it says that "there is no way to select everything except a certain site", so Stylish doesn't fit with my scenario :/
    – Joril
    Commented Jun 19, 2011 at 9:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .