Code

My hobbies are mostly programming (sad I know), and are mostly related to computer graphics (just never could shake that addiction since childhood :).

As an example of the kind of stuff I like to do for fun, here's an applet I once wrote as a creative piece for a Java+Internet assignment. Warning: This applet eventually crashes older (eg. 4.x) versions of the Netscape JVM, and Netscape with it, when run under Linux, so leave this page soon if using Netscape 4.x to be safe!


The applet should've been here, but you must have turned off Java in your browser, or your browser just doesn't support Java.


Fragments

Below is a small selection of code fragments I used to build this website. Hopefully they'll prove useful to someone else as well.

Squishy.java and SquishyPoint.java
A small Java applet and it's supporting class. You can see this applet in action on this page.
thumbs.pl
A perl script used for automatically generating thumbnails and suitable HTML code for collections of photos. It uses ImageMagick and so could in theory be used for generating thumbsnails of anything (including PostScript documents :)
style.txt
A fragment of Server-Side Includes HTML that I use to provide the correct style information for the menu. Note the cool bit which highlights any link in the menu which points at the current page. And the fact that <a> tags are displayed as blocks, avoiding the need for tables and making the whole thing work properly on Lynx!
paper.makefile
A makefile that I use for compiling my LaTeX documents. It includes a line to convert Dia documents to EPS automatically.
base.tar.gz
A basic LaTeX file, BibTeX file, makefile, and a logo for presentations in the Cafe DSL series. Uses texpower (not included).
jed.rc and screenshot
My preferred .jedrc file. Uses colours similar to an Emacs theme I once used. I find the lower contrast much easier to look at. Also includes my preferred indenting settings, and a line to make .tex files open in LaTeX mode.
thumbnailer.tar.gz
A collection of fast Gnome2.2 thumbnailers for PostScript, PDF and Dia diagrams.
proofs.tex
versions of the popular collection of proof methods found all oer the web. Also in .pdf, and .ps. Hope that you find them useful. :)
counter.c
A small CGI program for counting the number of hits to a website. Only increments the count of hits for known user agents. Keeps track of the last 256 IP addresses so that we don't count a single user twice. Takes a filename as an argument, and stores the list of IPs in there. Written in C and using an efficient file format to avoid putting any load on the server.
hsbc.sh
A small shell script to allow Linux users to login to HSBC Australia's online banking. To use it you need to visit HSBC's online banking (you get an error message, but it it sets a cookie which is required for further operation). Then run this script and enter your PBN and PIN in the HTML form. You can now login to HSBC!