git.iko.soy/typeable/pandoc
on 1.9.0.5 help sign in
typeable/pandoc/tests/lhs-test.latex
81 lines 2.9 kB history raw
1\documentclass[]{article}
2\usepackage{amssymb,amsmath}
3\usepackage{ifxetex,ifluatex}
4\ifxetex
5 \usepackage{fontspec,xltxtra,xunicode}
6 \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
7\else
8 \ifluatex
9 \usepackage{fontspec}
10 \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
11 \else
12 \usepackage[utf8]{inputenc}
13 \fi
14\fi
15\usepackage{color}
16\usepackage{fancyvrb}
17\DefineShortVerb[commandchars=\\\{\}]{\|}
18\DefineVerbatimEnvironment{Highlighting}{Verbatim}{commandchars=\\\{\}}
19% Add ',fontsize=\small' for more characters per line
20\newenvironment{Shaded}{}{}
21\newcommand{\KeywordTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{\textbf{{#1}}}}
22\newcommand{\DataTypeTok}[1]{\textcolor[rgb]{0.56,0.13,0.00}{{#1}}}
23\newcommand{\DecValTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
24\newcommand{\BaseNTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
25\newcommand{\FloatTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
26\newcommand{\CharTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
27\newcommand{\StringTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
28\newcommand{\CommentTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textit{{#1}}}}
29\newcommand{\OtherTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{{#1}}}
30\newcommand{\AlertTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
31\newcommand{\FunctionTok}[1]{\textcolor[rgb]{0.02,0.16,0.49}{{#1}}}
32\newcommand{\RegionMarkerTok}[1]{{#1}}
33\newcommand{\ErrorTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
34\newcommand{\NormalTok}[1]{{#1}}
35\ifxetex
36 \usepackage[setpagesize=false, % page size defined by xetex
37 unicode=false, % unicode breaks when used with xetex
38 xetex,
39 colorlinks=true,
40 linkcolor=blue]{hyperref}
41\else
42 \usepackage[unicode=true,
43 colorlinks=true,
44 linkcolor=blue]{hyperref}
45\fi
46\hypersetup{breaklinks=true, pdfborder={0 0 0}}
47\setlength{\parindent}{0pt}
48\setlength{\parskip}{6pt plus 2pt minus 1pt}
49\setlength{\emergencystretch}{3em} % prevent overfull lines
50\setcounter{secnumdepth}{0}
53\begin{document}
55\section{lhs test}
57\texttt{unsplit} is an arrow that takes a pair of values and combines them to
58return a single value:
60\begin{Shaded}
61\begin{Highlighting}[]
62\OtherTok{unsplit ::} \NormalTok{(}\DataTypeTok{Arrow} \NormalTok{a) }\OtherTok{=>} \NormalTok{(b }\OtherTok{->} \NormalTok{c }\OtherTok{->} \NormalTok{d) }\OtherTok{->} \NormalTok{a (b, c) d}
63\NormalTok{unsplit }\FunctionTok{=} \NormalTok{arr }\FunctionTok{.} \FunctionTok{uncurry}
64 \CommentTok{-- arr (\textbackslash{}op (x,y) -> x `op` y) }
65\end{Highlighting}
66\end{Shaded}
67\texttt{(***)} combines two arrows into a new arrow by running the two arrows
68on a pair of values (one arrow on the first item of the pair and one arrow on
69the second item of the pair).
71\begin{verbatim}
72f *** g = first f >>> second g
73\end{verbatim}
74Block quote:
76\begin{quote}
77foo bar
79\end{quote}
81\end{document}