From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: Expansion of macros conditional on export type Date: Fri, 27 May 2016 11:17:53 +0100 Message-ID: <87shx3954e.fsf@ucl.ac.uk> References: Reply-To: Eric S Fraga 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]:37121) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b6EqD-0004ux-82 for emacs-orgmode@gnu.org; Fri, 27 May 2016 06:18:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b6Eq9-0001im-1d for emacs-orgmode@gnu.org; Fri, 27 May 2016 06:18:04 -0400 Received: from mail-am1on0144.outbound.protection.outlook.com ([157.56.112.144]:17472 helo=emea01-am1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b6Eq8-0001ib-MQ for emacs-orgmode@gnu.org; Fri, 27 May 2016 06:18:00 -0400 In-Reply-To: (Giacomo M.'s message of "Fri, 27 May 2016 10:03:15 +0000") 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" To: Giacomo M Cc: "emacs-orgmode@gnu.org" > I know one way would be to use @@latex: ... @@ w/ ascii counterpart > each time, but I would rather envision a single macro, which then gets > defined in different way depending on the export, in order to reduce > redundancy. You can put all the different alternatives together? I do the following for degrees Celsius: #+macro: degc @@odt:=C2=B0C@@@@latex:\(^{\circ}\)C@@ Looks ugly but I don't have to look at it often. In text, I simply have {{{degc}}}. (minor aside: I wish macros had been defined to be used with [[[degc]]] instead as much easier to type than {{{degc}}}) --=20 : Eric S Fraga (0xFFFCF67D), Emacs 25.0.94.1, Org release_8.3.4-869-gf2c421