From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id OEprA1UUvWAg3AAAgWs5BA (envelope-from ) for ; Sun, 06 Jun 2021 20:30:45 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id qJYnOlQUvWD4MwAAbx9fmQ (envelope-from ) for ; Sun, 06 Jun 2021 18:30:44 +0000 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 506DA1588C for ; Sun, 6 Jun 2021 20:30:44 +0200 (CEST) Received: from localhost ([::1]:49080 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lpxXm-0004ti-40 for larch@yhetil.org; Sun, 06 Jun 2021 14:30:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55760) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lpxWu-0004sq-Bq for emacs-orgmode@gnu.org; Sun, 06 Jun 2021 14:29:50 -0400 Received: from mout01.posteo.de ([185.67.36.65]:59777) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lpxWq-0001wx-BG for emacs-orgmode@gnu.org; Sun, 06 Jun 2021 14:29:48 -0400 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 3453124002B for ; Sun, 6 Jun 2021 20:29:41 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1623004181; bh=xZQoKHKl19yzspzfzUvtqCY098IbcfzadxnLZ7KrZcw=; h=From:To:Cc:Subject:Date:From; b=Uz/nk+m3QmPO5LmMpqUk0GOPrVhmGSG2bH8PIbbT7uFmTl/+/eRPA6d9nJ9EaJSPY u90e+hyBvjRQWoa95Bf3DE2J4n6/f22qtucZc73qi/o72Kp2crv6ADDWlDtRacVj0e AHzJdJxKJJkapAqyx3XWV7x0PqfMW/aVhEon3afwcZqukItnEmM6MfgoSoZM+9J459 bDZBtcLfO5SZMZiKXUwj4Y++4CDfdCECgbrF9Y9T522R6xjNFmaLb+GRg4uhNGt4Nn jTayLyq7bb7YTKVyeYMR7nTDssnbg8/SkTAZxd+kqvIctepLkhW9BROM2dY1+8JlgO 8unN8uifqNWhw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4FylQr2zG5z6tmR; Sun, 6 Jun 2021 20:29:40 +0200 (CEST) From: =?utf-8?Q?Juan_Manuel_Mac=C3=ADas?= To: Timothy Subject: Re: [PATCH] Allow LaTeX reference command (\ref) to be customised References: <87mts25000.fsf@gmail.com> Date: Sun, 06 Jun 2021 18:29:39 +0000 In-Reply-To: <87mts25000.fsf@gmail.com> (Timothy's message of "Mon, 07 Jun 2021 02:19:43 +0800") Message-ID: <87sg1u4zjg.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.65; envelope-from=maciaschain@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.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, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, 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.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: orgmode Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1623004244; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=YH17587+FpGRgYVaDgN7vym7EaNQUIh2TFq2Tbn722k=; b=jWk1e83wdlYzgHmSuJ0tjO5AVE1x6FF2Q6H2dJ3pVBaPnCN3AZZvxAniocdMiMgFNYDLFw Lw/2K6kn9yLe/ShD23qWs1m4fGPLGehZwFCMUyobq3FWZFgptBqm/SGD4OGANV9TNZaFOg wkypS3AB5S1XmLPsz+zslJVBRvSkBsRkALmbDk84xCksnc/+Jsg06NYoTmeBEvOOTzDRPj Cafgilg7qg/WNvJ2rocqTLaV8uSEAg9JmbjdskejpBztnjBZ5hjatQCcx2J99Nfhxr+Pj/ d9luHcuyrn0oo06EUl7iXA8FqNAEMU+a7/NEQNwjzN71wacrGUeDocpCC52WsA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1623004244; a=rsa-sha256; cv=none; b=uev20cdt0agJzhArX6L2DPT2vrZS1gB/oXKWMXuNr3q3FKsJZE6reSlGebaHszF62Mg1v0 5pAuDqgF3bV5XyvHWCd2EmrsIsw/99W1Mkz73jye2bF6tcO4FGuo3lYHM47pTcyExNVrmj j2KwwtnEHYvjVjeLKlJ8Zq9jtCSqYJdyHHS8S8/vouKpQkZYpUQWALCcuvR9WJYZ+Uewxn QjrI3urZxOKTQhaDBfdIrsR6qVploSY4HYbphd4DFdoySZHZ+YbumDsDPAMstyXsliNPk0 /PQIu4esQiUPR5S/EAKn2tpXKBEGjjhrpQ8QRxLRPbaYrU243mHcGkQ00Sp1cQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Uz/nk+m3"; dmarc=pass (policy=none) header.from=posteo.net; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -3.13 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Uz/nk+m3"; dmarc=pass (policy=none) header.from=posteo.net; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 506DA1588C X-Spam-Score: -3.13 X-Migadu-Scanner: scn0.migadu.com X-TUID: 74OJhNNE7Abv Hi Timothy, Timothy writes: > I've started doing some more cross-referencing in documents exported to > LaTeX, and a hardcoded use of \ref has begun to stand out to me as a > rather annoying thing. Hypperef provides \autoref for adding helpful > prefixes (section, figure, etc.), and there are other packages which one > may want to use to generate 'clever' references (like cleveref with > \cref). > > As such, I think that the hardcoded \ref should actually be turned into > a customisable format string, which is what the attached patch does. I think it's a great idea. There are many options in LaTeX to manage cross references, beyond the standar \ref. I use the varioref package a lot (https://www.ctan.org/pkg/varioref). Best regards, Juan Manuel