\TeXtiles

Thanks to Wouter for finding it (as some of you will have already seen) we now have a \LaTeX plugin to pull off crazy stunts such as:

$\bfig \Vtrianglepair/>`<-`>`..>`>/[A`A+B`B`C ;\mathrm{inl}`\mathrm{inr}`f`{[f,g]}`g] \efig$

Hmm, I wonder if I can get Conor’s Epigram macros into it…

UPDATE:


$\footnotesize
\AR{
\RW{data}\;\;
\Axiom{\TC{Nat}\hab \Type}\;\;
\RW{where}\;\;
\Axiom{\DC{zero}\hab\TC{Nat}}\;\;
\Rule{\vn\hab\TC{Nat}}{\DC{suc}\;\vn\hab\TC{Nat}}\\
\RW{let}\;\;
\Rule{\vm, \vn\hab\TC{Nat}}{\vm\FN{+}\vn\hab\TC{Nat}}\\
\begin{array}{llll}
\vm & \FN{+} & \vn & \BY\RW{rec}\;\vm\\
\;\;\DC{zero}& \FN{+} & \vn & \cq \vn \\
\;\;(\DC{suc}\ \vm) & \FN{+} & \vn & \cq\DC{suc}\;(\vm\FN{+}\vn)\\
\end{array}}$

Yes, it seems I can.

It guess the next thing people would want is lhs2tex. I’m on it

UPDATE 2:

%format ^+^ = &#8220;\ensuremath{\oplus}&#8221;

> data Nat        = Zero
>                 | Succ Nat
>
> (^+^)            :: Nat -> Nat -> Nat
> Zero      ^+^ n  = n
> (Succ m)  ^+^ n  = Succ (m ^+^ n)

BINGO

4 Responses to “\TeXtiles”

  1. Cyril Konopko says:

    It looked much better a couple of hours ago… Why do I see tex source instead of beatiful pictures now?

  2. pwm says:

    oops

  3. Cyril Konopko says:

    Yes, now it’s better

  4. txa says:

    Great! You don’t need to post the source-code because we can see it anyway.

Leave a Reply