Write out referenced chapter number
Use cleveref
together with fmtcount
:
\documentclass{scrreprt}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage{csquotes}
\usepackage{fmtcount}
\usepackage{hyperref}
\usepackage{cleveref}
\crefformat{chapter}{\chaptername~#2\numberstringnum{#1}#3}
\begin{document}
\chapter{Referenzieren}
\label{cha:referencing}
Dies ist ein Verweis auf \cref{cha:referencing}.
\end{document}
Blame Google if the German is bad.
If you want that also “Kapitel” is in the hyperlink, change the \crefformat
line into
\crefformat{chapter}{#2\chaptername~\numberstringnum{#1}#3}
and if you want the number name to begin with a capital letter, use \Numberstringnum
.
Yes, this is possible, but it's necessary to extract the chapter number first before it can be used. \ref...
does not provide a number at all, so refcount
and its getrefnumber
comes into action. This will produce 1
here.
To get a verbal expression of 1
as Eins
here, use \Numberstringnum
or \numberstringnum
for eins
from fmtcount
package.
\documentclass{scrreprt}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage{csquotes}
\usepackage{refcount}
\usepackage{fmtcount}
\usepackage{hyperref}
\begin{document}
\chapter{Hallo Welt}
I'm referencing Chapter~\Numberstringnum{\getrefnumber{cha:referencing}},~\enquote{\nameref{cha:referencing}}
\chapter{Referencing}
\label{cha:referencing}
\end{document}