Yay for the internet

July 18, 2006 at 9:50 pm | Posted in Blogroll, javascript, linux, personal, rugby, tech, travel, ubuntu | 2 Comments

After a very very long time – way over a month now – I finally have internet at home again! a direct result of this is that I have set myself up with a proper install of wordpress on a brand new hosting package …

http://notes.natbat.net/

This wordpress.com site will no longer be updated.

Women in technology and Ubuntu

March 3, 2006 at 12:37 am | Posted in linux, tech, ubuntu | 5 Comments

Looks like there is a new drive afoot to recruit more of us girls to the great Ubuntu cause. The Ubuntu group have recently launched ‘Ubuntu Women‘. The aim of which is to initiate more women into Ubuntu, open source software and technology in general, through mentoring and encouragement.

A quote from the Ubuntu Women wiki page on one of the reasons for the project:

“[to] Transcend the technical barrier which will empower women to create new software and think out-of-the-box.”

Despite the arguable overuse of metaphors, encouraging women in technology is a really good idea. Its no secret that a lot of women do feel intimidated by this mainly male centric industry, there are many reasons why this should be so.

One article on how to encourage women in Linux that has an interesting analogy, comparing the fear to going into a sports bar with a t-shirt saying ‘I hate sport’. Now I don’t personally believe this is entirely correct, while I completely understand that if you are starting out it sometimes feels like everyone is talking a different language, its not trying to be different, you just are.

Some men, and even some women may think it wimpy, perhaps sexist to even admit there is a difference between the genders and their attitudes; but its true, we are not the same, it is sometimes a struggle to prove yourself as a female geek.

One huge difference that has a significant effect could be that women are less prone to self promotion; while this modesty trait may be good in polite society, it doesn’t work well in the geek world. Men are quite happy to promote their ideas, share there excitement and unashamedly display the cool things they have made, this is a great thing and I’m not generalising without exception, there are many women who are able to overcome this and be proud of what they have done. Myself and many others I spoke with are less forthcoming with our enthusiasm and this may well be to our disadvantage.

Another great barrier to entry is a partner with similar interests in the field, naturally a common occurrence due to similar social circles and shared interests, it can happen many people overlook the female partner’s geeky credentials, unintentionally perhaps but noticeable none the less. From personal experience I can confirm this is true, I would never claim to be better than my other half – nowhere near – however a few people who meet me at geek events just think I come along for the ride, and not knowing I work as a web developer and just automatically talk down to me.

Although not being recognised for our abilities as women geeks, is partly our fault for not being outwardly proud enough of our achievements and accolades, the lack of women in technology is not helped by assumptions of others that we have none to be proud of.

Further Reading

Cotswolds adventuring

February 27, 2006 at 10:10 pm | Posted in personal, travel | 6 Comments

Mum and dad navigating arround BurfordI have just spent a very happy weekend exploring the Cotswolds with my family. I had Friday afternoon off, so we took this as a perfect opportunity to go for lunch at the Bell in Charlbury near where I work, then explore the local villages a little.

We drove up to Islip, the most humorously literal village I have ever seen, all the houses were called things like ‘river view’, ‘the old smithy’ and suchlike, the main street was ‘the walk’, I found this all very funny. Afterwards we went to the Hotel and watched DVDs and ate popcorn and cake.

We went to a number of other little towns over the weekend, including Burford, Woodstock, Blenheim palace and Bourton on the water (so called ‘Venice of the Cotswolds’) all very pretty, I think Burford was my favourite, every so picturesque.

On Saterday night I even managed to successfully introduce my family to Tapas!

Nearly there with the ‘permalink-slideshow’

February 24, 2006 at 2:34 am | Posted in javascript, tech | 94 Comments

Well at the risk of too many entries on this permalink-slideshow, here goes another. I have always wanted (since i lost my fear of JavaScript) something that i can cut my teeth on so to speak. A medium-ly complex project to do in JavaScript that I can have fun playing around with, and more importantly to learn from. I think I may have found it.

This evening I have had some fun playing with performance, which incidentally seams to work fine now, there appeared to be a problem with the images stacking on top of each other with 'visibility: hidden' and a not-quite-opaque opacity. Using 'display: none' in addition seams to sort things out just fine. I also sorted out the weird forward / back problem pointed out by Richard by not letting the fade start unless it is not already running, unfortunately another global variable but unavoidable in this case I think.

The images now start at 1 not 0 because it made more sense when reading it, I also put in 'page x of x' at the bottom of the image and changed the document.title so that the back history remains understandable, quick fixes but quite a nice effect.

With regards to the image id's not matching the location.hash to avoid jumping, it really was quite a problem so I changed to my initial idea of 'position:absolute; top:0;' with the padding on the image to position it instead, though depending on how it will be used eventually the jump may be unavoidable. Oh well.

