You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
% https://tex.stackexchange.com/questions/81634/cleveref-configure-symbol-for-all-sectioning-types-once-time
%
% I believe it's customary not to leave a space between the section symbol generated by \S (plural form \S\S) and the associated number (or numbers). To achieve this outcome using cleveref's cross-referencing commands, it's necessary to use the "low-level" controls \crefformat and \crefmultiformat; relying on the "high-level" control \crefname doesn't quite get you there, I think. The following MWE is a modified form of lockstep's example:
\crefformat{chapter}{\S#2#1#3}
\crefmultiformat{chapter}{\S\S#2#1#3}{ and~#2#1#3}{, #2#1#3}{, and~#2#1#3}
\usepackage{cleveref} % This package must be loaded in the end.
\Crefname{table}{Table}{Tables}
\crefname{table}{Table}{Tables}
\Crefname{figure}{Figure}{Figures}
\crefname{figure}{Figure}{Figures}
% \crefname{figure}{Fig.}{Figs.}
\Crefname{algocf}{Algorithm}{Algorithms}
\crefname{algocf}{Algorithm}{Algorithms}
% https://tex.stackexchange.com/questions/81634/cleveref-configure-symbol-for-all-sectioning-types-once-time
%
% I believe it's customary not to leave a space between the section symbol generated by \S (plural form \S\S) and the associated number (or numbers). To achieve this outcome using cleveref's cross-referencing commands, it's necessary to use the "low-level" controls \crefformat and \crefmultiformat; relying on the "high-level" control \crefname doesn't quite get you there, I think. The following MWE is a modified form of lockstep's example:
\crefformat{chapter}{\S#2#1#3}
\crefmultiformat{chapter}{\S\S#2#1#3}{ and~#2#1#3}{, #2#1#3}{, and~#2#1#3}
\crefformat{section}{\S#2#1#3}
\crefmultiformat{section}{\S\S#2#1#3}{ and~#2#1#3}{, #2#1#3}{, and~#2#1#3}
The text was updated successfully, but these errors were encountered: