HaTeX-2.0.1: Library for write LaTeX code.




LaTeX Monad

type LaTeXT m a = WriterT Result m aSource

LaTeXT is the monadic transformer that represents LaTeX code. Bind operator plays as concatenator.

Instances of LaTeXT:

type LaTeX m = LaTeXT m ()Source

Basic functions over LaTeX Monad

lx :: Monad m => Result -> LaTeX mSource

Write a result.

lxany :: (Monad m, Show a) => a -> LaTeX mSource

Write anything of Show class.

lxw :: Monad m => Result -> LaTeXT m aSource

Like lx, but returns an undefined value.

lxanyw :: (Monad m, Show b) => b -> LaTeXT m aSource

Like lxany, but returns an undefined value.

nlx :: Monad m => LaTeXT m a -> m ResultSource

Run a LaTeXT computation.

mlx :: Monad m => m a -> LaTeXT m aSource

Performs a monadic computation, returning his value in the LaTeXT monad.

reslx :: Monad m => (Result -> Result) -> LaTeXT m a -> LaTeXT m aSource

Transform a Result modifier in a LaTeXT modifier.


genlx :: Monad m => LaTeX m -> LaTeXT m aSource

ungenlx :: Monad m => LaTeXT m a -> LaTeX mSource