I still need to implement the funky image pre-loading trick as it hangs while you wait for the images to load, but other than that – and the hideous browser incompatibilities – I'm relatively happy with it. Tomorrow I show it to the people at work for real, if they don't like it that doesn't really matter as I have had a lot of fun making it!

Current working version:

UPDATE [4th Apr 06]: new demo (see comments for list of changes)

Fixing a few JavaScript slideshow loose ends

February 23, 2006 at 1:06 am | Posted in javascript, tech | 11 Comments

As pointed out by Jeremy, my linkable slideshow (v2) needed some work to fix the load order of the page without altering the ‘unobtrusiveness’ of its behaviour.

I opted for Jeremy’s second method; not waiting for the page to load, instead hiding the images and sorting things out later on. Since the slideshow already relied on importing the CSS with JavaScript I simply moved this outside of the function called onload.

To ensure nothing untoward happens with crazy partial loaded DOM editing I encased the addition of the CSS into a try / catch. On fail of inserting the link rel into the page, the function then simply just calls itself again.

So in the root of the JavaScript file:

...
function setCSS(css) {
try {
// append stylesheet to alter
document.getElementsByTagName("head")[0].appendChild(css);
} catch (e) {
setTimeout(function(){setCSS(css)}, 100);
}
}
// on load
addEvent(window, 'load', setupPage);
// create CSS element to set up the page
var css = document.createElement("link");
css.setAttribute("href","style3.css");
css.setAttribute("rel","stylesheet");
css.setAttribute("type","text/css");
// attempt to add the css and then keep trying till we do
setCSS(css);

The CSS then sets all the images except the first one (over-ridden in the JS) to have ‘visibility: hidden;’ and to be positioned absolute in the right place.

Other changes to this version include vague attempts to improve performance through clearing the setInterval() during the fade and resetting after, also through using ‘display: none’ as well as the visibility. This seamed to improve it slightly but nothing revolutionary, it always slows down after 7 or so images regardless of how long you leave between page load and moving to an image.

Image maps work right enough with the slideshow too now which is good, since this was part of the original specification. I also stopped the jumping due to the id’s of the image, I am not too pleased with the solution to this as it involves using a different hash fragment to the image id’s.

The jumping was due to the browser automatically moving to the top of the image with the id, using non-existent id’s stopped this problem but does sort of spoil the seamless effect. For example if i bookmark an image then turn off JavaScript that bookmark will no longer work. The only other solution I can think of to this issue is playing with z-indexes of the other page elements and having the image positioned absolute at the top of the page with padding down to the appropriate height.

This new version is available for your interest here:

Photo sharing

February 22, 2006 at 2:22 am | Posted in personal | 2 Comments

Photo sharing

Photo sharing

The Torchbox crew admire Bryans skiing photos in Sip, the classy cocktail bar in Jericho, Oxford.

JavaScript slideshow fun

February 22, 2006 at 12:48 am | Posted in javascript, tech | 25 Comments

There are things that go smoothly, run like a dream and never complain; there are others that don’t. For me, debugging JavaScript is always one the latter.

DHTML UtopiaI have only recently begun to appreciate the power and fun to be had hacking at javascript, I used to panic at the thought of it. This was until I joined Torchbox where I received not only the help and confidence boost I needed, but also the office has a copy of Stuart’s book ‘DHTML Utopia‘.

I have only gone through the first three or so chapters in detail but over the past six months I have learnt to love event listeners and writing JavaScript as a seamless behaviour layer. No more do I panic about getting tangled up in ‘onclick‘s and ‘JavaScript:‘ – things become easier and a lot more fun when you can abstract the JavaScript from the page entirely.

I have written one or two snippets that I am quite pleased with, and although I have learnt to love writing JavaScript, I still hate debugging it. My most recent exploit has been into the realm of an accessible slideshow.

For work we wanted a way of showing images as a funky slideshow, the slideshow however needed to change the URL for each image and have the ability for the user to either manually alter the URL to go to an image, use the browser’s back button and bookmark an image. The user should choose when to move to another image so in the previously mentioned situations and when next or previous is clicked the images should fade into the next.

In true 2.0 style I have a beta‘ version up and running, its not yet there but its a start. The next and previous links work and fade nicely, the back button really does work (even with the fade) as does the ability to change the URL manually. All images used are ones I have taken and are licensed under the creative commons.

