Received: from mail.proteosys.com ([213.139.130.197]) by nummer-3.proteosys with Microsoft SMTPSVC(5.0.2195.6713); Sat, 15 May 2004 14:56:17 +0200 Received: by mail.proteosys.com (8.12.10/8.12.2) with ESMTP id i4FCuElo001850 for ; Sat, 15 May 2004 14:56:15 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.119.176]) by relay2.uni-heidelberg.de (8.12.10/8.12.10) with ESMTP id i4FCpPD6007273; Sat, 15 May 2004 14:51:25 +0200 (MET DST) MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C43A7C.02C46E80" Received: from listserv (listserv.uni-heidelberg.de [129.206.119.176]) by listserv.uni-heidelberg.de (8.12.7/8.12.7/SuSE Linux 0.6) with ESMTP id i4E1Rh6n005625; Sat, 15 May 2004 14:49:49 +0200 Received: from LISTSERV.UNI-HEIDELBERG.DE by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 1.8e) with spool id 207628 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Sat, 15 May 2004 14:49:48 +0200 X-MimeOLE: Produced By Microsoft Exchange V6.5 Received: from relay.uni-heidelberg.de (relay.uni-heidelberg.de [129.206.100.212]) by listserv.uni-heidelberg.de (8.12.7/8.12.7/SuSE Linux 0.6) with ESMTP id i4FCnmUZ027047 for ; Sat, 15 May 2004 14:49:48 +0200 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) by relay.uni-heidelberg.de (8.12.10/8.12.10) with ESMTP id i4FCoq1K009911 for ; Sat, 15 May 2004 14:50:55 +0200 (MET DST) Received: from [212.227.126.205] (helo=mrelayng.kundenserver.de) by moutng.kundenserver.de with esmtp (Exim 3.35 #1) id 1BOycv-0000cW-00 for LATEX-L@listserv.uni-heidelberg.de; Sat, 15 May 2004 14:50:53 +0200 Received: from [80.129.11.43] (helo=istrati.mittelbach-online.de) by mrelayng.kundenserver.de with asmtp (TLSv1:EDH-RSA-DES-CBC3-SHA:168) (Exim 3.35 #1) id 1BOycr-0001Bf-00 for LATEX-L@listserv.uni-heidelberg.de; Sat, 15 May 2004 14:50:53 +0200 Received: (from frank@localhost) by istrati.mittelbach-online.de (8.11.2/8.11.2/SuSE Linux 8.11.1-0.5) id i4FCoLJ27584; Sat, 15 May 2004 14:50:21 +0200 In-Reply-To: References: <16549.4057.399610.750080@istrati.mittelbach-online.de> Return-Path: X-Mailer: VM 6.96 under Emacs 20.7.1 X-OriginalArrivalTime: 15 May 2004 12:56:18.0017 (UTC) FILETIME=[035F9D10:01C43A7C] X-Authentication-Warning: istrati.mittelbach-online.de: frank set sender to frank@mittelbach-online.de using -f X-Scanned-By: MIMEDefang 2.28 (www . roaringpenguin . com / mimedefang) X-Provags-ID: kundenserver.de abuse@kundenserver.de auth:923c546e49b26a7485eda6910e23f403 X-ProteoSys-SPAM-Score: 0.2 () RCVD_IN_NJABL,RCVD_IN_SORBS Content-class: urn:content-classes:message Subject: Re: Why don't we do just the following: Date: Sat, 15 May 2004 13:50:21 +0100 Message-ID: A<16550.4621.526207.509473@istrati.mittelbach-online.de> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Why don't we do just the following: Thread-Index: AcQ6fAN+u2jF8Bh3QTiHDvK1Bu2JeA== From: "Frank Mittelbach" Sender: "Mailing list for the LaTeX3 project" To: Reply-To: "Mailing list for the LaTeX3 project" Status: R X-Status: X-Keywords: X-UID: 4784 This is a multi-part message in MIME format. ------_=_NextPart_001_01C43A7C.02C46E80 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable \iffalse David Kastrup writes: > \def\@float{... > \let\@currentlabel\barf ... > } > > {\xdef\barf{% > \csname > No, read the FAQ. Really. You have to place \string\caption > \space before using \string\label \space inside of a figure. > \endcsname}} > > Something like that. perhaps better ... \fi \documentclass{article} \makeatletter \def\@float#1{% \def\@currentlabel{\@latexerr{ref to misplaced label}{explain}}% \@ifnextchar[% {\@xfloat{#1}}% {\edef\reserved@a{\noexpand\@xfloat{#1}[\csname fps@#1\endcsname]}% \reserved@a}} \makeatother \begin{document} \begin{figure} \label{foo} \end{figure} Hallo \ref{foo} \end{document} > Or does _anybody_ know of _any_ intentional use > of a \label _inside_ of a figure, _not_ referring to the figure but > to its section? no and any env or command that would allow for labels would change \@currentlabel anyway > I mean, this must be the candidate for the most frequently asked > question on LaTeX, ever. well it keeps people busy any suggestion for a good text? frank ------_=_NextPart_001_01C43A7C.02C46E80 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Re: Why don't we do just the following:

\iffalse
David Kastrup writes:
 > \def\@float{...
 >   \let\@currentlabel\barf = ...
 > }
 >
 > {\xdef\barf{%
 >     \csname
 >     No, read the FAQ. = Really. You have to place \string\caption
 >     \space before = using \string\label \space inside of a figure.
 >     = \endcsname}}
 >
 > Something like that.

perhaps better ...
\fi

\documentclass{article}

\makeatletter
\def\@float#1{%
  \def\@currentlabel{\@latexerr{ref to misplaced = label}{explain}}%
  \@ifnextchar[%
    {\@xfloat{#1}}%
    = {\edef\reserved@a{\noexpand\@xfloat{#1}[\csname = fps@#1\endcsname]}%
     \reserved@a}}

\makeatother

\begin{document}

\begin{figure} \label{foo} \end{figure}

Hallo \ref{foo}

\end{document}

 > Or does _anybody_ know of _any_ intentional = use
 > of a \label _inside_ of a figure, _not_ = referring to the figure but
 > to its section?

no and any env or command that would allow for labels = would change
\@currentlabel anyway

 > I mean, this must be the candidate for the = most frequently asked
 > question on LaTeX, ever.

well it keeps people busy

any suggestion for a good text?

frank

------_=_NextPart_001_01C43A7C.02C46E80--