From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alan Schmitt Subject: Re: Org Babel blocks exports dollar signs to LaTeX verbatim Date: Fri, 04 Sep 2015 13:57:11 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35076) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZXpcQ-0007u4-Hh for emacs-orgmode@gnu.org; Fri, 04 Sep 2015 07:57:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZXpcK-0005SY-SX for emacs-orgmode@gnu.org; Fri, 04 Sep 2015 07:57:22 -0400 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]:30198) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZXpcK-0005S1-MG for emacs-orgmode@gnu.org; Fri, 04 Sep 2015 07:57:16 -0400 In-Reply-To: (Matthew MacLean's message of "Tue, 18 Aug 2015 10:13:52 -0600") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Matthew MacLean Cc: emacs-orgmode@gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable (Still catching up on orgmode mail =E2=80=A6 sorry if you already found a w= ay to address the issue) On 2015-08-18 18:13, Matthew MacLean writes: > When working with Org Babel source code blocks, if I have a dollar sign i= n my > code and export it to PDF using LaTeX, it appears to parse as an internal > link. (Maybe?) > > This is what it looks like: > Inline image 1 > That comes from the following source code block: > > #+BEGIN_SRC sql :eval no :var id=3D1 > SELECT * FROM blah > WHERE id=3D$id > #+END_SRC > > The resulting LaTeX from the source code block is: > > \begin{minted}[]{sql} > SELECT * FROM blah > WHERE id=3D$id > \end{minted} > > I have verified that SQL is not the only block type to do this by having a > Ruby block with nothing except a "$" in it, and got the same result. These red boxes often come from signaling a syntax error from pygments, which I confirmed by putting the code in a test.sql file and running: % pygmentize -f latex test.sql \begin{Verbatim}[commandchars=3D\\\{\}] \PY{k}{SELECT} \PY{o}{*} \PY{k}{FROM} \PY{n}{blah} \PY{k}{WHERE} \PY{n}{id}\PY{o}{=3D}\PY{err}{\PYZdl{}}\PY{n}{id} \end{Verbatim} You can see the =E2=80=9C\PY{err}=E2=80=9D that signals a parser error arou= nd the dollar sign. There are some solutions to hide these boxes here: http://tex.stackexchange.com/questions/14166/red-box-drawn-around-question-= mark-operator-in-minted-erlang-code Best, Alan =2D-=20 OpenPGP Key ID : 040D0A3B4ED2E5C7 Last week athmospheric CO=E2=82=82 average (Updated August 31, 2015, Mauna = Loa Obs.): 377.82 ppm --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBCgAGBQJV6YcXAAoJEAQNCjtO0uXHWA8H/i98ATwCoRyUYj0L45+EAi3j Hd9FjZZaqveMB/MGGnWnr0l8Abkj5hw2Gr66q6SdBr4lEnkrjR3v7pwTBzjPlzC7 4TPskz3gjrU5jvDOL6KRszj/bW3pFhuSUUfFMRl/vY+uCbwzP+H7gACmk0n9aWs7 XX8lBawCxjusE5JCIO2f/JZKR9eaLwfksrFEH8cm6xX4mc9sYNMXpRxL50ktLlJG 9Xj3Z+xEEctIaYtWwE+15UvJxikPbEPx6kosYwvV6Hnyq/k8lSQ6vdcU9I4SoxSh Gw+4AV+3tmpv+/GVuO5iKvntfWYzTDyFaWK6GGG3wtZVbcgKqG2AWlLtbjlDPD8= =aqq2 -----END PGP SIGNATURE----- --=-=-=--