summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/generic/gobble
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-03-07 23:22:23 +0000
committerKarl Berry <karl@freefriends.org>2016-03-07 23:22:23 +0000
commitd9eed51f22174ef543823392b76a190f3c7f83a4 (patch)
tree171993e52668bfb362abdb9dd2b3eec2d615626b /Master/texmf-dist/doc/generic/gobble
parent7ac81bc4c8445b925f4504174ad526d178221fcb (diff)
gobble (7mar16)
git-svn-id: svn://tug.org/texlive/trunk@39964 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/generic/gobble')
-rw-r--r--Master/texmf-dist/doc/generic/gobble/README19
-rw-r--r--Master/texmf-dist/doc/generic/gobble/gobble-user.tex31
-rw-r--r--Master/texmf-dist/doc/generic/gobble/gobble.pdfbin0 -> 157385 bytes
-rw-r--r--Master/texmf-dist/doc/generic/gobble/gobble.tex61
4 files changed, 111 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/generic/gobble/README b/Master/texmf-dist/doc/generic/gobble/README
new file mode 100644
index 00000000000..df5d8c2fd02
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/gobble/README
@@ -0,0 +1,19 @@
+LaTeX and generic TeX packages 'gobble' and 'gobble-user'
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+Copyright (c) 2012 by Martin Scharrer <martin@scharrer-online.de>
+CTAN: http://www.ctan.org/pkg/gobble
+Code repository: https://bitbucket.org/martin_scharrer/gobble
+
+The LaTeX package 'gobble' includes several gobble macros not
+included in the LaTeX kernel. These macros remove a number of
+arguments after them; a feature regulary used inside other
+macros. This includes gobble macros for optional arguments.
+
+The LaTeX package 'gobble-user' provides these macros to the
+user level, i.e. using names without '@', so that these can be
+used without \makeatletter and \makeatother.
+
+The same macros are provided inside .tex files for use with
+plain-TeX or other TeX formats. However, the gobble macros
+for optional macros require \@ifnextchar to be defined.
+
diff --git a/Master/texmf-dist/doc/generic/gobble/gobble-user.tex b/Master/texmf-dist/doc/generic/gobble/gobble-user.tex
new file mode 100644
index 00000000000..f5a6aef4e09
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/gobble/gobble-user.tex
@@ -0,0 +1,31 @@
+\expandafter\ifx\csname gobble-user.tex loaded\endcsname\relax
+ \expandafter\def\csname gobble-user.tex loaded\endcsname{1}%
+\else
+ \expandafter\endinput
+\fi
+\input{gobble}
+\expandafter\edef\csname gobbletex@catcode\endcsname{%
+ \catcode`\noexpand\@=\the\catcode`\@%
+}%
+\catcode`\@=11
+\let\gobble\@gobble
+\let\gobbletwo\@gobbletwo
+\let\gobblethree\@gobblethree
+\let\gobblefour\@gobblefour
+\let\gobbleopt\@gobbleopt
+\let\gobbletwoopt\@gobbletwoopt
+\let\gobbleallopt\@gobbleallopt
+\let\gobbletwoopttwo\@gobbletwoopttwo
+\let\firstofone\@firstofone
+\let\firstoftwo\@firstoftwo
+\let\secondoftwo\@secondoftwo
+\let\firstofthree\@firstofthree
+\let\secondofthree\@secondofthree
+\let\thirdofthree\@thirdofthree
+\let\gobbletofi\@gobbletofi
+\let\gobbletoelse\@gobbletoelse
+\let\gobbletoor\@gobbletoor
+\gobbletex@catcode
+\endinput
+%%
+%% End of file `gobble-user.tex'.
diff --git a/Master/texmf-dist/doc/generic/gobble/gobble.pdf b/Master/texmf-dist/doc/generic/gobble/gobble.pdf
new file mode 100644
index 00000000000..cf3dd7a4cdb
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/gobble/gobble.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/generic/gobble/gobble.tex b/Master/texmf-dist/doc/generic/gobble/gobble.tex
new file mode 100644
index 00000000000..723fd4992db
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/gobble/gobble.tex
@@ -0,0 +1,61 @@
+\expandafter\ifx\csname gobble.tex loaded\endcsname\relax
+ \expandafter\def\csname gobble.tex loaded\endcsname{1}%
+\else
+ \expandafter\endinput
+\fi
+\expandafter\edef\csname gobbletex@catcode\endcsname{%
+ \catcode`\noexpand\@=\the\catcode`\@%
+}%
+\catcode`\@=11
+\long\def\@gobble#1{}%
+\long\def\@gobbletwo#1#2{}%
+\long\def\@gobblethree#1#2#3{}%
+\long\def\@gobblefour#1#2#3#4{}%
+\long\def\@gobbleopt{%
+ \@ifnextchar[%
+ {\@gobbleopt@}%
+ {}%
+}%
+\def\@gobbleopt@[#1]{}%
+\long\def\@gobbletwoopt{%
+ \@ifnextchar[%
+ {\@gobbletwoopt@}%
+ {}%
+}%
+\def\@gobbletwoopt@[#1]{\@gobbleopt}%
+\long\def\@gobbleallopt{%
+ \@ifnextchar[%
+ {\@gobbleallopt@}%
+ {}%
+}%
+\long\def\@gobbleallopt@[#1]{%
+ \@ifnextchar[%
+ {\@gobbleallopt@}%
+ {}%
+}%
+\long\def\@gobbletwoopttwo{%
+ \@ifnextchar[%
+ {\@gobbletwoopttwo@}%
+ {\@gobbletwo}%
+}%
+\long\def\@gobbletwoopttwo@[#1]{%
+ \@ifnextchar[%
+ {\@gobbletwoopttwo@@}%
+ {\@gobbletwo}%
+}%
+\long\def\@gobbletwoopttwo@@[#1]{%
+ \@gobbletwo
+}%
+\long\def\@firstofone#1{#1}%
+\long\def\@firstoftwo#1#2{#1}%
+\long\def\@secondoftwo#1#2{#2}%
+\long\def\@firstofthree#1#2#3{#1}%
+\long\def\@secondofthree#1#2#3{#2}%
+\long\def\@thirdofthree#1#2#3{#3}%
+\long\def\@gobbletofi#1#2\fi{\fi#1}%
+\long\def\@gobbletoelse#1#2\else{\else#1}%
+\long\def\@gobbletoor#1#2\or{\or#1}%
+\gobbletex@catcode
+\endinput
+%%
+%% End of file `gobble.tex'.