From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcin Borkowski Subject: Re: Embedded LaTeX does not work with Unicode quotes Date: Wed, 12 Nov 2014 19:37:19 +0100 Message-ID: <87sihonu3k.fsf@wmi.amu.edu.pl> References: <877fz1e7s5.fsf@wmi.amu.edu.pl> <87k331j6mr.fsf@pierrot.dokosmarshall.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58095) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XocnJ-0000MY-RW for emacs-orgmode@gnu.org; Wed, 12 Nov 2014 13:37:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XocnE-0001IS-5H for emacs-orgmode@gnu.org; Wed, 12 Nov 2014 13:37:29 -0500 Received: from msg.wmi.amu.edu.pl ([2001:808:114:2::50]:51607) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XocnD-0001I8-Up for emacs-orgmode@gnu.org; Wed, 12 Nov 2014 13:37:24 -0500 Received: from localhost (localhost [127.0.0.1]) by msg.wmi.amu.edu.pl (Postfix) with ESMTP id 5710D42071 for ; Wed, 12 Nov 2014 19:37:21 +0100 (CET) Received: from msg.wmi.amu.edu.pl ([127.0.0.1]) by localhost (msg.wmi.amu.edu.pl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uXNlipxf32dn for ; Wed, 12 Nov 2014 19:37:21 +0100 (CET) Received: from localhost (117-116.echostar.pl [213.156.117.116]) by msg.wmi.amu.edu.pl (Postfix) with ESMTPSA id CACC64206C for ; Wed, 12 Nov 2014 19:37:20 +0100 (CET) In-reply-to: <87k331j6mr.fsf@pierrot.dokosmarshall.org> 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: emacs-orgmode@gnu.org On 2014-11-12, at 07:05, Nick Dokos wrote: > Marcin Borkowski writes: > >> Hi list, >> >> I have this: =E2=80=9E$n\eps\le b$=E2=80=9D, and it seems not to be re= cognized as a >> LaTeX fragment. The manual says: >> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> To avoid conflicts with currency specifications, single `$' characters >> are only recognized as math delimiters if the enclosed text contains a= t >> most two line breaks, is directly attached to the `$' characters with = no >> whitespace in between, and if the closing `$' is followed by whitespac= e, >> punctuation or a dash. >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> >> When I C-u C-x =3D on the closing quote, I get >> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> ... >> syntax: . which means: punctuation >> ... >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> >> so I don't know why it is not recognized as punctuation. Consequently= , >> it is exported verbatim (with `\$') into LaTeX, and also (obviously) C= -c >> C-x C-l does not fontify it. When I change =E2=80=9D into " (the ASCI= I #x22 >> quote), everything is ok. >> > > The $...$ construct is recognized by a regexp which, while complicated, > is not complicated enough to recognize everything that's marked > "punctuation" in the syntax tables. Look for org-latex-regexps in org.e= l > (and note that the regexp for "$" is about twice as long as the next > longest regexp - the one for "begin"). The others (for \(...\), \[...\] > and $$..$$) are fairly trivial. > >> My questions: >> >> 1. Isn't it a bug? >> > > Yes, probably - but looking at the regexp, I cringe: I don't want to ev= en > try deciphering it, let alone change it - life's too short... Ah, regex. I have no more questions... >> 2. If not, what can I do to in my config so that it is recognized >> properly? >> >> PS. I just recalled that using \(...\) should help, and indeed it does= . >> Still, I'm curious about the answer to my questions (now that I >> remembered a workaround, especially #1). >> > That is indeed the best solution. Yep. Thanks! --=20 Marcin Borkowski http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski Adam Mickiewicz University