Scala William's Sygments: Visual Pygments for Scala
What is it?
Sygments is a syntax highlighting service and HTML5 app that uses Jython and Pygments.
Pygments is an excellent program syntax highlighter developed in Python.
Sygments lets you try different Pygments themes against a range of programming languages, including custom backgrounds.
It is especially suited for creating presentations.
See the demo at http://sygments.herokuapp.com/
Here is a sample rendering. It looks lovely:
What problem does it solve?
Syntax highlighter themes do not work well with custom backgrounds. I had chosen a background in Google Presentations but it did not work nicely with IntelliJ's highlighting for XQuery and Scala.
Finding the right syntax highlighting theme for the background you've chosen
Highlighting your code so it is ready to be copy-and-pasted straight into Google Presentation or other targets
Out of the initial manual work, I created this nice usable app.
- Install Java and SBT
- Go to (http://localhost:9000/)
If you want to host this behind an nginx reverse proxy and need to configure a context path, then add the
-DcontextPath=/some/place to the above line of code.
Highlighter interface performance:
- Play 2.4
Please refer to source material for copyright detail. The intention of this code is fair use, attributing authors via a web link.
Sygments back end code is available under the MIT license.