2

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)}

would work fine; actually, they seem to work ok, also with capitalize, etc, except when I refer to multiple stuff, e.g. \cref{sec1,sec2}, in which case it still uses the default 'sections', or 'eqs.': What is then the correct way to customize cref behavior, so that for multiple sections I get something like §§1,2 and for equations I get (4),(5) or similar?

1 Answer 1

3

Add this to your preamble:

\crefmultiformat{section}{\S\S\,#2#1#3}%
{ and~(#2#1#3)}{, #2#1#3}{ and~#2#1#3}
\crefmultiformat{equation}{ (#2#1#3)}%
{ and~(#2#1#3)}{, (#2#1#3)}{ and~(#2#1#3)}
2
  • 1
    actually, the complete set of commands should specify \crefformat \crefrange \crefmultiformat \crefrangemultiformat, isn't it?
    – jj_p
    May 14, 2015 at 12:12
  • Yes. I supposed you would have a look at the doc and would find it by yourself. Apparently, 'twas a good bet (or a good bait? :o))
    – Bernard
    May 14, 2015 at 13:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .