CTAN update: cleveref-usedon

CTAN Announcements ctan-ann at ctan.org
Sat Apr 22 22:51:48 CEST 2023

Sven Pistre submitted an update to the



Version number: 0.4.0 2023-04-21
License type: lppl1.3

Summary description: Adds forward-referencing functionality to the cleveref package

Announcement text:

### Changed
- the .dtx file to use the l3doc document class instead of ltxdoc.

### Added
- an abstract explanation of the implementation in Section 2 of the documentation.
- the change log CHANGES.md
- more descriptive \PackageError's to abort loading the package when the expl3 or LaTeX
format is older than 2021-05-16.

### New Features
- Experimental options UsedBy and UsedByAndOn:

The new (experimental) options UsedBy and UsedByAndOn add the messages
    "(Used by <list of theorem-like destination(s)>.)"
    "(Used by <list of theorem-like destination(s)> on page(s) <list of page(s)>.)",
respectively, after the original location of the label <LabelName> when it is referenced
via e.g. \cref[UsedBy]{<LabelName>}.
Thanks to Murray Eisenberg for this suggestion.

Unfortunately, due to how this package is currently implemented, to get these
experimental options to work it is necessary to abuse the usage of proof environments.
Namely, one needs to nest the proof environment \emph{inside} the theorem-like
environment, i.e. \begin{theorem}
        PROOF CONTENT with \cref[UsedBy]{lemma:AuxiliaryCalculation}.
instead of
        PROOF CONTENT with \cref[UsedBy]{lemma:AuxiliaryCalculation}.
Note carefully how the proof environments are (ab)used in the above code example.

This is -- as far is I know -- not how these environments are supposed to be used.
In particular, placing text between theorem-like environment and the corresponding proof,
as is often common, will result in a wrong reference. Namely, instead of referencing the
theorem-like environment by name only the corresponding section name would be printed,
e.g. "(Used by Section 2.2.)"
Check Section 2.2 of the documentation for an example.
Hence, using proof environments correctly results in "UsedBy" and "UsedByAndOn" messages 
which are less helpful to the reader. On the other hand, using this experimental
functionality to help the reader forces users (i.e. authors) of this package to use proof
environments incorrectly. This sounds like a No-Free-Lunch theorem...
Therefore, use these two experimental options at your own discretion!

If anyone has an idea how to implement this without nesting the proof environment, let me
know! ----------------------------------------------------------------------

This package is located at 

More information is at

CTAN is run entirely by volunteers and supported by TeX user groups

Please join a user group or donate to one, see https://ctan.org/lugs


   Thanks for the upload.

     For the CTAN Team
    Ina Dau


More information about the Ctan-ann mailing list