From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id MOuMFpjBR2ZF4wAAqHPOHw:P1 (envelope-from ) for ; Fri, 17 May 2024 22:44:08 +0200 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id MOuMFpjBR2ZF4wAAqHPOHw (envelope-from ) for ; Fri, 17 May 2024 22:44:08 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=eBhCGJ3e; 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1715978648; a=rsa-sha256; cv=none; b=exeaKJwdhpr+DfQOfmxoiXPOC2MApQaH9ok1HoUV/LfXuvdIUG43Z2XEewZhmzVi28PZHS RcRwyWb6SmCQtNUPUkbhZRYqLpoqIO9MMBhC8ARlblq9BoUEW42HTpwFxwVEmIS5hpQ924 ILxAaA8zk4pgDFF3SzTUTVuo5xn+X95/iRffjzbqI0fcQWnQ5nE6yosFQilBXkBJ0b1wWA 3Z+w4VKW648zY1NofezPbbeKqu07j5c3NRD0237enuulXRHUgSKdf5bR9VR68NEamm8REi DLzPWhSVR3sguJ3vzZ78YyiMSbc0o35Y5bxAJvLr6f3JrsokJM1SFL8pIk1iIQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=eBhCGJ3e; 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" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1715978648; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=lIC7DW54wzFtqnTZ293BIx78XmmmDLyt9gbB6E6znwk=; b=nd6tUMy90zBTIzjXYoeaSOqNuk93ySUJVGCrpP7ZA+gpsoDjT4ZVJr1U7NX3AE2+V8QEUA NVN+cA9U9TtcLghN7etQ5IXAD8XXZBumLLpKMp97dMXBZSs34LYixZzQKYU4MSzAkLSJHZ UMXICG4Q7ojEuFbxqo9eN/FBwLEAHpdIDi+jALjfEqY3fNwUBgN90ZSQHXALQ2olivaFBC IlroUg87/Iv2a0uD3WPzt4vRPGbk9184DODKOpwbNHWBRl9IBm77kOxnD9BTDzUXDJhN8X sq9R+V63hAiTxiUgPy6MxvXtpHXY9f1F3XIOsqA6Zbpmc11mLbJGr2gQUB/+AA== 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 04AF83553F for ; Fri, 17 May 2024 22:44:08 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s84Q0-0007GO-En; Fri, 17 May 2024 16:43:08 -0400 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 1s84Pz-0007GG-Jt for emacs-orgmode@gnu.org; Fri, 17 May 2024 16:43:07 -0400 Received: from mail-lf1-x136.google.com ([2a00:1450:4864:20::136]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s84Px-0008TY-9X for emacs-orgmode@gnu.org; Fri, 17 May 2024 16:43:07 -0400 Received: by mail-lf1-x136.google.com with SMTP id 2adb3069b0e04-51f782c666eso192244e87.0 for ; Fri, 17 May 2024 13:43:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715978583; x=1716583383; darn=gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=lIC7DW54wzFtqnTZ293BIx78XmmmDLyt9gbB6E6znwk=; b=eBhCGJ3egMTXodCOX/GScHlNK+eYmePqjKDBqkJkS6of4DWYNoBmEbeDCqUus1l3Ow wLd8k2AlAaolM0RTNnttXz9DMB5DL/TQhxb56WEw8XyNGUzRwUR16fNFYQKwztrekUxD uK1/97iTc6sVRLXQJgNeiLpxlod4Obv4l2ADfZxR5dwNzXuUQmr43E5EXdQWdFfEtLpa 1V7kgEbPueKS8D15+9Yn0DIgVG7r+GOpqC31aUKXt2NmLTIGeIlsWsalujv853e8lZI4 n00i7ekchsL2plP2VLVcycg6rRNTqTQK9kq55aS7MVijD7j6K5grToOv1YBUioc6/BA+ B+fQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715978583; x=1716583383; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lIC7DW54wzFtqnTZ293BIx78XmmmDLyt9gbB6E6znwk=; b=DcAfLbtafz262ibEeIfkCxOlXHE4SD0hEOnPoIshhyO1TzcYllPl7JsEEXHdl7a9wH pNMQPfrPhgTCGU7Rl8JcJhzeGdRX+0Sonfzpsp/fQLcik9g1A9fejrRaZZljLa59hi/s FBrVXUL8+ett/LKDCYq1RoTHBTQc902YEKQh2hMGObBE5X5eAWhwQLZiE2fIQAg11vBn w2KZR1MuqC2++7nDws8MWfCarM1svzP1AR+1OJ5bOo3sFCArYY2kcFBQPg4WF1SFX4eX NDHehWvyX6qP3MIqc/udSv0K12ccx/CkoWw7XSwKKmCbCRYiocSNW1OV4HFmmi11ZEfC 2jXQ== X-Gm-Message-State: AOJu0Yx09JDx0Fnd1gh9xIKXAxdBUfsXS0NSrspqUgu7AUS09+6mffbC VJuuJkPfdbCFTLcAvjnWA+FxsLAswzqLqOuKExx5BUha4yEsheNr/2FfSkVYzAR4Ea8D0aaQB1K OunyceiBxkuzTJP7Gh70iI82Qv54= X-Google-Smtp-Source: AGHT+IHzGdHjXJwSrvt3tUIKCd8NbiG0INOCq82QBVQCJRZXPb72x3fxMu6uYkbVMQTmV5yOi1gKMqoWw+rng9/yd0I= X-Received: by 2002:a05:6512:e81:b0:51b:ada6:f1a2 with SMTP id 2adb3069b0e04-5221006e63bmr16452564e87.3.1715978582648; Fri, 17 May 2024 13:43:02 -0700 (PDT) MIME-Version: 1.0 References: <87a5kosgax.fsf@localhost> In-Reply-To: <87a5kosgax.fsf@localhost> From: Stefano Ghirlanda Date: Fri, 17 May 2024 13:42:26 -0700 Message-ID: Subject: Re: Exporting user labels to non-latex backends To: Ihor Radchenko Cc: emacs-orgmode@gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::136; envelope-from=sg19721222@gmail.com; helo=mail-lf1-x136.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-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Queue-Id: 04AF83553F X-Migadu-Scanner: mx12.migadu.com X-Migadu-Spam-Score: -9.69 X-Spam-Score: -9.69 X-TUID: HLL7HTORkeuv Thanks! I was just under the impression that #+name: was the preferred way of labeling things and I was surprised it did not work as I expected on some backends. I was surprised to see that #+name: eq:x gives a different result from \label{eq:x} as I understood the two things to be equivalent. Thanks for the clarification, Stefano On Fri, May 17, 2024 at 6:43=E2=80=AFAM Ihor Radchenko wrote: > > Stefano Ghirlanda writes: > > > There may be an issue with using #+name: labels when exporting to > > non-latex backends. For example: > > ... > > #+name: eq:x > > \begin{equation} > > x =3D 1 > > \end{equation} > > > > cref:eq:x > > --- > > > > exports with a mix of org labels and user labels: > > > > --- > > \begin{equation} > > \label{orgf29908c} > > x =3D 1 > > \end{equation} > > > > equation \ref{eq:x} > > --- > > > > This does not affect latex export because one can set > > org-latex-prefer-user-labels, but most other backends do not seem to > > have this setting. I think there is one for HTML but I could not find > > one for markdown. Would it be useful to have a global setting for all > > backends? Or, is there a way to fix this with the current code base? > > AFAIK, there is nothing to fix - the current behavior is intentional: > > Commit 981f25031dd17 > * lisp/ox-md.el (org-md-latex-environment, org-md-latex-fragment): > These two new filters wrap LaTeX maths in $ / $$ TeX-style notation. > While ox-md endeavours to adhere to the original Markdown specification, > and not any particular variant, the original specification does not deal > with LaTeX fragments at all, and so this change does not reduce how > faithfully the original specification is followed. > There is a major upside to this though. Of the many Markdown variants > that have emerged, those that support LaTeX very often exclusively > support TeX style notation. This change thus improves the utility of > the Markdown export for many use cases, and deviates no more from the > original specification that the current method. > > Please, provide more context about the problem you are trying to solve. > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at --=20 Stefano Ghirlanda CTO, DataWorks - https://dataworks.consulting Guest Professor - Stockholm University Centre for Cultural Evolution