Categories
GUI/X11/Xfree86/Xorg

X Terminal TrueType Fonts

This article examines some of the monospaced TrueType fonts suitable for use in an xterm window, and why you might want to use them.

Categories
CSS

Ordering of dynamic pseudo-class blocks in stylesheet

The best order for dynamic link pseudo-class blocks in your stylesheet is (from W3C):

a:link    { color: red }    /* unvisited links */
a:visited { color: blue }   /* visited links   */
a:hover   { color: yellow } /* user hovers     */
a:active  { color: lime }   /* active links    */

The order matters because these dynamic pseudo-classes are not mutually exclusive in CSS2 (some of them were in CSS1), and later rules override earlier ones if they clash. In the example above, if a:link were placed last, all links would be the same colour (red) irrespective of whether they are visited, active or hovered.

Actually this doesn’t only apply to links; in some browsers any element can have :hover, for example.

Categories
CSS

CSS Golden Rules: Class Names

Name your CSS classes according to what they are for, not what they look like.

That is, use names like codeblock, quotation, document-title, error-message and so on.

I’m currently having to deal with a mess of stylesheets for a client which are full of classnames like bigblack and reddots and bottomrightbox. They are just not helpful. I can see what it looks like by reading the stylesheet, what I want to know is what these classes are expected to be used for! If you have classnames like this, they’ll end up being used indiscriminately, and then you’re in real trouble if you ever want to change anything, because you have no idea what might be affected. But inevitably, at some point, the presentation of the class will get changed, but you can’t change the name because it’s too widely used, so it becomes downright misleading — you have a bigblack class which actually makes the text green or something…

Even worse are names like nobordertable. Here we have an extra dose of useless or wrong information, with the implication that this class is for use with tables (again without telling me what *sort* of table it’s for). Well why not specify that with a selector like table.classname? Then maybe I wouldn’t be finding this class applied to divs, spans, blockquotes….

Addendum 22nd March 2005: The W3C’s explanation is probably clearer.

Categories
GUI/X11/Xfree86/Xorg

X Terminal Program Comparison

As a result of eye problems, I started to investigate the visual features offered by different X terminal programs, such as support for TrueType fonts or vertical spacing adjustment. This article features a comparison table and some notes about what I have found so far. It may be of particular interest to the partially sighted or anyone who works long hours in terminal windows.

Categories
Linux

Linux on the NVidia Nforce2 / Geforce 4MX / Shuttle SN41G2

This article discusses some specific issues with getting Linux to work on the Shuttle SN41G2 with Nvidia chipset, but may be applicable to other Nvidia boards.

Categories
Eco UK

Green Electricity suppliers

Which is the best supplier to choose if you want to encourage the development of renewable energy sources?