Welcome to the TeXnik web site

Labels
TUG logo

Main page

Index
English FAQ
Documentation
Software
CTAN
Search CTAN:
Main Server

Statistics

 


 


More Books
Defining an own Label |  Umlauts in a Label | 


Defining an own Label
If you want an own text for referring labels you can modify the variable @currentlabel. For example we have an environment which does anything and we want to refer to this one with a special text than write in preamble:
\newenvironment{myOwnEnv}{%
  \def\@currentlabel{any Text I like}%  <-- labeltext for refs to this env
}{}
In the text we have something like
[...]
\begin{myOwnEnv}
  blah ... \label{test}
  blah ...
\end{myOwnEnv}
blah ..
See: \ref{test}.
[...]
Than you'll get an output like See: any Text I like


Umlauts in a Label
If you want to use f.ex. german umlauts in a label then write in the preamble
\shorthandon{"}
\DeclareInputText{228}{"a}
% ... (see latin1.def)
\shorthandoff{"}
Now you can use a label like \label{Änderung}

local time: Fri May 22 19:15:46 UTC 2026; file is: 1.2242 days old
contact webmaster _at_ TeXnik.de