Externalized syntax highlighting to a package, fixing many small issues