Changing default font sizes and styles in Mozilla Prism/XulRunner/WebRunner

I’ve been using Prism for the last month or so and am really loving it. Having Gmail and Reader in their own windows with their own memory footprints has significantly changed the way I work each day.

Having said all of that, there are other sites that I’ve wanted to wrap in a Prism app and use from there, but have been stymied by various problems. Wikipedia, for example. Wikipedia drives me nuts with it’s default “x-small” font size. In Firefox it’s no problem because I can set the minimum font size. Today I figured out how to do this in Prism:

  1. Navigate to the folder for the Prism webapp. It will probably be something like:
    c:/Documents and Settings/rick/Application Data/Prism/Profiles/whatever/webapps/wikipedia@prism.app/
  2. Create a file in the same directory as the webapp.ini called webapp.css.
  3. Smack yourself in the forehead for not thinking of something so obvious.
  4. Edit the webapp.css file to include any CSS overrides you’d like to have in place. Such as:
    body {
    	font-size: 13px !important;
    	font-family: Calibri !important;
    }
  5. Save the CSS and close and reopen the webapp.

Depending on the application and how its CSS is structured, you may need to muck around with inheritance, specificity, !important declarations, etc. But it works!

Published by

Rick Osborne

I am a web geek who has been doing this sort of thing entirely too long. I rant, I muse, I whine. That is, I am not at all atypical for my breed.