The final version will:

  • Fix all the bugs – so the style ‘issues’, (mainly in IE) there is a flash of the previous image in Safari and some nightmarish debugging is needed for the ‘Permission denied’ error I am getting in IE6! (You may have already guessed that I unashamedly developed this in FireFox.)
  • Fix the performance problem – I really don’t know why this occurs but if you click through a number of images by the time you get to 6 or 7 the performance lag is very noticeable. Currently, I am changing the URL with fragment ID’s from the location.hash property and updating the location.href with the id of the current image. Listening to the URL is done through a function on setInterval() on 500ms that checks against one of the few global variables if the location.hash has changed. I’m thinking of changing this to use setTimeout() instead so I can stop it during the fade and start up again straight after, this might work.
  • Have ‘further information’ links – per image that then changes (not necessarily fades) as the images do
  • Use image maps - As this was the original intention of the slideshow, to work with images that are image maps, I am really hoping that this is going to be a nice easy stage; I have yet to try setting the opacity on image maps.
  • Stress test it! - The fun part, its the fixing afterward that might not be quite such a laugh.

Some inspiration for the slideshow came from Matthew Westcott who developed the cool main image fade on http://breakthrough.org.uk/ and from the Image Cross Fader Redux.

Feel free to view my efforts:

Frosty pitch

November 29, 2005 at 12:28 am | Posted in personal, rugby | 4 Comments

It’s minus four degrees outside, there is a frost forming. How do I know this? because I was there. Running about with an egg shaped ball as the grass slowly crystallised at my feet. Yes, I was playing rugby.

The predictions currently hold that this year will be one of the coldest years on record, what a perfect time I thought, to start playing rugby again. This is a game that despite being as English as I am, I learnt to play when on placement in Giessen Germany.

I was sat with some friends of varying nationalities in the student bar in Germany, when the waitress who was German, noticed my accent and proclaimed “you’re English!”. Excited at the prospect of bringing a real Brit back to their rugby practice, (despite zero experience on my part) she then told me of their team (URC Giessen) who were enthusiastic but limited in size, and their coach who was a fellow Brit in Deutschland.

I firmly believe that everyone should take any opportunity to do something, anything, that scares you. One thing that scared me was that first practice, a foreign country where I did not speak the language, playing an unknown game that by all accounts was really rough. I should explain, my history with exercise has not been a harmonious one. At school I very conveniently had ‘exercised induced asthma’ which was my excuse on many a P.E. lesson or ‘cross country day’.

There were however, a few sports I did try with varying degrees of enthusiasm and success. Hiking on Dartmoor was a favourite for quite a while as I trained with the Clyst Vale Community College Ten Tors team for just over four years. I also dallied in Tennis outside of school for a bit, before I realised that I really hated summer sports – sunshine and exercise don’t sit well together.

Girls didn’t play rugby at school and other than a few half hearted attempts at playing badminton or going to the gym, people didn’t play sport at all during college. University was hugely different, at the University of Bath everyone played many varying types of sport. Everyone that is, except us computer scientists, who (with a few exceptions) were put off by the fact that in order to get fit, we would have to be around fit people. Anyone coming to sport late in life will doubtless share this opinion.

So, from the context I’m sure you can understand that I was pretty darned scared by rugby initially, not purely of the exercise but the apparent brutality in comparison to say, hiking. In fact when I first got tackled I squeaked out of shock, this earned me the nickname ‘Meerschweinchen’ [Guinea pig] which was fortunate as the only German I knew at that time really was “Ich bin ein meerschweinchen”.

I grew to love the game though, being a winter sport there was little chance of having to run in 40 degree heat. I found the egg shaped ball a lot easier to catch than a netball, tackling was great fun and though the rules to this day still perplex me, I really enjoyed it and found a niche as a hooker (still maintaining a-fore mentioned nickname)for our small sevens team.

me playing rugby

The experience was fantastic, some of my happiest memories are playing training or drinking with the rugby team in Giessen, or training with various friends roped into things like jogging for miles the night before a match and even ball handling practice in the kitchen.

Back at university, in a country home to the sport I had learnt to play, I joined Bath University Ladies Rugby Team. I went to the initiation and one practice but the sheer size of the team threw me completely, that and the effort of finishing my degree at the same time. Coming from a team of 9 playing 7′s I was suddenly in a team of over 50 playing 15′s, quite a culture shock.

Now that I have moved to Oxford and settled in a little, (Ive been here nearly 2 months now) I decided to give the game another go. Sunday two weeks ago I played in my first 15′s match, 35 mins each way is an awful lot longer than our tournaments of 6 games 7 minutes each side. I play sub for the forwards at the moment as I am new, I was put on as Flanker in the last game, it is a good position to play and is quite fun but I think given the choice I would still prefer to play Hooker. I’m really enjoying playing rugby again despite the cold, Oxford Ladies Rugby team has about 18ish players and although we play 15′s and I never did understand the rules even for sevens, I am slowly adjusting.

Blog at WordPress.com. | The Pool Theme.
Entries and comments feeds.

Follow

Get every new post delivered to your Inbox.