Just to make things clear on this, there is no 100% ssecure method to lock your computer so depending on your requirements this might not cut it. Even with the screen locked, Ctrl-Alt-Bkspace will still kill X leaving a malicious user with access to play with your files or even just restart X. Switching to other VTs generally still works as well with the screen locked.
The best way is to start X as so:
That way as soon as X exits your user logs out so if someone does come along and kill X they won't have access to your terminal either. Might not be applicable if you're just trying to keep your brother off your MSN but probably worth knowing at any rate