texlive[43170] Master/texmf-dist: skdoc (8feb17)

commits+karl at tug.org commits+karl at tug.org
Wed Feb 8 23:19:13 CET 2017


Revision: 43170
          http://tug.org/svn/texlive?view=revision&revision=43170
Author:   karl
Date:     2017-02-08 23:19:13 +0100 (Wed, 08 Feb 2017)
Log Message:
-----------
skdoc (8feb17)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/skdoc/README
    trunk/Master/texmf-dist/doc/latex/skdoc/skdoc.pdf
    trunk/Master/texmf-dist/source/latex/skdoc/skdoc.dtx
    trunk/Master/texmf-dist/tex/latex/skdoc/skdoc.cls

Modified: trunk/Master/texmf-dist/doc/latex/skdoc/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/skdoc/README	2017-02-08 22:19:00 UTC (rev 43169)
+++ trunk/Master/texmf-dist/doc/latex/skdoc/README	2017-02-08 22:19:13 UTC (rev 43170)
@@ -1,6 +1,6 @@
 %% skdoc documentation class
 %%
-%% Copyright (C) 2012-2016 by Simon Sigurdhsson <sigurdhsson at gmail.com>
+%% Copyright (C) 2012-2017 by Simon Sigurdhsson <sigurdhsson at gmail.com>
 %%
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either version 1.3
@@ -17,7 +17,7 @@
 %% This work consists of the files skdoc.dtx
 %% and the derived filebase skdoc.cls.
 
-This is version 1.4b of the skdoc document class. It is designed to
+This is version 1.5 of the skdoc document class. It is designed to
 generate both documentation and derivative files using only LaTeX,
 i.e. without using docstrip and ins/dtx files.
 

Modified: trunk/Master/texmf-dist/doc/latex/skdoc/skdoc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/skdoc/skdoc.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/skdoc/skdoc.dtx	2017-02-08 22:19:00 UTC (rev 43169)
+++ trunk/Master/texmf-dist/source/latex/skdoc/skdoc.dtx	2017-02-08 22:19:13 UTC (rev 43170)
@@ -1,7 +1,7 @@
 % \iffalse
 %% skdoc documentation class
 %%
-%% Copyright (C) 2012-2016 by Simon Sigurdhsson <sigurdhsson at gmail.com>
+%% Copyright (C) 2012-2017 by Simon Sigurdhsson <sigurdhsson at gmail.com>
 %%
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either version 1.3
@@ -73,7 +73,7 @@
 %</driver>
 %<class>\ProvidesExplClass{skdoc}
 %<*class>
-    {2017/01/08}{1.4b}{skdoc documentation class}
+    {2017/02/07}{1.5}{skdoc documentation class}
 %</class>
 %
 %<*driver>
@@ -132,7 +132,7 @@
 % {}{\small\pagemark}
 % \pagestyle{skdoc-class}
 %
-% \version{1.4b}
+% \version{1.5}
 % \changes{1.0}{Initial version}
 % \changes{1.1}{Added support for syntax highlighting using \pkg{minted}}
 % \changes{1.1a}{Deprecate the use of \pkg{bibtex} in favour of \pkg{biblatex}}
@@ -143,6 +143,7 @@
 % \changes{1.4}{Added option to control \pkg{babel}. Allow optional default value arguments in \env{macro} and friends. Fix spacing issue in \env{option} and friends}
 % \changes{1.4a}{Fix various compatibility issues with latest \pkg{glossaries}}
 % \changes{1.4b}{Track \pkg{expl3} changes (thanks to Joseph Wright)}
+% \changes{1.5}{Fix incompatibilities with \pkg{minted}}
 % \iffalse
 %%% Don't forget to update the version number and release date of
 %%% the package declaration on line 76!
