package higlo
Syntax highlighting library
Install
Dune Dependency
Authors
Maintainers
Sources
higlo-0.10.0.tar.bz2
md5=8e6ad939c2e0fd0640efd4a10e4137fd
sha512=fdccc8aaebe084f0b5e5dfbeabf5a1b94186ef023431492c2083d9949237761946c7e9e195a4a81fc0f72032224f4942d3adb2590aa22ff35804b2d9bc2ea902
doc/higlo/Higlo/Printers/index.html
Module Higlo.Printers
Source
Printers for the higlo tool.
Source
type classes = {
bcomment : string;
constant : string;
directive : string;
escape : string;
id : string;
keyword : int -> string;
lcomment : string;
numeric : string;
string : string;
symbol : int -> string;
text : string;
title : int -> string;
}
This structure defines the (X)HTML classes to use when producing XML.
Map a token to an XML tree (just a <span class="...">code</span>
node).
Same as token_to_xml
but return a Xtmpl.Rewrite.tree
.
to_xtmpl ~lang code
gets the lexer associated to the language lang
, uses it to retrieve a list of tokens (using the Lang.parse
function) and maps these tokens to XML nodes. See token_to_xml
about the classes
parameter.
Same as to_xml
but return a Xtmpl.Rewrite.tree
.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>