emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <n.goaziou@gmail.com>
To: Eric Schulte <schulte.eric@gmail.com>
Cc: Org Mode Mailing List <emacs-orgmode@gnu.org>
Subject: Re: [PATCH] ox-latex.el --- CUSTOM_ID-as-section-label-in-latex-export
Date: Mon, 24 Jun 2013 18:48:17 +0200	[thread overview]
Message-ID: <87ppvbv4j2.fsf@gmail.com> (raw)
In-Reply-To: <87wqpjxyoo.fsf@gmail.com> (Eric Schulte's message of "Mon, 24 Jun 2013 10:26:15 -0600")

Hello,

Eric Schulte <schulte.eric@gmail.com> writes:

> From c087e84a8fd80b277bf064eb31f1b893c25f1b4a Mon Sep 17 00:00:00 2001
> From: Eric Schulte <schulte.eric@gmail.com>
> Date: Mon, 24 Jun 2013 10:25:03 -0600
> Subject: [PATCH] CUSTOM_ID as section label in latex export
>
>   When exporting to HTML, custom ids of headlines become references to
>   the resulting section in the exported document.  This is both more
>   stable and more readable than using section numbers.  This commit adds
>   this option to the latex exporter.

Thanks for the patch.

Though, it isn't as stable as relying on section numbers: there is no
guarantee the custom id will be unique nor that it will not contain any
forbidden character.

This patch also breaks cross references, which expects labels to be
built from section number (see `org-latex-link').

Since you (almost?) never need to write \ref{custom-id} in the Org
buffer, I don't think it is bad to keep current label system.

Another option would be to have both \label{sec-...} and
\label{custom-id}. But it would require the user to check validity of
its id.


Regards,

-- 
Nicolas Goaziou

  reply	other threads:[~2013-06-24 16:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-24 16:26 [PATCH] ox-latex.el --- CUSTOM_ID-as-section-label-in-latex-export Eric Schulte
2013-06-24 16:48 ` Nicolas Goaziou [this message]
2013-06-24 17:08   ` Eric Schulte

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ppvbv4j2.fsf@gmail.com \
    --to=n.goaziou@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=schulte.eric@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).