3

The package cleveref includes the type of the reference along with the counter as the output of its \cref command. It also knows some counter names, for instance theorem, so that it does not need to specified using say \crefname (well, for theorem-like environments, it actually recognizes the environment name, but I suppose we can ignore that difference). These are the 'default definitions' referred to in section 8.1.3 of the cleveref documentation. What are all the reference types defined by default?

Below is an example, which if compiled, generates this sentence (in particular, the string 'corollaries' has to come from cleveref):

Theorem 1 and corollaries 2 and 3.

\documentclass{article}

\usepackage{amsthm}
\usepackage{cleveref}

\newtheorem{theorem}{Theorem}
\newtheorem{corollary}[theorem]{Corollary}
\begin{document}

\begin{theorem}\label{x}
Blah.
\end{theorem}
\begin{corollary}\label{y}
Blah blah.
\end{corollary}
\begin{corollary}\label{z}
Blah blah blah.
\end{corollary}

\Cref{x,y,z}.

\end{document}
3

From the source (line 3877-3916 in version 2013/12/28 v0.19), the \crefname's defined by default are:

  • equation - eq. - eqs. (equation - equations if noabbrev)
  • (sub)figure - fig. - figs. (figure - figures if noabbrev)
  • page - page - pages
  • (sub)table - table - tables
  • part - part - parts
  • chapter - chapter - chapters
  • (sub/subsub)section - section - sections
  • (sub/subsub/subsubsub)appendix - appendix - appendices
  • enum{i-v} - item - items
  • footnote - footnote - footnotes
  • theorem - theorem - theorems
  • lemma - lemma - lemmas
  • corollary - corollary - corollaries
  • proposition - proposition - propositions
  • definition - definition - definitions
  • result - result - results
  • example - example - examples
  • remark - remark - remarks
  • note - note - notes
  • algorithm - algorithm - algorithms
  • listing - listing - listings
  • line - line - lines

There's an analogous set of \Crefname's.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.