Tag Archives: a-list-apart

Using Alternate Style Sheets to switch design

Due to the large number of images and diagrams that will be accompany the articles on “UK Government G2G Messaging Sub-Systems” to follow over the next week, I’ve implemented an “Image Resize” function, to allow you to alter the image size of all diagrams in the main body of this site.

You should be able to see a section heading on the right hand side bar called “Body Image Size”, the choices are “Small” (thumbnail) , “Medium” (default) and “Large” (body width).

It’s implemented using alternate CSS Style Sheets, and was inspired by Tim Bray’s site ‘Ongoing’, where Tim uses it as a technique to switch between the ‘Serif’ and ‘Sans-Serif’ font types.

I got assistance from this article “Alternative Style: Working With Alternate Style Sheets” by Paul Sowden, hosted over at ‘A List Apart’.

Thanks to Justin Hibbard, Lead Engagement Architect and Systems Engineer (SE) for the Department of Work and Pensions (DWP) at Sun in the UK, who’s comment on the issue of “illegible text” on my diagrams instigated me to add this functionality. Justin also points out that images are rendered poorly on both IE and Firefox, however Safari (both on Windows and Mac) does a better job, personally I find Opera has the best image rendering support.

In the future I’m hoping to use this technique to allow the readers to instantly change the look and feel of the site. I like the site look and feel as it is but change is good – and choice is even better.

Few last items before I sign off tonight:

  1. Congratulations to Gordon Brown on his ascension to Prime Minister tonight, and to Harriet Harman as the new deputy leader of the Labour Party.
  2. Congratulations to Harry Saxon on his ascension to Prime Minister last night (Whovian specific content).
  3. Pleased and proud to say that Andy and Joey were both awarded Orange belts (junior 4th Kyu), and that Donna and I were also both awarded Orange belts (adult 4th Kyu), at our Karate classes today.