Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 15
- Log:
Attempt to update Typo to a Typo SVN HEAD release from around the
time the prototype installation was set up on the RISC OS Open Limited
web site. Timestamps place this at 04-Jul so a revision from 05-Jul or
earlier was pulled and copied over the 2.6.0 tarball stable code.
- Author:
- adh
- Date:
- Sat Jul 22 23:27:35 +0100 2006
- Size:
- 1010 Bytes
1 | Because Syntax was written primarily to support syntax highlighting, that is going to be the task most clients of the library will use it for. So, to get you up and running quickly, converting, for example, Ruby code to HTML, consider the following: |
2 | |
3 | {{{lang=ruby,number=true,caption=Convert a Ruby script to HTML |
4 | require 'syntax/convertors/html' |
5 | |
6 | convertor = Syntax::Convertors::HTML.for_syntax "ruby" |
7 | html = convertor.convert( File.read( "program.rb" ) ) |
8 | |
9 | puts html |
10 | }}} |
11 | |
12 | The above script will convert a Ruby file called @program.rb@ to HTML, writing the HTML to stdout. HTML @span@ tags will be used in conjunction with "class" attributes to describe the various tokens--this allows you to use CSS to colorize the result. |
13 | |
14 | Incidentally, this entire document uses the Syntax library to colorize the Ruby code snippets! |
15 | |
16 | _Note: currently, only HTML conversion is supported, but it should be possible to create a convertor that takes the tokenized output and emits other formats, like LaTeX, PDF, or Rich Text._ |