@@ -738,12 +739,21 @@
 % \section{Known issues}
 % A list of current issues is available in the Github repository of this
 % package\footnote{\url{https://github.com/urdh/skdoc/issues}}, but as
-% of the release of \theversion, there are no known issues.
-% \iffalse
+% of the release of \theversion, there are two known issues.
 % \begin{description}
-%   \item[\#?]  ???
+%   \item[\#30]  The use of \pkg{expl3}-style macros in \cs{cs} may cause
+%     issues when generating a glossary. Since such macros are in general
+%     implementation details, a workaround may be to omit the
+%     implementation from the output by using \cs{OnlyDescription}.
+%   \item[\#34]  When generating examples utilizing the documented package,
+%     if a previous version of this package is installed on the machine
+%     where this generation is done, the installed version will be used
+%     instead of the version being documented. This may cause incorrect
+%     output or compiler errors. A workaround is to temporarily remove
+%     the installed version while generating documentation for the more
+%     recent version.
 % \end{description}
-% \fi
+%
 % If you discover any bugs in this package, please report them to the
 % issue tracker in the \thepackage\ Github repository.
 %
@@ -1011,6 +1021,15 @@
         \__skdoc_if_shellescape:TF{
             \__skdoc_if_pygmentize:TF{
                 \bool_gset_true:N\g__skdoc_use_minted_bool
+%    \end{macrocode}
+% Since \pkg{minted} (through \pkg{fancyvrb}) loads \pkg{lineno}, and something
+% above already defines \cs{c at linenumber}, we have to resort to a bit of a hack
+% before we actually load \pkg{minted}.
+%    \begin{macrocode}
+                \cs_undefine:N\c at linenumber
+                \cs_undefine:N\cl at linenumber
+                \cs_undefine:N\p at linenumber
+                \cs_undefine:N\thelinenumber
                 \RequirePackage{minted}
 %    \end{macrocode}
 % Now that we have \pkg{minted}, we redefine the style of the line
@@ -1032,7 +1051,6 @@
 % \texttt{pygmentize -S default -f html}), but it's not entirely
 % apparent which macro corresponds to what entity.
 %    \begin{macrocode}
-                \renewcommand\minted at usedefaultstyle{}
                 \def\PY at reset{\let\PY at it=\relax \let\PY at bf=\relax%
                     \let\PY at ul=\relax \let\PY at tc=\relax%
                     \let\PY at bc=\relax \let\PY at ff=\relax}
@@ -1245,7 +1263,7 @@
         \tl_set:Nx\l_tmpa_tl{\skdoc at preamble}
         \edef\skdoc at temp{\tl_head:N\l_tmpa_tl}
         \def\skdoc at preamble@extra{
-            \skdoc at temp\skdoc at temp\space~This~is~file~`#2',~generated~from~`\c_sys_jobame_str.tex'~(key~`\skdoc at key').
+            \skdoc at temp\skdoc at temp\space~This~is~file~`#2',~generated~from~`\c_sys_jobname_str.tex'~(key~`\skdoc at key').
         }
     }
     \expandafter\xdef\csname skdoc at write@#2\endcsname{%
@@ -1301,13 +1319,12 @@
 % If we're using \pkg{minted}, we set a few options ans open the
 % output file.
 %    \begin{macrocode}
-            \minted at resetoptions%
-            \exp_args:Nnx\setkeys{minted at opt}{
-                \int_compare:nNnF{\clist_count:N\l__skdoc_keys}>\c_one{
-                    \bool_if:NF\g__skdoc_in_example_bool{linenos,}
-                    firstnumber=\int_use:c{skdoc at output@#1 at line}
-                }
+            \bool_if:NF\g__skdoc_in_example_bool{
+                \setkeys{minted at opt@g}{linenos}
             }%
+            \exp_args:Nnx\setkeys{FV}{
+                firstnumber=\int_use:c{skdoc at output@#1 at line}
+            }%
             \iow_open:Nn\minted at code{\jobname.pyg}%
             \Needspace*{2\baselineskip}%
         }{
@@ -1508,10 +1525,11 @@
 % \end{macro}
 % \begin{macro}{\SelfPreambleTo}[1]
 %   {A token to which we will save the preamble}
+% \changes{1.4c}{Fix mis-spelling of \cs{c_sys_jobname_str}}
 % Shorthand to read preamble from current document.
 %    \begin{macrocode}
 \DeclareDocumentCommand\SelfPreambleTo{m}{%
-    \PreambleTo{#1}{\c_sys_jobame_str}%
+    \PreambleTo{#1}{\c_sys_jobname_str}%
 }
 %    \end{macrocode}
 % \end{macro}
@@ -3016,11 +3034,12 @@
 % \end{macro}
 % \begin{macro}{\Warning}[1]
 %   {Warning text}
+% \changes{1.5}{Fix spacing to consider \cs{fboxsep} and \cs{fboxrule}}
 %    \begin{macrocode}
 \DeclareDocumentCommand\Warning{+m}{
     \vspace{\baselineskip}
     \par\noindent
-    \fbox{\begin{minipage}[c]{\textwidth}
+    \fbox{\begin{minipage}[c]{\textwidth-2\fboxsep-2\fboxrule}
         \centering
         \textbf{Warning:}~#1
     \end{minipage}}
@@ -3031,11 +3050,12 @@
 % \end{macro}
 % \begin{macro}{\LongWarning}[1]
 %   {Warning text}
+% \changes{1.5}{Fix spacing to consider \cs{fboxsep} and \cs{fboxrule}}
 %    \begin{macrocode}
 \DeclareDocumentCommand\LongWarning{+m}{
     \Warning{
         \par\noindent
-        \begin{minipage}{\textwidth}
+        \begin{minipage}{\textwidth-2\fboxsep-2\fboxrule}
             #1
         \end{minipage}
     }
@@ -3048,9 +3068,9 @@
 % We redefine both, inspired slightly by the Prac\TeX\ journal and the
 % \pkg{skrapport} document class.
 % \begin{macro}{\@maketitle}
+% \changes{1.5}{Get rid of a superfluous \cs{newpage}}
 %    \begin{macrocode}
 \def\@maketitle{%
-    \newpage
     \null
     \begin{flushleft}%
     {%

Modified: trunk/Master/texmf-dist/tex/latex/skdoc/skdoc.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/skdoc/skdoc.cls	2017-02-08 22:19:00 UTC (rev 43169)
+++ trunk/Master/texmf-dist/tex/latex/skdoc/skdoc.cls	2017-02-08 22:19:13 UTC (rev 43170)
@@ -8,7 +8,7 @@
 %% 
 %% skdoc documentation class
 %%
-%% Copyright (C) 2012-2016 by Simon Sigurdhsson <sigurdhsson at gmail.com>
+%% Copyright (C) 2012-2017 by Simon Sigurdhsson <sigurdhsson at gmail.com>
 %%
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either version 1.3
@@ -26,7 +26,7 @@
 %% and the derived filebase skdoc.cls.
 \RequirePackage{expl3}
 \ProvidesExplClass{skdoc}
-    {2017/01/08}{1.4b}{skdoc documentation class}
+    {2017/02/07}{1.5}{skdoc documentation class}
 \PassOptionsToPackage{log-declarations=false}{xparse}
 \LoadClass[ DIV7,
             headings=big,
@@ -125,12 +125,15 @@
         \__skdoc_if_shellescape:TF{
             \__skdoc_if_pygmentize:TF{
                 \bool_gset_true:N\g__skdoc_use_minted_bool
+                \cs_undefine:N\c at linenumber
+                \cs_undefine:N\cl at linenumber
+                \cs_undefine:N\p at linenumber
+                \cs_undefine:N\thelinenumber
                 \RequirePackage{minted}
                 \renewcommand{\theFancyVerbLine}{
                     \sffamily\tiny\textcolor{lightgray}{
                     \oldstylenums{\arabic{FancyVerbLine}}}
                 }
-                \renewcommand\minted at usedefaultstyle{}
                 \def\PY at reset{\let\PY at it=\relax \let\PY at bf=\relax%
                     \let\PY at ul=\relax \let\PY at tc=\relax%
                     \let\PY at bc=\relax \let\PY at ff=\relax}
@@ -326,7 +329,7 @@
         \tl_set:Nx\l_tmpa_tl{\skdoc at preamble}
         \edef\skdoc at temp{\tl_head:N\l_tmpa_tl}
         \def\skdoc at preamble@extra{
-            \skdoc at temp\skdoc at temp\space~This~is~file~`#2',~generated~from~`\c_sys_jobame_str.tex'~(key~`\skdoc at key').
+            \skdoc at temp\skdoc at temp\space~This~is~file~`#2',~generated~from~`\c_sys_jobname_str.tex'~(key~`\skdoc at key').
         }
     }
     \expandafter\xdef\csname skdoc at write@#2\endcsname{%
@@ -354,13 +357,12 @@
     }
     \__skdoc_if_print_code:T{
         \bool_if:NTF\g__skdoc_use_minted_bool{
-            \minted at resetoptions%
-            \exp_args:Nnx\setkeys{minted at opt}{
-                \int_compare:nNnF{\clist_count:N\l__skdoc_keys}>\c_one{
-                    \bool_if:NF\g__skdoc_in_example_bool{linenos,}
-                    firstnumber=\int_use:c{skdoc at output@#1 at line}
-                }
+            \bool_if:NF\g__skdoc_in_example_bool{
+                \setkeys{minted at opt@g}{linenos}
             }%
+            \exp_args:Nnx\setkeys{FV}{
+                firstnumber=\int_use:c{skdoc at output@#1 at line}
+            }%
             \iow_open:Nn\minted at code{\jobname.pyg}%
             \Needspace*{2\baselineskip}%
         }{
@@ -476,7 +478,7 @@
     \group_end:
 }
 \DeclareDocumentCommand\SelfPreambleTo{m}{%
-    \PreambleTo{#1}{\c_sys_jobame_str}%
+    \PreambleTo{#1}{\c_sys_jobname_str}%
 }
 \definecolorset{RGB}{}{}{
     section,11,72,107;
@@ -1265,7 +1267,7 @@
 \DeclareDocumentCommand\Warning{+m}{
     \vspace{\baselineskip}
     \par\noindent
-    \fbox{\begin{minipage}[c]{\textwidth}
+    \fbox{\begin{minipage}[c]{\textwidth-2\fboxsep-2\fboxrule}
         \centering
         \textbf{Warning:}~#1
     \end{minipage}}
@@ -1275,13 +1277,12 @@
 \DeclareDocumentCommand\LongWarning{+m}{
     \Warning{
         \par\noindent
-        \begin{minipage}{\textwidth}
+        \begin{minipage}{\textwidth-2\fboxsep-2\fboxrule}
             #1
         \end{minipage}
     }
 }
 \def\@maketitle{%
-    \newpage
     \null
     \begin{flushleft}%
     {%



More information about the tex-live-commits mailing list