
markdown.sty
私は Overleaf を使用しています。これは、 ( が必要)を含めるのを簡単にしてくれるので便利です--shell-escape
。 を使って本の章を含めることができるので\markdownInput{chaptername.md}
、LaTeX を知らない共著者が、章にマークダウンを書き込むだけで、Overleaf 経由で私と共同作業できます。
markdown は明確な LaTeX コマンドを通過できます。これにより、 などのコマンドを簡単に含めることができます。また、間接的に展示にも機能します。すべての展示を定義したファイル\clearpage
があります。exhibits.tex
\providecommand{\figuretwentytwo}{%
\begin{figure}
\myspecialcaption[mylabel]{My Figure 22}
There is all sorts of figure stuff here.
\end{figure}
}
次に、各図に LaTeX マクロを挿入しますchaptername.md
。これは機能しますが、扱いにくくなっています。図と表が数十個あります。
ある領域を純粋な LaTeX 用に隔離しchaptername.md
、その領域を Markdown によって翻訳せず、タイプセット用に純粋な LaTeX としてのみ返すように markdown.sty に指示する方法はありますか?
chapter.md:
# Chapter 2
This is **nice** and simple markdown. We will do
1. one
2. two
3. and three.
Let me show you in a figure.
```latex passback
\providecommand[mylabel]{\figuretwentytwo}{%
\begin{figure}
\myspecialcaption{My Figure 22}
There is all sorts of figure stuff here.
\end{figure}
}
```
[Figure ](mylabel) does stuff.
これは実現可能ではないかもしれないが、かゆいところを掻きむしることになるだろう。