aboutsummaryrefslogtreecommitdiff
path: root/test/command
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2018-08-15 10:25:12 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2018-08-15 10:25:12 -0700
commit13dea94a9128a4caf3fb820bb21cd8176465c82e (patch)
tree96ec7405b1498d108cfcb04886b5d2e1c8ca148c /test/command
parent2ae82727546c1a989148b0ca34ae35fd2158cee6 (diff)
downloadpandoc-13dea94a9128a4caf3fb820bb21cd8176465c82e.tar.gz
Markdown reader: Use "tex" instead of "latex" for raw tex-ish content.
We can't always tell if it's LaTeX, ConTeXt, or plain TeX. Better just to use "tex" always. Also changed: ConTeXt writer: now outputs raw "tex" blocks as well as "context". (Closes #969). RST writer: uses ".. raw:: latex" for "tex" content. (RST doesn't support raw context anyway.) Note that if "context" or "latex" specifically is desired, you can still force that in a markdown document by using the raw attribute (see MANUAL.txt): ```{=latex} \foo ``` Note that this change may affect some filters, if they assume that raw tex parsed by the Markdown reader will be RawBlock (Format "latex"). In most cases it should be trivial to modify the filters to accept "tex" as well.
Diffstat (limited to 'test/command')
-rw-r--r--test/command/3558.md4
-rw-r--r--test/command/3804.md2
-rw-r--r--test/command/3947.md2
-rw-r--r--test/command/4056.md2
-rw-r--r--test/command/4159.md2
-rw-r--r--test/command/4781.md2
-rw-r--r--test/command/adjacent_latex_blocks.md4
-rw-r--r--test/command/hspace.md6
-rw-r--r--test/command/write18.md2
9 files changed, 13 insertions, 13 deletions
diff --git a/test/command/3558.md b/test/command/3558.md
index 795858b78..956b09e57 100644
--- a/test/command/3558.md
+++ b/test/command/3558.md
@@ -6,7 +6,7 @@ hello
\endmulti
^D
-[RawBlock (Format "latex") "\\multi"
+[RawBlock (Format "tex") "\\multi"
,Para [Str "hello"]
-,RawBlock (Format "latex") "\\endmulti"]
+,RawBlock (Format "tex") "\\endmulti"]
```
diff --git a/test/command/3804.md b/test/command/3804.md
index c13c2ef42..520d408df 100644
--- a/test/command/3804.md
+++ b/test/command/3804.md
@@ -2,5 +2,5 @@
% pandoc -t native
\titleformat{\chapter}[display]{\normalfont\large\bfseries}{第\thechapter{}章}{20pt}{\Huge}
^D
-[RawBlock (Format "latex") "\\titleformat{\\chapter}[display]{\\normalfont\\large\\bfseries}{\31532\\thechapter{}\31456}{20pt}{\\Huge}"]
+[RawBlock (Format "tex") "\\titleformat{\\chapter}[display]{\\normalfont\\large\\bfseries}{\31532\\thechapter{}\31456}{20pt}{\\Huge}"]
```
diff --git a/test/command/3947.md b/test/command/3947.md
index 7ce0be171..b1d695fbd 100644
--- a/test/command/3947.md
+++ b/test/command/3947.md
@@ -6,6 +6,6 @@
Another Code block
^D
-[RawBlock (Format "latex") "\\newpage"
+[RawBlock (Format "tex") "\\newpage"
,CodeBlock ("",[],[]) "Code block\n\nAnother Code block"]
```
diff --git a/test/command/4056.md b/test/command/4056.md
index eed4f6d6a..e972931dd 100644
--- a/test/command/4056.md
+++ b/test/command/4056.md
@@ -5,7 +5,7 @@
\end{shaded}
}
^D
-[RawBlock (Format "latex") "\\parbox[t]{0.4\\textwidth}{\n\\begin{shaded}\n\\end{shaded}\n}"]
+[RawBlock (Format "tex") "\\parbox[t]{0.4\\textwidth}{\n\\begin{shaded}\n\\end{shaded}\n}"]
```
```
diff --git a/test/command/4159.md b/test/command/4159.md
index 4881edcc5..d61959950 100644
--- a/test/command/4159.md
+++ b/test/command/4159.md
@@ -3,6 +3,6 @@
\newcommand{\gen}{a\ Gen\ b}
abc
^D
-[RawBlock (Format "latex") "\\newcommand{\\gen}{a\\ Gen\\ b}"
+[RawBlock (Format "tex") "\\newcommand{\\gen}{a\\ Gen\\ b}"
,Para [Str "abc"]]
```
diff --git a/test/command/4781.md b/test/command/4781.md
index 7dc973c7c..8a75e09a0 100644
--- a/test/command/4781.md
+++ b/test/command/4781.md
@@ -7,7 +7,7 @@ Markdown parsed *here*
*But not here*
^D
[Para [Str "Markdown",Space,Str "parsed",Space,Emph [Str "here"]]
-,RawBlock (Format "latex") "\\include{command/bar}"
+,RawBlock (Format "tex") "\\include{command/bar}"
,Para [Emph [Str "But",Space,Str "not",Space,Str "here"]]]
```
diff --git a/test/command/adjacent_latex_blocks.md b/test/command/adjacent_latex_blocks.md
index 3e72f1d4f..e7dc6d895 100644
--- a/test/command/adjacent_latex_blocks.md
+++ b/test/command/adjacent_latex_blocks.md
@@ -4,6 +4,6 @@
\listoftables
^D
-[RawBlock (Format "latex") "\\listoffigures"
-,RawBlock (Format "latex") "\\listoftables"]
+[RawBlock (Format "tex") "\\listoffigures"
+,RawBlock (Format "tex") "\\listoftables"]
```
diff --git a/test/command/hspace.md b/test/command/hspace.md
index ec1669ca5..a8b97b8bc 100644
--- a/test/command/hspace.md
+++ b/test/command/hspace.md
@@ -8,7 +8,7 @@ Here they need to be inline:
\caption{lalune \hspace{2em} \vspace{1em} bloo}
\end{figure}
^D
-[RawBlock (Format "latex") "\\begin{figure}\n\\includegraphics{lalune.jpg}\n\\caption{lalune \\hspace{2em} \\vspace{1em} bloo}\n\\end{figure}"]
+[RawBlock (Format "tex") "\\begin{figure}\n\\includegraphics{lalune.jpg}\n\\caption{lalune \\hspace{2em} \\vspace{1em} bloo}\n\\end{figure}"]
```
Here block:
@@ -32,7 +32,7 @@ F & T &\\
F & F &\\
\end{tabular}
^D
-[RawBlock (Format "latex") "\\begin{tabular}[t]{cc|c}\n\\(P\\) & \\(Q\\) & \\(P\\wedge Q\\)\\\\\n\\hline\nT & T &\\\\\nT & F &\\\\\nF & T &\\\\\nF & F &\\\\\n\\end{tabular}\n\\hspace{1em}\n\\begin{tabular}[t]{cc|c}\n\\(P\\) & \\(Q\\) & \\(P\\vee Q\\)\\\\\n\\hline\nT & T &\\\\\nT & F &\\\\\nF & T &\\\\\nF & F &\\\\\n\\end{tabular}"]
+[RawBlock (Format "tex") "\\begin{tabular}[t]{cc|c}\n\\(P\\) & \\(Q\\) & \\(P\\wedge Q\\)\\\\\n\\hline\nT & T &\\\\\nT & F &\\\\\nF & T &\\\\\nF & F &\\\\\n\\end{tabular}\n\\hspace{1em}\n\\begin{tabular}[t]{cc|c}\n\\(P\\) & \\(Q\\) & \\(P\\vee Q\\)\\\\\n\\hline\nT & T &\\\\\nT & F &\\\\\nF & T &\\\\\nF & F &\\\\\n\\end{tabular}"]
```
```
@@ -51,6 +51,6 @@ hi
there
^D
[Para [Str "hi"]
-,RawBlock (Format "latex") "\\hspace{1em}"
+,RawBlock (Format "tex") "\\hspace{1em}"
,Para [Str "there"]]
```
diff --git a/test/command/write18.md b/test/command/write18.md
index 344dfc8cf..5000c298b 100644
--- a/test/command/write18.md
+++ b/test/command/write18.md
@@ -3,7 +3,7 @@ Handle \write18{..} as raw tex:
% pandoc -t native
\write18{git --version}
^D
-[RawBlock (Format "latex") "\\write18{git --version}"]
+[RawBlock (Format "tex") "\\write18{git --version}"]
```
```