summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-12-22 00:05:19 +0000
committerKarl Berry <karl@freefriends.org>2010-12-22 00:05:19 +0000
commit01cfc3264298d1b9982c3955ff58a3f7b593d7b5 (patch)
treeab8540e0b8468d44c4a22e4ad8b5be3d3233d441 /Master
parent4d94830abaa19630ce446cf73cd5d2dca75dfc2f (diff)
ydoc (21dec10)
git-svn-id: svn://tug.org/texlive/trunk@20823 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/ydoc/ydoc.pdfbin634366 -> 521643 bytes
-rw-r--r--Master/texmf-dist/source/latex/ydoc/ydoc.dtx89
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc-code.sty30
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc-desc.sty31
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc-doc.sty12
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc-expl.sty4
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc.cls4
-rw-r--r--Master/texmf-dist/tex/latex/ydoc/ydoc.sty4
8 files changed, 131 insertions, 43 deletions
diff --git a/Master/texmf-dist/doc/latex/ydoc/ydoc.pdf b/Master/texmf-dist/doc/latex/ydoc/ydoc.pdf
index 720589586e5..d971cd1ef64 100644
--- a/Master/texmf-dist/doc/latex/ydoc/ydoc.pdf
+++ b/Master/texmf-dist/doc/latex/ydoc/ydoc.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/ydoc/ydoc.dtx b/Master/texmf-dist/source/latex/ydoc/ydoc.dtx
index 9335c986862..757c6372374 100644
--- a/Master/texmf-dist/source/latex/ydoc/ydoc.dtx
+++ b/Master/texmf-dist/source/latex/ydoc/ydoc.dtx
@@ -35,8 +35,8 @@
%<expl> [ydoc-expl]
%<doc> [ydoc-doc]
%<*driver|class|package|code|desc|expl|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]
%</driver|class|package|code|desc|expl|doc>
%<class> [ydoc class: document LaTeX class and packages]
%<package> [ydoc package: document LaTeX class and packages]
@@ -65,6 +65,7 @@
\caption
}
+\hypersetup{colorlinks=true,linkcolor=green}
\begin{document}
\DocInput{ydoc.dtx}
\PrintChanges
@@ -73,7 +74,7 @@
%</driver>
% \fi
%
-% \CheckSum{1151}
+% \CheckSum{1237}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -394,6 +395,11 @@
%
% \subsection{Macros and Environments to document Implementations}
%
+% \begin{macrocode}
+\RequirePackage{hyperref}
+\hypersetup{colorlinks=true,pdfborder=0 0 0,pdfborderstyle={}}
+% \end{macrocode}
+%
% \subsubsection{Color and style definitions}
% \begin{macrocode}
\RequirePackage{xcolor}
@@ -586,7 +592,7 @@
% \begin{macro}{\macro@impl@argline}[2]{argument number}{argument description}
% \begin{macrocode}
\def\macro@impl@argline#1#2{%
- \par{\texttt{\##1}:~#2}%
+ \par{\texttt{\##1}:~#2\strut}%
}
% \end{macrocode}
% \end{macro}
@@ -608,7 +614,7 @@
% \begin{environment}{macro}[1]{implemented macro}
% \begin{macrocode}
\def\macro#1{%
- \PrintMacroImplName{#1}%
+ \PrintMacroImpl{#1}%
\@ifnextchar[%]
{\macro@impl@args}%
{}%
@@ -629,16 +635,37 @@
% \end{macrocode}
% \end{environment}
%
-% \begin{macro}{\PrintMacroImplName}[1]{macro (token)}
+% \begin{macro}{\PrintMacroImpl}[1]{macro (token)}
% \begin{macrocode}
-\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
}
% \end{macrocode}
% \end{macro}
%
+% \begin{macro}{\PrintMacroImplName}[1]{macro (token)}
+% \begin{macrocode}
+\def\PrintMacroImplName#1{%
+ \implstyle{\string#1\strut}%
+}
+% \end{macrocode}
+% \end{macro}
+%
% \begin{macro}{\PrintEnvImplName}[1]{environment name}
% test
% \begin{macrocode}
@@ -813,9 +840,16 @@
% \end{macro}
%
% \begin{macro}{\GetFileInfo}
+% Current implementation taken from \pkg{doc} package.
% \begin{macrocode}
\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
}
% \end{macrocode}
% \end{macro}
@@ -860,6 +894,11 @@
% \fi
% \subsection{Description Macros and Environments}
%
+% \begin{macrocode}
+\RequirePackage{hyperref}
+\hypersetup{colorlinks=true,pdfborder=0 0 0,pdfborderstyle={}}
+% \end{macrocode}
+%
% \subsubsection{Color and style definitions}
% \begin{macrocode}
\RequirePackage{xcolor}
@@ -998,19 +1037,26 @@
% \begin{macro}{\pkg}
% \begin{macro}{\cls}
% \begin{macro}{\env}
-% \begin{macro}{\cs}
% \begin{macro}{\opt}
% \begin{macrocode}
-\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}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
+%
+% \begin{macro}{\cs}
+% \begin{macro}{\cmd}
+% \begin{macrocode}
+\newrobustcmd*\cs[1]{\texttt{\textbackslash #1}}
+\newrobustcmd*\cmd[1]{\texttt{{\escapechar=92\string#1}}}
+% \end{macrocode}
+% \end{macro}
% \end{macro}
%
% \subsubsection{Text Formatting Styles}
@@ -1343,8 +1389,14 @@
% \begin{macrocode}
\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
}
@@ -1390,9 +1442,10 @@
% \begin{macrocode}
\newcommand*\MacroArgs{%
\begingroup
- \let\end@Macro@args\endgroup
+ \def\end@Macro@args{\endgroup\xspace}%
\read@Macro@arg
}
+\RequirePackage{xspace}
% \end{macrocode}
% \end{macro}
%
@@ -1617,7 +1670,7 @@
\def\PrintEnvName#1#2{%
\strut
\string#1\braceleft
- {\macrodescstyle#2}%
+ {\macrodescstyle#2\strut}%
\braceright
}
% \end{macrocode}
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}