Visible line-numbers in emacs

I was asked about adding line-numbers down the side of code in emacs; This is the solution.

I was asked about adding line-numbers down the side of code in emacs; This is the solution.
The standard X11 fonts aren’t bad, but there are better options. In particular there are fonts designed for programming that give better symbol/number/parentheses contrast and are clearer at small sizes:
For terminal apps I use SGI’s ‘screen‘.
For applications that use fontconfig you should just be able to drop these into your ~/.fonts directory and (possibly) run fc-cache. However if your application doesn’t use fontconfig (Emacs is probably the only one you’ll use nowadays) the following is how to install these into the X server:
Copy the font files to a directory that is visible to the x-server’s Font Path. You may check the font path of the running server by typing the command:
xset q
On my FreeBSD machine I chose /usr/X11R6/lib/X11/fonts/misc/ to hold these new fonts. Next, you need to update the index file ‘fonts.dir’ by running ‘mkfontdir’. Here’s the command I used for my path:
mkfontdir /usr/X11R6/lib/X11/fonts/misc/
If you don’t want to restart your X server, you can update your current X session using:
xset fp rehash
Otherwise restarting X will also load the new fonts.
(I got these instructions off the web, I forget where from.) You may also need to restart the X font server.
Also for emacs users, alt-font-menu makes selecting these fonts easier.
I ordered a wireless controller from Games-Warehouse for my home Xbox (which is hacked to act as a media-center). This morning I received an email from them (edited highlights follow):
We have been unable to locate you in the White Pages at the address supplied (the National Australia Bank recommends we use the White Pages as a tool to help us prevent credit card fraud).
The address was the University of Sydney.
We accept payment by alternate methods which do not require address verification. These payment options are Direct Deposit, Money Orders and Cheque.
… however we won’t supply information on how to do this here.
We will need you to photocopy an official letter showing the credit card billing address (eg. Credit Card Statement showing the cards billing address, a rates notice/telephone bill showing billing address or a letter from a government department etc.) and fax it to us at…
Sure, I carry those around with me all the time.
My reply:
Hi,
Please cancel this order.
Thanks,
Steve
I sympathise with them wishing to prevent CC fraud, but I’ve never been asked for this before, and preemptively implying your customer may be a thief and then making it difficult give them your money is no way to run a business.
I’ve been fiddling with upgrading a couple of Ubuntu installations to the beta version of the upcoming ‘Breezy’ release. The now includes Cairo as the GTK backend, but I couldn’t work out why the colour-picker wasn’t being anti-aliased. As it turns out the Gimp uses its own picker, but if you access GTK built-in version (eg. in the panel properties) you get this:

http://hugin.sourceforge.net/
I spent a bit of the weekend on lisp-hacking and revisited my lisp version of the 'Lattice' server. I'd started this at LinuxConf but continually ran into issues with implementing truely asyncronous reads in SBCL's sockets. There are various fragments of code showing how to do this around, but they all use Lisp's native read, and my experiments show it would block, which is potentially disastrous in real-world usage. However I eventually worked out that I should be using sb-bsd-sockets:socket-receive, which is implemented with recvfrom. After nailing-down the various error conditions that can be returned (it's rather inconsistent there) I now have a toy single-threaded server implementation:
(Update: as somebody has asked to use this, I hearby place my portions of the code in the public domain)