Categories
Culture Other

CSS positioning

[Sorry, I know most of you won’t be even slightly interested in this]

I’ve just had a major intellectual breakthrough about how CSS positioning works. Or, to put it another way, I’ve just realised that I’ve been being very stupid for a very long time.

I’ve read lots and lots of online CSS tutorials, and either none of them made it clear, or I was being dense. They often suggest that ‘absolute’ positioning is measured from the containing block – or sometimes they say that it’s measured from the edge of the browser window. The containing block theory clearly didn’t work. The screen approach seemed to work most of the time, but it meant that you couldn’t, for example, center the page on the screen if you were using absolute positioning – because it would always be a fixed distance from one of the window-edges.

In fact, absolute positions are measured from the nearest containing block in the hierarchy which has a ‘position’ property specified as something other than static. So if you just set the page’s ‘position’ tag to ‘relative’, you can then move the page around as much as you want and all things you’ve positioned with ‘absolute’ measurements will follow it. Similarly, you can take one area of the page and set it to {position:relative} and then use absolute positioning within that area.

I assumed, you see, that you’d only set the position property if you wanted to change the position of the block in question, not as a way of affecting the blocks contained within it. Now I know better. The CSS positioning system is suddenly much easier to use and much saner. I can’t believe I’ve been struggling along trying to design table-free webpages without grasping this; and I can’t believe that none of the tutorials I read made it clearer, since it’s the single most important thing to understand if you want to use CSS positioning.

Categories
Culture Other

Testers wanted!

I mentioned earlier that I thought it might be fun to enter a WordPress theme competition. Well, I’ve got a theme worked up that I’m thinking of entering. You can see it in action on my test blog here. As you can see, it’s a two-column variation on the Swifts theme with a different picture.

I’ve checked it on Firefox, Safari and IE for Mac, and they all look basically OK, but I haven’t checked it on Windows at all. So I’d be grateful if anyone using IE, Firefox or Opera on Windows could take a look and poke around, see if there’s anything you think might be wrong, and let me know. Cheers.

EDIT: well, I’ve just tried it on Opera for Mac, and it doesn’t work right. It’s startling how no two browsers seem to render the same bit of code in the same way.

EDIT: OK, I’ve sorted that out. Further comments still appreciated. If something looks wrong, it would help if you could give me a screenshot of it so I can see what the problem is.

Categories
Culture Me Other

web design stuff

The more time I spend thinking about web design, the more easily irritated I am. Take Spork. Look at that lovely, stylish, front cover: it manages to have something of a print aesthetic without being heavy-handed, and it’s clear, simple and eye-catching. Classy.

But then you click on the names, and the links open as new windows. Like I don’t have enough windows cluttering up my screen all the time as it is. Look, I never, ever want any link I click to open as a new screen unless I specifically tell it to.

And you just know that they’re only done it that way because someone didn’t want navigation buttons cluttering up his nice neat page layouts. Humph.

Categories
Other

WordPress 2.0 Theme Design Competition

I’m somewhat tempted by this WordPress 2.0 Theme Design Competition. I wouldn’t enter either of my curent themes, though. I couldn’t use the swifts one anyway, because the photographer never replied to my request to use his photo, and while I only feel mild guilt about breaching his copyright on this site, I can hardly use it to enter a competition which requires that the theme is released with a GPL licence. So it would be dependent on me having a good idea by the end of the month.

Categories
Culture Me Other

New Theme

I’ve come up with a new design for the site, as I think should be pretty obvious. If you prefer the calmer qualities of the old look, there’s now a theme switcher in the sidebar so you can pick your favourite. The scarab picture is used by kind permission of elina. Fab, innit?

The main problem with the new theme from a design POV is that it looks a bit peculiar if you’re looking at a single post which isn’t very long. But I can’t think of an easy answer to that one. It’s also a wee bit visually aggressive, but hey, that’s what the theme switcher is for – you can take your pick.

Categories
Culture Nature Other

Birdstrike wing

A photo my brother took of the mark left by a bird hitting his window. You can see the whole bird in this one.



Birdstrike wing

Originally uploaded by rutherfordfamily.