diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx | 59 |
1 files changed, 37 insertions, 22 deletions
diff --git a/Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx b/Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx index 63acb86cee1..422fa674dcc 100644 --- a/Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx +++ b/Master/texmf-dist/source/latex/stex/reqdoc/reqdoc.dtx @@ -26,19 +26,18 @@ \usepackage[hyperref=auto,style=alphabetic]{biblatex} \bibliography{kwarc} \usepackage[eso-foot,today,draft]{svninfo} +\svnInfo $Id: reqdoc.dtx 1671 2010-11-06 07:05:15Z kohlhase $ +\svnKeyword $HeadURL: https://svn.kwarc.info/repos/stex/trunk/sty/reqdoc/reqdoc.dtx $ \usepackage{stex-logo} \usepackage{../ctansvn} \usepackage{hyperref} \makeindex -\begin{document} -\svnInfo $Id: reqdoc.dtx 1502 2010-07-20 08:17:00Z kohlhase $ -\svnKeyword $HeadURL: https://svn.kwarc.info/repos/stex/trunk/sty/reqdoc/reqdoc.dtx $ -\DocInput{reqdoc.dtx} -\end{document} +\def\tracissue#1{\cite{sTeX:online}, \hyperlink{http://trac.kwarc.info/sTeX/ticket/#1}{issue #1}} +\begin{document}\DocInput{reqdoc.dtx}\end{document} %</driver> % \fi % -%\CheckSum{195} +%\iffalse\CheckSum{195}\fi % % \changes{v0.3}{2008/06/26}{Integrated LaTeXML bindings} % \changes{v0.2}{2008/02/04}{First Version with Documentation} @@ -81,7 +80,9 @@ % The |reqdoc| package takes the package option \DescribeMacro{recorddeps}|recorddeps|. If % this is given, then the package generates an external file with dependencies that can be % used by external systems like the {\texttt{locutor}} system\ednote{add citation here}, -% see Section~\ref{sec:moc-deps}. +% see Section~\ref{sec:moc-deps}. If the \DescribeMacro{showmeta}|showmeta| is set, then +% the metadata keys are shown (see~\cite{Kohlhase:metakeys:ctan} for details and customization +% options). % % \subsection{Requirements} % The |reqdoc| package supplies two forms of writing down requirements that mainly differ @@ -111,6 +112,16 @@ % \meta{doc}, then we will need to know about their representations and can import the % necessary information via |\importreqs{|\meta{doc}|}|. % +% +% \section{Limitations}\label{sec:limitations} +% +% In this section we document known limitations. If you want to help alleviate them, +% please feel free to contact the package author. Some of them are currently discussed in +% the \sTeX TRAC~\cite{sTeX:online}. +% \begin{compactenum} +% \item none reported yet +% \end{compactenum} +% % \StopEventually{\newpage\PrintIndex\newpage\PrintChanges\printbibliography} % \newpage % @@ -125,10 +136,13 @@ % % \subsection{Package Options}\label{sec.impl.options} % -% We first introduce the single option |recorddeps| which comes with its own switch |\if@deps| -% +% We declare some switches which will modify the behavior according to the package +% options. Generally, an option |xxx| will just set the appropriate switches to true +% (otherwise they stay false).\ednote{need an implementation for {\latexml}} +% % \begin{macrocode} %<*package> +\DeclareOption{showmeta}{\PassOptionsToPackage{\CurrentOption}{metakeys}} \newif\if@deps\@depsfalse \DeclareOption{recorddeps}{\@depstrue} \ProcessOptions @@ -161,11 +175,11 @@ RegisterDocumentNamespace('r'=>"http://omdoc.org/ontology/requirements#"); % \begin{macrocode} %<*package> \newif\ifreqsnum\reqsnumfalse -\omdaddkey{reqs}{numbering} -\omdaddkey[R]{reqs}{prefix} +\addmetakey{reqs}{numbering} +\addmetakey[R]{reqs}{prefix} \def\reqs@no{no} \newenvironment{requirements}[1][]% -{\omdsetkeys{reqs}{#1}\ifx\reqs@numbering\reqs@no\reqsnumfalse\else\reqsnumtrue\fi}{} +{\metasetkeys{reqs}{#1}\ifx\reqs@numbering\reqs@no\reqsnumfalse\else\reqsnumtrue\fi}{} %</package> %<*ltxml> DefEnvironment('{requirements} OptionalKeyVals:reqs', @@ -174,15 +188,15 @@ DefEnvironment('{requirements} OptionalKeyVals:reqs', % \end{macrocode} % \end{environment} % -% We define a group of keywords using the |\omdaddkey| command from the |omd| -% package~\ctancite{Kohlhase:omd}. The group below, named as |req|, consists of three +% We define a group of keywords using the |\addmetakey| command from the |metakeys| +% package~\ctancite{Kohlhase:metakeys}. The group below, named as |req|, consists of three % keywords |id|, |prio| and |refs|. % \begin{macrocode} %<*package> -\omdaddkey{req}{id} -\omdaddkey{req}{prio} -\omdaddkey{req}{refs} -\omdaddkey{req}{num} +\addmetakey{req}{id} +\addmetakey{req}{prio} +\addmetakey{req}{refs} +\addmetakey{req}{num} \newcounter{reqnum}[section] % \end{macrocode} % This function cycles over a comma-separated list and does the references @@ -238,7 +252,7 @@ DefEnvironment('{requirements} OptionalKeyVals:reqs', % \begin{environment}{requirement} % \begin{macrocode} \newenvironment{requirement}[1][]% -{\omdsetkeys{req}{#1}\stepcounter{reqnum} +{\metasetkeys{req}{#1}\stepcounter{reqnum} \ifreqsnum\ifx\req@id\@empty\else\req@def\req@id{number}\thereqnum\fi \noindent\textbf{\print@req@label}\fi \newcommand{\reqnote}[1]{\par\noindent Note: ##1} @@ -261,7 +275,7 @@ DefConstructor('\reqnote{}', % \begin{environment}{reqtable} % \begin{macrocode} %<*package> -\newenvironment{reqtable}[1][]{\omdsetkeys{reqs}{#1} +\newenvironment{reqtable}[1][]{\metasetkeys{reqs}{#1} \begin{center}\begin{longtable}{|l|l|p{6cm}|p{5cm}|l|}\hline \# & Prio & Requirement & Notes & Refs\\\hline\hline} {\end{longtable}\end{center}} @@ -277,7 +291,7 @@ DefEnvironment('{reqtable} OptionalKeyVals:reqs', % \begin{macrocode} %<*package> \newcommand{\reqline}[3][]% -{\omdsetkeys{req}{#1}\stepcounter{reqnum} +{\metasetkeys{req}{#1}\stepcounter{reqnum} \req@def\req@id{number}\thereqnum% remember the number for reference \textbf{\sref@target@ifh\req@id{\reqs@prefix\arabic{reqnum}}}& \req@prio &\req@do@refs\req@refs{,}\tabularnewline\hline} @@ -363,10 +377,11 @@ DefMacro('\rinput','\input'); % LocalWords: recorddeps moc-deps DescribeEnv prio reqs reqtable reqtable deps % LocalWords: reqline importreqs printbibliography sec.impl textsf langle ifx % LocalWords: textsf langle ltxml newif depsfalse depstrue longtable ifreqsnum -% LocalWords: reqsnumfalse omdaddkey newenvironment omdsetkeys reqsnumtrue omd +% LocalWords: reqsnumfalse newenvironment reqsnumtrue omd % LocalWords: OptionalKeyVals omdoc omgroup ctancite req newcounter reqnum % LocalWords: tmpop tmpop csname xdef endcsname expandafter auxout thesection % LocalWords: hfill thereqnum reqnote stepcounter noindent textbf newcommand % LocalWords: medskip omtext texttype hline tabularnewline makeatletter rinput % LocalWords: makeatother sinput stex ifdeps bgroup egroup newwrite depfile % LocalWords: openout jobname.deps renewcommand requiremodules gdef defs defs +% LocalWords: showmeta showmeta metakeys addmetakey metasetkeys |