diff options
author | Karl Berry <karl@freefriends.org> | 2015-11-15 23:38:07 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-11-15 23:38:07 +0000 |
commit | cfae7628da8ad99c5862a08581c2a2202651fdb1 (patch) | |
tree | 3f95117edcc59594eaacaefb3add87608afe7316 /Master/texmf-dist/tex/generic/catcodes | |
parent | f771dc12c829ca2d5e42481634c17e4b7911c11e (diff) |
catcodes (15nov15)
git-svn-id: svn://tug.org/texlive/trunk@38859 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/catcodes')
-rw-r--r-- | Master/texmf-dist/tex/generic/catcodes/catchdq.sty | 31 | ||||
-rw-r--r-- | Master/texmf-dist/tex/generic/catcodes/catcodes.RLS | 1 |
2 files changed, 21 insertions, 11 deletions
diff --git a/Master/texmf-dist/tex/generic/catcodes/catchdq.sty b/Master/texmf-dist/tex/generic/catcodes/catchdq.sty index f98ddf717f9..4004ca7cd2b 100644 --- a/Master/texmf-dist/tex/generic/catcodes/catchdq.sty +++ b/Master/texmf-dist/tex/generic/catcodes/catchdq.sty @@ -1,7 +1,8 @@ \input plainpkg -\ProvidesPackage{catchdq}[2012/09/20 v0.2 simple typographic dqs (UL)] +\ProvidesPackage{catchdq}[2015/05/22 v0.21 typographic dqs (UL)] +%% %% rm. "simple" -- too long -- 2015/05/22 %% -%% Copyright (C) 2012 Uwe Lueck, +%% Copyright (C) 2012 2015 Uwe Lueck, %% http://www.contact-ednotes.sty.de.vu %% -- author-maintained in the sense of LPPL below -- %% @@ -75,15 +76,20 @@ \gdef\asciidqtd#1{"#1"} %% We allow loading 'catchdq' \emph{after} another package %% (such as 'blog.sty') has chosen meanings for `\endqtd' and the -%% like (difficult TODO) -\ifx\enldq \undefined \gdef\enldq{``} \fi -\ifx\enrdq \undefined \global\let\enrdq\asciidq \fi -\ifx\endqtd\undefined \gdef\endqtd#1{\enldq#1\enrdq} \fi +%% like. Before v0.21, definedness was tested by +%% `\ifx'...`\undefined', which two times fell +%% prey to some earlier `\@ifundefined'. So now: +\begingroup \escapechar=-1 +\def\provass#1#2#3{% + \expandafter\ifx\csname \string#2\endcsname\relax #1#2#3\fi} +\provass \gdef \enldq {{``}} +\provass {\global\let} \enrdq \asciidq +\provass \gdef \endqtd {#1{\enldq#1\enrdq}} %% Typographical alternatives to `\endqtd' may be obtained -%% from \CtanPkgRef{ngerman}{ngerman.sty} or so, if you are smart ... +%% from \ctanpkgstyref{ngerman} or so, if you are smart ... %% %% <- 2012/09/20 -> %% (see Section~\ref{sec:sw} for how it works): -\ifx\dedqtd\undefined \gdef\dedqtd#1{\glqq#1\grqq} \fi +\provass \gdef \dedqtd {#1{\glqq#1\grqq}} %% 'blog.sty', dealing with \acro{HTML}, had a different idea %% about `\endqtd' of course. It has also used the mechanism of %% the \ctanpkgref{langcode} package that allows using `\dqtd' and other @@ -97,14 +103,16 @@ \gdef\catchdqs{\MakeActiveLet\"\catchdq} %% After this, |"<no-dqs>"| will expand to `\dqtd{#1}'. %% The default expansion for |\dqtd| will be |\endqtd|: -\ifx\dqtd\undefined \global\let\dqtd\endqtd \fi +\provass {\global\let} \dqtd \endqtd %% Might be done by |\endqs|---when there are alternatives, %% but 'blog.sty' and 'langcode.sty' do this in a different way ... TODO % \gdef\endqs{\let\dqtd\endqtd} % \ifx\dqtd\undefined \global\endqs \fi +\endgroup %% \catchdqs Actually, here is a little "Tessst"~... -%% \let\dqtd\dedqtd \ and here with "doytshe doppleta anf..." $\dots$ \ -%% This has been achieved by +%% \let\dqtd\dedqtd \ and here with "doytshe doppleta unf..." $\dots$ \ +%% %% anf -> unf 2015/05/22 +%% The latter has been achieved by %% \[`\usepackage{ngerman} \originalTeX'\] %% \MakeOther\" %% @@ -131,3 +139,4 @@ v0.2 2012/09/17 own file, new ideas ... 2012/09/19 doc: stacklet 2012/09/20 \dedqtd conditionally; reworked doc., tested ngerman.sty +v0.21 2015/05/22 better test for undefinedness diff --git a/Master/texmf-dist/tex/generic/catcodes/catcodes.RLS b/Master/texmf-dist/tex/generic/catcodes/catcodes.RLS index 56603a9bf46..e4cabcf9e36 100644 --- a/Master/texmf-dist/tex/generic/catcodes/catcodes.RLS +++ b/Master/texmf-dist/tex/generic/catcodes/catcodes.RLS @@ -1,3 +1,4 @@ \ProvidesFile{catcodes.RLS} %% RELEASE INFO + [2015/11/14 r0.2 catchdq v0.21 proper definedness test] [2012/11/07 r0.1a documentation corrected/extended] [2012/09/20 r0.1 initial release] |