307
308
309
310
311
312
313
314
315
316
317
318
319
320
|
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
|
+
|
* Use a Javascript library that renders the code within your browser. One solution for this might be <a href="http://code.google.com/p/syntaxhighlighter">Google Syntax Highlighter</a>
I estimate that the <i>pipe</i> solution needs some more work/ code changes. Thus I am solely looking at the Javascript solution.
The SyntaxHighlighter is a library of some Javascript files, a little Flash application and a CSS file. The Flash application is for copying to clipboard, print and view source. You have the option to include all the files into your repository or use the files hosted at Google. The latter may only be an option if you are connected to internet all the time.
For syntax highlighting to work the Header and Footer templates need to be modified and a little code change has to be applied to the Fossil sources.
The examples below assume you have added the syntax highlighting library to your repository into a directory www/scripts.
<p>
<b>Header</b>
<pre>
<html>
<head>
<title>$<project_name>: $<title></title>
<link rel="alternate" type="application/rss+xml" title="RSS Feed"
|