converted from TextMate version, hand-edited to better support 256 colors