From my first project report containing code at school I had the need to create a syntax highlighting tool for These last years I had no time to do it. Even if I don't have more currently, having stopped the Eclipse plugin for development gives me a little more time for it.

To implement such a tool, I started from GeSHi, the famous PHP tool for syntax highlightinh. I'm converting the GeSHi algorithm into a Java extension for The only problem is that applying styles for the highlighting imposes rethinking some parts of the algorithm. For example:

  • GeSHi adds the style for a string before having found its end. In I need to get the end of the string before defining its style.
  • GeSHi defines the style of the escaped characters first and then finds the end of the string. In I first need to get the end of the string to set the string style before setting the escaped characters style.

After some other troubles like these there will be an extension to format source code in a clean and easy way. Thus stay tuned...