[From nobody Thu Nov 24 02:44:56 2005 Received: (qmail 32261 invoked by alias); 24 Nov 2005 03:23:45 -0000 Delivered-To: whytheluckystiff-net-why@whytheluckystiff.net Received: (qmail 32258 invoked from network); 24 Nov 2005 03:23:44 -0000 Received: from sigma.informatik.hu-berlin.de (141.20.20.51) by 72.9.109.163 with SMTP; 24 Nov 2005 03:23:44 -0000 Received: from [192.168.0.30] (dslb-084-059-140-163.pools.arcor-ip.net [84.59.140.163]) (authenticated bits=0) by sigma.informatik.hu-berlin.de (8.13.4+Sun/8.13.4/INF-2.0-MA-SOLARIS-2.10) with ESMTP id jAO3CvSw008948 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for <why@whytheluckystiff.net>; Thu, 24 Nov 2005 04:13:18 +0100 (CET) Message-ID: <43852FAE.3060502@cYcnus.de> Date: Thu, 24 Nov 2005 04:12:46 +0100 From: murphy <murphy@cYcnus.de> Organization: cYcnus User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: en-us, en MIME-Version: 1.0 To: why the lucky stiff <why@whytheluckystiff.net> Subject: Poignant Guide: highlighting with CodeRay instead? Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Status: No (sigma) X-Spam-Status: No, score=1.8 required=5.0 tests=RCVD_IN_NJABL_DUL, RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 X-Spam-Level: * X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on rabe hi why! Well, I tested replacing "Syntax" with "CodeRay", my highlighting lib in-development. The rubyforge website is here: http://rubyforge.org/projects/coderay/ Syntax does a good job, and maybe you should not change a running higlighter. But I think CodeRay could be more suitable for the Guide. Improvements would be: - more highlighting (eg. code inside strings) - more different token colors :D - 25% faster compiling (at least on my system) - bugfixes (syntax may crash on some code) - hints (if you move the cursor over a string, it says "String" etc.) - line numbers (if you want them) in the future: - highlighting for irb output - code-bits (eg. get \n highlighted as a char even outside a string) - whatever you want for the Guide, as CodeRay is in-development ;) The main drawback is that it is not released yet; documentation is incomplete, interface may change, etc. I don't recommend for anyone to rely on it before version 1.x - syntax highlighting can be a security issue for websites. Anyway, you can take look at the output: http://ruby.cycnus.de/guide/chapter-4.html or the website: http://rd.cYcnus.de/coderay and think about using it for the Guide in the future. hope you like it! [murphy] ]