summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-05-05 00:43:11 +0000
committerKarl Berry <karl@freefriends.org>2012-05-05 00:43:11 +0000
commit89b1dfc56201edac22f15c19f5d07f82c73e32e1 (patch)
tree8607158a8c30722719df485e2530408d3dbc197d
parent5b852adc46478e5d637ab87cc7045a9bf33a33d9 (diff)
chess-problem-diagrams (1may12)
git-svn-id: svn://tug.org/texlive/trunk@26206 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/chess-problem-diagrams/README2
-rw-r--r--Master/texmf-dist/doc/latex/chess-problem-diagrams/diagram.pdfbin315409 -> 318364 bytes
-rw-r--r--Master/texmf-dist/source/latex/chess-problem-diagrams/diagram.dtx86
-rw-r--r--Master/texmf-dist/tex/latex/chess-problem-diagrams/diagram.sty35
4 files changed, 94 insertions, 29 deletions
diff --git a/Master/texmf-dist/doc/latex/chess-problem-diagrams/README b/Master/texmf-dist/doc/latex/chess-problem-diagrams/README
index c709cd74317..73020382014 100644
--- a/Master/texmf-dist/doc/latex/chess-problem-diagrams/README
+++ b/Master/texmf-dist/doc/latex/chess-problem-diagrams/README
@@ -1,5 +1,5 @@
diagram --- A package for typesetting chessproblems
-Version 1.5.4 / Stefan Hoening 2010
+Version 1.6 / Stefan Hoening 2012
CONTENTS
diff --git a/Master/texmf-dist/doc/latex/chess-problem-diagrams/diagram.pdf b/Master/texmf-dist/doc/latex/chess-problem-diagrams/diagram.pdf
index 8424944c9cf..3c8df75dfc6 100644
--- a/Master/texmf-dist/doc/latex/chess-problem-diagrams/diagram.pdf
+++ b/Master/texmf-dist/doc/latex/chess-problem-diagrams/diagram.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/chess-problem-diagrams/diagram.dtx b/Master/texmf-dist/source/latex/chess-problem-diagrams/diagram.dtx
index 9036582e0fa..2dad0f501bc 100644
--- a/Master/texmf-dist/source/latex/chess-problem-diagrams/diagram.dtx
+++ b/Master/texmf-dist/source/latex/chess-problem-diagrams/diagram.dtx
@@ -13,9 +13,9 @@
%%
%%
% \fi
-% \def\fileversion{1.5.4}
-% \def\docdate{2011/06/04}
-% \CheckSum{4022}
+% \def\fileversion{1.6}
+% \def\docdate{2012/04/30}
+% \CheckSum{4046}
% \changes{v0.1}{15 Februar 2004}{First Version}
% \changes{v0.2}{23 Februar 2004}{Added the documentation for the
% {\itshape information collecting} macros which may be used
@@ -44,6 +44,15 @@
% stylefiles for the part over the diagram without influencing
% the one used for the solution. Added commands to set white,
% black and neutral Circles within text.}
+% \changes{v1.5.5}{01 July 2011}{Changed amount of lowering
+% figurine pieces.}
+% \changes{v1.5.6}{09 August 2011}{Added new command
+% 'solpar' to allow use
+% of 'putsol' inside a window environment.}
+% \changes{v1.6}{30 April 2012}{Added boolean showcity and code
+% to suppress display of city, when showcity is false. Added
+% commands for academic titles, which allow to suppress their
+% display.}
%
% \DoNotIndex{\@arabic,\def,\@idxitem,\@ifnextchar,\@ifstar,
% \@ne,\@ptsize,\ ,\advance,\AtEndOfPackage,\begin,\begingroup,
@@ -191,6 +200,12 @@
% |\reversednames|. This \verb+\author+ command does only
% overwrite the default behaviour when used inside a diagram
% environment.
+% \item \DescribeMacro{\Dr} \DescribeMacro{\Prof}
+% \DescribeMacro{\ProfDr}
+% Within the Authors command you should use the commands |\Dr|,
+% |\Prof| and |\ProfDr| to specify these academic titles. So one
+% may switch of the display of these titles --- like it is
+% generally done inside \Schwalbe.
% \item \DescribeMacro{\pieces}
% With |\pieces| you specify the position to be displayed on the
% board. For each kind of piece you may specify a list of fields.
@@ -225,7 +240,8 @@
% may be used to specify the city and country, where the author
% or the authors live. I use this inside the original section of
% \Schwalbe. You should separate multiple cities (for multiple
-% authors) with ";~".
+% authors) with ";~". There is also a boolean switch |showcity|,
+% which contols, whether this information is displayed.
% \item \DescribeMacro{\specialdiagnum}
% May be used to suppress the default diagram numbering (which
% uses a counter) and instead directly providing a diagram
@@ -395,6 +411,14 @@
% value may be changed using |\setboolean{showcomputer}{true}| or
% |\setboolean{showcomputer}{false}| For backwards compatiblity
% we support the macros |\nocomputer| and |\showcomputer|.
+% \item \DescribeMacro{showcity}
+% This is a boolean switch, which controls whether the informated
+% gathered using the |\city| command is displayed. The default of
+% this value is |false|.
+% \item \DescribeMacro{showacademictitle}
+% This is a boolean switch, which controls whether academic
+% titles |\Dr|, |\Prof| or |\ProfDr| --- typically used within
+% the |\author| command --- are displayed. The default is |true|.
% \end{itemize}
%
% \DescribeMacro{\notcomputerproofedsymbol}
@@ -819,6 +843,15 @@
% The source register is inserted into the text using
% |\sourceindex| and the theme register using |\themeindex|.
%
+% \subsubsection{Other useful stuff}
+% \DescribeMacro{\solpar}
+% In some environments --- like \verb+window+ --- the use of \verb+\par+ leads to unwanted
+% effects. Therefore we use the command \verb+\solpar+ inside the
+% definition of \verb+\@dia@solution+, which is used to display
+% a single solution when using \verb+\putsol+. You may use
+% \verb+\renewcommand{\solpar}+ to provide another definition of
+% \verb+\solpar+ in such situations.
+%
% \StopEventually{\PrintIndex\PrintChanges}
%
% \section{The documentation driver}
@@ -894,6 +927,10 @@
\newcount\w@cnt
\newcount\b@cnt
\newcount\n@cnt
+\newboolean{showcity}
+\setboolean{showcity}{false}
+\newboolean{showacademictitle}
+\setboolean{showacademictitle}{true}
% \end{macrocode}
%
% We have counters for each color to count the pieces on the
@@ -1567,6 +1604,20 @@
% \end{macrocode}
% \end{macro}
% \end{macro}
+% \begin{macro}{\ds@academictitle}
+% \begin{macro}{\Dr}
+% \begin{macro}{\Prof}
+% \begin{macro}{\ProfDr}
+% \begin{macrocode}
+\def\ds@academictitle#1{\ifthenelse{\boolean{showacademictitle}}{#1~}{}\ignorespaces}
+\newcommand{\Dr}{\ds@academictitle{Dr.}}
+\newcommand{\Prof}{\ds@academictitle{Prof.}}
+\newcommand{\ProfDr}{\ds@academictitle{Prof.\,Dr.}}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
%
% \begin{macrocode}
\def\city#1{%
@@ -1946,13 +1997,15 @@
\def\p@rsecity#1; {\@show@city#1;\l@@klist}
\def\@dia@city{%
- \if@city%
- \bgroup%
- \cityfont\@notfirstfalse%
- \let\@action=\p@rsecity\@parseTokenlist\city@tk;%
- \par%
- \egroup%
- \fi%
+ \ifthenelse{\boolean{showcity}}{%
+ \if@city%
+ \bgroup%
+ \cityfont\@notfirstfalse%
+ \let\@action=\p@rsecity\@parseTokenlist\city@tk;%
+ \par%
+ \egroup%
+ \fi%
+ }{}%
}
\def\@dia@after{%
@@ -2189,6 +2242,7 @@
\help@a=\z@%
\let\@action=\parse@params\l@@klist#1\e@list%
}
+\newcommand{\solpar}{\par}
\def\@dia@solution{%
\bgroup%
\parindent\z@%
@@ -2205,12 +2259,12 @@
\let\@action=\@sol@writename%
\@parseTokenlist\aut@tk;}:%
\fi%
- \par%
+ \newline%
\fi%
}%
- \if@develop\if@judgement\the\judgement@tk\par\fi\fi%
- \the\sol@tk\par%
- \if@comment\the\comment@tk\par\fi%
+ \if@develop\if@judgement\the\judgement@tk\solpar\fi\fi%
+ \the\sol@tk\solpar%
+ \if@comment\the\comment@tk\solpar\fi%
\egroup%
}
\grid@width=0.6\p@
@@ -2968,7 +3022,7 @@
}
\def\ch@fig#1{%
\ifvmode\noindent\fi%
- \hbox{\chtextfont\lower.3\fontdimen\tw@\chtextfont\hbox{\char#1}}%
+ \hbox{\chtextfont\lower.1\fontdimen\tw@\chtextfont\hbox{\char#1}}%
}
\def\@dia@index{%
\@ifundefined{newindex}%
diff --git a/Master/texmf-dist/tex/latex/chess-problem-diagrams/diagram.sty b/Master/texmf-dist/tex/latex/chess-problem-diagrams/diagram.sty
index 099275c3e43..434fc40c7f6 100644
--- a/Master/texmf-dist/tex/latex/chess-problem-diagrams/diagram.sty
+++ b/Master/texmf-dist/tex/latex/chess-problem-diagrams/diagram.sty
@@ -82,6 +82,10 @@
\newcount\w@cnt
\newcount\b@cnt
\newcount\n@cnt
+\newboolean{showcity}
+\setboolean{showcity}{false}
+\newboolean{showacademictitle}
+\setboolean{showacademictitle}{true}
\newboolean{cpd@checkPieceCounts}
\newcounter{cpd@defWhitePieces}
\newcounter{cpd@defBlackPieces}
@@ -597,6 +601,10 @@
\aut@tk={#1}\auth@rtrue%
\ignorespaces%
}
+\def\ds@academictitle#1{\ifthenelse{\boolean{showacademictitle}}{#1~}{}\ignorespaces}
+\newcommand{\Dr}{\ds@academictitle{Dr.}}
+\newcommand{\Prof}{\ds@academictitle{Prof.}}
+\newcommand{\ProfDr}{\ds@academictitle{Prof.\,Dr.}}
\def\city#1{%
\city@tk={#1}\@citytrue%
\ignorespaces%
@@ -913,13 +921,15 @@
\def\p@rsecity#1; {\@show@city#1;\l@@klist}
\def\@dia@city{%
- \if@city%
- \bgroup%
- \cityfont\@notfirstfalse%
- \let\@action=\p@rsecity\@parseTokenlist\city@tk;%
- \par%
- \egroup%
- \fi%
+ \ifthenelse{\boolean{showcity}}{%
+ \if@city%
+ \bgroup%
+ \cityfont\@notfirstfalse%
+ \let\@action=\p@rsecity\@parseTokenlist\city@tk;%
+ \par%
+ \egroup%
+ \fi%
+ }{}%
}
\def\@dia@after{%
@@ -1156,6 +1166,7 @@
\help@a=\z@%
\let\@action=\parse@params\l@@klist#1\e@list%
}
+\newcommand{\solpar}{\par}
\def\@dia@solution{%
\bgroup%
\parindent\z@%
@@ -1172,12 +1183,12 @@
\let\@action=\@sol@writename%
\@parseTokenlist\aut@tk;}:%
\fi%
- \par%
+ \newline%
\fi%
}%
- \if@develop\if@judgement\the\judgement@tk\par\fi\fi%
- \the\sol@tk\par%
- \if@comment\the\comment@tk\par\fi%
+ \if@develop\if@judgement\the\judgement@tk\solpar\fi\fi%
+ \the\sol@tk\solpar%
+ \if@comment\the\comment@tk\solpar\fi%
\egroup%
}
\grid@width=0.6\p@
@@ -1935,7 +1946,7 @@
}
\def\ch@fig#1{%
\ifvmode\noindent\fi%
- \hbox{\chtextfont\lower.3\fontdimen\tw@\chtextfont\hbox{\char#1}}%
+ \hbox{\chtextfont\lower.1\fontdimen\tw@\chtextfont\hbox{\char#1}}%
}
\def\@dia@index{%
\@ifundefined{newindex}%