File tree Expand file tree Collapse file tree 1 file changed +53
-1
lines changed Expand file tree Collapse file tree 1 file changed +53
-1
lines changed Original file line number Diff line number Diff line change @@ -146,7 +146,59 @@ We use `sphinx <https://www.sphinx-doc.org/en/master/>`__ to manage the document
146146
147147The source files for docs are .rst file in docs/source.
148148
149- For English docs, ``sphinx-build source build/html `` in docs dir is enough. The html version of the docs are in docs/build/html.
149+ For English docs, ``sphinx-build source build/html `` and ``make latexpdf LATEXMKOPTS="-silent" `` in docs dir are enough.
150+ The html and pdf version of the docs are in docs/build/html and docs/build/latex, respectively.
151+
152+ **Formula Environment Attention **
153+
154+ It should be noted that the formula environment ``$$CONTENT$$ `` in markdown is equivalent to the ``equation `` environment in latex.
155+ Therefore, in the jupyter notebook documents, do not nest the formula environment in ``$$CONTENT$$ `` that is incompatible with
156+ ``equation `` in latex, such as ``eqnarray ``, which will cause errors in the pdf file built by ``nbsphinx ``.
157+ However, compatible formula environments can be used. For example, this legal code in markdown
158+
159+ .. code-block :: markdown
160+
161+ $$
162+ \begin{split}
163+ X&=Y\\
164+ &=Z
165+ \end{split}
166+ $$
167+
168+ will be convert to
169+
170+ .. code-block :: latex
171+
172+ \begin {equation }
173+ \b egin{split}
174+ X&=Y\\
175+ &=Z
176+ \e nd{split}
177+ \end {equation }
178+
179+ in latex automatically by ``nbsphinx ``, which is a legal latex code. However, this legal code in markdown
180+
181+ .. code-block :: markdown
182+
183+ $$
184+ \begin{eqnarray}
185+ X&=&Y\\
186+ &=&Z
187+ \end{eqnarray}
188+ $$
189+
190+ will be convert to
191+
192+ .. code-block :: latex
193+
194+ \begin {equation }
195+ \b egin{eqnarray}
196+ X&=&Y\\
197+ &=&Z
198+ \e nd{eqnarray}
199+ \end {equation }
200+
201+ in latex, which is an illegal latex code.
150202
151203**Auto Generation of API Docs: **
152204
You can’t perform that action at this time.
0 commit comments