There should be no new line after equation block in tex document #2171
iarkhanhelsky
commented
nick-ulle
commented
Even worse:
The formula
\begin{math}
x = y
\end{math}
should be inline.
This gets output as 3 paragraphs. The math
environment is equivalent to \(
or $
in Latex documents.
It seems like Pandoc has a general problem with handling new lines when translating Markdown to Latex. If I recall correctly, this is a limitation of the current Pandoc AST, so it can't be fixed using a filter. Perhaps an attribute could be added to Block
elements?
Generally pandoc treats any LaTeX environment it doesn't
know as a raw LaTeX block. There are a few cases, like this, where
that isn't appropriate, and we can special-case them.
I'd never seen the "math" environment used, but it will be
trivial to treat this like `\(..\)`.
+++ Nick Ulle [Jan 28 16 18:25 ]:
…
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Assuming following code part in
md
file :In
tex
file I should get same result without any new line after equation block. Because it's breaking identation rules used in latex. And no,\noindent
[ #894] is not a solution, because it ridiculous.