highlighting-kate-0.5.8.5: Syntax highlighting

Portabilityportable
Stabilityalpha
MaintainerJohn MacFarlane <jgm@berkeley.edu>
Safe HaskellNone

Text.Highlighting.Kate.Syntax

Description

Token lexer for various languages.

Synopsis

Documentation

highlightAsSource

Arguments

:: String

Language syntax (e.g. haskell) or extension (e.g. hs).

-> String

Source code to highlight

-> [SourceLine]

List of highlighted source lines

Highlight source code. The source language may be specified by its canonical name (case-insensitive) or by a canonical extension (if unique). The parsers read the input lazily and parse line by line; results are returned immediately. Supported languages: actionscript, ada, alert, alert_indent, apache, asn1, asp, awk, bash, bibtex, boo, c, changelog, clojure, cmake, coffee, coldfusion, commonlisp, cpp, cs, css, curry, d, diff, djangotemplate, doxygen, doxygenlua, dtd, eiffel, email, erlang, fortran, fsharp, gcc, gnuassembler, go, haskell, haxe, html, ini, isocpp, java, javadoc, javascript, json, jsp, julia, latex, lex, literatecurry, literatehaskell, lua, makefile, mandoc, markdown, matlab, maxima, metafont, mips, modelines, modula2, modula3, monobasic, nasm, noweb, objectivec, objectivecpp, ocaml, octave, pascal, perl, php, pike, postscript, prolog, pure, python, r, relaxngcompact, restructuredtext, rhtml, roff, ruby, rust, scala, scheme, sci, sed, sgml, sql, sqlmysql, sqlpostgresql, tcl, texinfo, verilog, vhdl, xml, xorg, xslt, xul, yacc, yaml.

languages :: [String]Source

List of supported languages.

languagesByExtension :: String -> [String]Source

Returns a list of languages appropriate for the given file extension.

languagesByFilename :: FilePath -> [String]Source

Returns a list of languages appropriate for the given filename.