Support for definition lists in LaTeX writer.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@586 788f1e2b-df1e-0410-8736-df70ead52e1b
This commit is contained in:
parent
ffd7248af8
commit
7742301c09
1 changed files with 6 additions and 1 deletions
|
@ -110,6 +110,12 @@ blockToLaTeX (BulletList lst) = "\\begin{itemize}\n" ++
|
|||
(concatMap listItemToLaTeX lst) ++ "\\end{itemize}\n"
|
||||
blockToLaTeX (OrderedList lst) = "\\begin{enumerate}\n" ++
|
||||
(concatMap listItemToLaTeX lst) ++ "\\end{enumerate}\n"
|
||||
blockToLaTeX (DefinitionList lst) =
|
||||
let defListItemToLaTeX (term, def) = "\\item[" ++
|
||||
substitute "]" "\\]" (inlineListToLaTeX term) ++ "] " ++
|
||||
concatMap blockToLaTeX def
|
||||
in "\\begin{description}\n" ++ concatMap defListItemToLaTeX lst ++
|
||||
"\\end{description}\n"
|
||||
blockToLaTeX HorizontalRule =
|
||||
"\\begin{center}\\rule{3in}{0.4pt}\\end{center}\n\n"
|
||||
blockToLaTeX (Header level lst) =
|
||||
|
@ -141,7 +147,6 @@ blockToLaTeX (Table caption aligns widths heads rows) =
|
|||
else "\\begin{table}[h]\n" ++ centered tableBody ++ "\\caption{" ++
|
||||
captionText ++ "}\n" ++ "\\end{table}\n\n"
|
||||
|
||||
|
||||
printDecimal :: Float -> String
|
||||
printDecimal = printf "%.2f"
|
||||
|
||||
|
|
Loading…
Reference in a new issue