public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: BPJ <melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: pandoc-discuss <pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
Subject: Re: Pandoc to (La)TeX creates ampersands inside tables
Date: Wed, 15 Sep 2021 09:49:02 +0200	[thread overview]
Message-ID: <CADAJKhBidpr9MJSZ7foO4yo3w0quvckLzzvDAUA4EF8d-5k5ew@mail.gmail.com> (raw)
In-Reply-To: <0967c094-0aeb-45a2-a617-34eb476aa189n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 2475 bytes --]

LaTeX uses & to separate the cells/columns in table rows so `foo & bar &
baz \\` is one row with three cells/columns with the text "foo", "bar" and
"baz" respectively. That is perfectly normal. If these ampersands show up
in your PDF something else is wrong somewhere. It is impossible to tell
what it is without seeing your Markdown source for the whole table and the
LaTeX Pandoc produces from it. Try to get a minimal working example (MWE)
by copying the Markdown source for just the table into a file of its own
and converting that to LaTeX and PDF. If the problem persists attach the
input and output from the MWE to a message so we can have a look at it
(obviously removing/replacing any sensitive content as long as it doesn't
affect the result.)

Disclaimer: I am not a Pandoc developer, just another user who knows a
thing or two about LaTeX.

/bpj

Den ons 15 sep. 2021 09:27Ferty <felixcreates-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:

> I am using Pandoc to turn my latest book, written in markdown, into Tex.
> On the way, Pandoc adds & (ampersand) to the one table I have in the book.
> So this
>
> | Sample                    | 14 €/kg |
>
> gets turned into this:
>
> Sample & 14\,€/kg \\
>
> Which, of course, creates problems during my conversion from tex to pdf
> further up the road.
>
> Why does Pandoc do that? How can I stop it?
> Using Pandoc to go from Markdown straight to PDF works fine
>
> --
> You received this message because you are subscribed to the Google Groups
> "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pandoc-discuss/0967c094-0aeb-45a2-a617-34eb476aa189n%40googlegroups.com
> <https://groups.google.com/d/msgid/pandoc-discuss/0967c094-0aeb-45a2-a617-34eb476aa189n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CADAJKhBidpr9MJSZ7foO4yo3w0quvckLzzvDAUA4EF8d-5k5ew%40mail.gmail.com.

[-- Attachment #2: Type: text/html, Size: 3477 bytes --]

      parent reply	other threads:[~2021-09-15  7:49 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-15  7:26 Ferty
     [not found] ` <0967c094-0aeb-45a2-a617-34eb476aa189n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2021-09-15  7:49   ` BPJ [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CADAJKhBidpr9MJSZ7foO4yo3w0quvckLzzvDAUA4EF8d-5k5ew@mail.gmail.com \
    --to=melroch-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).