[R] R-code in html help pages: syntax highlighting

Jose Quesada quesada at gmail.com
Mon Mar 16 18:49:57 CET 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
 
Hi,

A follow up to my previous post. It'd be good to have syntax
highlighting in the html help pages. There is highlight
(http://www.andre-simon.de/) which seems to be open source. Since code
is delimited in the help file format, it should not be too difficult
to run a highlighting program (actually, vim and emacs do this too)
recursively and pretty-print all the R examples in the entire CRAN.
Including the highlighter with R, or whatever supplementary tools
people use to make R html help files could simplify things. I've never
written docs or released a package, so I may be understimating the
effort it'd take to get this working.

Using the r-help gmane archives also leads to plain code.
This is probably more trouble than it's worth, since there's no
metadata delimiting a block of code and it might be difficult... but
grepping through all R-help posts and coloring code would be really
nice too. Again, this lands straight into 'nice to have, but not
essential' territory.

If anyone wants to do this, feel free to.

Best,
- -J

- --
Jose Quesada, PhD.
Max Planck Institute,
Center for Adaptive Behavior and cognition,
Berlin
http://www.josequesada.name/           
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iQIVAwUBSb6RRGMobUVGH+HKAQI2RxAAijNIj7qlBogc9M6lhQ2Ah1Px29iU/uzS
45t5blwNSGVSbAbZF7N7rRcBdn8/c4W8n+oI62nnap0snwLMFW/ynikVNJuBY+XA
+yNaO5nIJo5SWu60WkcMinm/ysPZ4o4Jdxr1+lGfJ/ceVSTWPWVLb//GN8QElgwT
Vf0ZQUSqfWczzeVDSDtfMKGTJOz4y60eF5hounA/PkzyUd8RRo1WpEXzJHYsCTI+
RwBrYZ5Q30cpKLAJQNeiiv8GDtv7QvJl38uRAqBRK5Ec9CGC0brGZquX8UgHi1q1
1+NzHSt95E4Y0CKWPS48t+eO58MUE8v69gjLa9DdnhII4tCdAUURuP+AsaFm+hzP
a7OufMNnh/S8igDmqon0c9W6sJrkDo9DdrZPlu6MFjGQ5SbS6mSfvwSRKVd3RTCN
2/+uz0EwBygq1OKS+Z7Z+kx29UR8+bNXOGaPRlsr5CKcwVV9w3FBvEICuDaP75vj
l0d75+2R+CB/R/e2+dMMRCQY5MNWtYuuqoz3jNws59J+0z5K35usLoaKdB7Ez3D6
G2CCBKJSrugT0s8OkhX5pcTiU6NUIrq6q8h7JNEeuR0bniFClXlDrAs9iIdNb4PS
oFpqtNJWPLaicHRMnJdnxPCriHa0lmI3QVoGrf6UFtBAXuiOkFxcHUmTcQczyfOm
IGyGcgCko3o=
=djsT
-----END PGP SIGNATURE-----




More information about the R-help mailing list