summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-04-18 00:16:29 +0000
committerKarl Berry <karl@freefriends.org>2012-04-18 00:16:29 +0000
commit75320f538abdfe4732d4218c4814ccca7163d907 (patch)
tree96cfa19a707f64ec6bd6bcf8a105252cf4a1f04c
parentdd5fdc960f44e171cd33c9e04ca64dd4f830407d (diff)
chemnum (17apr12)
git-svn-id: svn://tug.org/texlive/trunk@26016 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/README10
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum-codehelper.tex309
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_de.pdfbin0 -> 991515 bytes
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_de.tex (renamed from Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.tex)656
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.pdfbin897108 -> 0 bytes
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.pdfbin887742 -> 0 bytes
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_en.pdfbin0 -> 980153 bytes
-rw-r--r--Master/texmf-dist/doc/latex/chemnum/chemnum_en.tex (renamed from Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.tex)646
-rw-r--r--Master/texmf-dist/tex/latex/chemnum/chemnum.sty69
9 files changed, 646 insertions, 1044 deletions
diff --git a/Master/texmf-dist/doc/latex/chemnum/README b/Master/texmf-dist/doc/latex/chemnum/README
index 33fa8a58a67..ac8436b2d52 100644
--- a/Master/texmf-dist/doc/latex/chemnum/README
+++ b/Master/texmf-dist/doc/latex/chemnum/README
@@ -1,4 +1,4 @@
-chemnum v0.4a
+chemnum v0.4b
a comprehensive approach for the numbering of chemical compounds
Basically one main command is provided, \cmpd{<label name>}. With
@@ -12,7 +12,7 @@ chemnum also needs the packages etoolbox, psfrag and textgreek or bm
to be fully functioning.
Clemens NIEDERBERGER
-2012/02/26
+2012/04/15
http://www.mychemistry.eu/
contact@mychemistry.eu
@@ -34,6 +34,6 @@ This work has the LPPL maintenance status `maintained'.
The Current Maintainer of this work is Clemens Niederberger.
-This work consists of the files chemnum.sty, chemnum_doc_de.tex,
-chemnum_doc_en.tex, chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps,
-README and the derived files chemnum_doc_de.pdf and chemnum_doc_en.pdf \ No newline at end of file
+This work consists of the files chemnum.sty, chemnum_de.tex, chemnum_en.tex,
+scheme-tmp.eps, scheme-bla.eps, README and the derived files chemnum_de.pdf
+and chemnum_en.pdf
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum-codehelper.tex b/Master/texmf-dist/doc/latex/chemnum/chemnum-codehelper.tex
deleted file mode 100644
index 9d0e3bd4490..00000000000
--- a/Master/texmf-dist/doc/latex/chemnum/chemnum-codehelper.tex
+++ /dev/null
@@ -1,309 +0,0 @@
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% - chemnum - chemnum-codehelper.tex - %
-% - a comprehensive approach for the numbering of chemical compounds - %
-% ------------------------------------------------------------------------------------- %
-% - Clemens NIEDERBERGER - %
-% - 2012/02/22 - %
-% ------------------------------------------------------------------------------------- %
-% - http://www.mychemistry.eu/ - %
-% - contact@mychemistry.eu - %
-% ------------------------------------------------------------------------------------- %
-% - If you have any ideas, questions, suggestions or bugs to report, please feel free - %
-% - to contact me. - %
-% ------------------------------------------------------------------------------------- %
-% - Copyright 2011-2012 Clemens Niederberger - %
-% - - %
-% - This work may be distributed and/or modified under the - %
-% - conditions of the LaTeX Project Public License, either version 1.3 - %
-% - of this license or (at your option) any later version. - %
-% - The latest version of this license is in - %
-% - http://www.latex-project.org/lppl.txt - %
-% - and version 1.3 or later is part of all distributions of LaTeX - %
-% - version 2005/12/01 or later. - %
-% - - %
-% - This work has the LPPL maintenance status `maintained'. - %
-% - - %
-% - The Current Maintainer of this work is Clemens Niederberger. - %
-% - - %
-% - This work consists of the files chemnum.sty, chemnum_doc_de.tex, - %
-% - chemnum_doc_en.tex, chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, - %
-% - README and the derived files chemnum_doc_de.pdf and chemnum_doc_en.pdf - %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
-% This code is just a copy from the LaTeXdemo environment in the siunitx documentation
-% which has been (minimally) adapted and provides environment beispiel with options
-% [code and example] (default)
-% [code only]
-% [code and float]
-%
-% Clemens NIEDERBERGER, 2011/12/01
-%
-% For creating examples with nice highlighting of code, and so
-% on; based on the system used in the listings source (lstsample).
-\RequirePackage[final]{listings}
-\RequirePackage{framed}
-\RequirePackage{xcolor}
- \xdefinecolor{code}{rgb}{.6,.25,.15}
- \xdefinecolor{key}{rgb}{0.02,0.48,0.18}
- \xdefinecolor{myblue}{rgb}{0.02,0.04,0.48}
- \xdefinecolor{myred}{rgb}{0.65,0.04,0.07}
- \xdefinecolor{mygray}{rgb}{0.4,0.4,0.4}
-\makeatletter
-\lst@RequireAspects{writefile}
-\newsavebox{\beispiel@box}
-\lstnewenvironment{beispiel}[1][code and example]
- {%
- \global\let\lst@intname\@empty
- \expandafter\let\expandafter\beispiel@end
- \csname beispiel@#1@end\endcsname
- \@nameuse{beispiel@#1}%
- }
- {\beispiel@end}
-\newcommand*\beispiel@new[3]{%
- \expandafter\newcommand\expandafter*\expandafter
- {\csname beispiel@#1\endcsname}{#2}%
- \expandafter\newcommand\expandafter*\expandafter
- {\csname beispiel@#1@end\endcsname}{#3}%
-}
-\newcommand*\beispiel@common{%
- \setkeys{lst}
- {
- language=[LaTeX]TeX,
- basicstyle={\ttfamily\footnotesize}, % Grundstil
- extendedchars=true,
- numbers=left, % Zeilennummern
- numberstyle=\tiny, % Größe des Zeilennummern
- numberblanklines=true, % Leerzeilen nummerieren
- gobble=0, % das erste Leerzeichen abschneiden
- xleftmargin=20pt, % Einrückung links
- breaklines=true, % Zeilenumbruch
- literate={ä}{{\"a}}1 {ö}{{\"o}}1 {ü}{{\"u}}1 {Ä}{{\"A}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1 {ß}{{\ss}}1,
- moredelim=[is][\color{red!25!purple}]{!!}{!!},% Hervorhebung
- moredelim=[is][\color{black}]{++}{++}, % Hervorhebung der Keywords rückgängig
- commentstyle={\color{mygray}},
- keywordstyle=\color{code},
- texcsstyle=[30]\color{code},
- moretexcs=[30]
- {
- @m,
- arrow,
- bf,
- ch,
- chemfig,
- chemname,
- cmpd,
- cmpdinit,
- cmpdref,
- cmpdreset,
- cmpdsetup,
- CNlabel,
- CNlabelnoref,
- CNref,
- CNlabelsub,
- CNlabelsubnoref,
- CNrefsub,
- declarecompound,
- color,
- compound,
- compoundprefix,
- compoundsuffix,
- fcite,
- includegraphics,
- lstinline,
- marker,
- midrule,
- penalty,
- renewcommand,
- schemename,
- schemestart,
- schemestop,
- selectlanguage,
- setarrowoffset,
- setatomsep,
- setcompoundsep,
- setdoublesep,
- section,
- sf,
- subsection,
- subsubsection,
- texorpdfstring,
- textcolor,
- textnumero,
- theffbibliography,
- uline
- }
- }%
-}
-\newcommand*\beispiel@input[1][\jobname.tmp]{%
- \catcode`\^^M=5\relax
- \small
- \begingroup
- \leavevmode
- \input{#1}%
- \endgroup
-}
-\beispiel@new{code and example}
- {%
- \setbox\beispiel@box=\hbox\bgroup
- \lst@BeginAlsoWriteFile{\jobname.tmp}%
- \beispiel@common
- }
- {%
- \lst@EndWriteFile
- \egroup
- \colorlet{shadecolor}{yellow!20}
- \begin{shaded}
- \ifdim\wd\beispiel@box>0.48\linewidth\relax
- \begin{minipage}{.9\linewidth}
- \hbox to \linewidth{\box\beispiel@box\hss}%
- \end{minipage}
- \vskip3mm
- \begin{minipage}{.9\linewidth}
- \beispiel@input
- \end{minipage}
- \else
- \begin{minipage}{0.48\linewidth}
- \hbox to\linewidth{\box\beispiel@box\hss}%
- \end{minipage}
- \hfill
- \begin{minipage}{0.48\linewidth}
- \beispiel@input
- \end{minipage}
- \fi
- \end{shaded}
- }
-\beispiel@new{code and float}{%
- \colorlet{shadecolor}{yellow!20}
- \shaded
- \lst@BeginAlsoWriteFile{bsp.tmp}%
- \beispiel@common
-}{%
- \lst@EndWriteFile
- \endshaded
- \beispiel@input[bsp.tmp]
-}
-\beispiel@new{code only}
- {\colorlet{shadecolor}{yellow!20}\shaded\beispiel@common}{\endshaded}
-\makeatother
-
-\lstset{
- language=[LaTeX]TeX,
- basicstyle={\ttfamily}, % Grundstil
- extendedchars=true,
- numbers=left, % Zeilennummern
- numberstyle=\tiny, % Größe des Zeilennummern
- numberblanklines=true, % Leerzeilen nummerieren
- gobble=0, % das erste Leerzeichen abschneiden
- xleftmargin=20pt, % Einrückung links
- breaklines=true, % Zeilenumbruch
- literate={ä}{{\"a}}1 {ö}{{\"o}}1 {ü}{{\"u}}1 {Ä}{{\"A}}1 {Ö}{{\"O}}1 {Ü}{{\"U}}1 {ß}{{\ss}}1,
- moredelim=[is][\color{myred}]{!!}{!!},% Hervorhebung
- moredelim=[is][\color{black}]{++}{++}, % Hervorhebung der Keywords rückgängig
- commentstyle={\color{mygray}},
- keywordstyle=\color{code},
- texcsstyle=[30]\color{code},
- moretexcs=[30]
- {
- @m,
- ch,
- cmpd,
- cmpdinit,
- cmpdref,
- cmpdreset,
- cmpdsetup,
- CNlabel,
- CNlabelnoref,
- CNref,
- CNlabelsub,
- CNlabelsubnoref,
- CNrefsub,
- declarecompound,
- color,
- compoundprefix,
- compoundsuffix,
- fcite,
- lstinline,
- penalty,
- psfrag,
- schemeref,
- tableofcontents,
- textnumero,
- theffbibliography,
- uline
- }
- }%
-
-\makeatletter
-\def\GetFileInfo#1{%
- \def\filename{#1}%
- \def\@tempb##1 ##2 ##3\relax##4\relax{%
- \def\filedate{##1}%
- \def\fileversion{##2}%
- \def\fileinfo{##3}}%
- \edef\@tempa{\csname ver@#1.sty\endcsname}%
- \expandafter\@tempb\@tempa\relax? ? \relax\relax}
-\makeatother
-
-\ExplSyntaxOn
-\DeclareDocumentEnvironment { myquote } { o }
- {
- \quote
- \small\sffamily
- }
- {
- \IfNoValueF { #1 }
- {
- \par\noindent
- \parbox { \linewidth } { \raggedleft \normalfont \itshape #1 }
- }
- \endquote
- }
-
-\NewDocumentCommand \paket { sm }
- {
- \textsf { #2 }
- \cs_if_exist:cF { paket @ #2 }
- {
- \cs_new_nopar:cpn { paket @ #2 } { }
- \IfBooleanF { #1 }
- { \footnote { CTAN: ~ \href { http://www.ctan.org/pkg/#2/ } { #2 } } }
- }
- \index { #2 @ \textsf { #2 } }
- }
-
-\NewDocumentCommand \key { mg }
- {
- \textcolor { key } { \texttt { #1 } }
- \IfNoValueF { #2 } { \texttt { ~=~#2 } }
- \index { #1 @ \textcolor { key } { \texttt { #1 } } }
- }
-
-\NewDocumentCommand \cmd { somoog }
- {
- \textcolor { code } { \texttt { \textbackslash #3 } }
- \IfNoValueF { #4 } { \texttt { [ #4 ] } }
- \IfNoValueF { #5 } { \texttt { [ #5 ] } }
- \IfNoValueF { #6 } { \texttt { \{ #6 \} } }
- \IfBooleanF { #1 }
- {
- \index
- {
- \IfNoValueTF { #2 } { #3 } { #2 }
- @ \textcolor { code } { \texttt { \textbackslash #3 } }
- }
- }
- }
-
-\NewDocumentCommand \secidx { som }
- {
- \IfBooleanTF { #1 }
- { \index { \IfNoValueTF { #2 } { #3 } { #2 } @ \textbf { #3 } |) } }
- { \index { \IfNoValueTF { #2 } { #3 } { #2 } @ \textbf { #3 } |( } }
- }
-
-\NewDocumentCommand \ma { m }
- { \texttt { \{ #1 \} } }
-
-\NewDocumentCommand \oa { m }
- { \texttt { [ #1 ] } }
-\ExplSyntaxOff \ No newline at end of file
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_de.pdf b/Master/texmf-dist/doc/latex/chemnum/chemnum_de.pdf
new file mode 100644
index 00000000000..2215405e9d4
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/chemnum/chemnum_de.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.tex b/Master/texmf-dist/doc/latex/chemnum/chemnum_de.tex
index 8d8b87f3749..a0886b63fa7 100644
--- a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.tex
+++ b/Master/texmf-dist/doc/latex/chemnum/chemnum_de.tex
@@ -1,50 +1,59 @@
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% - chemnum - chemnum_doc_de.tex - %
-% - a comprehensive approach for the numbering of chemical compounds - %
-% ------------------------------------------------------------------------------------- %
-% - Clemens NIEDERBERGER - %
-% - 2012/02/26 - %
-% ------------------------------------------------------------------------------------- %
-% - http://www.mychemistry.eu/ - %
-% - contact@mychemistry.eu - %
-% ------------------------------------------------------------------------------------- %
-% - If you have any ideas, questions, suggestions or bugs to report, please feel free - %
-% - to contact me. - %
-% ------------------------------------------------------------------------------------- %
-% - Copyright 2011-2012 Clemens Niederberger - %
-% - - %
-% - This work may be distributed and/or modified under the - %
-% - conditions of the LaTeX Project Public License, either version 1.3 - %
-% - of this license or (at your option) any later version. - %
-% - The latest version of this license is in - %
-% - http://www.latex-project.org/lppl.txt - %
-% - and version 1.3 or later is part of all distributions of LaTeX - %
-% - version 2005/12/01 or later. - %
-% - - %
-% - This work has the LPPL maintenance status `maintained'. - %
-% - - %
-% - The Current Maintainer of this work is Clemens Niederberger. - %
-% - - %
-% - This work consists of the files chemnum.sty, chemnum_doc_de.tex, - %
-% - chemnum_doc_en.tex, chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, - %
-% - README and the derived files chemnum_doc_de.pdf and chemnum_doc_en.pdf - %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\documentclass[DIV11,toc=index]{scrartcl}
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% - chemnum - chemnum_de.tex
+% - a comprehensive approach for the numbering of chemical compounds
+% -----------------------------------------------------------------------------
+% - Clemens NIEDERBERGER
+% - 2012/04/15
+% - contact@mychemistry.eu
+% -----------------------------------------------------------------------------
+% - If you have any ideas, questions, suggestions or bugs to report, please
+% - feel free to contact me.
+% -----------------------------------------------------------------------------
+% - Copyright 2011-2012 Clemens Niederberger
+% -
+% - This work may be distributed and/or modified under the
+% - conditions of the LaTeX Project Public License, either version 1.3
+% - of this license or (at your option) any later version.
+% - The latest version of this license is in
+% - http://www.latex-project.org/lppl.txt
+% - and version 1.3 or later is part of all distributions of LaTeX
+% - version 2005/12/01 or later.
+% -
+% - This work has the LPPL maintenance status `maintained'.
+% -
+% - The Current Maintainer of this work is Clemens Niederberger.
+% -
+% - This work consists of the files chemnum.sty, chemnum_de.tex, chemnum_en.tex,
+% - chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, README and the
+% - derived files chemnum_de.pdf and chemnum_en.pdf
+% -
+% - in order to compile this document you need the class `cnpkgdoc' with is
+% - available under the LPPL here: https://bitbucket.org/cgnieder/cnpkgdoc/
+% -
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\RequirePackage[textgreek]{chemnum}
+\documentclass[DIV11,toc=index]{cnpkgdoc}
+\docsetup{
+ pkg = chemnum,
+ language = de,
+ code-box = {backgroundcolor=cnpkgcodebg,skipabove=1ex,skipbelow=1ex}
+}
+\addcmds{
+ @m,arrow,bf,ch,chemfig,chemname,cmpd,cmpdinit,cmpdref,cmpdreset,cmpdsetup,
+ CNlabel,CNlabelnoref,CNref,CNlabelsub,CNlabelsubnoref,CNrefsub,
+ declarecompound,color,compound,compoundprefix,compoundsuffix,fcite,
+ includegraphics,midrule,penalty,renewcommand,schemename,schemestart,
+ schemestop,selectlanguage,setarrowoffset,setatomsep,setcompoundsep,
+ setdoublesep,section,sf,subsection,subsubsection,tableofcontents,
+ texorpdfstring,textcolor,theffbibliography,uline}
+
\usepackage[ngerman,german,naustrian,austrian,english,british,american,canadian,frenchb,canadien,spanish,italian]{babel}
-\usepackage[T1]{fontenc}
-\usepackage[utf8]{inputenx}
-\usepackage[textgreek]{chemnum}
-\usepackage{textcomp,microtype,libertine,url,xspace,longtable,tabu,booktabs,makeidx,multicol}
-\usepackage[scaled=.95]{inconsolata}
-\usepackage{chemscheme}
- \renewcommand*\schemename{Schema}
-\usepackage[german,iupac=strict]{chemmacros}
+\usepackage{textcomp,longtable,tabu,booktabs,chemscheme}
+\usepackage[iupac=strict]{chemmacros}
\DeclareChemIUPAC\a{\textalpha}
\DeclareChemIUPAC\b{\textbeta}
\usepackage{chemfig}
-\usepackage[normalem]{ulem}
\usepackage[runs=2]{auto-pst-pdf}
-\input{chemnum-codehelper}
\begin{filecontents}{index_de.ist}
preamble "\\begin{theindex}\n Abschnitts\\\"{u}berschriften werden \\textbf{fett}, Pakete \\textsf{serifenlos}, Befehle \\textcolor{code}{braun} und Keys \\textcolor{key}{gr\\\"{u}n} dargestellt.\\newline\n\n"
@@ -59,61 +68,16 @@
suffix_3p "\\nohyperpage{\\,ff.}"
\end{filecontents}
-\usepackage{hyperref}
- \hypersetup{colorlinks = true,
- allcolors = myblue,
- plainpages = false,
- bookmarksopen = true,
- bookmarksopenlevel = 2,
- bookmarksnumbered = true,
- pdfauthor = {Clemens Niederberger},
- pdftitle = {chemnum - deutsche Dokumentation},
- pdfsubject = {Chemische Substanzen Nummerieren},
- pdfkeywords = {chemmnum},
- pdfcreator = {LaTeX},
- pdfstartview = FitH
- }
-\ExplSyntaxOn
-\NewDocumentCommand \keyentry { mmm }
- {
- \noindent
- \textcolor { key } { \texttt { #1 } }
- \texttt { ~=~#2 }
- \hfill Typ:~
- \texttt { #3 }
- \index { #1 @ \textcolor { key } { \texttt { #1 } } }
- }
-\ExplSyntaxOff
-
-\GetFileInfo{chemnum}
-\newcommand*\chemnum{{\scshape\textcolor{myblue}{\filename}}\xspace}
-\newcommand*\CNversion{\fileversion\xspace}
-\newcommand*\CNdate{\filedate\xspace}
-\newcommand*\CNinfo{\fileinfo\ with \LaTeXe.}
-
-\newcommand*\zB{\mbox{z.\,B.}\xspace}
-\newcommand*\bzw{\mbox{bzw.}\xspace}
-\newcommand*\usw{\mbox{usw.}\xspace}
-
-\cmpdinit*{a,aa,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,benzol,r,s,t,{1,3-dichlorocyclohexanol}}
-\makeindex
-\begin{document}
-\selectlanguage{ngerman}
-\begin{titlepage}
- \centering
- \Huge\textcolor{myblue}{\biolinumshadow[\fontsize{1.5cm}{1.6cm}\fontshape{sc}]{chemnum}}
- \vskip.5cm
- \Large \CNversion \qquad \CNdate
- \vskip.5cm
- \large Clemens \textsc{Niederberger}
- \vskip.25cm
- \normalsize\url{https://bitbucket.org/cgnieder/chemnum/}\\
- \href{mailto:contact@mychemistry.eu}{contact@mychemistry.eu}
- \begin{center}
- \Large\color{myblue} \CNinfo \\[16pt]
- \normalcolor deutsche Dokumentation
- \end{center}
- \vskip3cm \cmpdinit*{glucose.alpha, glucose.beta, glucose.chain}
+\let\prog\textsc
+\let\name\textsc
+\let\CNversion\cnpkgdocpkgversion
+\let\CNdate\cnpkgdocpkgdate
+\def\Wikipedia{\textup{\libertineGlyph{W.alt}}\kern-.8pt\textsc{ikipedia}}
+
+\cmpdinit*{a,aa,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,benzene,r,s,t,{1,3-dichlorocyclohexanole}}
+
+\TitlePicture{%
+\cmpdinit*{glucose.alpha, glucose.beta, glucose.chain}
\cmpd*[sub-counter = greek]{glucose.alpha, glucose.beta}\cmpd*{glucose.chain}
\setatomsep{2em}
\definesubmol{x}{(-[4]H)(-[0]OH)}
@@ -131,26 +95,23 @@
\arrow(@chainlabel--){0}[180,2.3] \normalsize\cmpd[cmpd-delim]{glucose.alpha}
\schemestop
\caption{Das \a- und das \b-Anomer von \D-Glucose \cmpd[list-delim,list-lang=DE]{glucose.alpha,glucose.beta} stehen in Lösung über die offenkettige Form \cmpd[cmpd-delim]{glucose.chain} im Gleichgewicht.}
- \end{scheme}
-\end{titlepage}
-\cmpdreset
-\begin{multicols}{2}
- \tableofcontents
-\end{multicols}
+ \end{scheme}}
+
+\makeindex
+\begin{document}
+\selectlanguage{ngerman}\cmpdreset
\section{Ein sehr kurzes Readme}
-\chemnum \CNversion steht unter der \LaTeX\ Project Public License Version 1.3 oder später.\newline(\url{http://www.latex-project.org/lppl.txt})
+\chemnum \CNversion\ steht unter der \LaTeX\ Project Public License Version 1.3 oder später. (\url{http://www.latex-project.org/lppl.txt})
\chemnum ruft intern die Pakete \paket*{expl3} und \paket{xparse} auf. \paket{xparse} ist Teil des \paket{l3packages}-Bundles, \paket*{expl3} ist Teil des \paket{l3kernel}-Bundles. Das heißt, \chemnum benötigt \LaTeX3-Un\-ter\-stüt\-zung.
\chemnum benötigt außerdem die Pakete \paket{etoolbox} und \paket{psfrag} und entweder das Paket \paket{textgreek} oder das Paket \paket{bm}, abhängig von den Paketoptionen (siehe Abschnitt \ref{sec:package_options}).
-In diesem Dokument können Sie leicht zwischen einem \textcolor{code}{\ttfamily\textbackslash befehl}, einem \textcolor{key}{key} und sonstigem \texttt{code} unterscheiden.
-
\section{Neues und ein Wort der Entschuldigung}
Mit dem Update auf v0.4 hat sich einiges bei den Keys getan. Es gibt ein paar neue, ein paar von den alten haben andere Namen. Sie haben einheitlichere Namen erhalten, die meines Erachtens intuitiver ihre jeweilige Funktion widerspiegeln. Dadurch kann es sein, dass Ihre mit einer früheren Version von \chemnum erstellten Dokumente nicht mehr reibungslos kompilieren. Dafür möchte ich mich entschuldigen. \chemnum befindet sich noch in der Entwicklungsphase. Ist erst einmal v1.0 erreicht, wird es solche Änderungen nicht mehr\footnote{oder nur in größten Ausnahmefällen} geben.
-Geändert haben sich folgende Keys:
+Diese Optionen haben neue Namen:
\begin{center}
\begin{tabular}{ll}\toprule
\bfseries alter Name & \bfseries neuer Name \\\midrule
@@ -162,10 +123,10 @@ Geändert haben sich folgende Keys:
\key{sub-init} & \key{init-sub} \\\bottomrule
\end{tabular}
\end{center}
-Neu hinzugekommen sind diese:
+Diese Optionen sind neu:
\begin{center}
\begin{tabular}{ll}\toprule
- \bfseries Key & \bfseries Info \\\midrule
+ \bfseries Option & \bfseries Info \\\midrule
\key{sublist-output-sep} & Aufzählungszeichen in Labeln wie \cmpd{f.{one,two}}, siehe Seite \pageref{sssec:list-output-sep}. \\
\key{sublist-input-sep} & Eingabe von Labeln wie \cmpd{f.{one,two}}, siehe Seite \pageref{sssec:list-input-sep}. \\
\key{init-input-sep} & Eingabe bei \cmd{cmpdinit}, siehe Seite \pageref{sssec:init-input-sep}. \\
@@ -176,56 +137,52 @@ Neu hinzugekommen sind diese:
\end{tabular}
\end{center}
-Ebenfalls neu ist die Art und Weise, wie Sublabel-Listen und -Bereiche eingegeben werden. Der Key \key{sub-list} entfällt deshalb. Näheres siehe Abschnitt \ref{ssec:sub_ranges}.
+Ebenfalls neu ist die Art und Weise, wie Sublabel-Listen und -Bereiche eingegeben werden. Der Option \key{sub-list} entfällt deshalb. Näheres siehe Abschnitt \ref{ssec:sub_ranges}.
Dann gibt es nun die Möglichkeit, klickbare Links zu den Labeln herzustellen, vorausgesetzt, Sie haben \paket{hyperref} eingebunden, siehe Abschnitt \ref{sec:hyperref}.
-Diese Dokumentation hat mit v0.4 einen Index bekommen.
-
-\section{Paket-Optionen}\label{sec:package_options}\secidx{Paket-Optionen}
-\chemnum hat eine Option.
-\begin{framed}
- \centering\lstinline+\usepackage[textgreek = <value>]{chemnum}+
-\end{framed}
-Damit können Sie sowohl einen der drei Stile des \textsf{textgreek}-Pakets wählen\footnote{Zu Details siehe Dokumentation des \paket*{textgreek}-Pakets.} oder \chemnum ohne \paket{textgreek} laden. Folgende Werte stehen zur Auswahl: \lstinline=artemisia=, \lstinline=cbgreek=, \lstinline=euler= und \lstinline=false=. Wenn Sie \lstinline=<value>= weglassen, wird \paket{textgreek} mit dem \lstinline=cbgreek=-Stil geladen. Die Verwendung von \lstinline+\usepackage[textgreek]{chemnum}+ entspricht also \lstinline+\usepackage[textgreek = cbgreek]{chemnum}+. Wenn Sie \chemnum ohne Option verwenden, wird \paket{textgreek} nicht verwendet. Das entspricht \lstinline+\usepackage[textgreek = false]{chemnum}+, der Voreinstellung.
-
-Dieses Dokument wurde mit \lstinline+\usepackage[textgreek]{chemnum}+ gesetzt.
-\secidx*{Paket-Optionen}
+\section{Paketoptionen}\label{sec:package_options}\secidx{Paketoptionen}
+\chemnum hat eine Paketoption.
+\begin{beschreibung}
+ \Option{textgreek}{artemisia/\default{cbgreek}/euler/false} Default: \code{false}
+\end{beschreibung}
+Damit können Sie sowohl einen der drei Stile des \paket{textgreek}-Pakets wählen\footnote{Zu Details siehe Dokumentation des \paket*{textgreek}-Pakets.} oder \chemnum ohne \paket{textgreek} laden. Dieses Dokument wurde mit \verb+\usepackage[textgreek]{chemnum}+ gesetzt.
+\secidx*{Paketoptionen}
\section{Motivation}
Soweit mir bekannt ist, gab es bislang drei Pakete, die das Nummerieren von Verbindungen erleichtern sollen. Sie alle haben ihre Schwächen.
Das erste, \paket{chemcono}, hat für diesen Zweck Bibliographie-Befehle umdefiniert. Dort müs\-sen Verbindungen in einer Art Literaturliste definiert werden. Dadurch kann dann im Text auf sie referenziert werden. Da es die "`Verbindungs-Bibliothek"' immer mit ausgibt, schlägt der Paket-Autor folgendes vor:
-\begin{myquote}[Stefan Schulz]
+\begin{zitat}[Stefan Schulz]
After compilation and printout, discard the last page.
-\end{myquote}
+\end{zitat}
Ganz offensichtlich ist das keine perfekte Lösung.
Das zweite, \paket{chemcompounds}, ist enstanden, weil der Paket-Autor ebenfalls mit den Schwä\-chen von \paket{chemcono} nicht mehr arbeiten wollte. Bei der Erstellung des Pakets hielt er sich stark an den gleichen prinzipiellen Mechanismus wie \paket{chemcono}.
-\begin{myquote}[Stephan Schenk]
- When taking a closer look at the chemcono package, I realised that the only thing one has to do is to get rid of everything which produces text. Thus, as a basis I used the mechanism of \lstinline=\bibitem= and \lstinline=\cite= in pretty much the same way as \paket{chemcono} does by extracting the corresponding code from \lstinline=article.cls= and \lstinline=latex.ltx= but deleting any unnecessary commands producing output. I also introduced several lines of code to make the printing of the compound names more customisable.
-\end{myquote}
+\begin{zitat}[Stephan Schenk]
+ When taking a closer look at the chemcono package, I realised that the only thing one has to do is to get rid of everything which produces text. Thus, as a basis I used the mechanism of \verb=\bibitem= and \verb=\cite= in pretty much the same way as \paket{chemcono} does by extracting the corresponding code from \verb=article.cls= and \verb=latex.ltx= but deleting any unnecessary commands producing output. I also introduced several lines of code to make the printing of the compound names more customisable.
+\end{zitat}
Manche Schwächen hat auch dieses Paket:
\begin{enumerate}
- \item Verbindungen müssen in der Regel mit \lstinline=\declarecompound= deklariert werden. Sie müs\-sen es auf jeden Fall, wenn man Label der Art \cmpd{a.one} haben möchte. Dann muss man die La\-bel sogar von Hand vergeben, was den Sinn einer automatischen Nummerierung untergräbt.
+ \item Verbindungen müssen in der Regel mit \verb=\declarecompound= deklariert werden. Sie müs\-sen es auf jeden Fall, wenn man Label der Art \cmpd{a.one} haben möchte. Dann muss man die La\-bel sogar von Hand vergeben, was den Sinn einer automatischen Nummerierung untergräbt.
\item Das Layout lässt sich nicht einzeln ändern, sondern nur für alle Label.
\item Die Nummerierung kann nicht zurückgesetzt werden. Obwohl das in der allermeisten Fällen \emph{weder nötig noch zu empfehlen ist}, kann es Einzelfälle geben, in denen solches Verhalten gewünscht ist.
- \item Eine Liste mehrerer Verbindungen \lstinline=\compound{a,b,c}= kann nicht oder nur um\-ständ\-lich eigenen Vorstellungen angepasst werden.
+ \item Eine Liste mehrerer Verbindungen \verb=\compound{a,b,c}= kann nicht oder nur um\-ständ\-lich eigenen Vorstellungen angepasst werden.
\end{enumerate}
-Dann gibt es noch \paket{bpchem}, das Befehle ähnlich den Befehlen \lstinline=\label= und \lstinline=\ref= zur Ver\-fü\-gung stellt: \lstinline=\CNlabel{}=, \lstinline=\CNlabelnoref{}= und \lstinline=\CNref{}=. Außerdem hat es Befehle für Sublabel: \lstinline=\CNlabelsub{}{}=, \lstinline=\CNlabelsubnoref{}{}= und \lstinline=\CNrefsub{}{}=. Damit ist es flexibler als die anderen, stellt allerdings kaum Möglichkeiten zur Personalisierung bereit, Listen sind nicht möglich und die Tatsache, dass es verschiedene Befehle für Label und Label mit Sublabeln gibt, ist ebenfalls nicht die beste Lösung.
+Dann gibt es noch \paket{bpchem}, das Befehle ähnlich den Befehlen \verb=\label= und \verb=\ref= zur Ver\-fü\-gung stellt: \verb=\CNlabel{}=, \verb=\CNlabelnoref{}= und \verb=\CNref{}=. Außerdem hat es Befehle für Sublabel: \verb=\CNlabelsub{}{}=, \verb=\CNlabelsubnoref{}{}= und \verb=\CNrefsub{}{}=. Damit ist es flexibler als die anderen, stellt allerdings kaum Möglichkeiten zur Personalisierung bereit, Listen sind nicht möglich und die Tatsache, dass es verschiedene Befehle für Label und Label mit Sublabeln gibt, ist ebenfalls nicht die beste Lösung.
\chemnum soll diese Schwächen beheben. Dafür wurden alle Befehle vollständig neu geschrieben. Allerdings wurden Ideen von \paket{chemcompounds} aufgegriffen was Dar\-stel\-lungs\-mög\-lich\-kei\-ten wie Begrenzer \usw betrifft.
Wenn Ihnen irgendwelche fehlenden Features auf"|fallen, geben Sie mir bitte Bescheid, indem Sie mir eine E-Mail senden.
\section{Verbindungen Nummerieren}\label{sec:nummerieren}
-\subsection{Basisbefehl}\secidx{Basisbefehl}
+\subsection{Basisbefehl}\secidx{Basisbefehl}\cmpdreset
Der eigentliche Befehl des Pakets ist
-\begin{framed}
- \centering\cmd{cmpd}{<label name>}
-\end{framed}
-\noindent Beim ersten Aufruf mit \texttt{<label name>} wird das Label erzeugt und gespeichert (= deklariert) und ausgegeben. Bei jedem weiteren Aufruf wird nun dieses Label verwendet.
+\begin{beschreibung}
+ \Befehl{cmpd}{<label name>}
+\end{beschreibung}
+Beim ersten Aufruf mit \code{<label name>} wird das Label erzeugt und gespeichert (= deklariert) und ausgegeben. Bei jedem weiteren Aufruf wird nun dieses Label verwendet.
\begin{beispiel}
Verbindungen \cmpd{a} und \cmpd{b} werden deklariert und k\"onnen nun jederzeit wieder aufgerufen werden: \cmpd{a}. Es ist keine vorherige Deklarierung n\"otig. Die Substanzen wie \cmpd{c} werden in der Reihenfolge ihres ersten Erscheinens im Text nummeriert.\par
@@ -233,10 +190,12 @@ Der eigentliche Befehl des Pakets ist
\end{beispiel}
Falls es nötig sein sollte, eine Verbindung zu deklarieren, ohne ein Label auszugeben, kann man an entsprechender Stelle
-\begin{framed}\label{cmd:unsichtbares_label}
- \centering\cmd[cmpda]{cmpd*}{<label name>}
-\end{framed}
-\noindent verwenden. Dadurch wird ein entsprechendes Label deklariert aber nicht ausgegeben. \textbf{Dieser Befehl wird nicht benötigt, wenn man} \cmd{cmpdinit}{} \textbf{verwendet, siehe Abschnitt \ref{sec:cmpdinit} (S.\,\pageref{sec:cmpdinit}ff).}
+\begin{beschreibung}
+ \Befehl[cmpda]{cmpd*}\ma{<label name>}\label{cmd:unsichtbares_label}
+\end{beschreibung}
+verwenden. Dadurch wird ein entsprechendes Label deklariert aber nicht ausgegeben.
+
+\achtung{Dieser Befehl wird nicht benötigt, wenn man \cmd{cmpdinit} verwendet, siehe Abschnitt \ref{sec:cmpdinit} (S.\,\pageref{sec:cmpdinit}ff).}
\begin{beispiel}
Die versteckte Version\cmpd*{d} erzeugt zwar das Label, schreibt es aber nicht aus. Der n\"achste \cmpd{e} f\"uhrt die Z\"ahlung einfach weiter. Mit \cmpd{d} kann nat\"urlich auf das erzeugte Label zur\"uckgegriffen werden.
@@ -252,24 +211,20 @@ Als Label-Namen können Sie im Prinzip einsetzen, was Sie wollen, außer den als
\subsection{Sublabel}\label{ssec:unterlabel}\secidx{Sublabel}
Möchte man Label der Form \cmpd{a.one} erzeugen, geschieht das nach folgender Syntax:
-\begin{framed}
- \centering\cmd{cmpd}{<label name>.<subname>}
-\end{framed}
-\noindent Dabei muss \texttt{<label name>} der gleiche bleiben, \texttt{<subname>} variiert. Diese Syntax bedeutet, dass der Punkt \texttt{.} weder Teil von \texttt{<label name>} noch von \texttt{<subname>} sein darf. An Stelle des Punktes können Sie auch ein anderes Zeichen verwenden, siehe Abschnitt \ref{sssec:sub-input-sep}.
-
+\begin{beschreibung}
+ \Befehl{cmpd}{<label name>.<subname>}
+\end{beschreibung}
+Dabei muss \code{<label name>} der gleiche bleiben, \code{<subname>} variiert. Diese Syntax bedeutet, dass der Punkt \code{.} weder Teil von \code{<label name>} noch von \code{<subname>} sein darf. An Stelle des Punktes können Sie auch ein anderes Zeichen verwenden, siehe Abschnitt \ref{sssec:sub-input-sep}.
\begin{beispiel}
\cmpd{f.one} und \cmpd{f.two} sind eng verwandt, genauso \cmpd{g.one} und \cmpd{g.two}. Nat\"urlich bliebt auch hier bei sp\"aterem Aufruf das Label gleich: \cmpd{g.two} und \cmpd{f.one}.
\end{beispiel}
Diese Syntax funtioniert auch, wenn der Hauptname bereits vergeben wurde.
-
\begin{beispiel}
- \cmpd{a} und seine Varianten
- \cmpd{a.one} und \cmpd{a.two}
+ \cmpd{a} und seine Varianten \cmpd{a.one} und \cmpd{a.two}
\end{beispiel}
Genauso kann der Hauptname von kombiniert vergebenen Labeln einzeln aufgerufen werden.
-
\begin{beispiel}
\cmpd{f} und \cmpd{g}
\end{beispiel}
@@ -281,14 +236,15 @@ Wie Sie ein Label der Art \cmpd{f.{one,two}} erzeugen können,wird in Abschnitt
Tatsächlich wurde bislang nur die halbe Wahrheit über den Befehl erzählt. Er kann auch für mehrere Label auf einmal verwendet werden.
Die richtige Beschreibung des Befehls lautet also eher:
-\begin{framed}
- \centering\cmd{cmpd}{<(possibly comma separated list of) label name(s)>}
-\end{framed}
+\begin{beschreibung}
+ \Befehl{cmpd}{<(possibly comma separated list of) label name(s)>}
+\end{beschreibung}
Das bedeutet, dass in der Voreinstellung das Komma nicht Teil des Label-Namens sein kann, es sei denn versteckt in geschweiften Klammern. Sie können das ändern, siehe Abschnitt \ref{sssec:list-input-sep} (S.\,\pageref{sssec:list-input-sep}).
\begin{beispiel}
Mehrere Label k\"onnen einfach durch Kommata getrennt eingegeben werden. Dann wird eine Liste wie \cmpd{a, b, c, e, g.two} ausgegeben.
\end{beispiel}
+The Harvard comma (see \ref{ssec:harvard-comma}) in \code{, and} between \cmpd{e} and \cmpd{g.two} suggests that there are options to customize the list, see sections \ref{ssec:trenner} and \ref{sec:language_support}.
\secidx*{Listen}
\subsection{Listen und Bereiche von Sublabeln}\label{ssec:sub_ranges}\index{Sublabel!Listen}\index{Sublabel!Bereiche}
@@ -301,7 +257,7 @@ Das Prinzip ist recht intuitiv -- Sie geben einfach eine Liste von Sublabeln ein
\end{beispiel}
Da die Subliste in der Voreinstellung ebenfalls mit Komma getrennt eingegeben wird, müssen Sie die Subliste in geschweiften Klammern eingeben.
-Sie können auf diese Weise auch Bereiche von Sublabeln darstellen. Als Marker zwischen den Namen der beiden Sublabel werden zwei Punkte \lstinline=..= verwendet.
+Sie können auf diese Weise auch Bereiche von Sublabeln darstellen. Als Marker zwischen den Namen der beiden Sublabel werden zwei Punkte \verb=..= verwendet.
\begin{beispiel}
\cmpd{q.{two..four}}\\
\cmpd{q.{one,three..five}}\\
@@ -310,19 +266,20 @@ Sie können auf diese Weise auch Bereiche von Sublabeln darstellen. Als Marker z
Durch die Eingabe stehen Ihnen in der Voreinstellungen für Sublabel-Namen weder das Komma noch die zwei Punkte als Teils des Namens zur Verfügung. Wie Sie andere Symbole als Marker verwenden, damit Sie sie doch verwenden können, steht in den Abschnitten \ref{sssec:range-input-sep} und \ref{sssec:list-input-sep}. In Abschnitt \ref{sssec:input-sep-bsp} wird ein Beispiel gezeigt, wie eine geänderte Eingabe aussehen könnte.
-\chemnum stellt einen Key (siehe Abschnitt \ref{sec:cmpdsetup} zur näheren Erläuterung) zur Verfügung, mit denen alle Sublabel als Bereich ausgegeben werden können
-\begin{framed}
- \keyentry{cmpd-all}{true/false}{boolean}
-\end{framed}
+\chemnum stellt eine Option (siehe Abschnitt \ref{sec:cmpdsetup} zur näheren Erläuterung) zur Verfügung, mit denen alle Sublabel als Bereich ausgegeben werden können
+\begin{beschreibung}
+ \Option{cmpd-all}{\default{true}/false}
+\end{beschreibung}
\begin{beispiel}
\cmpd[cmpd-all]{q}
\end{beispiel}
-Damit der Key die richtigen Sublabel verwenden kann, müssen diese deklariert worden sein. Daher werden sie aus der Datei \lstinline=<jobname>.cmpd= (angenommen Ihre Quelldatei heißt \lstinline=<jobname>.tex=) gelesen. Das bedeutet, dass Sie zweimal (oder öfter) kompilieren müssen, bis alle Labels richtig dargestellt werden.
-Verwendet man Label mit Sublabel-Bereichen, dann möchte man vielleicht an anderer Stelle \emph{nur} das Sublabel ausgeben. Das ist möglich mit folgendem Key:
-\begin{framed}
- \keyentry{sub-only}{true/false}{boolean}
-\end{framed}
+Damit der Key die richtigen Sublabel verwenden kann, müssen diese deklariert worden sein. Daher werden sie aus der Datei \verb=<jobname>.cmpd= (angenommen Ihre Quelldatei heißt \verb=<jobname>.tex=) gelesen. Das bedeutet, dass Sie zweimal (oder öfter) kompilieren müssen, bis alle Labels richtig dargestellt werden.
+
+Verwendet man Label mit Sublabel-Bereichen, dann möchte man vielleicht an anderer Stelle \emph{nur} das Sublabel ausgeben. Das ist möglich mit folgender Option:
+\begin{beschreibung}
+ \Option{sub-only}{\default{true}/false}
+\end{beschreibung}
\begin{beispiel}
% use packages `chemfig', `chemmacros' and `booktabs'
\cmpd*{benzol.H,benzol.Me,benzol.OH,benzol.NH2}
@@ -346,57 +303,55 @@ Die in diesem Abschnitt beschriebenen Befehle sind für den Einsatz von \chemnum
\subsection{Verwendung}
\subsubsection{Haupt-Label}
-Vielleicht vermissen Sie ja den \lstinline=\declarecompound=-Befehl von \paket{chemcompounds}. Schließlich hat man dadurch am Beginn einen Überblick, welche Namen man bereits vergeben hat. Und man wird durch eine Fehlermeldung unter Umständen gewarnt, wenn man ein falsches Label setzt\footnote{\zB aufgrund eines Schreibfehlers}. Dieses Verhalten lässt sich mit den folgenden Befehlen realisieren.
-\begin{framed}
- \centering\cmd{cmpdinit}{<comma separated list of label names>}
- \centering\cmd[cmpdinita]{cmpdinit*}{<comma separated list of label names>}
-\end{framed}
+Vielleicht vermissen Sie ja den \verb=\declarecompound=-Befehl von \paket{chemcompounds}. Schließlich hat man dadurch am Beginn einen Überblick, welche Namen man bereits vergeben hat. Und man wird durch eine Fehlermeldung unter Umständen gewarnt, wenn man ein falsches Label setzt\footnote{\zB aufgrund eines Schreibfehlers}. Dieses Verhalten lässt sich mit den folgenden Befehlen realisieren.
+\begin{beschreibung}
+ \Befehl{cmpdinit}{<comma separated list of label names>}
+ \Befehl[cmpdinita]{cmpdinit*}{<comma separated list of label names>}
+\end{beschreibung}
Alle Verbindungen, die innerhalb dieses Befehls gesetzt werden, werden \emph{in der verwendeten Reihenfolge} initialisiert. Verwendet man ein Label, das nicht in der Liste enthalten ist, wird eine Warnung ausgegeben.
\cmpdreset
\begin{beispiel}
- \cmpdinit{A, B, C} \cmpd{B}
- \cmpd{A.a} \cmpd{C} \cmpd{D}
+ \cmpdinit{A, B, C} \cmpd{B} \cmpd{A.a} \cmpd{C} \cmpd{D}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init"\\
{}* \\
{}* You used \verb=\cmpdinit= but didn't initiate compound "D"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
Beachten Sie, dass Sie bei Labeln mit Sublabeln \emph{nur den Hauptnamen} initialisieren können und sollten. Dadurch sind dann \emph{alle} Verbindungen mit gleichem Hauptnamen initialisiert.
-\cmd[cmpdinita]{cmpdinit*}{} gibt die gleiche Warnung aus, allerdings werden die Nummern noch nicht vergeben, sondern erst bei Verwendung im Text und in der im Text verwendeten Reihenfolge.
+\cmd[cmpdinita]{cmpdinit*} gibt die gleiche Warnung aus, allerdings werden die Nummern noch nicht vergeben, sondern erst bei Verwendung im Text und in der im Text verwendeten Reihenfolge.
\cmpdreset
\begin{beispiel}
- \cmpdinit*{X, Y, Z} \cmpd{Y}
- \cmpd{X.x} \cmpd{Z} \cmpd{W}
+ \cmpdinit*{X, Y, Z} \cmpd{Y} \cmpd{X.x} \cmpd{Z} \cmpd{W}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init"\\
{}* \\
{}* You used \verb=\cmpdinit= but didn't initiate compound "W"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
-Wenn Sie also eigene Label vergeben wollen oder müssen (siehe Seite \pageref{ssec:own_labels}) und die Label geschlossen initialisieren wollen, sollten Sie \cmd[cmpda]{cmpdinit*}{} verwenden, da dort bei der Initialisierung \emph{keine} Label vergeben werden.
+Wenn Sie also eigene Label vergeben wollen oder müssen (siehe Seite \pageref{ssec:own_labels}) und die Label geschlossen initialisieren wollen, sollten Sie \cmd[cmpda]{cmpdinit*} verwenden, da dort bei der Initialisierung \emph{keine} Label vergeben werden.
-Der Befehl kann mehrfach verwendet werden, mit oder ohne \lstinline=*=. Sinnvoll ist aber wohl eine \emph{einmalige} Verwendung, vielleicht in der Dokumentenpräambel nach dem \chemnum-Setup (siehe Abschnitt \ref{sec:cmpdsetup}).
+Der Befehl kann mehrfach verwendet werden, mit oder ohne \verb=*=. Sinnvoll ist aber wohl eine \emph{einmalige} Verwendung, vielleicht in der Dokumentenpräambel nach dem \chemnum-Setup (siehe Abschnitt \ref{sec:cmpdsetup}).
\subsubsection{Sublabel}
Wenn Sie zusätzlich auch für jede Label-Sublabel-Kombination gewarnt werden wollen oder die Reihenfolge im Voraus festlegen wollen, dann können Sie
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-sub}{true}]{<comma separated list of label names>}
-\end{framed}
-\noindent verwenden. So werden Sie auch in diesen Fällen gewarnt.
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-sub}{true}]{<comma separated list of label names>}
+\end{beschreibung}
+verwenden. So werden Sie auch in diesen Fällen gewarnt.
\cmpdreset
\begin{beispiel}
@@ -404,7 +359,7 @@ Wenn Sie zusätzlich auch für jede Label-Sublabel-Kombination gewarnt werden wo
\cmpd{E.e, E.h}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init-sub"\\
@@ -412,25 +367,25 @@ Wenn Sie zusätzlich auch für jede Label-Sublabel-Kombination gewarnt werden wo
{}* You used \verb=\cmpdinit= and "{}init-sub = true"{} but didn't initiate sub-compound\\
{}* "{}E.h"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
\subsection{Fehler statt Warnung}
Wenn Sie lieber eine Fehler-Meldung anstelle einer Warnung mögen, können Sie das realisieren, indem Sie \cmd{cmpdinit} folgendermaßen aufrufen:
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-strict}{true}]{<comma separated list of label names>}
-\end{framed}
-Die Verwendung \key{init-strict}{false} entspricht der Verwendung ohne optionalem Argument. Die Option kann natürlich auch bei der Stern-Variante eingesetzt werden.
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-strict}{true}]{<comma separated list of label names>}
+\end{beschreibung}
+Die Verwendung \key{init-strict}{false} entspricht der Verwendung ohne optionalem Argument. Die Option kann natürlich auch bei der Stern-Variante eingesetzt werden
Durch \key{init-strict}{true} wird der \LaTeX-Lauf mit einer entsprechenden Fehlermeldung abgebrochen, wenn man einen Label-Namen verwendet, der nicht initialisiert wurde.
-Natürlich können Sie \cmd{cmpdinit} auch mit beiden Keys aufrufen
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-strict}{true}, \key{init-sub}{true}]{<comma separated list of label names>}
-\end{framed}
-\noindent oder \cmd{cmpdsetup} verwenden, siehe Abschnitt \ref{sec:cmpdsetup}.
+Natürlich können Sie \cmd{cmpdinit} auch mit beiden Optionen aufrufen
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-strict}{true}, \key{init-sub}{true}]{<comma separated list of label names>}
+\end{beschreibung}
+oder \cmd{cmpdsetup} verwenden, siehe Abschnitt \ref{sec:cmpdsetup}.
\subsection{Personalisierte Eingabe}
-Wenn Sie andere Eingabezeichen für \key{sub-input-sep} (siehe Seite \pageref{sssec:sub-input-sep}) oder \key{sublist-input-sep} (siehe Seite \pageref{sssec:list-input-sep}) ausgewählt haben, müssen Sie sie mit \cmd{cmpdinit}[\key{sub-init}{true}] ebenfalls verwenden.
+Wenn Sie andere Eingabezeichen für \key{sub-input-sep} (siehe Seite \pageref{sssec:sub-input-sep}) oder \key{sublist-input-sep} (siehe Seite \pageref{sssec:list-input-sep}) ausgewählt haben, müssen Sie sie mit \key{sub-init}{true} ebenfalls verwenden.
Die Änderung der Listen-Eingabe \key{list-input-sep} (siehe Seite \pageref{sssec:list-input-sep}) wirkt sich auf \cmd{cmpdinit} nicht aus. Wenn Sie die Eingabe dort ebenfalls ändern wollen, verwenden Sie \key{init-input-sep}, siehe Seite \pageref{sssec:init-input-sep}.
@@ -442,44 +397,45 @@ Wie zu Beginn dieses Abschnitts erwähnt, ist die Initialisierung von Labeln nic
\end{enumerate}
\secidx*{Label initialisieren}
-\section{Zurücksetzen des Zählers}\label{sec:cmpdreset}\secidx[zuruecksetzen]{Zurücksetzen des Zählers}
+% TODO: übersetzen
+\section{Zurücksetzen des Zählers}\label{sec:cmpdreset}\secidx{Zurücksetzen des Zählers}
Es ist möglich, mit folgendem Befehl
-\begin{framed}
- \centering\cmd{cmpdreset}[<number>]
-\end{framed}
-\noindent den Zähler wieder zurückzusetzen. Ohne Argument wird er auf \verb=1= gesetzt und entspricht damit \cmd{cmpdreset}[1]. Dieser Befehl wirkt sich global aus, nicht nur lokal innerhalb einer Gruppe -- im Gegensatz zu den meisten anderen vorgestellten Befehlen.
-
+\begin{beschreibung}
+ \Befehl{cmpdreset}[<number>]
+\end{beschreibung}
+den Zähler wieder zurückzusetzen. Ohne Argument wird er auf \verb=1= gesetzt und entspricht damit \cmd{cmpdreset}[1]. Dieser Befehl wirkt sich global aus, nicht nur lokal innerhalb einer Gruppe -- im Gegensatz zu den meisten anderen vorgestellten Befehlen.
\begin{beispiel}
- \cmpdreset
- Die Verbindungen werden jetzt wieder von 1 gez\"ahlt: \cmpd{h, i, j}
+ \cmpdreset Die Verbindungen werden jetzt wieder von 1 gez\"ahlt: \cmpd{h, i, j}
\end{beispiel}
-\textbf{Sie sollten mit diesem Befehl sehr vorsichtig umgehen! In der Regel ist es nicht zu empfehlen, den Zähler zurückzusetzen. Dadurch können ein und dieselbe Nummer an verschiedene Verbindungen vergeben werden!}
+\achtung{Sie sollten mit diesem Befehl sehr vorsichtig umgehen! In der Regel ist es nicht zu empfehlen, den Zähler zurückzusetzen. Dadurch können ein und dieselbe Nummer an verschiedene Verbindungen vergeben werden!}
\begin{beispiel}
Gleiche Nummern: \cmpd{a}, \cmpd{h}
\end{beispiel}
-\secidx*[zuruecksetzen]{Zurücksetzen des Zählers}
+\secidx*{Zurücksetzen des Zählers}
-\section{Besondere Verwendung}
+\section{Besondere Verwendung}\secidx{besondere Verwendung}
\subsection{Abschnitts-Titel}
Die Verwendung von \cmd{cmpd} in einer Überschrift scheint auf den ersten Blick kein Problem zu sein. Es gibt keine Fehler und der Output sieht wie erwartet aus:
\begin{beispiel}[code only]
\section{Compound \cmpd[cmpd-delim]{b}}
\ldots
\end{beispiel}
-Wenn man allerdings \lstinline=\tableofcontents= verwendet -- was ziemlich wahrscheinlich ist, wie ich vermute --, geschieht etwas unerwünschtes: da das Inhaltsverzeichnis am Anfang des Dokuments geschrieben wird, wird das Label beim Erscheinen im Inhaltsverzeichnis deklariert, anstatt an der Stelle im Text, an der es zuerst erscheint. Es gibt zwei Möglichkeiten, das zu umgehen:
+Wenn man allerdings \verb=\tableofcontents= verwendet -- was ziemlich wahrscheinlich ist, wie ich vermute --, geschieht etwas unerwünschtes: da das Inhaltsverzeichnis am Anfang des Dokuments geschrieben wird, wird das Label beim Erscheinen im Inhaltsverzeichnis deklariert, anstatt an der Stelle im Text, an der es zuerst erscheint. Es gibt zwei Möglichkeiten, das zu umgehen:
\begin{enumerate}
\item Sie deklarieren die Label in der Präambel mit \cmd{cmpdinit}{} (siehe Seite \pageref{sec:cmpdinit}).
- \item Sie verwenden \cmd[cmpdb]{cmpd+}, um das Label zu setzen. Damit wird das Label von der Datei \lstinline=<jobname>.cmpd= ausgelesen (vorausgesetzt ihre Hauptdatei heißt \lstinline=<jobname>.tex=). Das bedeutet, dass \emph{mindestens zwei}, unter Umständen mehr \LaTeX\ Durchläufe nötig sind, bis alle Labels richtig gesetzt sind.
+ \item Sie verwenden \cmd[cmpdb]{cmpd+}, um das Label zu setzen. Damit wird das Label von der Datei \verb=<jobname>.cmpd= ausgelesen (vorausgesetzt ihre Hauptdatei heißt \verb=<jobname>.tex=). Das bedeutet, dass \emph{mindestens zwei}, unter Umständen mehr \LaTeX\ Durchläufe nötig sind, bis alle Labels richtig gesetzt sind.
\end{enumerate}
Das gleiche gilt für jede andere Liste von beweglichen Argumenten, die \emph{vor} dem Erscheinen des Labels im Text eingesetzt wird.
Der Befehl\label{cmd:cmpd_plus}
-\begin{framed}
- \centering\cmd[cmpdb]{cmpd+}{<label name>}
-\end{framed}
-liest den Labelnamen, der ausgegeben werden soll, aus der Datei \lstinline=<jobname>.cmpd=. Damit ist er sozusagen das Gegenteil von \cmd[cmpda]{cmpd*}, da das Label nicht deklariert sondern nur referenziert und ausgegeben wird. Damit man also \cmd[cmpdb]{cmpd+}{<label>} einsetzen kann, muss \lstinline=<label>= entweder mit \cmd{cmpd}{<label>} oder \cmd[cmpda]{cmpd*}{<label>} (davor oder danach) deklariert worden sein. \cmd[cmpdb]{cmpd+} ist nützlich, wenn ein Label in einem beweglichen Argument wie in \lstinline=\section{}= eingesetzt werden soll. \textbf{Er wird nicht benötigt, wenn} \cmd{cmpdinit}{} \textbf{verwendet wird, siehe Abschnitt \ref{sec:cmpdinit} (S.\,\pageref{sec:cmpdinit}ff).}
+\begin{beschreibung}
+ \Befehl[cmpdb]{cmpd+}\ma{<label name>}
+\end{beschreibung}
+liest den Labelnamen, der ausgegeben werden soll, aus der Datei \verb=<jobname>.cmpd=. Damit ist er sozusagen das Gegenteil von \cmd[cmpda]{cmpd*}, da das Label nicht deklariert sondern nur referenziert und ausgegeben wird. Damit man also \cmd[cmpdb]{cmpd+}{<label>} einsetzen kann, muss \verb=<label>= entweder mit \cmd{cmpd}{<label>} oder \cmd[cmpda]{cmpd*}{<label>} (davor oder danach) deklariert worden sein. \cmd[cmpdb]{cmpd+} ist nützlich, wenn ein Label in einem beweglichen Argument wie in \verb=\section{}= eingesetzt werden soll. \textbf{Er wird nicht benötigt, wenn} \cmd{cmpdinit} \textbf{verwendet wird, siehe Abschnitt \ref{sec:cmpdinit} (S.\,\pageref{sec:cmpdinit}ff).}
+
+\achtung{It is not needed when \cmd{cmpdinit} is used, see section \ref{sec:cmpdinit} (pages \pageref{sec:cmpdinit}\,ff).}
\begin{beispiel}
\subsubsection{Test-\"Uberschrift mit Verbindungslabel \cmpd+[cmpd-delim]{f.one}}
@@ -506,11 +462,11 @@ Es funktioniert auch alles wie gewünscht, wenn die Gleitumgebung vor den aktuel
\cmpdinit*{Alc,EtherBr,cpd}
\subsection{Schemata externer Programme}\label{ssec:cmpdref}\secidx{Schemata externer Programme}
-Wenn Sie Ihre Schemata mit externen Programmen wie \zB \textsc{ChemDraw} oder \textsc{Marvin\-Sketch} erstellen und dort ebenfalls \chemnum einsetzen wollen, dann können Sie das mit
-\begin{framed}
- \centering\cmd{cmpdref}[<keyval>][<tag>]{<label name>}=
-\end{framed}
-tun. Dieser Befehl ist vom Befehl \lstinline=\schemeref= des Pakets \paket{chemscheme} inspiriert und funktioniert letztlich gleich. Sie erstellen das Schema und speichern es mit temporären Labeln als \lstinline=eps=-Datei.
+Wenn Sie Ihre Schemata mit externen Programmen wie \zB \prog{ChemDraw} oder \prog{Marvin\-Sketch} erstellen und dort ebenfalls \chemnum einsetzen wollen, dann können Sie das mit
+\begin{beschreibung}
+ \Befehl{cmpdref}[<options>]\oa[<tag>]\ma{<label name>}
+\end{beschreibung}
+tun. Dieser Befehl ist vom Befehl \verb=\schemeref= des Pakets \paket{chemscheme} inspiriert und funktioniert letztlich gleich. Sie erstellen das Schema und speichern es mit temporären Labeln als \verb=eps=-Datei.
\begin{beispiel}[code and float]
\begin{scheme}[ht]
\centering
@@ -526,11 +482,11 @@ tun. Dieser Befehl ist vom Befehl \lstinline=\schemeref= des Pakets \paket{chems
\caption{Schema mit automatisierten Labeln.}
\end{scheme}
\end{beispiel}
-Sie nummerieren also im Schema die Substanzen mit \textsf{TMP1}, \textsf{TMP2} \usw durch. Diese Marker werden dann durch die entsprechenden Label ersetzt. Dafür verwendet \chemnum genau wie \paket{chemscheme} den Befehl \lstinline=\psfrag= des \paket{psfrag}-Pakets. Damit er funktioniert, müssen Sie also entweder über \textsc{latex}, \textsc{dvips}, \textsc{ps2pdf} kompilieren, oder \zB das Paket \paket{auto-pst-pdf} zusammen mit \textsc{pdflatex} einsetzen. \textsc{xelatex} wird leider nicht funktionieren, \textsc{lualatex} voraussichtlich ebensowenig, wurde aber vom Autor nicht getestet.
+Sie nummerieren also im Schema die Substanzen mit \textsf{TMP1}, \textsf{TMP2} \usw durch. Diese Marker werden dann durch die entsprechenden Label ersetzt. Dafür verwendet \chemnum genau wie \paket{chemscheme} den Befehl \verb=\psfrag= des \paket{psfrag}-Pakets. Damit er funktioniert, müssen Sie also entweder über \prog{latex}, \prog{dvips}, \prog{ps2pdf} kompilieren, oder \zB das Paket \paket{auto-pst-pdf} zusammen mit \prog{pdflatex} einsetzen. \prog{xelatex} wird leider nicht funktionieren, \prog{lualatex} voraussichtlich ebensowenig, wurde aber vom Autor nicht getestet.
-In jedem Fall ist es wichtig, dass der Marker als \emph{Text} im \lstinline=eps= gespeichert ist.
+In jedem Fall ist es wichtig, dass der Marker als \emph{Text} im \verb=eps= gespeichert ist.
-Mit den Keys, die in Abschnitt \ref{sec:cmpdsetup} vorgestellt werden, können Sie die Label hier auch personalisieren.
+Mit den Optionen, die in Abschnitt \ref{sec:cmpdsetup} vorgestellt werden, können Sie die Label hier auch personalisieren.
\begin{beispiel}[code and float]
\begin{scheme}[ht]
\centering
@@ -569,15 +525,15 @@ Natürlich funktioniert das mit Sublabeln nach dem gewohnten Muster:
\caption{Schema mit automatisierten Labeln und Sublabeln.}
\end{scheme}
\end{beispiel}
-\secidx*{Schemata externer Programme}\cmpdreset[10]
+\secidx*{Schemata externer Programme}\secidx*{besondere Verwendung}\cmpdreset[10]
-\section{Verwendung mit \textsf{hyperref}}\label{sec:hyperref}\secidx[Verwendung mit hyperref]{Verwendung mit \textsf{hyperref}}
+\section{Verwendung mit \textsf{hyperref}}\label{sec:hyperref}\secidx{Verwendung mit \textsf{hyperref}}[Verwendung mit hyperref]
\subsection{Grundprinzip}
-Wenn Sie das Paket \paket{hyperref} eingebunden haben, können Sie die Label zu klickbaren Links im \textsc{pdf} machen.
-\begin{framed}
- \keyentry{hyper-use}{true/false}{boolean}
-\end{framed}
-Wenn Sie diesen Key (siehe Abschnitt \ref{sec:cmpdsetup} für nähere Informationen) auf \texttt{true} setzen, dann wird beim ersten Einsatz eines Labels danach ein Ziel festgelegt und bei jedem weiteren ein Link zu diesem Ziel erzeugt. Das funktioniert allerdings nur, solange das Label \emph{ohne} Liste oder Bereich von Sublabeln gesetzt wird. Auch ein mit \cmd[cmpda]{cmpd*} gesetztes Label kann nicht als Ziel markiert werden.
+Wenn Sie das Paket \paket{hyperref} eingebunden haben, können Sie die Label zu klickbaren Links im \prog{pdf} machen.
+\begin{beschreibung}
+ \Option{hyper-use}{\default{true}/false}
+\end{beschreibung}
+Wenn Sie diese Option (siehe Abschnitt \ref{sec:cmpdsetup} für nähere Informationen) auf \texttt{true} setzen, dann wird beim ersten Einsatz eines Labels danach ein Ziel festgelegt und bei jedem weiteren ein Link zu diesem Ziel erzeugt. Das funktioniert allerdings nur, solange das Label \emph{ohne} Liste oder Bereich von Sublabeln gesetzt wird. Auch ein mit \cmd[cmpda]{cmpd*} gesetztes Label kann nicht als Ziel markiert werden.
\begin{beispiel}
\cmpdsetup{hyper-use}
@@ -588,15 +544,15 @@ Wenn Sie diesen Key (siehe Abschnitt \ref{sec:cmpdsetup} für nähere Informatio
\subsection{Gezielter Einsatz}
Der automatisierte Einsatz ist vielleicht nicht der, den man möchte. Vielleicht reicht es, an ein oder zwei Stellen einen Verweis zu erzeugen. Das kann mit folgenden Keys erfolgen.
-\begin{framed}
- \keyentry{hyper-target}{<link name>}{literal}\\
- \keyentry{hyper-link}{<link name>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{hyper-target}{<link name>}
+ \Option{hyper-link}{<link name>}
+\end{beschreibung}
Mit \key{hyper-target} kann man ein Ziel festsetzen. \textbf{Achtung}: wenn Sie diesen Key mit einer Liste einsetzen, dann erhält \emph{jedes} Label den gleichen Linkzielnamen und \paket{hyperref} wird eine Warnung
-\begin{framed}\ttfamily
-destination with the same identifier (name{<link name>}) has been already used, duplicate ignored
-\end{framed}
-\noindent ausgeben.
+\begin{mdframed}\ttfamily
+ destination with the same identifier (name\{<link name>\}) has been already used, duplicate ignored
+\end{mdframed}
+ausgeben.
Mit \key{hyper-link} kann man nun einen Link auf dieses Ziel erzeugen. \textbf{Achtung}: wenn Sie diesen Key mit einer Liste einsetzen, wird \emph{jedes} Label auf das gleiche Ziel verweisen.
\begin{beispiel}
@@ -604,50 +560,42 @@ Mit \key{hyper-link} kann man nun einen Link auf dieses Ziel erzeugen. \textbf{A
\end{beispiel}
Wenn Sie \key{hyper-link} einsetzen, ohne das entsprechende \key{hyper-target} festgelegt zu haben, dann wird \paket{hyperref} eine Warnung
-\begin{framed}\ttfamily
-name{<link name>} has been referenced but does not exist, replaced by a fixed one
-\end{framed}
-\noindent ausgeben.
-\secidx*[Verwendung mit hyperref]{Verwendung mit \textsf{hyperref}}
+\begin{mdframed}\ttfamily
+ name\{<link name>\} has been referenced but does not exist, replaced by a fixed one
+\end{mdframed}
+ausgeben.
+\secidx*{Verwendung mit \textsf{hyperref}}[Verwendung mit hyperref]
\section{Personalisieren}\label{sec:cmpdsetup}
\subsection{Das Prinzip}\label{ssec:prinzip}
Das Personalisieren geschieht mit einem Schlüssel-Wert-System. Einstellungen können dabei entweder zentral über
-\begin{framed}
- \centering\cmd{cmpdsetup}{key1 = value1, key2 = value2}
-\end{framed}
-\noindent oder lokal direkt beim Befehl
-\begin{framed}
- \centering\cmd{cmpd}[key1 = value1, key2 = value2]{<label name>}
-\end{framed}
-\noindent vorgenommen werden.
-
-Dabei gibt es verschiedene Arten von Schlüsseln. Je nach Art können sie andere Werte bekommen.
-\begin{description}
- \item[\ttfamily macro] Diese Schlüssel erwarten als Eingabe ein Makro, das auch ein obligatorisches Argument besitzen kann, \zB \lstinline=\bfseries= oder \lstinline=\textbf=. \chemnum hat nur einen einzigen Schlüssel dieser Art, siehe Abschnitt \ref{ssec:schriftstil}.
- \item[\ttfamily literal] Diese Sorte Schlüssel verwendet das eingegebene direkt, also buchstäblich. Die meisten Schlüssel von \chemnum entsprechen dieser Art.
- \item[\ttfamily choice] Auswahl-Schlüssel, für den es vorgegebene Optionen gibt, aus denen gewählt werden kann.
-\end{description}
-
-Wenn Sie Schlüssel ohne Wertzuweisung verwenden \cmd{cmpdsetup}{key1,key2}, werden De\-faultwerte\label{opt:default} verwendet. Diese sind \emph{nicht} unbedingt leer und stimmen auch \emph{nicht} unbedingt mit der Voreinstellung des Pakets überein. \emph{Alle} Schlüssel von \chemnum haben Defaultwerte. Sie werden in Abschnitt \ref{tab:keys} auf Seite \pageref{tab:keys} aufgelistet.
-
-Die Schlüssel sind in verschiedene Klassen\label{key_classes} unterteilt, die auf ihren Verwendungsbereich hindeuten. Sie folgen alle der Form \lstinline+<class>-key = <value>+:
-\begin{description}
- \item[\ttfamily cmpd] Schlüssel, die damit beginnen, wirken sich auch das Label insgesamt oder speziell auf das Hauptlabel aus.
- \item[\texttt{sub}, \texttt{sublist}, \texttt{subrange}] Diese Schlüssel haben mit den Sublabeln direkt zu tun.
- \item[\ttfamily list] Schlüssel, die die Ausgabe der Listen ändern.
- \item[\ttfamily ref] Schlüssel, die speziell mit \cmd{cmpdref} zu tun haben.
- \item[\ttfamily hyper] Schlüssel, die mit der Verwendung von \paket{hyperref} zu tun haben.
- \item[\ttfamily init] Schlüssel, die mit der Initialisierung von Labeln zu tun haben.
-\end{description}
+\begin{beschreibung}
+ \Befehl{cmpdsetup}{key1 = value1, key2 = value2}
+\end{beschreibung}
+oder lokal direkt beim Befehl
+\begin{beschreibung}
+ \Befehl{cmpd}[key1 = value1, key2 = value2]{<label name>}
+\end{beschreibung}
+vorgenommen werden.
+
+Wenn Sie Schlüssel ohne Wertzuweisung verwenden \cmd{cmpdsetup}{key1,key2}, werden De\-faultwerte\label{opt:default} verwendet. Diese sind \emph{nicht} unbedingt leer und stimmen auch \emph{nicht} unbedingt mit der Voreinstellung des Pakets überein.
+
+Die Schlüssel sind in verschiedene Klassen\label{key_classes} unterteilt, die auf ihren Verwendungsbereich hindeuten. Sie folgen alle der Form \verb+<class>-key = <value>+:
+\begin{itemize}
+ \item \code{cmpd}: Schlüssel, die damit beginnen, wirken sich auch das Label insgesamt oder speziell auf das Hauptlabel aus.
+ \item \code{sub}, \code{sublist}, \code{subref}: Diese Schlüssel haben mit den Sublabeln direkt zu tun.
+ \item \code{list}: Schlüssel, die die Ausgabe der Listen ändern.
+ \item \code{ref}: Schlüssel, die speziell mit \cmd{cmpdref} zu tun haben.
+ \item \code{hyper}: Schlüssel, die mit der Verwendung von \paket{hyperref} zu tun haben.
+ \item \code{init}: Schlüssel, die mit der Initialisierung von Labeln zu tun haben.
+\end{itemize}
\subsection{Schriftstil}\label{ssec:schriftstil}\secidx{Schriftstil}
Um den Stil zu ändern, mit dem die Nummern geschrieben werden, verwenden Sie folgende Optionen:
-\begin{framed}
- \keyentry{cmpd-style}{<style>}{macro}\\
- \keyentry{cmpd-weight}{bold/normal}{choice}\\
- \keyentry{ref-style}{<style>}{macro}
-\end{framed}
+\begin{beschreibung}
+ \Option{cmpd-style}{<style>}
+ \option{cmpd-weight}{bold/normal} Default = \code{bold}
+\end{beschreibung}
Da es nicht unüblich ist, Schemata serifenlos zu setzen, während der Text mit Serifen gesetzt wird, ist es möglich, für \cmd{cmpdref} einen eigenen Stil festzulegen. In der Voreinstellung werden mit \cmd{cmpdref} erzeugte Label mit \lstinline+\sffamily+ gesetzt.
\begin{beispiel}
% preamble:
@@ -665,9 +613,9 @@ Dass die Schriftstärke separat eingestellt wird, hat seine Ursache bei den grie
\subsection{Eigene Labels}\label{ssec:own_labels}\secidx{Eigene Labels}
Mit dem Schlüssel
-\begin{framed}
- \keyentry{cmpd-label}{<name>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{cmpd-label}{<label>}
+\end{beschreibung}
kann man eigene Labels vergeben.
\begin{beispiel}
@@ -682,13 +630,12 @@ Wenn Sie für die temporären Label, die durch \cmd{cmpdref} (siehe Seite \pager
\end{beispiel}
\secidx*{Eigene Marker}
-\subsection{Zähler}\label{ssec:counter}\secidx[Zaehler]{Zähler}
+\subsection{Zähler}\label{ssec:counter}\secidx{Zähler}
Wenn Sie mögen, können Sie auch das Zählerformat \cmpd{a.one} ändern.
-\begin{framed}
- \keyentry{cmpd-counter}{<counter>}{choice}\\
- \keyentry{sub-counter}{<counter>}{choice}\label{key:sub-counter}
-\end{framed}
-Zur Auswahl stehen \lstinline=arabic=, \lstinline=alph=, \lstinline=Alph=, \lstinline=greek=, \lstinline=Greek=, \lstinline=roman=, \lstinline=Roman= und \lstinline=Symbol=.
+\begin{beschreibung}
+ \option{cmpd-counter}{arabic/alph/Alph/greek/Greek/roman/Roman/Symbol} Default = \code{arabic}
+ \option{sub-counter}{arabic/alph/Alph/greek/Greek/roman/Roman/Symbol} Default = \code{alph}
+\end{beschreibung}
Bitte beachten Sie: ein Ändern des Zählerformats wirkt sich nur auf \emph{noch nicht erzeugte} Label aus!
\begin{beispiel}
@@ -698,15 +645,14 @@ Bitte beachten Sie: ein Ändern des Zählerformats wirkt sich nur auf \emph{noch
\cmpd{f.three,f.four}\\ % Vorsicht: Hauptlabel wurde bereits erzeugt und wird nicht geaendert!
\cmpd[cmpd-counter,sub-counter = greek]{p.one,p.two}
\end{beispiel}
-\secidx*[Zaehler]{Zähler}
+\secidx*{Zähler}
\subsection{Begrenzer}\secidx{Begrenzer}
Sie können sowohl den einzelnen Nummern wie auch eine ganze Liste mit Begrenzern versehen. Dafür gibt es die Schlüssel:
-\begin{framed}
- \keyentry{cmpd-delim}{<odelim><cdelim>}{literal}\\
- \keyentry{list-delim}{<odelim><cdelim>}{literal}\\
- Benötigen \emph{zwei} Token als Wert!
-\end{framed}
+\begin{beschreibung}
+ \option{cmpd-delim}{<odelim><cdelim>} Benötigen \emph{zwei} Token als Wert!
+ \option{list-delim}{<odelim><cdelim>} Benötigen \emph{zwei} Token als Wert!
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[cmpd-delim = ()]{a, b, f.two, k}\\ % eingeklammert
@@ -714,7 +660,7 @@ Sie können sowohl den einzelnen Nummern wie auch eine ganze Liste mit Begrenzer
\cmpdsetup{cmpd-delim = ()}
\cmpd{a, b, f.two, k} % eingeklammert
\end{beispiel}
-Wenn Sie \cmd{cmpd}[\key{cmpd-delim}]{<label>} schreiben, also keinen Wert spezifizieren, werden \lstinline=()= verwendet. Dasselbe gilt für \key{list-delim}. Beachten Sie, dass die Listenbegrenzer erst ab \emph{zwei} Labeln verwendet werden.
+Wenn Sie \cmd{cmpd}[\key{cmpd-delim}]{<label>} schreiben, also keinen Wert spezifizieren, werden \verb=()= verwendet. Dasselbe gilt für \key{list-delim}. Beachten Sie, dass die Listenbegrenzer erst ab \emph{zwei} Labeln verwendet werden.
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[list-delim = {[}{]}]{a, b, f.two, k}\\ % eingeklammert
@@ -729,11 +675,11 @@ Wenn Sie generell die Label eingeklammert verwenden, aber ein einzelnes einmal o
Normal \cmpd{b}, \cmpd{c}, \cmpd{d.one}, aber manchmal so \cmpd[cmpd-delim = ]{e} oder so \cmpd-{e}.
\end{beispiel}
Mit
-\begin{framed}\label{cmd:ohne_begrenzer}
- \centering\cmd[cmpdc]{cmpd-}{<label name>}\\
- \cmd[cmpdrefc]{cmpdref-}{<label name>}
-\end{framed}
-\noindent kann man die Klammern eines Labels schnell entfernen (nicht jedoch die der Liste).
+\begin{beschreibung}\label{cmd:ohne_begrenzer}
+ \Befehl[cmpdc]{cmpd-}\ma{<label name>}
+ \Befehl[cmpdrefc]{cmpdref-}\ma{<label name>}
+\end{beschreibung}
+kann man die Klammern eines Labels schnell entfernen (nicht jedoch die der Liste).
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpdsetup{cmpd-delim = (), list-delim = []}
@@ -744,14 +690,14 @@ Mit
Durch leere Argumente, \cmd{cmpdsetup}{\key{cmpd-delim}{ }} und \cmd{cmpdsetup}{\key{list-delim}{ }}, können Sie die Voreinstellung wieder herstellen.
\secidx*{Begrenzer}
-\subsection{Suffix und Präfix}\secidx[Suffix und Praefix]{Suffix und Präfix}
+\subsection{Suffix und Präfix}\secidx{Suffix und Präfix}
Falls Sie wollen, können sie sowohl einzelnen Labeln als auch den Listen Prä- und Suffixe geben.
-\begin{framed}
- \keyentry{cmpd-prefix}{<prefix>}{literal}\\
- \keyentry{cmpd-suffix}{<prefix>}{literal}\\
- \keyentry{list-prefix}{<prefix>}{literal}\\
- \keyentry{list-suffix}{<prefix>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{cmpd-prefix}{<prefix>}
+ \Option{cmpd-suffix}{<prefix>}
+ \Option{list-prefix}{<prefix>}
+ \Option{list-suffix}{<prefix>}
+\end{beschreibung}
Wie bei den Begrenzern gilt: Listen-Attribute werden erst bei einer Liste -- also zwei oder mehr Labeln -- verwendet.
Beispiel für die Label-Attribute:
@@ -776,21 +722,21 @@ Zwischen Präfix, Label und Suffix ist per Default ein Leerraum:
\cmpd[cmpd-suffix=Sx,cmpd-prefix=Px]{k}
\end{beispiel}
Dieser kann durch
-\begin{framed}
- \keyentry{cmpd-space}{<space>}{literal}
-\end{framed}
-\noindent geändert werden.
+\begin{beschreibung}
+ \Option{cmpd-space}{<space>}
+\end{beschreibung}
+geändert werden.
\begin{beispiel}
\cmpd[cmpd-suffix=Sx,cmpd-prefix=Px,cmpd-space={}]{k}
\end{beispiel}
-\secidx*[Suffix und Praefix]{Suffix und Präfix}
+\secidx*{Suffix und Präfix}
\subsection{Trennzeichen}\label{ssec:trenner}\secidx{Trennzeichen}
\subsubsection{Bei Labeln -- Eingabe}\label{sssec:sub-input-sep}\index{Trennzeichen!Label!Input}
-Als Voreinstellung verwendet \chemnum den Punkt \lstinline=.= als Zeichen, um Hauptlabelnamen von Sublabelnamen zu unterscheiden. Sie können das Symbol nach Belieben ändern. Die Zeichen \verb=% #= können Sie nicht verwenden und \lstinline=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole (siehe folgende Abschnitte) nicht die gleichen Zeichen zu verwenden.
-\begin{framed}
- \keyentry{sub-input-sep}{<separator>}{literal}
-\end{framed}
+Als Voreinstellung verwendet \chemnum den Punkt \code{.} als Zeichen, um Hauptlabelnamen von Sublabelnamen zu unterscheiden. Sie können das Symbol nach Belieben ändern. Die Zeichen \verb=% #= können Sie nicht verwenden und \verb=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole (siehe folgende Abschnitte) nicht die gleichen Zeichen zu verwenden.
+\begin{beschreibung}
+ \option{sub-input-sep}{<separator>} Default = \code{.}
+\end{beschreibung}
\begin{beispiel}
\cmpdsetup{sub-input-sep = !}%
\cmpd{f!one, g!two}\\
@@ -799,13 +745,13 @@ Als Voreinstellung verwendet \chemnum den Punkt \lstinline=.= als Zeichen, um Ha
\cmpd[sub-input-sep= &]{f&one, g&two}\\
\cmpd[sub-input-sep= *]{f*one, g*two}
\end{beispiel}
-Sie sollten -- nicht nur aus Gründen der Konsistenz -- nur \emph{einmal} am Anfang ihres Dokuments entscheiden, welches Symbol Sie verwenden. Und zwar \emph{bevor} Sie \lstinline=\tableofcontents= einsetzen. Am besten in der Präambel. Ansonsten kann \lstinline=\tableofcontents= nicht wissen, welchen Symbol Sie verwenden und Label im Inhaltsverzeichnis können falsch dargestellt werden.
+Sie sollten -- nicht nur aus Gründen der Konsistenz -- nur \emph{einmal} am Anfang ihres Dokuments entscheiden, welches Symbol Sie verwenden. Und zwar \emph{bevor} Sie \verb=\tableofcontents= einsetzen. Am besten in der Präambel. Ansonsten kann \verb=\tableofcontents= nicht wissen, welchen Symbol Sie verwenden und Label im Inhaltsverzeichnis können falsch dargestellt werden.
\subsubsection{Bei Labeln -- Ausgabe}\index{Trennzeichen!Label!Output}
Haben Sie Label mit Sublabeln, können Sie dort auch ein Trenn-Symbol verwenden. Das erscheint dann zwischen Hauptlabel und Sublabel.
-\begin{framed}
- \keyentry{sub-output-sep}{<separator>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{sub-output-sep}{<separator>}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, f.three, k}\\ % default
\cmpd[sub-output-sep = -]{a, b, f.two, f.three, k}\\
@@ -815,10 +761,10 @@ Haben Sie Label mit Sublabeln, können Sie dort auch ein Trenn-Symbol verwenden.
\end{beispiel}
\subsubsection{Bei Sublabeln -- Eingabe}\label{sssec:range-input-sep}\index{Trennzeichen!Sublabel!Input}
-Für die Eingabe eines Bereiches von Sublabeln verwendet \chemnum in der Voreinstellung zwei Punkte \texttt{..}. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \lstinline=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole nicht die gleichen Zeichen zu verwenden.
-\begin{framed}
- \keyentry{subrange-input-sep}{<separator>}{literal}
-\end{framed}
+Für die Eingabe eines Bereiches von Sublabeln verwendet \chemnum in der Voreinstellung zwei Punkte \code{..}. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \verb=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole nicht die gleichen Zeichen zu verwenden.
+\begin{beschreibung}
+ \option{subrange-input-sep}{<separator>} Default = \code{..}
+\end{beschreibung}
\begin{beispiel}
\cmpd[subrange-input-sep=:]{q.{one:four}}\\
\cmpdsetup{subrange-input-sep=--}
@@ -826,10 +772,10 @@ Für die Eingabe eines Bereiches von Sublabeln verwendet \chemnum in der Voreins
\end{beispiel}
\subsubsection{Bei Sublabeln -- Ausgabe}\index{Trennzeichen!Sublabel!Output}
-Vielleicht gefällt Ihnen die Ausgabe \cmpd[cmpd-all]{q} nicht und Sie wollen den Bereich anders darstellen? Das geht mit diesem Key:
-\begin{framed}
- \keyentry{subrange-output-sep}{<separator>}{literal}
-\end{framed}
+Vielleicht gefällt Ihnen die Ausgabe \cmpd[cmpd-all]{q} nicht und Sie wollen den Bereich anders darstellen? Das geht mit dieser Option:
+\begin{beschreibung}
+ \option{subrange-output-sep}{<separator>} Default = \verb|--|
+\end{beschreibung}
\begin{beispiel}
\cmpd[subrange-output-sep={ {\normalfont bis} }]{q.{one..four}}\\
\cmpdsetup{subrange-output-sep=-}
@@ -837,10 +783,11 @@ Vielleicht gefällt Ihnen die Ausgabe \cmpd[cmpd-all]{q} nicht und Sie wollen de
\end{beispiel}
\subsubsection{Bei Listen -- Eingabe}\label{sssec:list-input-sep}\index{Trennzeichen!Listen!Input}
-Wenn Sie mögen, können Sie das Trennsymbol der Listen-Eingabe ändern. Per Default wird hier das Komma \texttt{,} verwendet. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \lstinline=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole nicht die gleichen Zeichen zu verwenden.
-\begin{framed}
- \keyentry{list-input-sep}{<separator>}{literal}
-\end{framed}
+Wenn Sie mögen, können Sie das Trennsymbol der Listen-Eingabe ändern. Per Default wird hier das Komma \code{,} verwendet. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \verb=@= sollten Sie nicht verwenden. Außerdem sollten Sie darauf achten, für die anderen Trennsymbole nicht die gleichen Zeichen zu verwenden.
+\begin{beschreibung}
+ \option{list-input-sep}{<separator>} Default = \code{,}
+ \option{sub-input-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[list-input-sep = +]{a + b + f.two + k}\\
@@ -856,9 +803,10 @@ Das ermöglicht Ihnen \zB, IUPAC-Namen als Label-Namen zu verwenden\footnote{Vie
\subsubsection{Bei Listen -- Ausgabe}\label{sssec:list-output-sep}\index{Trennzeichen!Listen!Output}
Auch bei Listen lässt sich ein Trennsymbol festlegen, das bestimmt, wie einzelne Label voneinander getrennt werden. Per Default ist das das Komma.
-\begin{framed}
- \keyentry{list-output-sep}{<separator>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \option{list-output-sep}{<separator>} Default = \code{,}
+ \option{sub-output-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[list-output-sep = ]{a, b, f.two, k}\\
@@ -869,11 +817,10 @@ Auch bei Listen lässt sich ein Trennsymbol festlegen, das bestimmt, wie einzeln
\subsubsection{Bei Listen -- letzter Trenner}\label{sssec:last-sep}\index{Trennzeichen!Listen!letzter Trenner}
Der letzte Trenner bei Listen, derjenige zwischen dem vorletzten und letzten aufgelisteten Label, ist ein besonderer Fall. Hierfür gibt es zwei Schlüssel, mit dem er angepasst werden kann.
-\begin{framed}
- \keyentry{list-last-sep}{<separator>}{literal}\\
- \keyentry{list-lang}{<lang>}{choice}
-\end{framed}
-Zum einen gibt es den \lstinline=choice=-Schlüssel \key{list-lang}, mit dem Sprachspezifische Einstellungen ge\-än\-dert werden können. Zur Auswahl stehen \lstinline=US= (default), \lstinline=GB=, \lstinline=DE=, \lstinline=FR=, \lstinline=ES= und \lstinline=IT=.
+\begin{beschreibung}
+ \Option{list-last-sep}{<separator>}
+ \option{list-lang}{US/GB/DE/FR/ES/IT} Default = \code{US}
+\end{beschreibung}
\begin{beispiel}
\cmpd[list-lang = US]{a, b, f.two, k} \cmpd[list-lang = US]{a, b}\\
\cmpd[list-lang = GB]{a, b, f.two, k} \cmpd[list-lang = GB]{a, b}\\
@@ -882,7 +829,7 @@ Zum einen gibt es den \lstinline=choice=-Schlüssel \key{list-lang}, mit dem Spr
\cmpd[list-lang = ES]{a, b, f.two, k} \cmpd[list-lang = ES]{a, b}\\
\cmpd[list-lang = IT]{a, b, f.two, k} \cmpd[list-lang = IT]{a, b}
\end{beispiel}
-Wie Sie sehen, verwendet die Spracheinstellung \lstinline=US= per Default das Harvard-Komma, alle anderen Sprachen verwenden es nicht. Mehr zur Sprach-Unterstützung und zum Harvard-Komma finden Sie in Abschnitt \ref{sec:language_support}.
+Wie Sie sehen, verwendet die Spracheinstellung \verb=US= per Default das Harvard-Komma, alle anderen Sprachen verwenden es nicht. Mehr zur Sprach-Unterstützung und zum Harvard-Komma finden Sie in Abschnitt \ref{sec:language_support}.
Sie können den letzten Trenner mit \key{list-last-sep} auch individuell festlegen.
\begin{beispiel}
@@ -893,7 +840,7 @@ Sie können den letzten Trenner mit \key{list-last-sep} auch individuell festleg
\cmpd[list-last-sep = empty]{a, b, f.two, k}
\end{beispiel}
-Ein spezieller Wert ist \lstinline=empty=. Wird er verwendet, wird überall der Trenner eingesetzt, der mit \key{list-output-sep} festgelegt wurde.
+Eine spezielle Option ist \key{list-last-sep}{empty}. Wird er verwendet, wird überall der Trenner eingesetzt, der mit \key{list-output-sep} festgelegt wurde.
\begin{beispiel}
\cmpdsetup{list-last-sep = empty}%
\cmpd{a, b, f.two, k}\\
@@ -901,11 +848,11 @@ Ein spezieller Wert ist \lstinline=empty=. Wird er verwendet, wird überall der
\cmpd[list-output-sep = {\ und}]{a, b, f.two, k}
\end{beispiel}
-\subsubsection{Bei \texttt{\textbackslash\textcolor{code}{cmpdinit}} -- Eingabe}\label{sssec:init-input-sep}\index{Trennzeichen!cmpdinit@\textcolor{code}{\texttt{\textbackslash cmpdinit}}}
-Wenn Sie mögen, können Sie das Trennsymbol der Listen-Eingabe ändern. Per Default wird hier das Komma \texttt{,} verwendet. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \lstinline=@= sollten Sie nicht verwenden.
-\begin{framed}
- \keyentry{init-input-sep}{<separator>}{literal}
-\end{framed}
+\subsubsection{Bei \code{\textbackslash\textcolor{code}{cmpdinit}} -- Eingabe}\label{sssec:init-input-sep}\index{Trennzeichen!cmpdinit@\textcolor{code}{\code{\textbackslash cmpdinit}}}
+Wenn Sie mögen, können Sie das Trennsymbol der Listen-Eingabe ändern. Per Default wird hier das Komma \code{,} verwendet. Sie können aber eine beliebige andere Eingabe wählen. Die Zeichen \verb=% #= können Sie nicht verwenden und \verb=@= sollten Sie nicht verwenden.
+\begin{beschreibung}
+ \option{init-input-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\subsubsection{Ein Beispiel}\label{sssec:input-sep-bsp}
Im folgenden sehen Sie ein kleines Beispiel, wie eine personalisierte Variante der Trennzeichen aussehen könnte.
@@ -920,7 +867,7 @@ Im folgenden sehen Sie ein kleines Beispiel, wie eine personalisierte Variante d
\end{beispiel}
\secidx*{Trennzeichen}
-\section{Sprachunterstützung}\label{sec:language_support}\secidx[Sprachunterstuetzung]{Sprachunterstützung}
+\section{Sprachunterstützung}\label{sec:language_support}\secidx{Sprachunterstützung}
\subsection{Zusammenarbeit mit \textsf{babel}}
\chemnum unterstützt die Sprachauswahl durch das \paket{babel}-Paket für eine Reihe von Sprachen. Dies geschieht mit Hilfe des \paket*{translator} Pakets, falls es vorhanden ist. Kann \paket*{translator} nicht geladen werden, muss die Sprachunterstützung von Hand vorgenommen werden, siehe Abschnitt \ref{sssec:last-sep}. Die Einstellung von Hand funktioniert natürlich auch, wenn \paket*{translator} geladen wurde.
\begin{beispiel}
@@ -939,16 +886,16 @@ Bei weitem nicht alle Sprachen werden unterstützt, schon allein aus Machbarkeit
\subsection{Harvard-Komma}\label{ssec:harvard-comma}\secidx{Harvard-Komma}
Im US-Amerikanischen ist die Verwendung des sogenannten Harvard- oder Oxford-Kommas weit verbreitet, im Britischen und in anderen europäischen Sprachen ist sie eher unüblich.
-\begin{myquote}[\href{http://en.wikipedia.org/wiki/Serial_comma}{Wikipedia}, 2011/11/07]
+\begin{zitat}[\href{http://en.wikipedia.org/wiki/Serial_comma}{\protect\Wikipedia}, 2011/11/07]
The serial comma (also known as the Oxford comma or Harvard comma, and sometimes referred to as the series comma) is the comma used immediately before a coordinating conjunction (usually and or or, and sometimes nor) preceding the final item in a list of three or more items. For example, a list of three countries can be punctuated as either "Portugal, Spain, and France" (with the serial comma) or as "Portugal, Spain and France" (without the serial comma).
- Opinions vary among writers and editors on the usage or avoidance of the serial comma. In American English, the serial comma is standard usage in non-journalistic writing that follows the \textsc{Chicago Manual of Style}. Journalists, however, usually follow the AP Stylebook, which advises against it. It is used less often in British English, where it is standard usage to leave it out, with some notable exceptions such as \textsc{Fowler's Modern English Usage}. In many languages (e.g., French, German, Italian, Polish, Spanish), the serial comma is not the norm and may even go against punctuation rules. It may be recommended in many cases, however, to avoid ambiguity or to aid prosody.
-\end{myquote}
-\chemnum verwendet das Harvard-Komma bei der Verwendung von American English, nicht aber bei anderen Sprachen. Sie haben jedoch die Möglichkeit, das Harvard-Komma mit dem Schlüssel
-\begin{framed}
- \keyentry{list-serial-comma}{true/false}{boolean}\label{key:list-serial-comma}
-\end{framed}
-\noindent nach Belieben zu (De-)Aktivieren.
+ Opinions vary among writers and editors on the usage or avoidance of the serial comma. In American English, the serial comma is standard usage in non-journalistic writing that follows the \name{Chicago Manual of Style}. Journalists, however, usually follow the AP Stylebook, which advises against it. It is used less often in British English, where it is standard usage to leave it out, with some notable exceptions such as \name{Fowler's Modern English Usage}. In many languages (e.g., French, German, Italian, Polish, Spanish), the serial comma is not the norm and may even go against punctuation rules. It may be recommended in many cases, however, to avoid ambiguity or to aid prosody.
+\end{zitat}
+\chemnum verwendet das Harvard-Komma bei der Verwendung von American English, nicht aber bei anderen Sprachen. Sie haben jedoch die Möglichkeit, das Harvard-Komma mit der Option
+\begin{beschreibung}
+ \Option{list-serial-comma}{\default{true}/false}
+\end{beschreibung}
+nach Belieben zu (De-)Aktivieren.
\begin{beispiel}
\selectlanguage{ngerman}DE: \cmpd[list-serial-comma]{r,s,t} vs. \cmpd{r,s,t}\\
\selectlanguage{american}US: \cmpd[list-serial-comma=false]{r,s,t} vs. \cmpd{r,s,t}
@@ -958,15 +905,15 @@ Wenn Sie die Spracheinstellung manuell vornehmen, beachten Sie, dass dabei auf d
falsch: \cmpdsetup{list-serial-comma=false, list-lang=US}\cmpd{r,s,t}\\
richtig: \cmpdsetup{list-lang=US, list-serial-comma=false}\cmpd{r,s,t}
\end{beispiel}
-\secidx*{Harvard-Komma}\secidx*[Sprachunterstuetzung]{Sprachunterstützung}
+\secidx*{Harvard-Komma}\secidx*{Sprachunterstützung}
-\section{Übersicht}
+\section{Overview}
\subsection{Keys}\label{ssec:keys_uebersicht}
-Im folgenden sind alle verfügbaren Schlüssel aufgelistet.
+Im folgenden sind alle verfügbaren Optionen aufgelistet.
\begin{center}
\label{tab:keys}
\begin{longtabu*}{>{\ttfamily\color{key}}l>{\ttfamily}l>{\ttfamily}l>{\ttfamily}l}\toprule
- \normalfont\bfseries\normalcolor Key & \normalfont\bfseries Leerwert & \normalfont\bfseries Voreinstellung & \normalfont\bfseries Typ \\\midrule
+ \normalfont\bfseries\normalcolor Option & \normalfont\bfseries Leerwert & \normalfont\bfseries Voreinstellung & \normalfont\bfseries Typ \\\midrule
cmpd-style & & & macro \\
cmpd-weight & bold & bold & choice \\
cmpd-label & & & literal \\
@@ -975,7 +922,7 @@ Im folgenden sind alle verfügbaren Schlüssel aufgelistet.
cmpd-cdelim & & & literal \\
cmpd-prefix & & & literal \\
cmpd-suffix & & & literal \\
- cmpd-space & \lstinline=\penalty\@m\ = & \lstinline=\penalty\@m\ = & literal \\
+ cmpd-space & \verb=\penalty\@m\ = & \verb=\penalty\@m\ = & literal \\
cmpd-counter & arabic & arabic & choice \\
cmpd-all & true & false & boolean \\\midrule
sub-only & true & false & boolean \\
@@ -997,7 +944,7 @@ Im folgenden sind alle verfügbaren Schlüssel aufgelistet.
list-last-sep & and$^\mathrm{c}$ & & literal \\
list-serial-comma & true & true$^\mathrm{c}$ & boolean \\\midrule
ref-tag & TMP & TMP & literal \\
- ref-style & & \lstinline=\sffamily= & macro \\\midrule
+ ref-style & & \verb=\sffamily= & macro \\\midrule
init-strict & true & false & boolean \\
init-sub & true & false & boolean \\
init-input-sep & , & , & literal \\\midrule
@@ -1032,8 +979,9 @@ Im folgenden werden alle von \chemnum definierten Befehle und deren Varianten au
\end{longtabu*}%
\end{center}
-\section{Dank}
-Ich möchte Joseph \textsc{Wright} und Russell \textsc{Hewitt} danken, die mir wertvolle Vorschläge und Feedback gaben, um \chemnum zu verbessern.
+\appendix
+\addsec{Dank}
+Ich möchte Joseph \name{Wright} und Russell \name{Hewitt} danken, die mir wertvolle Vorschläge und Feedback gaben, um \chemnum zu verbessern.
\printindex
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.pdf b/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.pdf
deleted file mode 100644
index 435b8eb42ca..00000000000
--- a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_de.pdf
+++ /dev/null
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.pdf b/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.pdf
deleted file mode 100644
index e8cf63a54dd..00000000000
--- a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.pdf
+++ /dev/null
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_en.pdf b/Master/texmf-dist/doc/latex/chemnum/chemnum_en.pdf
new file mode 100644
index 00000000000..486687c7941
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/chemnum/chemnum_en.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.tex b/Master/texmf-dist/doc/latex/chemnum/chemnum_en.tex
index aadee3048bc..788912e05e4 100644
--- a/Master/texmf-dist/doc/latex/chemnum/chemnum_doc_en.tex
+++ b/Master/texmf-dist/doc/latex/chemnum/chemnum_en.tex
@@ -1,51 +1,61 @@
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% - chemnum - chemnum_doc_en.tex - %
-% - a comprehensive approach for the numbering of chemical compounds - %
-% ------------------------------------------------------------------------------------- %
-% - Clemens NIEDERBERGER - %
-% - 2012/02/26 - %
-% ------------------------------------------------------------------------------------- %
-% - http://www.mychemistry.eu/ - %
-% - contact@mychemistry.eu - %
-% ------------------------------------------------------------------------------------- %
-% - If you have any ideas, questions, suggestions or bugs to report, please feel free - %
-% - to contact me. - %
-% ------------------------------------------------------------------------------------- %
-% - Copyright 2011-2012 Clemens Niederberger - %
-% - - %
-% - This work may be distributed and/or modified under the - %
-% - conditions of the LaTeX Project Public License, either version 1.3 - %
-% - of this license or (at your option) any later version. - %
-% - The latest version of this license is in - %
-% - http://www.latex-project.org/lppl.txt - %
-% - and version 1.3 or later is part of all distributions of LaTeX - %
-% - version 2005/12/01 or later. - %
-% - - %
-% - This work has the LPPL maintenance status `maintained'. - %
-% - - %
-% - The Current Maintainer of this work is Clemens Niederberger. - %
-% - - %
-% - This work consists of the files chemnum.sty, chemnum_doc_de.tex, - %
-% - chemnum_doc_en.tex, chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, - %
-% - README and the derived files chemnum_doc_de.pdf and chemnum_doc_en.pdf - %
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\documentclass[DIV11,toc=index]{scrartcl}
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% - chemnum - chemnum_en.tex
+% - a comprehensive approach for the numbering of chemical compounds
+% -----------------------------------------------------------------------------
+% - Clemens NIEDERBERGER
+% - 2012/04/15
+% - contact@mychemistry.eu
+% -----------------------------------------------------------------------------
+% - If you have any ideas, questions, suggestions or bugs to report, please
+% - feel free to contact me.
+% -----------------------------------------------------------------------------
+% - Copyright 2011-2012 Clemens Niederberger
+% -
+% - This work may be distributed and/or modified under the
+% - conditions of the LaTeX Project Public License, either version 1.3
+% - of this license or (at your option) any later version.
+% - The latest version of this license is in
+% - http://www.latex-project.org/lppl.txt
+% - and version 1.3 or later is part of all distributions of LaTeX
+% - version 2005/12/01 or later.
+% -
+% - This work has the LPPL maintenance status `maintained'.
+% -
+% - The Current Maintainer of this work is Clemens Niederberger.
+% -
+% - This work consists of the files chemnum.sty, chemnum_de.tex, chemnum_en.tex,
+% - chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, README and the
+% - derived files chemnum_de.pdf and chemnum_en.pdf
+% -
+% - in order to compile this document you need the class `cnpkgdoc' with is
+% - available under the LPPL here: https://bitbucket.org/cgnieder/cnpkgdoc/
+% -
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\RequirePackage[textgreek]{chemnum}
+\documentclass[DIV11,toc=index]{cnpkgdoc}
+\docsetup{
+ pkg = chemnum,
+ code-box = {backgroundcolor=cnpkgcodebg,skipabove=1ex,skipbelow=1ex}
+}
+\addcmds{
+ @m,arrow,bf,ch,chemfig,chemname,cmpd,cmpdinit,cmpdref,cmpdreset,cmpdsetup,
+ CNlabel,CNlabelnoref,CNref,CNlabelsub,CNlabelsubnoref,CNrefsub,
+ declarecompound,color,compound,compoundprefix,compoundsuffix,fcite,
+ includegraphics,midrule,penalty,renewcommand,schemename,schemestart,
+ schemestop,selectlanguage,setarrowoffset,setatomsep,setcompoundsep,
+ setdoublesep,section,sf,subsection,subsubsection,tableofcontents,
+ texorpdfstring,textcolor,theffbibliography,uline}
+
\usepackage[ngerman,german,naustrian,austrian,english,british,american,canadian,frenchb,canadien,spanish,italian]{babel}
-\usepackage[T1]{fontenc}
-\usepackage[utf8]{inputenx}
-\usepackage[textgreek]{chemnum}
-\usepackage{textcomp,microtype,libertine,url,xspace,longtable,tabu,booktabs,chemscheme,makeidx,multicol}
-\usepackage[scaled=.95]{inconsolata}
+\usepackage{textcomp,longtable,tabu,booktabs,chemscheme}
\usepackage[iupac=strict]{chemmacros}
\DeclareChemIUPAC\a{\textalpha}
\DeclareChemIUPAC\b{\textbeta}
\usepackage{chemfig}
-\usepackage[normalem]{ulem}
\usepackage[runs=2]{auto-pst-pdf}
-\input{chemnum-codehelper}
\begin{filecontents}{index_en.ist}
- preamble "\\begin{theindex}\n Section headings are typeset \\textbf{bold}, packages \\textsf{sans serif}, commands \\textcolor{code}{brown}, and keys \\textcolor{key}{green}.\\newline\n\n"
+ preamble "\\begin{theindex}\n Section headings are typeset \\textbf{bold}, packages \\textsf{sans serif}, commands \\textcolor{code}{brown}, and options \\textcolor{key}{green}.\\newline\n\n"
heading_prefix "{\\bfseries "
heading_suffix "\\hfil}\\nopagebreak\n"
headings_flag 1
@@ -57,62 +67,16 @@
suffix_3p "\\nohyperpage{\\,ff.}"
\end{filecontents}
-\usepackage{hyperref}
- \hypersetup{colorlinks = true,
- allcolors = myblue,
- plainpages = false,
- bookmarksopen = true,
- bookmarksopenlevel = 2,
- bookmarksnumbered = true,
- pdfauthor = {Clemens Niederberger},
- pdftitle = {chemnum - English documentation},
- pdfsubject = {Numbering chemical compounds},
- pdfkeywords = {chemmnum},
- pdfcreator = {LaTeX}
- pdfstartview = FitH
- }
-
-\ExplSyntaxOn
-\NewDocumentCommand \keyentry { mmm }
- {
- \noindent
- \textcolor { key } { \texttt { #1 } }
- \texttt { ~=~#2 }
- \hfill type:~
- \texttt { #3 }
- \index { #1 @ \textcolor { key } { \texttt { #1 } } }
- }
-\ExplSyntaxOff
-
-\GetFileInfo{chemnum}
-\newcommand*\chemnum{{\scshape\textcolor{myblue}{\filename}}\xspace}
-\newcommand*\CNversion{\fileversion\xspace}
-\newcommand*\CNdate{\filedate\xspace}
-\newcommand*\CNinfo{\fileinfo\ with \LaTeXe.}
-
-\newcommand*\eg{\mbox{e.\,g.}\xspace}
-\newcommand*\ie{\mbox{i.\,e.}\xspace}
-\newcommand*\etc{\mbox{etc.}\xspace}
+\let\prog\textsc
+\let\name\textsc
+\let\CNversion\cnpkgdocpkgversion
+\let\CNdate\cnpkgdocpkgdate
+\def\Wikipedia{\textup{\libertineGlyph{W.alt}}\kern-.8pt\textsc{ikipedia}}
\cmpdinit*{a,aa,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,benzene,r,s,t,{1,3-dichlorocyclohexanole}}
-\makeindex
-\begin{document}
-\selectlanguage{english}
-\begin{titlepage}
- \centering
- \Huge\textcolor{myblue}{\biolinumshadow[\fontsize{1.5cm}{1.6cm}\fontshape{sc}]{chemnum}}
- \vskip.5cm
- \Large \CNversion \qquad \CNdate
- \vskip.5cm
- \large Clemens \textsc{Niederberger}
- \vskip.25cm
- \normalsize\url{https://bitbucket.org/cgnieder/chemnum/}\\
- \href{mailto:contact@mychemistry.eu}{contact@mychemistry.eu}
- \begin{center}
- \Large\color{myblue} \CNinfo \\[16pt]
- \normalcolor English documentation
- \end{center}
- \vskip3cm \cmpdinit*{glucose.alpha, glucose.beta, glucose.chain}
+
+\TitlePicture{%
+\cmpdinit*{glucose.alpha, glucose.beta, glucose.chain}
\cmpd*[sub-counter = greek]{glucose.alpha, glucose.beta}\cmpd*{glucose.chain}
\setatomsep{2em}
\definesubmol{x}{(-[4]H)(-[0]OH)}
@@ -130,29 +94,26 @@
\arrow(@chainlabel--){0}[180,2.3] \normalsize\cmpd[cmpd-delim]{glucose.alpha}
\schemestop
\caption{In a solution the \a- and the \b-anomer of \D-glucose \cmpd[list-delim]{glucose.alpha,glucose.beta} are in equilibrium via the open-chain form \cmpd[cmpd-delim]{glucose.chain}.}
- \end{scheme}
-\end{titlepage}
-\cmpdreset
-\begin{multicols}{2}
- \tableofcontents
-\end{multicols}
+ \end{scheme}}
+
+\makeindex
+\begin{document}
+\selectlanguage{english}\cmpdreset
\section{A very short readme}
-\chemnum \CNversion underlies the \LaTeX\ Project Public License Version 1.3 or later.\newline(\url{http://www.latex-project.org/lppl.txt})
+\chemnum \CNversion\ underlies the \LaTeX\ Project Public License Version 1.3 or later. (\url{http://www.latex-project.org/lppl.txt})
\chemnum internally loads the packages \paket*{expl3} and \paket{xparse}. \paket{xparse} is part of the \paket{l3packages} bundle, \paket*{expl3} is part of the \paket{l3kernel} bundle. This means, \chemnum needs \LaTeX3 Support.
\chemnum also needs the packages \paket{etoolbox}, \paket{psfrag} and either \paket{textgreek} or \paket{bm}, see section \ref{sec:package_options}.
-In this command you can easily distinguish between a \textcolor{code}{\ttfamily\textbackslash command}, a \textcolor{key}{\ttfamily key} belonging to a key/value pair and \texttt{other code}.
-
\section{News and a word of apology}
-In the update to v0.4 there have been some changes made with the keys. There are a few new ones and some of the old ones got new names. They now have consistent names which in my opinion better reflect their function. This means that your documents set with an older version of \chemnum might not compile any more without errors. I am sorry for that. \chemnum still is actively developped. Once it reaches v1.0, such changes won't be made any more\footnote{Or only in absolutely necessary cases.}.
+In the update to v0.4 there have been some changes made with the options. There are a few new ones and some of the old ones got new names. They now have consistent names which in my opinion better reflect their function. This means that your documents set with an older version of \chemnum might not compile any more without errors. I am sorry for that. \chemnum still is actively developped. Once it reaches v1.0, such changes won't be made any more\footnote{Or only in absolutely necessary cases.}.
-These keys have new names:
+These options have new names:
\begin{center}
\begin{tabular}{ll}\toprule
- \bfseries old name & \bfseries new name \\\midrule
+ \bfseries old name & \bfseries new name \\\midrule
\key{cmpd-sep} & \key{sub-output-sep} \\
\key{sub-marker} & \key{sub-input-sep} \\
\key{sub-range-sep} & \key{subrange-output-sep} \\
@@ -175,56 +136,52 @@ These ones are new:
\end{tabular}
\end{center}
-Also new is the way how lists and ranges of sublabels are input. The key \key{sub-list} no longer exists. More on this in section \ref{ssec:sub_ranges}.
+Also new is the way how lists and ranges of sublabels are input. The option \key{sub-list} no longer exists. More on this in section \ref{ssec:sub_ranges}.
Then there is the possibility of creating hyperlinked labels together with the package \paket{hyperref}, see section \ref{sec:hyperref}.
-With v0.4 this documentation got an index.
-
\section{Package options}\label{sec:package_options}\secidx{Package options}
\chemnum has one package option.
-\begin{framed}
- \centering\lstinline+\usepackage[textgreek = <value>]{chemnum}+
-\end{framed}
-With this you can both choose between the three different styles of the \paket{textgreek} package\footnote{See the \paket*{textgreek} documentation for details.} or load \chemnum without the \paket{textgreek} package. Available values are \lstinline=artemisia=, \lstinline=cbgreek=, \lstinline=euler= and \lstinline=false=. Using \lstinline+\usepackage[textgreek]{chemnum}+ is the same as \lstinline+\usepackage[textgreek = cbgreek]{chemnum}+. If you use \chemnum without option \textsf{textgreek} is not used. This corresponds to \lstinline+\usepackage[textgreek = false]{chemnum}+, the default setting.
-
-This document was set with \lstinline+\usepackage[textgreek]{chemnum}+.
+\begin{beschreibung}
+ \Option{textgreek}{artemisia/\default{cbgreek}/euler/false} Default: \code{false}
+\end{beschreibung}
+This document was set with \verb+\usepackage[textgreek]{chemnum}+.
\secidx*{Package options}
\section{Motivation}
As far as I know there are three packages that are meant to help with numbering chemical compounds. All of them have their weaknesses.
-The first one -- \paket{chemcono} -- redefined bibliography commands for that purpose. Compounds have to be declared in what is called \lstinline=\theffbibliography=. Then one can reference them with \lstinline=\fcite=. However, it produces a list of compounds in the text. So the package author suggests:
-\begin{myquote}[Stefan Schulz]
+The first one -- \paket{chemcono} -- redefined bibliography commands for that purpose. Compounds have to be declared in what is called \verb=\theffbibliography=. Then one can reference them with \verb=\fcite=. However, it produces a list of compounds in the text. So the package author suggests:
+\begin{zitat}[Stefan Schulz]
After compilation and printout, discard the last page.
-\end{myquote}
+\end{zitat}
Obviously that's not a perfect solution.
The second one -- \paket{chemcompounds} -- was written, because the author didn't want to work with the weaknesses of \paket{chemcono} any more. When he wrote the package he basically used the same mechanism to create the labels as \paket{chemcono} did.
-\begin{myquote}[Stephan Schenk]
- When taking a closer look at the chemcono package, I realised that the only thing one has to do is to get rid of everything which produces text. Thus, as a basis I used the mechanism of \lstinline=\bibitem= and \lstinline=\cite= in pretty much the same way as \paket{chemcono} does by extracting the corresponding code from \lstinline=article.cls= and \lstinline=latex.ltx= but deleting any unnecessary commands producing output. I also introduced several lines of code to make the printing of the compound names more customisable.
-\end{myquote}
+\begin{zitat}[Stephan Schenk]
+ When taking a closer look at the chemcono package, I realised that the only thing one has to do is to get rid of everything which produces text. Thus, as a basis I used the mechanism of \verb=\bibitem= and \verb=\cite= in pretty much the same way as \paket{chemcono} does by extracting the corresponding code from \verb=article.cls= and \verb=latex.ltx= but deleting any unnecessary commands producing output. I also introduced several lines of code to make the printing of the compound names more customisable.
+\end{zitat}
Some points still left me unsatisfied, though:
\begin{enumerate}
- \item Compounds usually need to be declared with \lstinline=\declarecompound=. They need to be declared in any case if you need a label like \textbf{1a}. Then, one even needs to choose the label by hand, what somehow undermines the automatic numbering principle.
+ \item Compounds usually need to be declared with \verb=\declarecompound=. They need to be declared in any case if you need a label like \textbf{1a}. Then, one even needs to choose the label by hand, what somehow undermines the automatic numbering principle.
\item The layout can't be changed for a single label but only for all.
\item The numbers can't be reset. \emph{Although in most cases this is neither necessary nor can it be recommended}, there can be individual cases where this would be useful.
- \item A list of several compounds \lstinline=\compound{a,b,c}= can only be customized with more effort than what would be convenient.
+ \item A list of several compounds \verb=\compound{a,b,c}= can only be customized with more effort than what would be convenient.
\end{enumerate}
-Then there is \paket{bpchem}, which provides commands similar to \lstinline=\label= \lstinline=\ref=: \lstinline=\CNlabel{}=, \lstinline=\CNlabelnoref{}= and \lstinline=\CNref{}=. It provides commands for sublabels, too: \lstinline=\CNlabelsub{}{}=, \lstinline=\CNlabelsubnoref{}{}= and \lstinline=\CNrefsub{}{}=. This makes it more flexible than the others regarding sublabels. However, it barely provides possibilities to customize the labels, lists are not possible and the fact that there are different commands for labels and sublabels isn't the best solution, either.
+Then there is \paket{bpchem}, which provides commands similar to \verb=\label= \verb=\ref=: \verb=\CNlabel{}=, \verb=\CNlabelnoref{}= and \verb=\CNref{}=. It provides commands for sublabels, too: \verb=\CNlabelsub{}{}=, \verb=\CNlabelsubnoref{}{}= and \verb=\CNrefsub{}{}=. This makes it more flexible than the others regarding sublabels. However, it barely provides possibilities to customize the labels, lists are not possible and the fact that there are different commands for labels and sublabels isn't the best solution, either.
\chemnum is intended to fill these gaps. For this all commands have been written from scratch. Some of the ideas of \paket{chemcompounds} \eg regarding delimiters and layout have been picked up, though.
If you notice any feature missing, please let me know by sending me an email.
\section{Numbering compounds}\label{sec:nummerieren}
-\subsection{Main command}\secidx{Main command}
+\subsection{Main command}\secidx{Main command}\cmpdreset
The main command of this package is this one:
-\begin{framed}
- \centering\cmd{cmpd}{<label name>}
-\end{framed}
-\noindent When \lstinline=<label name>= is used the first time, the label is created, saved (= declared) and printed. Each further use just prints the label.
+\begin{beschreibung}
+ \Befehl{cmpd}{<label name>}
+\end{beschreibung}
+When \code{<label name>} is used the first time, the label is created, saved (= declared) and printed. Each further use just prints the label.
\begin{beispiel}
Compounds \cmpd{a} and \cmpd{b} are declared and can be used any time: \cmpd{a}. No pre-declaring is necessary. Compounds like \cmpd{c} are numbered in the order they appear in the text.\par
@@ -232,10 +189,11 @@ The main command of this package is this one:
\end{beispiel}
If it is necessary to declare a compound without printing the label, this is possible with
-\begin{framed}\label{cmd:unsichtbares_label}
-\centering\cmd[cmpda]{cmpd*}{<label name>}
-\end{framed}
-\noindent This declares the label but doesn't print anything. \textbf{This command is not needed when} \cmd{cmpdinit}{} \textbf{is used, see section \ref{sec:cmpdinit} (pages \pageref{sec:cmpdinit}ff).}
+\begin{beschreibung}
+ \Befehl[cmpda]{cmpd*}\ma{<label name>}\label{cmd:unsichtbares_label}
+\end{beschreibung}
+This declares the label but doesn't print anything.
+\achtung{This command is not needed when \cmd{cmpdinit} is used, see section \ref{sec:cmpdinit} (pages \pageref{sec:cmpdinit}ff).}
\begin{beispiel}
The hidden version\cmpd*{d} declares the label but doesn't print anything. The next \cmpd{e} continues to count with the next number. With \cmpd{d} the label can be used, of course.
@@ -251,23 +209,20 @@ You can pretty much use what you like for a label name except for the separator
\subsection{Sublabel}\label{ssec:unterlabel}\secidx{Sublabel}
If you want a label like \cmpd{a.one}, you need to use the following syntax:
-\begin{framed}
- \centering\cmd{cmpd}{<label name>.<subname>}
-\end{framed}
-\noindent \lstinline=<label name>= is the main name which stays the same, \lstinline=<subname>= varies. This syntax means that the point \lstinline=.= \emph{cannot} be a part of \lstinline=<label name>= or \lstinline=<subname>=. Instead of the point you also can use another symbol, see section \ref{sssec:sub-input-sep}.
-
+\begin{beschreibung}
+ \Befehl{cmpd}{<label name>.<subname>}
+\end{beschreibung}
+\code{<label name>} is the main name which stays the same, \code{<subname>} varies. This syntax means that the point \code{.} \emph{cannot} be a part of \code{<label name>} or \code{<subname>}. Instead of the point you also can use another symbol, see section \ref{sssec:sub-input-sep}.
\begin{beispiel}
\cmpd{f.one} and \cmpd{f.two} are related, as are \cmpd{g.one} and \cmpd{g.two}. Of course, these labels can be used again: \cmpd{g.two} and \cmpd{f.one}.
\end{beispiel}
This also works, if the main name has already been used.
-
\begin{beispiel}
\cmpd{a} and its variants \cmpd{a.one} and \cmpd{a.two}
\end{beispiel}
The same way the main name of combined labels can be used solely.
-
\begin{beispiel}
\cmpd{f} and \cmpd{g}
\end{beispiel}
@@ -279,15 +234,15 @@ How you can create a label like \cmpd{f.{one,two}} is explained in section \ref{
There is actually more to the \cmd{cmpd} command. It also prints lists of labels.
The right description would be something like:
-\begin{framed}
- \centering\cmd{cmpd}{<(possibly comma separated list of) label name(s)>}
-\end{framed}
+\begin{beschreibung}
+ \Befehl{cmpd}{<(possibly comma separated list of) label name(s)>}
+\end{beschreibung}
This means that with default settings the comma can't be part of the label name unless hidden in braces. You can change that, see section \ref{sssec:list-input-sep} on page \pageref{sssec:list-input-sep}. Section \ref{sssec:input-sep-bsp} shows an example how a changed input could look like.
\begin{beispiel}
- More than one label can be put inside \cmd{cmpd}, separated by commas. Then a list like \cmpd{a, b, c, e, g.two} is printed.
+ More than one label can be put inside \verb=\cmpd=, separated by commas. Then a list like \cmpd{a, b, c, e, g.two} is printed.
\end{beispiel}
-The Harvard comma (see \ref{ssec:harvard-comma}) in \verb=, and= between \cmpd{e} and \cmpd{g.two} suggests that there are options to customize the list, see sections \ref{ssec:trenner} and \ref{sec:language_support}.
+The Harvard comma (see \ref{ssec:harvard-comma}) in \code{, and} between \cmpd{e} and \cmpd{g.two} suggests that there are options to customize the list, see sections \ref{ssec:trenner} and \ref{sec:language_support}.
\secidx*{Lists}
\subsection{Lists and ranges of sublabels}\label{ssec:sub_ranges}\index{Sublabel!lists}\index{Sublabel!ranges}
@@ -300,7 +255,7 @@ The syntax is rather intuitive -- you just input a list of sublabels:
\end{beispiel}
Since the sublist is input with a comma in the default setting, you have to put them into braces.
-Using this syntax you also can create ranges of sublabels. As a marker to indicate the range \chemnum uses two points \lstinline=..=.
+Using this syntax you also can create ranges of sublabels. As a marker to indicate the range \chemnum uses two points \verb=..=.
\begin{beispiel}
\cmpd{q.{two..four}}\\
\cmpd{q.{one,three..five}}\\
@@ -309,20 +264,20 @@ Using this syntax you also can create ranges of sublabels. As a marker to indica
This means you can neither use the comma nor the two points as part of a sublabel name. How you can use other markers for the input you can read in sections \ref{sssec:range-input-sep} and \ref{sssec:list-input-sep}.
-\chemnum provides a key (see section \ref{sec:cmpdsetup} for more details), with which all sublabels of a main label can be printed as range.
-\begin{framed}
- \keyentry{cmpd-all}{true/false}{boolean}
-\end{framed}
+\chemnum provides an option (see section \ref{sec:cmpdsetup} for more details), with which all sublabels of a main label can be printed as range.
+\begin{beschreibung}
+ \Option{cmpd-all}{\default{true}/false}
+\end{beschreibung}
\begin{beispiel}
\cmpd[cmpd-all]{q}
\end{beispiel}
-In order to get the right sublabels the command needs to know, which sublabels have been declared. This means that they're read from the \lstinline=<jobname>.cmpd= file (supposing your source file is called \lstinline=<jobname>.tex=). So you may need to compile twice (or more) until the labels are printed right.
+In order to get the right sublabels the command needs to know, which sublabels have been declared. This means that they're read from the \verb=\jobname.cmpd= file (supposing your source file is called \verb=\jobname.tex=). So you may need to compile twice (or more) until the labels are printed right.
-If one uses label with sublabel ranges, one might want to use \emph{only} the sublabels in a different place. This is possible with this key:
-\begin{framed}
- \keyentry{sub-only}{true/false}{boolean}
-\end{framed}
+If one uses label with sublabel ranges, one might want to use \emph{only} the sublabels in a different place. This is possible with this option:
+\begin{beschreibung}
+ \Option{sub-only}{\default{true}/false}
+\end{beschreibung}
\begin{beispiel}
% uses packages `chemfig', `chemmacros' and `booktabs'
\cmpd*{benzene.H,benzene.Me,benzene.OH,benzene.NH2}
@@ -346,44 +301,44 @@ The commands described in this section are not essential for the usage of \chemn
\subsection{Usage}
\subsubsection{Main labels}
-Perhaps you're missing \textsf{chemcompounds}' command \lstinline=\declarecompound= already. For one thing one has a summary of all used label names. And one may be warned if one uses an uninitialized label name\footnote{for instance due to a typing error}. This behaviour can be realized with these commands:
-\begin{framed}
- \centering\cmd{cmpdinit}{<comma separated list of label names>}
- \centering\cmd[cmpdinita]{cmpdinit*}{<comma separated list of label names>}
-\end{framed}
-All compounds set inside \cmd{cmpdinit}{} are initialized and declared \emph{in the given order}. If one uses a label name that's not in the list, \chemnum produces a warning message.
+Perhaps you're missing \paket{chemcompounds}' command \verb=\declarecompound= already. For one thing one has a summary of all used label names. And one may be warned if one uses an uninitialized label name\footnote{for instance due to a typing error}. This behaviour can be realized with these commands:
+\begin{beschreibung}
+ \Befehl{cmpdinit}{<comma separated list of label names>}
+ \Befehl[cmpdinita]{cmpdinit*}{<comma separated list of label names>}
+\end{beschreibung}
+All compounds set inside \cmd{cmpdinit} are initialized and declared \emph{in the given order}. If one uses a label name that's not in the list, \chemnum produces a warning message.
\cmpdreset
\begin{beispiel}
\cmpdinit{A, B, C} \cmpd{B} \cmpd{A.a} \cmpd{C} \cmpd{D}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init"\\
{}* \\
{}* You used \verb=\cmpdinit= but didn't initiate compound "D"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
Please note that for labels with sublabels only the \emph{main name} can and should be initialized. This initializes all compounds with the same main name.
-\cmd[cmpdinita]{cmpdinit*}{}= also produces a warning but doesn't declare the labels. They are declared when you first use them in the order of appearance in the text.
+\cmd[cmpdinita]{cmpdinit*} also produces a warning but doesn't declare the labels. They are declared when you first use them in the order of appearance in the text.
\cmpdreset
\begin{beispiel}
\cmpdinit*{X, Y, Z} \cmpd{Y} \cmpd{X.x} \cmpd{Z} \cmpd{W}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init"\\
{}* \\
{}* You used \verb=\cmpdinit= but didn't initiate compound "W"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
If you need to use own labels (see page \pageref{ssec:own_labels}) but still want to initialize all labels at once, you should use \cmd[cmpdinita]{cmpdinit*}{}, because then no labels are declared when they're initialized.
@@ -391,10 +346,10 @@ This command can be used several times, with or without \verb=*=. A useful way w
\subsubsection{Sublabels}
If you'd like a warning for label-sublabel combinations as well, or want to preset their order, you can use
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-sub}{true}]{<comma separated list of label names>}
-\end{framed}
-\noindent This will give you a warning in these cases, too.
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-sub}{true}]{<comma separated list of label names>}
+\end{beschreibung}
+This will give you a warning in these cases, too.
\cmpdreset
\begin{beispiel}
@@ -402,7 +357,7 @@ If you'd like a warning for label-sublabel combinations as well, or want to pres
\cmpd{E.e, E.h}
\end{beispiel}
-\begin{framed}
+\begin{mdframed}
\small\ttfamily\noindent
{}*************************************************\\
{}* chemnum warning: "cmpd-init-sub"\\
@@ -410,22 +365,22 @@ If you'd like a warning for label-sublabel combinations as well, or want to pres
{}* You used \verb=\cmpdinit= and "{}init-sub = true"{} but didn't initiate sub-compound\\
{}* "{}E.h"{} on line 1.\\
{}*************************************************
-\end{framed}
+\end{mdframed}
\subsection{Error instead of warning}
If you want \chemnum to produce an error instead of a warning when you use an unititialized label name, you can use \cmd{cmpdinit} like this:
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-strict}{true}]{<comma separated list of label names>}
-\end{framed}
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-strict}{true}]{<comma separated list of label names>}
+\end{beschreibung}
A usage of \key{init-strict}{false} would be the usage without optional argument. Of course the *-version has the same option.
With \key{init-strict}{true} the \LaTeX\ run will be aborted with a corresponding error message, if a label name is used that hasn't been initialized before.
-Of course you can use \cmd{cmpdinit} with both keys
-\begin{framed}
- \centering\cmd{cmpdinit}[\key{init-strict}{true}, \key{init-sub}{true}]{<comma separated list of label names>}
-\end{framed}
-\noindent or use \cmd{cmpdsetup}, see section \ref{sec:cmpdsetup}.
+Of course you can use \cmd{cmpdinit} with both options
+\begin{beschreibung}
+ \Befehl{cmpdinit}[\key{init-strict}{true}, \key{init-sub}{true}]{<comma separated list of label names>}
+\end{beschreibung}
+or use \cmd{cmpdsetup}, see section \ref{sec:cmpdsetup}.
\subsection{Customized input}
When you're using other tokens for \key{sub-input-sep} (page \pageref{sssec:sub-input-sep}) or \key{sublist-input-sep} (page \pageref{sssec:list-input-sep}), you have to use them with \cmd{cmpdinit} as well.
@@ -442,39 +397,42 @@ As mentioned in the beginning of this section the initiation of labels is not re
\section{Resetting the counter}\label{sec:cmpdreset}\secidx{Reset the counter}
With the command
-\begin{framed}
- \centering\cmd{cmpdreset}[<number>]
-\end{framed}
-\noindent it is possible to reset the counter. Without argument it is reset to \verb=1=. So \cmd{cmpdreset} and \cmd{cmpdreset}[1] are the same. Unlike most other \chemnum commands its impact is not only inside the local \TeX\ group but resets the counter globally.
+\begin{beschreibung}
+ \Befehl{cmpdreset}[<number>]
+\end{beschreibung}
+it is possible to reset the counter. Without argument it is reset to \verb=1=. So \cmd{cmpdreset} and \cmd{cmpdreset}[1] are the same. Unlike most other \chemnum commands its impact is not only inside the local \TeX\ group but resets the counter globally.
\begin{beispiel}
\cmpdreset The numbering starts with 1 again: \cmpd{h, i, j}
\end{beispiel}
-\textbf{You should be careful with how you use this command! Usually it cannot be recommended to reset the counter. Different compounds can get the same label!}
+\achtung{You should be careful with how you use this command! Usually it cannot be recommended to reset the counter. Different compounds can get the same label!}
+
\begin{beispiel}
Same label: \cmpd{a}, \cmpd{h}
\end{beispiel}
\secidx*{Reset the counter}
-\section{Special usage}
+\section{Special usage}\secidx{Special usage}
\subsection{Moving arguments -- section titles}
Using \cmd{cmpd} inside a section title in the first instant doesn't seem to be a problem. This doesn't give any errors and the output looks like expected:
\begin{beispiel}[code only]
\section{Compound \cmpd[cmpd-delim]{b}}
\ldots
\end{beispiel}
-However, if you use \lstinline=\tableofcontents= -- which is rather probable, I guess -- something unwanted happens: because the table of contents is at the beginning of the document, the label is declared in the table of contents instead of at the first appearance in the text. There are two ways to circumvent this:
+However, if you use \verb=\tableofcontents= -- which is rather probable, I guess -- something unwanted happens: because the table of contents is at the beginning of the document, the label is declared in the table of contents instead of at the first appearance in the text. There are two ways to circumvent this:
\begin{enumerate}
\item You declare your labels in the order you want with \cmd{cmpdinit}{}= (see page \pageref{sec:cmpdinit}) in the preamble or the beginning of the document.
- \item You use \cmd[cmpdb]{cmpd+} to set the label. It will read the label from the file \lstinline=<jobname>.cmpd= (supposing your main file is called \lstinline=<jobname>.tex=). This means \emph{at least two}, maybe more \LaTeX\ runs are necessary until all labels are set.
+ \item You use \cmd[cmpdb]{cmpd+} to set the label. It will read the label from the file \verb=<jobname>.cmpd= (supposing your main file is called \verb=<jobname>.tex=). This means \emph{at least two}, maybe more \LaTeX\ runs are necessary until all labels are set.
\end{enumerate}
The same is true for any other list of moving arguments that is created \emph{before} the actual appearance of the label in the text.
The command\label{cmd:cmpd_plus}
-\begin{framed}
- \centering\cmd[cmpdb]{cmpd+}{<label name>}
-\end{framed}
-reads the label name that is to be printed from \lstinline=<jobname>.cmpd=. In a way this is the opposite of \cmd[cmpda]{cmpd*} since it doesn't declare a label but only references and prints it. So in order to use \cmd[cmpdb]{cmpd+}{<label>}, \lstinline=<label>= must have been declared, either with \cmd{cmpd}{<label>} or with \cmd[cmpda]{cmpd*}{<label>}. It doesn't matter, if this declaration is done before or after the usage of \cmd[cmpdb]{cmpd+}. This command is useful, if the label is used inside a moving argument like in \lstinline=\section{}=. \textbf{It is not needed when} \cmd{cmpdinit}{} \textbf{is used, see section \ref{sec:cmpdinit} (pages \pageref{sec:cmpdinit}\,ff).}
+\begin{beschreibung}
+ \Befehl[cmpdb]{cmpd+}\ma{<label name>}
+\end{beschreibung}
+reads the label name that is to be printed from \verb=\jobname.cmpd=. In a way this is the opposite of \cmd[cmpda]{cmpd*} since it doesn't declare a label but only references and prints it. So in order to use \cmd[cmpdb]{cmpd+}{<label>}, \verb=<label>= must have been declared, either with \cmd{cmpd}{<label>} or with \cmd[cmpda]{cmpd*}{<label>}. It doesn't matter, if this declaration is done before or after the usage of \cmd[cmpdb]{cmpd+}. This command is useful, if the label is used inside a moving argument like in \verb=\section{}=.
+
+\achtung{It is not needed when \cmd{cmpdinit} is used, see section \ref{sec:cmpdinit} (pages \pageref{sec:cmpdinit}\,ff).}
\begin{beispiel}
\subsubsection{Test section title with compound label \cmpd+[cmpd-delim]{f.one}}
@@ -496,15 +454,15 @@ The usage of \cmd{cmpd} inside a float shouldn't be a problem: labels are declar
\end{scheme}
\end{beispiel}
-This also works, of the floating environment is placed before the code, for instance by using the option \lstinline=[t]=.
+This also works, of the floating environment is placed before the code, for instance by using the option \verb=[t]=.
\cmpdinit*{Alc,EtherBr,cpd}
\subsection{Schemes created by external programs}\label{ssec:cmpdref}\secidx{Schemes by external programs}
-If you create your schemes by external programs like for \eg \textsc{ChemDraw} or \textsc{Marvin\-Sketch}, and want to use \chemnum with them as well, you can use this command:
-\begin{framed}
- \centering\cmd{cmpdref}[<keyval>][<tag>]{<label name>}
-\end{framed}
-This command is inspired by the \lstinline=\schemeref= command from the package \paket{chemscheme}. It works in a very similar way. You create the scheme and save it with temporary labels as an \lstinline=eps= file.
+If you create your schemes by external programs like for \eg \prog{ChemDraw} or \prog{Marvin\-Sketch}, and want to use \chemnum with them as well, you can use this command:
+\begin{beschreibung}
+ \Befehl{cmpdref}[<options>]\oa[<tag>]\ma{<label name>}
+\end{beschreibung}
+This command is inspired by the \verb=\schemeref= command from the package \paket{chemscheme}. It works in a very similar way. You create the scheme and save it with temporary labels as an \verb=eps= file.
\begin{beispiel}[code and float]
\begin{scheme}[ht]
\centering
@@ -520,11 +478,11 @@ This command is inspired by the \lstinline=\schemeref= command from the package
\caption{Scheme with automated labels.}
\end{scheme}
\end{beispiel}
-So you nummerate the compounds with \textsf{TMP1}, \textsf{TMP2} \etc These markers will then be replaced with the corresponding labels. Like \paket{chemscheme} \chemnum uses the \lstinline=\psfrag= command of the \paket{psfrag} package to do that. This means you have to either compile via \textsc{latex}, \textsc{dvips}, \textsc{ps2pdf}, or for instance use the package \paket{auto-pst-pdf} to be able to use \textsc{pdflatex}.
+So you nummerate the compounds with \textsf{TMP1}, \textsf{TMP2} \etc These markers will then be replaced with the corresponding labels. Like \paket{chemscheme} \chemnum uses the \verb=\psfrag= command of the \paket{psfrag} package to do that. This means you have to either compile via \prog{latex}, \prog{dvips}, \prog{ps2pdf}, or for instance use the package \paket{auto-pst-pdf} to be able to use \prog{pdflatex}.
-In each case it is important that the marker is saved as \emph{text} in the \lstinline=eps= file.
+In each case it is important that the marker is saved as \emph{text} in the \verb=eps= file.
-You can customize the labels with the keys presented in section \ref{sec:cmpdsetup}.
+You can customize the labels with the options presented in section \ref{sec:cmpdsetup}.
\begin{beispiel}[code and float]
\begin{scheme}[ht]
\centering
@@ -563,14 +521,15 @@ Of course sublabels work in the known way:
\end{scheme}
\end{beispiel}
\cmpdreset[10]\secidx*{Schemes by external programs}
+\secidx*{Special usage}
-\section{Usage with \textsf{hyperref}}\label{sec:hyperref}\secidx[Usage with hyperref]{Usage with \textsf{hyperref}}
+\section{Usage with \paket{hyperref}}\label{sec:hyperref}\secidx[Usage with hyperref]{Usage with \textsf{hyperref}}
\subsection{Basics}
-If you are using the package \paket{hyperref} you can make hyperlinked labels in your \textsc{pdf}.
-\begin{framed}
- \keyentry{hyper-use}{true/false}{boolean}
-\end{framed}
-Setting this key (see section \ref{sec:cmpdsetup} for more information) to \texttt{true}, the next usage of a label will create a link target and the ones after that will create links to this target. This only works if the label does \emph{not} contain a list or range of sublabels. Also a label set with \cmd[cmpda]{cmpd*} can't be marked as target.
+If you are using the package \paket{hyperref} you can make hyperlinked labels in your \prog{pdf}.
+\begin{beschreibung}
+ \Option{hyper-use}{\default{true}/false}
+\end{beschreibung}
+Setting this option (see section \ref{sec:cmpdsetup} for more information) to \texttt{true}, the next usage of a label will create a link target and the ones after that will create links to this target. This only works if the label does \emph{not} contain a list or range of sublabels. Also a label set with \cmd[cmpda]{cmpd*} can't be marked as target.
\begin{beispiel}
\cmpdsetup{hyper-use}
@@ -580,65 +539,65 @@ Setting this key (see section \ref{sec:cmpdsetup} for more information) to \text
\end{beispiel}
\subsection{Selected usage}
-Maybe the automated use isn't what you want or need. Maybe is is enough to create a hyperlink in one or two places. This can be achieved with two keys:
-\begin{framed}
- \keyentry{hyper-target}{<link name>}{literal}\\
- \keyentry{hyper-link}{<link name>}{literal}
-\end{framed}
-With \key{hyper-target} you can set the target. \textbf{Caution}: if you use this key with a list \emph{every} label of the list will get the same link name and \paket{hyperref} will warn you:
-\begin{framed}\ttfamily
-destination with the same identifier (name{<link name>}) has been already used, duplicate ignored
-\end{framed}
-
-\key{hyper-link} creates a link for the denominated target. \textbf{Caution}: if you use this key with a list \emph{every} label of the list will refer to the same target.
+Maybe the automated use isn't what you want or need. Maybe is is enough to create a hyperlink in one or two places. This can be achieved with two options:
+\begin{beschreibung}
+ \Option{hyper-target}{<link name>}
+ \Option{hyper-link}{<link name>}
+\end{beschreibung}
+With \key{hyper-target} you can set the target. \textbf{Caution}: if you use this option with a list \emph{every} label of the list will get the same link name and \paket{hyperref} will warn you:
+\begin{mdframed}\ttfamily
+ destination with the same identifier (name\{<link name>\}) has been already used, duplicate ignored
+\end{mdframed}
+
+\key{hyper-link} creates a link for the denominated target. \textbf{Caution}: if you use this option with a list \emph{every} label of the list will refer to the same target.
\begin{beispiel}
Create a link \cmpd[hyper-link=mylink,cmpd-all]{f} but don't forget the corresponding target: \cmpd[hyper-target=mylink,cmpd-all]{f}.
\end{beispiel}
If you use \key{hyper-link} without the corresponding \key{hyper-target} \paket{hyperref} will issue a warning:
-\begin{framed}\ttfamily
-name{<link name>} has been referenced but does not exist, replaced by a fixed one
-\end{framed}
+\begin{mdframed}\ttfamily
+ name\{<link name>\} has been referenced but does not exist, replaced by a fixed one
+\end{mdframed}
\secidx*[Usage with hyperref]{Usage with \textsf{hyperref}}
\section{Customization}\label{sec:cmpdsetup}
\subsection{The principle}
\chemnum is customized with a key-value system. They can either be used for all following commands with
-\begin{framed}
- \centering\cmd{cmpdsetup}{key1 = value1, key2 = value2}
-\end{framed}
-\noindent or only for a single command directly with
-\begin{framed}
- \centering\cmd{cmpd}[key1 = value1, key2 = value2]{<label name>}
-\end{framed}
-
-There are different kinds of keys. Depending on it they can have different kinds of values.
-\begin{description}
- \item[\ttfamily macro] This kind of keys expects one or more macros as value. The last of them may have a mandatory argument, \eg \lstinline=\bfseries= or \lstinline=\textbf=. \chemnum has only one such key, see section \ref{ssec:schriftstil}.
- \item[\ttfamily literal] These keys use the given value "as it is", \ie literally. Most of \chemnum's keys are \lstinline=literal= keys.
- \item[\ttfamily choice] For these keys there is a list of options from which one must be chosen as a value.
- \item[\ttfamily boolean] These keys can either have the value \lstinline=true= or \lstinline=false=.
-\end{description}
-
-If you use keys without values like \cmd{cmpdsetup}{key1,key2}, default values\label{opt:default} are used. These are \emph{not} necessarily empty are \emph{not} necessarily the default setting of \chemnum. \emph{All} of \chemnum's keys have default values. They are listed in section \ref{tab:keys} on page \pageref{tab:keys}.
-
-The keys are divided in to different classes\label{key_classes}, which indicate the scope they're used for. They all follow the form \lstinline+<class>-key = <value>+:
-\begin{description}
- \item[\ttfamily cmpd] These keys change the whole label or the main label.
- \item[\texttt{sub}, \texttt{sublist}, \texttt{subref}] These keys have an impact on sublabels.
- \item[\ttfamily list] Keys which change the output of lists.
- \item[\ttfamily ref] Keys which have an impact on \cmd{cmpdref}.
- \item[\ttfamily hyper] Keys which have an impact on the usage with \paket{hyperref}.
- \item[\ttfamily init] Keys which have an impact in the initialization of the labels.
-\end{description}
+\begin{beschreibung}
+ \Befehl{cmpdsetup}{key1 = value1, key2 = value2}
+\end{beschreibung}
+or only for a single command directly with
+\begin{beschreibung}
+ \Befehl{cmpd}[key1 = value1, key2 = value2]{<label name>}
+\end{beschreibung}
+
+% There are different kinds of keys. Depending on it they can have different kinds of values.
+% \begin{description}
+% \item[\ttfamily macro] This kind of keys expects one or more macros as value. The last of them may have a mandatory argument, \eg \verb=\bfseries= or \verb=\textbf=. \chemnum has only one such key, see section \ref{ssec:schriftstil}.
+% \item[\ttfamily literal] These keys use the given value "as it is", \ie literally. Most of \chemnum's keys are \verb=literal= keys.
+% \item[\ttfamily choice] For these keys there is a list of options from which one must be chosen as a value.
+% \item[\ttfamily boolean] These keys can either have the value \verb=true= or \verb=false=.
+% \end{description}
+
+If you use keys without values like \cmd{cmpdsetup}{key1,key2}, default values\label{opt:default} are used. These are \emph{not} necessarily empty are \emph{not} necessarily the default setting of \chemnum.% \emph{All} of \chemnum's keys have default values. They are listed in section \ref{tab:keys} on page \pageref{tab:keys}.
+
+The options are divided in to different classes\label{key_classes}, which indicate the scope they're used for. They all follow the form \verb+<class>-option = <value>+:
+\begin{itemize}
+ \item \code{cmpd}: These options change the whole label or the main label.
+ \item \code{sub}, \code{sublist}, \code{subref}: These options have an impact on sublabels.
+ \item \code{list}: Options which change the output of lists.
+ \item \code{ref}: Options which have an impact on \cmd{cmpdref}.
+ \item \code{hyper}: Options which have an impact on the usage with \paket{hyperref}.
+ \item \code{init}: Options which have an impact in the initialization of the labels.
+\end{itemize}
\subsection{Font style}\label{ssec:schriftstil}\secidx{Font style}
With the keys
-\begin{framed}
- \keyentry{cmpd-style}{<style>}{macro}\\
- \keyentry{cmpd-weight}{bold/normal}{choice}
-\end{framed}
-\noindent you can change the style with which the labels are printed.
+\begin{beschreibung}
+ \Option{cmpd-style}{<style>}
+ \option{cmpd-weight}{bold/normal} Default = \code{bold}
+\end{beschreibung}
+you can change the style with which the labels are printed.
\begin{beispiel}
% preamble:
@@ -656,10 +615,10 @@ The separate handling of the bold face is because of the greek labels (see secti
\subsection{Own labels}\label{ssec:own_labels}\secidx{Own labels}
With the key
-\begin{framed}
- \keyentry{cmpd-label}{<label>}{literal}
-\end{framed}
-\noindent one can choose the label associated with the label name.
+\begin{beschreibung}
+ \Option{cmpd-label}{<label>}
+\end{beschreibung}
+one can choose the label associated with the label name.
\begin{beispiel}
Own label: \cmpd[cmpd-label = XYZ]{l}; in a list \emph{all new compounds} get this label! \cmpd[cmpd-label = XYZ]{l, a, m}
@@ -667,7 +626,7 @@ With the key
\secidx*{Own labels}
\subsection{Own markers in images}\secidx{Own markers in images}
-If you don't want to use \lstinline=TMP= as temporary markers for \cmd{cmpdref} (see page \pageref{ssec:cmpdref}), you can change this. For example into \lstinline=tmp=: \label{key:key-tag}
+If you don't want to use \code{TMP} as temporary markers for \cmd{cmpdref} (see page \pageref{ssec:cmpdref}), you can change this. For example into \code{tmp}: \label{key:key-tag}
\begin{beispiel}[code only]
\cmpdsetup{ref-marker = tmp}
\end{beispiel}
@@ -675,11 +634,10 @@ If you don't want to use \lstinline=TMP= as temporary markers for \cmd{cmpdref}
\subsection{Counter}\label{ssec:counter}\secidx{Counter}
You can change the format of the counters, too, if you like.
-\begin{framed}
- \keyentry{cmpd-counter}{<counter>}{choice}\\
- \keyentry{sub-counter}{<counter>}{choice}\label{key:sub-counter}
-\end{framed}
-You can choose between \lstinline=arabic=, \lstinline=alph=, \lstinline=Alph=, \lstinline=greek=, \lstinline=Greek=, \lstinline=roman=, \lstinline=Roman= and \lstinline=Symbol=.
+\begin{beschreibung}
+ \option{cmpd-counter}{arabic/alph/Alph/greek/Greek/roman/Roman/Symbol} Default = \code{arabic}
+ \option{sub-counter}{arabic/alph/Alph/greek/Greek/roman/Roman/Symbol} Default = \code{alph}
+\end{beschreibung}
Please note: a change of format only affects labels \emph{which are not yet declared}!
\begin{beispiel}
@@ -692,12 +650,11 @@ Please note: a change of format only affects labels \emph{which are not yet decl
\secidx*{Counter}
\subsection{Delimiters}\secidx{Delimiters}
-Both single labels and whole lists can get delimiters. This is done with the keys
-\begin{framed}
- \keyentry{cmpd-delim}{<odelim><cdelim>}{literal}\\
- \keyentry{list-delim}{<odelim><cdelim>}{literal}\\
-values need \emph{two} tokens!
-\end{framed}
+Both single labels and whole lists can get delimiters. This is done with the options
+\begin{beschreibung}
+ \option{cmpd-delim}{<odelim><cdelim>} values need \emph{two} tokens!
+ \option{list-delim}{<odelim><cdelim>} values need \emph{two} tokens!
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[cmpd-delim = ()]{a, b, f.two, k}\\ % in braces
@@ -720,11 +677,11 @@ If you generally use labels in braces but want to use a single one without brace
normally: \cmpd{b}, \cmpd{c}, \cmpd{d.one}, but sometimes so \cmpd[cmpd-delim = ]{e} or so \cmpd-{e}.
\end{beispiel}
With
-\begin{framed}\label{cmd:ohne_begrenzer}
- \centering\cmd[cmpdc]{cmpd-}{<label name>}\\
- \cmd[cmpdrefc]{cmpdref-}{<label name>}
-\end{framed}
-\noindent the braces of single labels can easily be removed (but not the ones of a list).
+\begin{beschreibung}\label{cmd:ohne_begrenzer}
+ \Befehl[cmpdc]{cmpd-}\ma{<label name>}
+ \Befehl[cmpdrefc]{cmpdref-}\ma{<label name>}
+\end{beschreibung}
+the braces of single labels can easily be removed (but not the ones of a list).
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpdsetup{cmpd-delim = (), list-delim = []}
@@ -737,12 +694,12 @@ Using \cmd{cmpdsetup}{\key{cmpd-delim}{ }} and \cmd{cmpdsetup}{\key{list-delim}{
\subsection{Suffix and prefix}\secidx{Suffix and prefix}
If you want to, you can also add a prefix and/or a suffix to a compound and/or a list.
-\begin{framed}
- \keyentry{cmpd-prefix}{<prefix>}{literal}\\
- \keyentry{cmpd-suffix}{<prefix>}{literal}\\
- \keyentry{list-prefix}{<prefix>}{literal}\\
- \keyentry{list-suffix}{<prefix>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{cmpd-prefix}{<prefix>}
+ \Option{cmpd-suffix}{<prefix>}
+ \Option{list-prefix}{<prefix>}
+ \Option{list-suffix}{<prefix>}
+\end{beschreibung}
The same rule as for the delimiters applies: list attributes are only used with lists, \ie at least with two items.
An example for the label attributes:
@@ -767,9 +724,9 @@ Between prefix, label and suffix there is a space inserted as default behaviour:
\cmpd[cmpd-suffix=sx,cmpd-prefix=px]{k}
\end{beispiel}
It can be changed with
-\begin{framed}
- \keyentry{cmpd-space}{<space>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{cmpd-space}{<space>}
+\end{beschreibung}
\begin{beispiel}
\cmpd[cmpd-suffix=sx,cmpd-prefix=px,cmpd-space={}]{k}
\end{beispiel}
@@ -777,10 +734,10 @@ It can be changed with
\subsection{Separators}\label{ssec:trenner}\secidx{Separators}
\subsubsection{Labels -- input}\label{sssec:sub-input-sep}\index{Separators!labels!input}
-As a default setting \chemnum use the point \lstinline=.= as a marker to separate main labels from sublabels. You can change that as you like. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \lstinline=@=. Furthermore you should be careful to use different symbols for the other separators (see the next sections).
-\begin{framed}
- \keyentry{sub-input-sep}{<separator>}{literal}
-\end{framed}
+As a default setting \chemnum use the point \code{.} as a marker to separate main labels from sublabels. You can change that as you like. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \verb=@=. Furthermore you should be careful to use different symbols for the other separators (see the next sections).
+\begin{beschreibung}
+ \option{sub-input-sep}{<separator>} Default = \code{.}
+\end{beschreibung}
\begin{beispiel}
\cmpdsetup{sub-input-sep = !}
\cmpd{f!one, g!two}\\
@@ -789,13 +746,13 @@ As a default setting \chemnum use the point \lstinline=.= as a marker to separat
\cmpd[sub-input-sep= &]{f&one, g&two}\\
\cmpd[sub-input-sep= *]{f*one, g*two}
\end{beispiel}
-You should -- not only for the sake of consistency -- decide only \emph{once} in the beginning of your document \emph{before} the \lstinline=\tableofcontents= or in the preamble, which marker you use. Otherwise, the \lstinline=\tableofcontents= won't know the marker anymore and your labels might be at least displayed wrong in the table of contents. Also you need to setup the marker \emph{before} you use it with \cmd{cmpd} or \cmd{cmpdinit} etc.
+You should -- not only for the sake of consistency -- decide only \emph{once} in the beginning of your document \emph{before} the \verb=\tableofcontents= or in the preamble, which marker you use. Otherwise, the \verb=\tableofcontents= won't know the marker anymore and your labels might be at least displayed wrong in the table of contents. Also you need to setup the marker \emph{before} you use it with \cmd{cmpd} or \cmd{cmpdinit} etc.
\subsubsection{Labels -- output}\index{Separators!labels!output}
You can separate the labels from the sublabels if you like to.
-\begin{framed}
- \keyentry{sub-output-sep}{<separator>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \Option{sub-output-sep}{<separator>}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, f.three, k}\\ % default
\cmpd[sub-output-sep = -]{a, b, f.two, f.three, k}\\
@@ -805,10 +762,10 @@ You can separate the labels from the sublabels if you like to.
\end{beispiel}
\subsubsection{Sublabels -- input}\label{sssec:range-input-sep}\index{Separators!subabels!input}
-As a default setting \chemnum use two points \lstinline=..= as a marker to detect two sublabels as end and beginning of a range. But you can choose any tokens you like to do that. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \lstinline=@=. Furthermore you should be careful to use different symbols for the other separators.
-\begin{framed}
- \keyentry{subrange-input-sep}{<separator>}{literal}
-\end{framed}
+As a default setting \chemnum use two points \code{..} as a marker to detect two sublabels as end and beginning of a range. But you can choose any tokens you like to do that. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \verb=@=. Furthermore you should be careful to use different symbols for the other separators.
+\begin{beschreibung}
+ \option{subrange-input-sep}{<separator>} Default = \code{..}
+\end{beschreibung}
\begin{beispiel}
\cmpd[subrange-input-sep=:]{q.{one:four}}\\
\cmpdsetup{subrange-input-sep=--}
@@ -817,9 +774,9 @@ As a default setting \chemnum use two points \lstinline=..= as a marker to detec
\subsubsection{Sublabels -- output}\index{Separators!subabels!output}
Maybe you don't like the output of \cmpd[cmpd-all]{q} and you want it displayed differently? Then you need this key:
-\begin{framed}
- \keyentry{subrange-output-sep}{<separator>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \option{subrange-output-sep}{<separator>} Default = \verb|--|
+\end{beschreibung}
\begin{beispiel}
\cmpd[subrange-output-sep={ {\normalfont to} }]{q.{one..four}}\\
\cmpdsetup{subrange-output-sep=-}
@@ -827,11 +784,11 @@ Maybe you don't like the output of \cmpd[cmpd-all]{q} and you want it displayed
\end{beispiel}
\subsubsection{Lists -- input}\label{sssec:list-input-sep}\index{Separators!lists!input}
-If you like you can change the list input separator for both main label lists and lists of sublabels. In both cases \chemnum uses the comma \texttt{,} as default. You can change that as you like. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \lstinline=@=. Furthermore you should be careful to use different symbols for the other separators.
-\begin{framed}
- \keyentry{list-input-sep}{<separator>}{literal}\\
- \keyentry{sub-input-sep}{<separator>}{literal}
-\end{framed}
+If you like you can change the list input separator for both main label lists and lists of sublabels. In both cases \chemnum uses the comma \code{,} as default. You can change that as you like. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \verb=@=. Furthermore you should be careful to use different symbols for the other separators.
+\begin{beschreibung}
+ \option{list-input-sep}{<separator>} Default = \code{,}
+ \option{sub-input-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[list-input-sep = +]{a + b + f.two + k}\\
@@ -847,10 +804,10 @@ With this you can for example use IUPAC names as label names\footnote{Thanks to
\subsubsection{Lists -- output}\label{sssec:list-output-sep}\index{Separators!lists!output}
You can change the separator symbol with which lists are printed as well. \chemnum uses the comma for both cases in the default setting.
-\begin{framed}
- \keyentry{list-output-sep}{<separator>}{literal}\\
- \keyentry{sub-output-sep}{<separator>}{literal}
-\end{framed}
+\begin{beschreibung}
+ \option{list-output-sep}{<separator>} Default = \code{,}
+ \option{sub-output-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\begin{beispiel}
\cmpd{a, b, f.two, k}\\ % default
\cmpd[list-output-sep = ]{a, b, f.two, k}\\
@@ -860,12 +817,12 @@ You can change the separator symbol with which lists are printed as well. \chemn
\end{beispiel}
\subsubsection{Lists -- last separator}\label{sssec:last-sep}\index{Separators!list!last seperator}
-The last separator in the main label list is a special case. \chemnum provides two keys with which it can be customized.
-\begin{framed}
- \keyentry{list-last-sep}{<separator>}{literal}\\
- \keyentry{list-lang}{<lang>}{choice}
-\end{framed}
-There is the \lstinline=choice= key \key{list-lang}, which changes language dependent settings. You can choose between \lstinline=US= (default), \lstinline=GB=, \lstinline=DE=, \lstinline=FR=, \lstinline=ES= and \lstinline=IT=.
+The last separator in the main label list is a special case. \chemnum provides two options with which it can be customized.
+\begin{beschreibung}
+ \Option{list-last-sep}{<separator>}
+ \option{list-lang}{US/GB/DE/FR/ES/IT} Default = \code{US}
+\end{beschreibung}
+% There is the option \key{list-lang}, which changes language dependent settings. You can choose between \verb=US= (default), \verb=GB=, \verb=DE=, \verb=FR=, \verb=ES= and \verb=IT=.
\begin{beispiel}
\cmpd[list-lang = US]{a, b, f.two, k} \cmpd[list-lang = US]{a, b}\\
\cmpd[list-lang = GB]{a, b, f.two, k} \cmpd[list-lang = GB]{a, b}\\
@@ -874,7 +831,7 @@ There is the \lstinline=choice= key \key{list-lang}, which changes language depe
\cmpd[list-lang = ES]{a, b, f.two, k} \cmpd[list-lang = ES]{a, b}\\
\cmpd[list-lang = IT]{a, b, f.two, k} \cmpd[list-lang = IT]{a, b}
\end{beispiel}
-As you can see the language \lstinline=US= uses the Harvard comma, all other languages don't. You'll find more on language support and the Harvard comma in section \ref{sec:language_support}.
+As you can see the language \key{list-lang}{US} uses the Harvard comma, all other languages don't. You'll find more on language support and the Harvard comma in section \ref{sec:language_support}.
With the key \key{list-last-sep} you also can set the last separator individually.
\begin{beispiel}
@@ -885,7 +842,7 @@ With the key \key{list-last-sep} you also can set the last separator individuall
\cmpd[list-last-sep = empty]{a, b, f.two, k}
\end{beispiel}
-\lstinline=empty= is a special value. If it is used, the separator set with \key{list-output-sep} is used for the whole list.
+\key{list-last-sep}{empty} is a special value. If it is used, the separator set with \key{list-output-sep} is used for the whole list.
\begin{beispiel}
\cmpdsetup{list-last-sep = empty}%
\cmpd{a, b, f.two, k}\\
@@ -893,11 +850,11 @@ With the key \key{list-last-sep} you also can set the last separator individuall
\cmpd[list-output-sep = {\ und}]{a, b, f.two, k}
\end{beispiel}
-\subsubsection{\texttt{\textbackslash\textcolor{code}{cmpdinit}} -- input}\label{sssec:init-input-sep}\index{Separators!cmpdinit@\textcolor{code}{\texttt{\textbackslash cmpdinit}}}
-When you've changed the separator for \cmd{cmpd} you might want to change it for \cmd{cmpdinit} as well. \chemnum uses the comma in the default setting. You can change that as you like. Sie können aber eine beliebige andere Eingabe wählen. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \lstinline=@=.
-\begin{framed}
- \keyentry{init-input-sep}{<separator>}{literal}
-\end{framed}
+\subsubsection{\code{\textbackslash\textcolor{code}{cmpdinit}} -- input}\label{sssec:init-input-sep}\index{Separators!cmpdinit@\textcolor{code}{\code{\textbackslash cmpdinit}}}
+When you've changed the separator for \cmd{cmpd} you might want to change it for \cmd{cmpdinit} as well. \chemnum uses the comma in the default setting. You can change that as you like. Sie können aber eine beliebige andere Eingabe wählen. Tokens you \emph{can't use} are \verb=, % #= and \emph{you shouldn't} use \verb=@=.
+\begin{beschreibung}
+ \option{init-input-sep}{<separator>} Default = \code{,}
+\end{beschreibung}
\subsubsection{An example}\label{sssec:input-sep-bsp}
A small example how a customized input could look like:
@@ -914,7 +871,7 @@ A small example how a customized input could look like:
\section{Language support}\label{sec:language_support}\secidx{Language support}
\subsection{Cooperation with \textsf{babel}}
-\chemnum supports the language choice made with the \paket{babel} package for a number of languages. This is done with the \lstinline=\translate= command of the \paket*{translator} package, if it is available. If \paket*{translator} cannot be loaded, language support must be done manually, see section \ref{sssec:last-sep}. Manual language settings can of course still be done if \paket*{translator} has been loaded.
+\chemnum supports the language choice made with the \paket{babel} package for a number of languages. This is done with the \verb=\translate= command of the \paket*{translator} package, if it is available. If \paket*{translator} cannot be loaded, language support must be done manually, see section \ref{sssec:last-sep}. Manual language settings can of course still be done if \paket*{translator} has been loaded.
\begin{beispiel}
\selectlanguage{ngerman}DE: \cmpd{r,s,t}\\
\selectlanguage{english}EN: \cmpd{r,s,t}\\
@@ -928,15 +885,17 @@ If you find a language missing, please send me an email\footnote{\href{mailto:co
\subsection{Harvard comma}\label{ssec:harvard-comma}\secidx{Harvard comma}
In American English the so-called Harvard comma is quite commonly used. In British English and other European languages it is rather uncommon.
-\begin{myquote}[\href{http://en.wikipedia.org/wiki/Serial_comma}{Wikipedia}, 2011/11/07]
+\begin{zitat}[\href{http://en.wikipedia.org/wiki/Serial_comma}{\protect\Wikipedia}, 2011/11/07]
The serial comma (also known as the Oxford comma or Harvard comma, and sometimes referred to as the series comma) is the comma used immediately before a coordinating conjunction (usually and or or, and sometimes nor) preceding the final item in a list of three or more items. For example, a list of three countries can be punctuated as either "Portugal, Spain, and France" (with the serial comma) or as "Portugal, Spain and France" (without the serial comma).
- Opinions vary among writers and editors on the usage or avoidance of the serial comma. In American English, the serial comma is standard usage in non-journalistic writing that follows the \textsc{Chicago Manual of Style}. Journalists, however, usually follow the AP Stylebook, which advises against it. It is used less often in British English, where it is standard usage to leave it out, with some notable exceptions such as \textsc{Fowler's Modern English Usage}. In many languages (e.g., French, German, Italian, Polish, Spanish), the serial comma is not the norm and may even go against punctuation rules. It may be recommended in many cases, however, to avoid ambiguity or to aid prosody.
-\end{myquote}
+ Opinions vary among writers and editors on the usage or avoidance of the serial comma. In American English, the serial comma is standard usage in non-journalistic writing that follows the \name{Chicago Manual of Style}. Journalists, however, usually follow the AP Stylebook, which advises against it. It is used less often in British English, where it is standard usage to leave it out, with some notable exceptions such as \name{Fowler's Modern English Usage}. In many languages (e.g., French, German, Italian, Polish, Spanish), the serial comma is not the norm and may even go against punctuation rules. It may be recommended in many cases, however, to avoid ambiguity or to aid prosody.
+\end{zitat}
\chemnum uses the Harvard comma when American English is used and doesn't, when other languages are used. However, you have the possibility to disable or enable the Harvard comma as you wish:
-\begin{framed}
- \keyentry{list-serial-comma}{true/false}{boolean}\label{key:list-serial-comma}
-\end{framed}
+
+\begin{beschreibung}
+ \Option{list-serial-comma}{\default{true}/false}
+\end{beschreibung}
+
\begin{beispiel}
\selectlanguage{ngerman}DE: \cmpd[list-serial-comma]{r,s,t} vs. \cmpd{r,s,t}\\
\selectlanguage{american}US: \cmpd[list-serial-comma=false]{r,s,t} vs. \cmpd{r,s,t}
@@ -950,7 +909,7 @@ If you choose the language manually, please note that this resets the default be
\section{Overview}
\subsection{Keys}\label{ssec:keys_uebersicht}
-In this section all keys are listed.
+In this section all options are listed.
\begin{center}
\label{tab:keys}
\begin{longtabu*}{>{\ttfamily\color{key}}l>{\ttfamily}l>{\ttfamily}l>{\ttfamily}l}\toprule
@@ -963,7 +922,7 @@ In this section all keys are listed.
cmpd-cdelim & & & literal \\
cmpd-prefix & & & literal \\
cmpd-suffix & & & literal \\
- cmpd-space & \lstinline=\penalty\@m\ = & \lstinline=\penalty\@m\ = & literal \\
+ cmpd-space & \verb=\penalty\@m\ = & \verb=\penalty\@m\ = & literal \\
cmpd-counter & arabic & arabic & choice \\
cmpd-all & true & false & boolean \\\midrule
sub-only & true & false & boolean \\
@@ -985,7 +944,7 @@ In this section all keys are listed.
list-last-sep & and$^\mathrm{c}$ & & literal \\
list-serial-comma & true & true$^\mathrm{c}$ & boolean \\\midrule
ref-tag & TMP & TMP & literal \\
- ref-style & & \lstinline=\sffamily= & macro \\\midrule
+ ref-style & & \verb=\sffamily= & macro \\\midrule
init-strict & true & false & boolean \\
init-sub & true & false & boolean \\
init-input-sep & , & , & literal \\\midrule
@@ -1006,22 +965,23 @@ In this section all commands provided by \chemnum as well as their variants are
\begin{center}
\label{tab:commands}
\begin{tabu*} to \linewidth {X[l]X[p]}\toprule
- \bfseries command & \bfseries description \tabularnewline\midrule
- \cmd*{cmpd}[<keyval>]{<labels>} & basic command, declares and prints labels or lists of labels, see pages \pageref{sec:nummerieren}ff. \tabularnewline
- \cmd*[cmpda]{cmpd*}{<labels>} & invisible, declares label, see page \pageref{cmd:unsichtbares_label} \tabularnewline
- \cmd*[cmpdc]{cmpd-}[<keyval>]{<labels>} & without delimiters, see page \pageref{cmd:ohne_begrenzer} \tabularnewline
- \cmd*[cmpdd]{cmpd+-}[<keyval>]{<labels>} & label is read from auxiliary file, see page \pageref{cmd:cmpd_plus} \tabularnewline\midrule
- \cmd*{cmpdinit}[<keyval>]{<labels>} & initialise and declare labels, see pages \pageref{sec:cmpdinit}f. \tabularnewline
- \cmd*[cmpdinita]{cmpdinit*}[<keyval>]{<labels>} & initialise labels, see pages \pageref{sec:cmpdinit}f. \tabularnewline\midrule
- \cmd*{cmpdref}[<keyval>][<marker>]{<label>} & replace temporary markers in \texttt{eps} files by labels, see page \pageref{ssec:cmpdref} \tabularnewline
- \cmd*[cmpdrefc]{cmpdref-}[<keyval>][<marker>]{<label>} & replace temporary markers in \texttt{eps} files by labels without delimiters, see page \pageref{cmd:ohne_begrenzer} \tabularnewline\midrule
- \cmd*{cmpdreset}[<num>] & reset counter, siehe page \pageref{sec:cmpdreset} \tabularnewline\midrule
- \cmd*{cmpdsetup}{<keyval>} & setup \chemnum, siehe pages \pageref{sec:cmpdsetup}ff. \tabularnewline\bottomrule
+ \bfseries command & \bfseries description \tabularnewline\midrule
+ \cmd*{cmpd}[<keyval>]{<labels>} & basic command, declares and prints labels or lists of labels, see pages \pageref{sec:nummerieren}ff. \tabularnewline
+ \cmd*[cmpda]{cmpd*}{<labels>} & invisible, declares label, see page \pageref{cmd:unsichtbares_label} \tabularnewline
+ \cmd*[cmpdc]{cmpd-}[<keyval>]{<labels>} & without delimiters, see page \pageref{cmd:ohne_begrenzer} \tabularnewline
+ \cmd*[cmpdd]{cmpd+-}[<keyval>]{<labels>} & label is read from auxiliary file, see page \pageref{cmd:cmpd_plus} \tabularnewline\midrule
+ \cmd*{cmpdinit}[<keyval>]{<labels>} & initialise and declare labels, see pages \pageref{sec:cmpdinit}f. \tabularnewline
+ \cmd*[cmpdinita]{cmpdinit*}[<keyval>]{<labels>} & initialise labels, see pages \pageref{sec:cmpdinit}f. \tabularnewline\midrule
+ \cmd*{cmpdref}[<keyval>]\oa[<marker>]\ma{<label>} & replace temporary markers in \texttt{eps} files by labels, see page \pageref{ssec:cmpdref} \tabularnewline
+ \cmd*[cmpdrefc]{cmpdref-}[<keyval>]\oa[<marker>]\ma{<label>} & replace temporary markers in \texttt{eps} files by labels without delimiters, see page \pageref{cmd:ohne_begrenzer} \tabularnewline\midrule
+ \cmd*{cmpdreset}[<num>] & reset counter, siehe page \pageref{sec:cmpdreset} \tabularnewline\midrule
+ \cmd*{cmpdsetup}{<keyval>} & setup \chemnum, siehe pages \pageref{sec:cmpdsetup}ff. \tabularnewline\bottomrule
\end{tabu*}
\end{center}
-\section{Credits}
-I would like to thank Joseph \textsc{Wright} and Russell \textsc{Hewitt} who provided me with valuable feedback and suggestions to improve \chemnum.
+\appendix
+\addsec{Credits}
+I would like to thank Joseph \name{Wright} and Russell \name{Hewitt} who provided me with valuable feedback and suggestions to improve \chemnum.
\printindex
diff --git a/Master/texmf-dist/tex/latex/chemnum/chemnum.sty b/Master/texmf-dist/tex/latex/chemnum/chemnum.sty
index a8dd423aaae..ce0a076fea1 100644
--- a/Master/texmf-dist/tex/latex/chemnum/chemnum.sty
+++ b/Master/texmf-dist/tex/latex/chemnum/chemnum.sty
@@ -1,41 +1,38 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% - chemnum - chemnum.sty - %
-% - a comprehensive approach for the numbering of chemical compounds - %
-% --------------------------------------------------------------------------- %
-% - Clemens NIEDERBERGER - %
-% - 2012/02/26 - %
-% --------------------------------------------------------------------------- %
-% - http://www.mychemistry.eu/ - %
-% - contact@mychemistry.eu - %
-% --------------------------------------------------------------------------- %
-% - If you have any ideas, questions, suggestions or bugs to report, please - %
-% - feel free to contact me. - %
-% --------------------------------------------------------------------------- %
-% - Copyright 2011-2012 Clemens Niederberger - %
-% - - %
-% - This work may be distributed and/or modified under the - %
-% - conditions of the LaTeX Project Public License, either version 1.3 - %
-% - of this license or (at your option) any later version. - %
-% - The latest version of this license is in - %
-% - http://www.latex-project.org/lppl.txt - %
-% - and version 1.3 or later is part of all distributions of LaTeX - %
-% - version 2005/12/01 or later. - %
-% - - %
-% - This work has the LPPL maintenance status `maintained'. - %
-% - - %
-% - The Current Maintainer of this work is Clemens Niederberger. - %
-% - - %
-% - This work consists of the files chemnum.sty, chemnum_doc_de.tex, - %
-% - chemnum_doc_en.tex, chemnum-codehelper.tex, scheme-tmp.eps, - %
-% - scheme-bla.eps, README and the derived files chemnum_doc_de.pdf and - %
-% - chemnum_doc_en.pdf - %
+% - chemnum - chemnum.sty
+% - a comprehensive approach for the numbering of chemical compounds
+% -----------------------------------------------------------------------------
+% - Clemens NIEDERBERGER
+% - 2012/04/15
+% - contact@mychemistry.eu
+% -----------------------------------------------------------------------------
+% - If you have any ideas, questions, suggestions or bugs to report, please
+% - feel free to contact me.
+% -----------------------------------------------------------------------------
+% - Copyright 2011-2012 Clemens Niederberger
+% -
+% - This work may be distributed and/or modified under the
+% - conditions of the LaTeX Project Public License, either version 1.3
+% - of this license or (at your option) any later version.
+% - The latest version of this license is in
+% - http://www.latex-project.org/lppl.txt
+% - and version 1.3 or later is part of all distributions of LaTeX
+% - version 2005/12/01 or later.
+% -
+% - This work has the LPPL maintenance status `maintained'.
+% -
+% - The Current Maintainer of this work is Clemens Niederberger.
+% -
+% - This work consists of the files chemnum.sty, chemnum_de.tex, chemnum_en.tex,
+% - chemnum-codehelper.tex, scheme-tmp.eps, scheme-bla.eps, README and the
+% - derived files chemnum_de.pdf and chemnum_en.pdf
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\RequirePackage { expl3 , xparse , l3keys2e , etoolbox , psfrag }
\ProvidesExplPackage
{chemnum}
- {2012/02/26}
- {0.4a}
+ {2012/04/15}
+ {0.4b}
{An approach for the numbering of chemical compounds}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -1457,8 +1454,11 @@
{
\tl_set:Nn \l_chemnum_cmpdref_tl { #3 }
}
- \IfNoValueTF { #2 }
+ \IfNoValueTF { #2 }
{
+ % need to call it once invisible in case it's the first time the label
+ % is called. Somehow it otherwise “vanishes” inside \psfrag
+ \cmpd_main_command:w * { #4 }
\psfrag { \l_chemnum_cmpdref_tl } [ b ] [ b ]
{
\group_begin:
@@ -1469,6 +1469,7 @@
}
}
{
+ \cmpd_main_command:w * [ #2 ] { #4 }
\psfrag { \l_chemnum_cmpdref_tl } [ b ] [ b ]
{
\group_begin:
@@ -1605,8 +1606,10 @@ HISTORY:
- new key: "ref-style"
- documentation got an index
2012/02/22 version 0.4a - corrected outdated expl3 function
+ 2012/04/15 version 0.4b - bugfix in \cmpdref
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% TODO:
+ - add a possibility to \ref{} the compounds
- (rudimentäre) Unterstützung für hyperref und pdfstrings
- polyglossia: localization of us-variant of english
- Bug: Key "cmpd-style" wenn zB \color{<farbe>} eingegeben: Fehler beim Test