diff options
author | Karl Berry <karl@freefriends.org> | 2010-12-22 00:05:19 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-12-22 00:05:19 +0000 |
commit | 01cfc3264298d1b9982c3955ff58a3f7b593d7b5 (patch) | |
tree | ab8540e0b8468d44c4a22e4ad8b5be3d3233d441 /Master/texmf-dist/tex/latex/ydoc | |
parent | 4d94830abaa19630ce446cf73cd5d2dca75dfc2f (diff) |
ydoc (21dec10)
git-svn-id: svn://tug.org/texlive/trunk@20823 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/ydoc')
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty | 30 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty | 31 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty | 12 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc.cls | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/ydoc/ydoc.sty | 4 |
6 files changed, 60 insertions, 25 deletions
diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty b/Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty index 2581ec83ec3..f07e180f963 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty @@ -29,9 +29,11 @@ \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackageSVN [ydoc-code] - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc package to document macro code] +\RequirePackage{hyperref} +\hypersetup{colorlinks=true,pdfborder=0 0 0,pdfborderstyle={}} \RequirePackage{xcolor} \definecolor{macroimpl}{rgb}{0.0,0.0,0.4} \@ifundefined{ydocwrite}{% @@ -152,7 +154,7 @@ \unskip\par\noindent\ignorespaces } \def\macro@impl@argline#1#2{% - \par{\texttt{\##1}:~#2}% + \par{\texttt{\##1}:~#2\strut}% } \def\macro@impl@arg#1{% \advance\macro@impl@curarg by\@ne\relax @@ -164,7 +166,7 @@ \fi } \def\macro#1{% - \PrintMacroImplName{#1}% + \PrintMacroImpl{#1}% \@ifnextchar[%] {\macro@impl@args}% {}% @@ -177,11 +179,27 @@ {}% } \def\endenvironment{} -\def\PrintMacroImplName#1{% +\def\PrintMacroImpl#1{% \par\bigskip\noindent - \hbox{\hspace*{\descindent}\fbox{{\implstyle{\string#1}}}}% + \hbox{% + \edef\name{\expandafter\@gobble\string#1}% + \global\@namedef{href@impl@\name}{}% + \immediate\write\@mainaux{% + \global\noexpand\@namedef{href@impl@\name}{}% + }% + \raisebox{4ex}[4ex]{\hypertarget{impl:\name}{}}% + \hspace*{\descindent}\fbox{% + \hspace*{\descsep}% + \@ifundefined{href@desc@\name}{}{\hyperlink{desc:\name}}% + {\PrintMacroImplName{#1}}% + \hspace*{\descsep}% + }% + }% \par\medskip\noindent } +\def\PrintMacroImplName#1{% + \implstyle{\string#1\strut}% +} \def\PrintEnvImplName#1{% \par\bigskip\noindent \hbox{\hspace*{\descindent}\fbox{{\implstyle{#1}}}}% diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty b/Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty index f921666ae5a..0a91285f3d4 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty @@ -29,9 +29,11 @@ \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackageSVN [ydoc-desc] - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc package to describe macros, environments, options etc.] +\RequirePackage{hyperref} +\hypersetup{colorlinks=true,pdfborder=0 0 0,pdfborderstyle={}} \RequirePackage{xcolor} \definecolor{macrodesc}{rgb}{0.0,0.0,0.8} \definecolor{macroimpl}{rgb}{0.0,0.0,0.4} @@ -87,11 +89,13 @@ }}% } \def\sarg{{\sargstyle{*}}} -\def\pkg{\texttt} -\def\cls{\texttt} -\def\env{\texttt} -\def\cs#1{\texttt{\textbackslash #1}} -\def\opt{\textsf} +\RequirePackage{etoolbox} +\newrobustcmd*\pkg{\texttt} +\newrobustcmd*\cls{\texttt} +\newrobustcmd*\env{\texttt} +\newrobustcmd*\opt{\textsf} +\newrobustcmd*\cs[1]{\texttt{\textbackslash #1}} +\newrobustcmd*\cmd[1]{\texttt{{\escapechar=92\string#1}}} \def\macrodescstyle{\ttfamily\bfseries\color{macrodesc}} \def\macroargsstyle{\ttfamily} \def\envcodestyle{\ttfamily} @@ -217,8 +221,14 @@ } \def\Describe@Macro#1{% \endgroup + \edef\name{\expandafter\@gobble\string#1}% + \global\@namedef{href@desc@\name}{}% + \immediate\write\@mainaux{% + \global\noexpand\@namedef{href@desc@\name}{}% + }% \hbox\y@bgroup - \PrintMacroName{#1}% + \@ifundefined{href@impl@\name}{}{\hyperlink{impl:\name}}% + {\hypertarget{desc:\name}{\PrintMacroName{#1}}}% \macroargsstyle \read@Macro@arg } @@ -238,9 +248,10 @@ } \newcommand*\MacroArgs{% \begingroup - \let\end@Macro@args\endgroup + \def\end@Macro@args{\endgroup\xspace}% \read@Macro@arg } +\RequirePackage{xspace} \def\DescribeMacros{% \begingroup \let\Macro\@Macro @@ -359,7 +370,7 @@ \def\PrintEnvName#1#2{% \strut \string#1\braceleft - {\macrodescstyle#2}% + {\macrodescstyle#2\strut}% \braceright } \def\PrintMacros{% diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty b/Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty index e6fef3e7ffc..78a8ff597a2 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty @@ -29,8 +29,8 @@ \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackageSVN [ydoc-doc] - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc package to provide 'doc' macros] \newcount\ydoc@bslashcnt \def\ydoc@countbslashes{% @@ -89,7 +89,13 @@ \PackageWarning{ydoc}{Cross references not implemented yet!}{}{}% } \providecommand*\GetFileInfo[1]{% - \PackageWarning{ydoc}{Get File Info not implemented yet!}{}{}% + \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\endcsname}% + \expandafter\@tempb\@tempa\relax? ? \relax\relax } \def\ydoc@checkchecksum{% \ifnum\ydoc@checksum=\m@ne diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty b/Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty index d8daf010426..0301d962437 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty @@ -29,8 +29,8 @@ \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackageSVN [ydoc-expl] - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc package to insert live examples of LaTeX code] \RequirePackage{listings} \lst@RequireAspects{writefile} diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc.cls b/Master/texmf-dist/tex/latex/ydoc/ydoc.cls index bbc121b7925..9792bbf100c 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc.cls +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc.cls @@ -27,8 +27,8 @@ %% \RequirePackage{svn-prov}[2010/04/03] \ProvidesClassSVN - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc class: document LaTeX class and packages] \LoadClassWithOptions{article} %%\RequirePackage{doc} diff --git a/Master/texmf-dist/tex/latex/ydoc/ydoc.sty b/Master/texmf-dist/tex/latex/ydoc/ydoc.sty index 08fce81ff34..5392103a998 100644 --- a/Master/texmf-dist/tex/latex/ydoc/ydoc.sty +++ b/Master/texmf-dist/tex/latex/ydoc/ydoc.sty @@ -28,8 +28,8 @@ \RequirePackage{svn-prov}[2010/04/03] \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackageSVN - {$Id: ydoc.dtx 1847 2010-04-10 10:57:11Z martin $} - [v0.1alpha] + {$Id: ydoc.dtx 1921 2010-12-20 21:55:39Z martin $} + [v0.3alpha] [ydoc package: document LaTeX class and packages] \RequirePackage{ydoc-code} \RequirePackage{ydoc-expl} |