From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 2M0UMRfbkWNyWQEAbAwnHQ (envelope-from ) for ; Thu, 08 Dec 2022 13:39:51 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id gEcRMRfbkWPuagEA9RJhRA (envelope-from ) for ; Thu, 08 Dec 2022 13:39:51 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 5D2A13E75D for ; Thu, 8 Dec 2022 13:39:51 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p3GBU-0006oT-6C; Thu, 08 Dec 2022 07:39:28 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p3GB8-0006kQ-DG for emacs-orgmode@gnu.org; Thu, 08 Dec 2022 07:39:11 -0500 Received: from mail-pj1-x1030.google.com ([2607:f8b0:4864:20::1030]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p3GB6-0007sg-R5 for emacs-orgmode@gnu.org; Thu, 08 Dec 2022 07:39:06 -0500 Received: by mail-pj1-x1030.google.com with SMTP id q17-20020a17090aa01100b002194cba32e9so4494730pjp.1 for ; Thu, 08 Dec 2022 04:39:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:to:subject:message-id:date:from :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Je3jAKDBrXw2auKp2hA21kDqt62zwJs+Ns8Yz/dtJ60=; b=ay5PNZHE1O0fT4Zn1sqvkX8fDxWg4fyhaQ9ZfxVT4ThgKobn+LvLzSv6xeM6UIU0xF SbtRVzlvR90dXVm82jTrJFrRDHBx6PvhKUTUIfcoOmaUw7SQz9p0RcMguex7UH/YPAoe VGXsLbb3b0D82T/vP1dINPgS2I+d+iFLCZEU3PERyJ65OmTz4CWRFlB8MeyisblSBeKP 40RslKTxnucdtrO5CsTh5wIIPfxSICUGgDloTpU1uqw0nQcHYhGYfIfAFppYeL1pi8S0 qAf/GhtUPXIRjUOEC2GrdZV0kRqxjbhdz2i6I/s4ZYwA/kRvmUZRRbo7OvHZhngik9In 3IZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:to:subject:message-id:date:from :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Je3jAKDBrXw2auKp2hA21kDqt62zwJs+Ns8Yz/dtJ60=; b=3uQLap/X3xhaerGjHr1r2vX1rnswE2cYPWql8gkL1IK6fKdajBF5ElNRSLoyUEBKY7 ZCl+xJgnQLL3Bh8zKDNZJv1y2m3QiCEzPuusGYodW7nkiauinDsAAob1gyiAdBBMd3L9 +KOWoctXZQMx0nRsOZAzsy4I7Hkkn5uIFtSPWWYUM5bQw1okSFNp2A8FG/kvp0FsoJrg uAZapnCvQydrhScSF3rNOWUcP8OzOc1tC6AGQVddO/7A4EaY6k0zAoxwmMnqFzorfur7 zZnimlsRmtyemhHjPH3DY9QHMr8UGU2GZW+/nj5PYk/1negihCN37GGx3ck0gaJN38or gwug== X-Gm-Message-State: ANoB5pm+338zIq29+hwOPKiHlLjxmPv2MS1JwZfA8PKzfMijt3MZh7vh W2iOBL2SfjYSFUYUh7UwC6QH9DmCNdFzE3+sYuRRUKsT9Rg= X-Google-Smtp-Source: AA0mqf4Lc4ajC+E/zrRurVWeOevAAnEPpRIRDO71tZYMcXjVQNyiXv8XTL3jRCOVtfDSjvWvaGdku7MVkfVmrQ+Ozw0= X-Received: by 2002:a17:90a:5b09:b0:218:a0cd:5a99 with SMTP id o9-20020a17090a5b0900b00218a0cd5a99mr92295090pji.76.1670503140043; Thu, 08 Dec 2022 04:39:00 -0800 (PST) MIME-Version: 1.0 From: =?UTF-8?Q?Carlos_Mart=C3=ADnez?= Date: Thu, 8 Dec 2022 13:38:33 +0100 Message-ID: Subject: Macro: exporting roman numerals formatted as small-caps To: emacs-orgmode@gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::1030; envelope-from=martinez.carlos.93@gmail.com; helo=mail-pj1-x1030.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670503191; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=Je3jAKDBrXw2auKp2hA21kDqt62zwJs+Ns8Yz/dtJ60=; b=FlSwggfy2ILXeG8+r83VVhrgv6ZvvVuPSVtxwc/BP6LfHJrypLDKU59cunLV2xdciZJxtT ZKRkC/PWkF+9MIHbd3Ar57dqjgkJMkUnSrqsYG8Jqiv/GS0j4f9LtBW7G/UYQNAyGUiPT8 Wr+hATVqHOuok6RF4OPrnFvejD3sRdLozk+jru5dcKATtDdoPzU/h17JScM/QZiWQ5YIAA TNIE3fW271dkndErUBslUV+kgjuLXb+vw0wXHNrd258SBksVRmdOxGl6Q/k2Oe7hNIJmDm Jkk8vvlowUULM4jj/mlRVpRfEkzBJUVVXDfQlWoRCSSirg5fcjimqdDfrZjhpA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670503191; a=rsa-sha256; cv=none; b=qnilo9tKj80EQ34QqgDKFCgYprorQiYvTeIaGrGEJAsdipctXwVWfpdBVHgLXIcs2YXg28 AMF8ZO4Cu9j6zUoMcKWlM/z4hM5GmbI6SsT4mKg/9x2/p8ao4087g0rGHBxxHjc+clecjD ykIku51E26t19432XrXPh63mS/XSvw2gs3DdgX5CO9XfdmzpTaaxET+ZFR6oxNqaa4CjSX 59CuXyc9X53hZ/jxIP6upM1MIgseTiVvrKs55rNZWZwUSgfIve8r1hFrll/1aD4KEoz6ZL /L6B+21XfqCcmiY8SPwb0xChENibOCTJd7tp4ql9oQB89tuFwGVJ1XGU5q/biA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=ay5PNZHE; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.96 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=ay5PNZHE; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 5D2A13E75D X-Spam-Score: -3.96 X-Migadu-Scanner: scn0.migadu.com X-TUID: VhY49Qoavj+u Hello everyone!, I am working in a paper written in org mode. There are lots of roman numerals referring to centuries. In Spanish, those are written in roman numerals and small caps. I want to export my paper both to odt and to LaTeX. I found a macro by Juan Manuel Mac=C3=ADas which helped me to export the numerals surrounded by \textsc{} when exporting to pdf, but I struggle to do the same when exporting to odt. This is the macro: #+MACRO: sc (eval (if (org-export-derived-backend-p org-export-current-backend 'latex) (concat "@@latex:\\textsc{@@" $1 "@@latex:}@@") (concat "@@odt:@@"$1"@@odt:@@"))) I want to achieve something like this: "When exporting to LaTeX (o derived formats), surround the argument with \textsc{}; if any other format [it will always be odt], do the same with the proper odt code. Thanks everyone, and my apologies if this is a noob question (but I am actually a noob). Best regards N.B.: I extracted the odt snippet looking at the contents.xml inside the odt file.