Questions tagged [cleveref]

{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.

Filter by
Sorted by
Tagged with
1 vote
1 answer
32 views

cleveref not supporting a language

I want a document where you can select between two languages and use cleveref. However, cleveref does not support the second language nynorsk. I still want to be able to use the english version, so I ...
user avatar
  • 690
2 votes
0 answers
22 views

Conflict with hyperref's draft option, cleveref's \cref and... \textbf in \caption

The following MCE compiles like a charm. \documentclass{article} \usepackage{hyperref} \usepackage{cleveref} \hypersetup{draft} \begin{document} \begin{figure} \caption{% foo% % \textbf{...
user avatar
0 votes
1 answer
15 views

\crefname with multiple language definitions

I am making a LaTeX template with 2 languages, and use \selectlanguage{english} to set the document language after \begin{document}. This works fine for the cleveref package, except that I have made a ...
user avatar
  • 690
0 votes
0 answers
25 views

Named Equations with cleveref

I have a strange problem, where using a tag with an equation creates a warning (that obviously later leads to some unwanted behavior, though not in the context of this question) I use to import two ...
user avatar
  • 367
1 vote
1 answer
76 views

Skipping non-numeric part of counter label in local Cross-referencing

When quoting linguistic examples from authors inside a quotation, I like to use a special label specifying the name of the author. (I enclose it between square brackets but it will not appear here ...
user avatar
0 votes
0 answers
10 views

How to access algorithm caption and procedure name

I would like to be able to access an algorithm's caption and procedure name in a similar way I can reference the algorithm number; i.e. using something like \ref{somelabel}. Is there a straightforward ...
user avatar
  • 141
2 votes
1 answer
19 views

Autonum wrong behaviour

I get the wrong behaviour with this code, using autonum. When one clicks on the hyperlink to the equation it jumps to the beginning of the page. Minimal (not) working example: \documentclass{book} \...
user avatar
1 vote
1 answer
63 views

Hyperlink prints OK but jumps to wrong target

When I use pdflatex to process a book-length document, in chapter 6 a couple of isolated links to theorem-like environments in that same chapter appear printed correctly in the pdf output, but ...
user avatar
  • 6,382
0 votes
1 answer
61 views

Non-ascii characters in label with cleveref in Overleaf

I'm collaboratively working in a LaTeX document in Overleaf and some team members use German umlauts (ä, ö, ü, Ä, Ö, Ü) in their labels. It works with \ref: \documentclass{scrartcl} \usepackage[utf8]{...
user avatar
  • 103
0 votes
0 answers
26 views

Best practices for class authors: configurable names / translations

How should I suggest document authors rename elements that my class provides, either because they're not writing in English, or because they need to change a word or two? Here are three tools, each ...
user avatar
0 votes
2 answers
44 views

Incorrect label type using threeparttable and cleveref

I'm having an issue with the threeparttable package label type, causing cleverref to not be able to refer correctly to the table. Compiling on Overleaf produces the following warning: "cref ...
user avatar
0 votes
1 answer
50 views

MPDI article with cleveref

I need to write an article using the MDPI template. The latest version of this template is available on Overleaf or directly on MDPI website. This template is said to be compatible with cleveref ...
user avatar
  • 860
2 votes
1 answer
98 views

Adding `UsedOn` option to cleveref's \cref to mimic hyperref's \backcite

I am trying to overload \label and \cref, so that the following happens (similar in spirit to backref's \backcite): In some preliminary chapter, I define in Theorem A a label \label{thm:A}. Later in ...
user avatar
0 votes
0 answers
39 views

Using cleveref with mdpi template

I would like to use the \cref command provided by the cleveref package in a project using the MDPI template. However, I can't seem to do so without getting an error. Because I'm working from the ...
user avatar
  • 2,990
1 vote
1 answer
46 views

cleveref conflicts with polyglossia when required in a class

When I run the following MWE (with xelatex): % File myclass.cls \NeedsTeXFormat{LaTeX2e} \ProvidesClass{myclass} \LoadClass[12pt]{article} \RequirePackage{polyglossia} \RequirePackage{cleveref} % ...
user avatar
1 vote
1 answer
42 views

Custom counter for cross-referencing is incorrect when used inside tabularray

I would like share with something. I have created a custom counter to cross-reference sub figures. For some reason, the counter is wrong if I use it inside tblr environment (the one defined in ...
user avatar
  • 540
3 votes
2 answers
99 views

Cleveref and caption-based command - wrong references

I am trying to create a caption command that highlights the first sentence and also uses the first sentence as a short caption for the table of *. Let's call it kaption. This is done using the ...
user avatar
  • 253
0 votes
2 answers
187 views

How to adapt \crefrangelabelformat to subexample formatting?

I would like to be able to redefine something which is supposed to be defined in the preamble. In this example and in relation to this question : Cross-referencing: more sublevels, and presets, I want ...
user avatar
4 votes
0 answers
210 views

Cross-referencing: more sublevels, and presets

I'm typing a lot of linguistic examples and I would like label formatting to gain flexibility, i.e. setting up presets would be great. That is, I'd like to be able to have ready-to-use setups ...
user avatar
0 votes
1 answer
42 views

Obtain (1)‒(3) style when referring to ranges of examples, when default \crefrangelabelformat has no parentheses

I need \crefrangelabelformat to be without parentheses, so I can type 1‒3 when in an "already between parentheses" context, as in (for this issue, see 1–3 and following examples). But then, ...
user avatar
0 votes
1 answer
22 views

Hyperlink jumping to incorrect location for \newtcolorbox labeling in compilation LaTeX -> dvi -> ps -> pdf

By compiling the following sample code: \documentclass{report} \usepackage{lipsum} \usepackage{amsthm} \usepackage[many]{tcolorbox} \usepackage[dvips,colorlinks,bookmarks]{hyperref} \usepackage[...
user avatar
  • 11
1 vote
1 answer
14 views

Repeat argument of macro for cleveref referencing (forcsvlist?)

This is a follow up question on How to customize enumerate list with resuming numbering on second level using customize item command?. Now I am wondering how I can reference to the entries of my ...
user avatar
1 vote
1 answer
46 views

LaTeX Warnings: `' multiply defined and `@cref' multiply defined

By compiling a LaTeX file, I get the following messages: `' multiply defined And `@cref' multiply defined What could be generating this and how to fix it? Here is (a sample of) my code: \...
user avatar
0 votes
2 answers
52 views

Why doesn't cleveref work in Portuguese?

I'm using cleveref in a document in Portuguese, but the reference of the chapter is in English? How I can fix this? Here it is a sample of my code: \documentclass[portuges]{report} \usepackage[...
user avatar
0 votes
0 answers
34 views

Bold, color, and hypertext links in tcolorbox

I'm trying to cross-reference theorems in colorbox style at once. My goal is to get the following: \documentclass{article} \usepackage{xcolor} \usepackage[many]{tcolorbox} \newtcolorbox[auto counter,...
user avatar
  • 1
1 vote
0 answers
34 views

math tools and cleveref gives no equation number

Using the following \documentclass{scrartcl} \usepackage{amsmath} \usepackage[tbtags]{mathtools} \mathtoolsset{% showonlyrefs = true ,showmanualtags = true } \usepackage{varioref} \...
user avatar
  • 607
3 votes
1 answer
61 views

Cleveref/hyperref: incorrect link to step in algorithm

I am using the cleveref and hyperref packages. This works well overall, but cross-references to lines in algorithms are incorrect. I found some other related posts, this one and this one. However, ...
user avatar
  • 303
0 votes
1 answer
172 views

Advanced Cross-Referencing with Linguex/Philex: Skipping and Stripping

\documentclass{report} \usepackage{philex} % Includes linguex. Only loading it for \phildashes. \usepackage{cleveref} % Referring to Subexample Ranges \crefname{ExNo}{}{} \crefname{SubExNo}{}{} \...
user avatar
2 votes
3 answers
185 views

Refer to a range of subsubexamples

I use Cleveref to refer to subexamples such as "2a–c". Now I want to use crefrange to refer to 1ai–ii as well. \documentclass[a4paper,12pt]{report} \usepackage{philex} \usepackage{cleveref} ...
user avatar
1 vote
1 answer
29 views

Is it possible to use a place holder as the counter name in \crefname?

When \cref a theorem, in order to show the referencing name corresponding to the original appearance in its context (i.e., if you write a theorem in English context, and later refer to it in French ...
user avatar
  • 4,737
1 vote
0 answers
25 views

Reference a theorem with its name "as is" using cleveref (in searching of a new way of implementing of the "originalref " mode in ProjLib)

When writing multi-language documents, if a theorem title has different name corresponding to different languages, then there are two ways to refer to them: Using the original name as it appeared. ...
user avatar
  • 4,737
0 votes
1 answer
21 views

Referencing in Cleveref with annotations

With the \cite[] instruction, you can add some annotations to references: Is it possible to do the same with Cleveref (\Cref)?
user avatar
  • 103
1 vote
1 answer
49 views

Referencing a set of consecutive equation using \cref

I want to refer to a set of consecutive equations. Following this and this I tried the following - \documentclass{article} \usepackage{amsmath} \usepackage{hyperref, cleveref%,hyperref } \...
user avatar
  • 83
0 votes
1 answer
33 views

Table caption exceeding page margins when using captionsetup and xltabular with cleveref active

today I discovered a strange side-effect which I would like to share in the community and gather your insights and feedback. As indicated below, there is a workaround for the issue by not using the ...
user avatar
  • 352
2 votes
1 answer
64 views

Cleveref produces incorrect labels when I cross-reference theorem-like environments

If I set the counter of corollaries to follow theorem, cleveref incorrectly uses the label theorem in the text, rather than corollary. How can I correct this? Minimum working example: \documentclass{...
user avatar
1 vote
1 answer
97 views

Color all \cref cleveref

I am unable to get this to work, I am trying to use, \creflabelformat{*}{\textcolor{darkred}{#1}} to color all labels or links with the same color however, this does not appear to work. \documentclass[...
user avatar
  • 171
1 vote
1 answer
53 views

How to get rid the additional dot at the end of “Appendix A.”?

Consider the following MWE: \documentclass[a4paper]{scrartcl} % PACKAGES LOADING \usepackage[title]{appendix} \usepackage{cleveref} \usepackage{secdot} \begin{document} See \cref{aa} for details. ...
user avatar
  • 2,037
0 votes
0 answers
34 views

How do I use cleveref within section titles whose formatting is in uppercase?

In my text, section titles should be in capital letters, so I used the sectsty package for this. However, when I want to put a cleveref inside the section title (which is in uppercase), the output is ...
user avatar
2 votes
1 answer
37 views

Referencing an algorithm written in Algorithm2e using Cleveref prints the word "Line+Number" instead of "Algorithm+Number"

I am using the package algorithm2e to write some algorithms. However, when I reference a specific algorithm using cleveref, I get [Line 1] instead of [Algorithm 1]. Is there anyway to let cleveref ...
user avatar
  • 23
1 vote
2 answers
90 views

Compilation errors when babel and cleveref are included. and other errors when \frontmatter is present

Overview I'm currently re-writing some of my lecture notes in LaTeX. My first language is Spanish, so I'm using the babel package. I also wanted to add some utility to the resulting document, like ...
user avatar
3 votes
1 answer
112 views

Adding "Appendix" in front of "Figure" in cref

I'm trying to create a list of appendix table/figures, which are formatted as: "Appendix Table/Figure #." I'm using the following code: \renewcommand{\figurename}{Appendix Figure} \...
user avatar
0 votes
1 answer
46 views

Cleveref behaviour for multilingual documents

I want to have a chapter (Extended abstract) in a foreign language (Brazilian), where all cleveref references to sections and chapters are written in Portuguese (ex. "Seção 3", "...
user avatar
  • 156
3 votes
1 answer
54 views

TeX4ht: conflict between hyperref and cleveref (II)

This is another problem after applying the code in https://tex.stackexchange.com/a/623536/ MWE: \documentclass{amsart} \usepackage{hyperref} \usepackage{cleveref} \newtheorem{theorem}{Theorem} \...
user avatar
  • 669
0 votes
1 answer
40 views

How to get \nameref{} to be displayed in small caps?

Consider the following MWE: \documentclass[a4paper]{scrartcl} % PACKAGES LOADING \usepackage[dvipsnames]{xcolor} \usepackage{amsmath, mathtools, amsthm, mathrsfs, amssymb} \usepackage[framemethod=...
user avatar
  • 2,037
0 votes
1 answer
41 views

Change reference name of listing

I would like to reference the listing like Codebeispiel 1. How can I do that? What I got is only ?? 1 \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{blindtext} \usepackage{titlesec} \...
user avatar
4 votes
1 answer
74 views

tex4ht: conflict between hyperref and cleveref

MWE: \documentclass{amsart} \usepackage{hyperref} \usepackage{cleveref} \newtheorem{theorem}{Theorem} \begin{document} \begin{theorem} \label{test} This is a theorem. \end{theorem} Look at \...
user avatar
  • 669
2 votes
2 answers
58 views

Cryptocode: Cref should link to a game, and write its name

I'm using \cryptocode to display codes like: By default, it seems that it's not floating. However, when the games are big I'd prefer to make them float. Moreover, to refer to them, I'd like to just ...
user avatar
  • 5,053
0 votes
0 answers
38 views

Remove parentheses for only one reference

I need to reference some items from an enumerate environment. I can do this by adding a label at the beginning of each \item (see MWE at the bottom). So far, so good. Each item in the enumerate has a ...
user avatar
  • 175
3 votes
2 answers
111 views

[greek]babel + cleveref + Roman pagenumbering + label = ☇

Feeding \documentclass{article} \usepackage[greek]{babel}%%% greek should not necessarily be the main language; e.g., [greek, ngerman] would also expose the bug. \usepackage{cleveref}%%% option [...
user avatar
3 votes
2 answers
59 views

How to suppress the numbering of a single appendix chapter?

Consider the following LaTeX code saved in the file Thesis.tex: % arara: lualatex % arara: lualatex \documentclass[openany]{scrbook} \usepackage{xr-hyper, hyperref} \hypersetup{colorlinks=true} \...
user avatar
  • 8,684

1
2 3 4 5
17