{cleveref} is a package that enhances LaTeX's {cross-referencing} features, allowing the format of references to be determined automatically according to the type of reference.

learn more… | top users | synonyms

2
votes
1answer
19 views

autonum and cleveref conflict

The following code produces erroneous output. When I put cleveref first, it doesn't pick up the references at all. When I put autonum first, really weird stuff happens. See the images below. I ...
2
votes
1answer
26 views

automatic numbering of labeled equations

Since autonum doesn't play nicely with cleveref (nor does the mathtools automatic numbering option work for me), I'm looking for a simpler solution. I'd like equations to be numbered automatically if ...
0
votes
0answers
13 views

Parenthesized subfigure references except when already in parenthesis

I would like to style my subfigure references as Fig. 1(a) in running text and (Fig. 1a) when parenthetical. The subfigure labels are created using this code. (I would prefer to use subcaption like in ...
3
votes
1answer
30 views

Is it possible to remove parenthesis from single cref references?

I am using cleveref to crossreference everything. Sometimes I write the reference inline like eq.(1). That is fine. But when it is enclosed in parenthesis it turns out like (eq.(2)). Which is not so ...
11
votes
4answers
241 views

Automatically insert “in the next [chapter/section/subsection]” if reference is sequential

I'm aware of the cleveref package \cref which adds the correct reference name (see: Automatically inserting "Section", "Subsection", etc). I have a few references which refer to ...
3
votes
2answers
48 views

Changing cleveref type for a single chapter

I have an appendix in my thesis that, due to fancyheader constraints, I define as \chapter* and not \appendix. However, now when I refer to it using \cref I get "chapter", I can change this manually, ...
0
votes
0answers
5 views

Create cross-reference like “in the previous section” where appropriate [duplicate]

Is there a referencing command that will use the wording "the previous section" or "the next section" if appropriate, and default to "Section x.y" (as in cleveref)? \documentclass{scrartcl} ...
3
votes
1answer
211 views

Varioref, cleveref and autonum together

I'm trying to mix varioref, cleveref and autonum to have the following behaviors: Automatic adding of reference type (i.e. adding "section" when referencing a section). -> cleveref; Adding the "on ...
4
votes
2answers
848 views

acronym \acresetall & cleveref: multiply defined labels

I'm using the acronym package to expand acronyms and I'm also using the cleveref package. I would like to have acronyms expanded once per chapter. For instance in the following code, both acronyms ...
0
votes
0answers
22 views

Varioref and Cleveref inconsistent while redefining page

I am trying to use cleveref and varioref. I read here how should be the correct order of loading the packages. Also saying that \vref and friends would become clever since cleveref changes the ...
5
votes
1answer
38 views

cleveref and aliascnt: referring to subequations and inequalities in a smart way

Preliminary Remark: A document may contain labels referring to equations and subequations, respectively. Moreover, some of the equations may actually represent inequalities. When using the cleveref ...
1
vote
1answer
25 views

Forcing abbreviations with cleverref

As an apposite situation of this question, I would like to use cleveref, but it constantly prints unabbreviated text (Chapter, Section, etc.). Is there a way to force the abbreviated form (Chap., ...
2
votes
1answer
31 views

Always getting upright numbers in references created with \cref, with italic-correction for conjunction between references

How do I make it so that I get upright numbers all the time in references created with \cref? I believe I'm supposed to do this with \crefdefaultlabelformat{#2\textup{#1}#3}. But in my example below, ...
1
vote
0answers
23 views

Using cleveref with 2 different styles

I like to style my \cref as following (Geophysical Prospecting): Type 1: Fig. 1, Fig. 1(a), Fig. 1(a,b), Figs 1 and 2 Type 2: (Fig. 1), (Fig. 1a), (Fig. 1a,b), (Figs 1 and 2) I have tried with ...
2
votes
0answers
47 views

Cleveref: Change behaviour of \Cref to use the abbreviated form

The journal International Journal of Solids and Structures uses always capitalised and abbreviated form of references, i.e. Fig. 1, Eq. 1, even at the beginning of a sentence. I use the package ...
4
votes
1answer
77 views

Is there a way to divide ONE figure to reference the subparts of the figure?

I have a figure that basically consists of smaller figures. I don't want to split the big image apart to put it together with latex for convenience. Instead, I want to reference each subpart of the ...
1
vote
1answer
55 views

Change cross-reference name of enumerated items using cleveref

I feel this is a really basic question, but I haven't figured out a solution after searching for half an hour so maybe other people will find this question useful as well. I'm using the cleveref ...
2
votes
1answer
39 views

Referencing sublabels without subfloats

Suppose that I have a figure with different panels and I want to use the command \cref to reference each one of the panels. A way to do this is to use the packages subfig, subfigure, or subcaption. ...
1
vote
1answer
16 views

Combine mdframed, xparse and cleveref

Inspired by this post: Typesetting a definition, I wanted to define some fancy theorem-like environments. Contrary to the examples given in this post, I need a definition environment with a counter ...
1
vote
0answers
12 views

How to tell cleveref to use the correct label type [duplicate]

I'm trying to use cleveref to reference some figures, but it is incorrectly labelling them as sections. (i.e. It will say something like Section 5.12 instead of Figure 5.1 in the text) I'm also using ...
5
votes
1answer
64 views

Suppress hyperlinks to current page

Is it possible to suppress hyperlinks pointing to the same page as the hyperlink? I currently use the hyperref and cleveref packages for the hyperlinks, but I don't find any option to disable ...
2
votes
1answer
53 views

“destination with the same identifier” warning with shared counters, cleveref and amsart

The following mwe \documentclass{amsart} \usepackage{hyperref} \usepackage{cleveref} \newtheorem{theorem}{Theorem} \newtheorem{proposition}[theorem]{Proposition} \begin{document} ...
1
vote
1answer
20 views

''Proof of Theorem x'' header trough modification of \ref

I had a problem that was solved in a previous question, and that now is coming back. The idea was to use \ref for internal links with color A, and \cref with nameinlink option in cleveref (!) and ...
3
votes
2answers
786 views

Extra “appendix” when referencing using cleveref in elsarticle

How do I get rid of the extra "appendix" appearing when I cross-reference an appendix section? Example output is "...see appendix Appendix A". MWE as follows: \documentclass[preprint,3p]{elsarticle} ...
1
vote
2answers
64 views

How to make a custom \crefformat dependent on language chosen with babel?

For my custom class I use the cleveref package and define new custom reference styles: \crefformat{figure}{Meine tolle Abbildung ~#2#1#3} Is there a way to make this command consider the language ...
4
votes
1answer
75 views

Cleveref-like command in ConTeXt

Following ConTeXt garden, I set up theorem environments like in the below MWE. I wonder if ConTeXt has a command similar to \cref from the LaTeX package cleveref which automatically adds "Corollary,", ...
2
votes
1answer
21 views

IEEEtran cls and cleveref: the special case of IEEEeqnarray

How to properly reference equations in an IEEEeqnarray with the cleveref package? Here is possible MWE: \documentclass[a4paper,10pt,conference,twocolumn,twoside]{IEEEtran} ...
2
votes
1answer
69 views

Cross-reference to appendix sections in elsarticle document class

I am trying to reference a result given in the appendix, but cleveref is giving "Appendix Appendix" (doubling it). A way to solve this problem is to add \def\appendixname{} Not surprisingly, this ...
1
vote
0answers
80 views

Cleveref's \cpageref{} command leads to “Missing number, treated as zero” error, when used in a document using (at least) two page numbering schemes

Update: I have updated this question & the corresponding code. The minimal working example code was overhauled after receiving some valuable suggestions from @Johannes_B regarding how to make it ...
10
votes
2answers
596 views

Making refcheck work with cleveref

It seems that refcheck does not recognize references made by cleveref: \documentclass{article} \usepackage{amsmath} \usepackage{cleveref} \usepackage{refcheck} \begin{document} \begin{align} a ...
2
votes
1answer
34 views

Remove space in the default `\cref` command

I have my crefs defined as \crefname{section}{§}{§} \crefname{subsection}{§§}{§§} And when I reference it displays, for example, like § 4.5. I would like the middle space to dissapear and this ...
0
votes
0answers
18 views

Special cref display for sections and subsections in external documents

This is a variation of Special \cref display for \externaldocument where the solution by @David Carlisle takes us almost there. The question is how to get \cref to generate special prefixes for ...
4
votes
2answers
110 views

displaying ?? instead of the name of the lstlisting when using \cref

I change the name of the label of the lstlisting to Algorithm and it works fine for the caption. But when I use \cref, the instead of displaying algorithms 1 it shows ?? 1. \documentclass{scrreprt} ...
6
votes
1answer
119 views

No cleveref in beamer?

I am trying to get a math beamer presentation to work and it seems that cleveref is causing problems. The MWE below gives the error Paragraph ended before \@ynthm was complete In the documentation ...
0
votes
1answer
322 views

Put the § symbol before each section number [duplicate]

I'm writing a document (article class). I'm using the clever reference package to crossreference sections, and I have modified the references so the \cref{label} produces, for example if it's section ...
17
votes
5answers
3k views

Not using abbreviations with cleveref

I’d like to use the cleveref package but I don’t like that it inserts most names as abbreviations; for instance, it will print “… fig. 2.1 …” instead of “… figure 2.1 …”. Is there a way of changing ...
3
votes
1answer
71 views

Special \cref display for \externaldocument

I am using cleveref pointing to equations within my document, as well as to a technical appendix in a separate file (loaded by \externaldocument) Setup Lets that the the first file was in main.tex, ...
4
votes
1answer
53 views

Subequations with varioref and cleverref

Can somebody tell me why the references don't work in this example? \documentclass{article} \usepackage{varioref} \usepackage{hyperref} \usepackage{cleveref} \usepackage{amsmath} \begin{document} ...
0
votes
1answer
31 views

how to correctly customize section and equation using cleveref

I want to be able to change the standard way cleveref package makes reference to a section, or an equation. I thought the commands \crefformat{section}{\S#2#1#3} \crefformat{equation}{(#2#1#3)} ...
3
votes
2answers
83 views

cref table caption: works in body, not in lot

I am using cleveref package. In one of my table, i'm refering to an equation in the text. The reference works fine (also hyperref) in the caption just below the table. Unfortunately it doesn't work in ...
2
votes
1answer
57 views

Correct ordering of xr-hyper, hyperref, and cleveref

I want to use \cref, external documents, and hyperrefs. Take the following file, label it main1.tex and compile it: \documentclass{article} \usepackage[capitalise,noabbrev]{cleveref} ...
12
votes
2answers
7k views

Tex capacity exceeded sorry input stacksize=5000

I am getting this error while trying to build my tex file. As soon as I include the cleveref package, I get this error and it shows cleveref.sty with the cursor at the bolded part of the file. ...
2
votes
1answer
62 views

Distinguishing \ref and \cref through different colors

I have the following problem with the hyperref, and the cleverefpackages. I would like to distinguish internal links (e.g. sections, etc) from mathematical links (e.g. definitions, theorems, ...
0
votes
1answer
29 views

refer equations across chapters

I want to refer equations and figures from the previous chapters(showing in structure). I have to find the label from that chapter each time which is consuming more time. I want pop ups for all ...
4
votes
1answer
289 views

Cross-ref an equation using RefTeX, AUCTeX and cleveref

After an updated of AUCTeX (to 11.87) the solution that worked wonderful from this answer stopped working. In particular, I got the following error: reftex-reference: Wrong number of arguments: ...
5
votes
1answer
100 views

Referring with cleveref to a custom listing (\lstnewenvironment)

I use cleveref's \cref command for referencing, and \lstnewenvironment to create a new listing type. My document has multiple types of listings, each of them with their own counter. However, cleveref ...
7
votes
1answer
156 views

How to change cleveref references to 'verbal' varioref style?

I would like to use cleveref's automatic ref target type recognition but with the more verbal page reference of varioref. This is my MWE: \documentclass{report} \usepackage{varioref} ...
8
votes
1answer
91 views

Cleveref isn't sorting nested lists properly

I wanted to use the cleveref to automatically sort cross-references, but for some reason it isn't sorting labels in nested enumerate environments properly. This is my reduced code: ...
6
votes
1answer
76 views

breqn not playing well with cleveref (or vice versa)

This is a little different from Cleveref and breqn packages don't play nice together, and may not have a simple answer. I was experimenting with breqn, and found some of my tagged equations were ...
8
votes
1answer
235 views

Is cleveref safe to use?

I have sometimes been warned against using cleveref because it makes very fundamental changes of some of the basic LaTeX commands, like \label. Is this concern justified, and what are the issues of ...