summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/ducksay
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-06-11 21:01:50 +0000
committerKarl Berry <karl@freefriends.org>2019-06-11 21:01:50 +0000
commit1916574aa9536f615e431e1b246674d9e4cb1bf2 (patch)
treef27590f80ffd7b90b25a94c0a997716b8114316f /Master/texmf-dist/tex/latex/ducksay
parent67fdef123d0cd393e03d0e6a37e2a427e064d47e (diff)
ducksay (11jun19)
git-svn-id: svn://tug.org/texlive/trunk@51364 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/ducksay')
-rw-r--r--Master/texmf-dist/tex/latex/ducksay/ducksay.animals.tex198
-rw-r--r--Master/texmf-dist/tex/latex/ducksay/ducksay.code.v1.tex2
-rw-r--r--Master/texmf-dist/tex/latex/ducksay/ducksay.code.v2.tex102
-rw-r--r--Master/texmf-dist/tex/latex/ducksay/ducksay.sty9
4 files changed, 176 insertions, 135 deletions
diff --git a/Master/texmf-dist/tex/latex/ducksay/ducksay.animals.tex b/Master/texmf-dist/tex/latex/ducksay/ducksay.animals.tex
index e0077f6f47b..30ba8b01769 100644
--- a/Master/texmf-dist/tex/latex/ducksay/ducksay.animals.tex
+++ b/Master/texmf-dist/tex/latex/ducksay/ducksay.animals.tex
@@ -32,7 +32,9 @@
%% ducksay.code.v2.tex and
%% ducksay.animals.tex.
%%
-\AddAnimal{duck}%>>>
+\ProvidesFile{ducksay.animals.tex}
+ [\ducksay@date\space v\ducksay@version\space ducksay animals]
+\AddAnimal{duck}%>>=
{ \
\ __
>(' )
@@ -40,42 +42,42 @@
/(
/ `----/
\ ~=- /
- ~^~^~^~^~^~^~^}%<<<
-\AddAnimal{small-duck}%>>>
+ ~^~^~^~^~^~^~^}%=<<
+\AddAnimal{small-duck}%>>=
{ \
\
>()_
- (__)__ _}%<<<
-\AddAnimal{duck-family}%>>>
+ (__)__ _}%=<<
+\AddAnimal{duck-family}%>>=
{ \
\ __
>(' )
)/
/(
/ `----/ -()_ >()_
- __\__~=-_/__ _(__)__(__)__ _}%<<<
-\AddAnimal{cow}%>>>
+ __\__~=-_/__ _(__)__(__)__ _}%=<<
+\AddAnimal{cow}%>>=
{ \ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
- || ||}%<<<
-\AddAnimal{head-in}%>>>
+ || ||}%=<<
+\AddAnimal{head-in}%>>=
{ \
\ ^__^ /
(oo)\_______/ ________
(__)\ )=( ___|_ \____
||----w | \ \ \____ |
- || || || ||}%<<<
-\AddAnimal{sodomized}%>>>
+ || || || ||}%=<<
+\AddAnimal{sodomized}%>>=
{ \ _
\ (_)
^__^ / \
(oo)\_____/_\ \
(__)\ ) /
||----w ((
- || ||>>}%<<<
-\AddAnimal{tux}%>>>
+ || ||>>}%=<<
+\AddAnimal{tux}%>>=
{ \
\ .--.
|o_o |
@@ -83,67 +85,68 @@
// \ \
(| | )
/'\_ _/`\
- \___)=(___/}%<<<
-\AddAnimal{pig}%>>>
+ \___)=(___/}%=<<
+\AddAnimal{pig}%>>=
+ \ _//| .-~~~-.
\ _/oo } }-@
('')_ } |
`--'| { }--{ }
- //_/ /_/+%<<<
-\AddAnimal{frog}%>>>
+ //_/ /_/+%=<<
+\AddAnimal{frog}%>>=
{ \
\ (.)_(.)
_ ( _ ) _
/ \/`-----'\/ \
__\ ( ( ) ) /__
) /\ \._./ /\ (
- )_/ /|\ /|\ \_(}%<<<
-\AddAnimal{snowman}%>>>
+ )_/ /|\ /|\ \_(}%=<<
+\AddAnimal{snowman}%>>=
{ \
\_[_]_
(")
>-( : )-<
- (__:__)}%<<<
-\AddAnimal[tail-symbol=s]{hedgehog}%>>>
+ (__:__)}%=<<
+\AddAnimal[tail-symbol=s]{hedgehog}%>>=
{ s .\|//||\||.
s |/\/||/|//|/|
/. `|/\\|/||/||
- o__,_|//|/||\||'}%<<<
-\AddAnimal{kangaroo}%>>>
+ o__,_|//|/||\||'}%=<<
+\AddAnimal{kangaroo}%>>=
{ \
\ _,' ___
<__\__/ \
\_ / _\
\,\ / \\
// \\
- ,/' `\_,}%<<<
-\AddAnimal[tail-symbol=s,tail-count=3]{rabbit}%>>>
-{ s / \`\ __
- s | \ `\ /`/ \
- s \_/`\ \-"-/` /\ \
- | | \ |
- (d b) \_/
- / \
- ,".|.'.\_/.'.|.",
- / /\' _|_ '/\ \
- | / '-`"`-' \ |
- | | | |
- | \ \ / / |
- \ \ \ / / /
- `"`\ : /'"`
- `""`""`}%<<<
-\AddAnimal{bunny}%>>>
+ ,/' `\_,}%=<<
+\AddAnimal[tail-symbol=s,tail-count=3]{rabbit}%>>=
+{ s
+ s / \`\ __
+ s | \ `\ /`/ \
+ \_/`\ \-"-/` /\ \
+ | | \ |
+ (d b) \_/
+ / \
+ ,".|.'.\_/.'.|.",
+ / /\' _|_ '/\ \
+ | / '-`"`-' \ |
+ | | | |
+ | \ \ / / |
+ \ \ \ / / /
+ `"`\ : /'"`
+ `""`""`}%=<<
+\AddAnimal{bunny}%>>=
{ \
\ /
/\ /
( )
- .( o ).}%<<<
-\AddAnimal{small-rabbit}%>>>
+ .( o ).}%=<<
+\AddAnimal{small-rabbit}%>>=
{ \
\ _//
(')---.
- _/-_( )o}%<<<
-\AddAnimal[tail-symbol=s,tail-count=3]{dragon}%>>>
+ _/-_( )o}%=<<
+\AddAnimal[tail-symbol=s,tail-count=3]{dragon}%>>=
{ s / \ //\
s |\___/| / \// \\
s /0 0 \__ / // | \ \
@@ -159,14 +162,14 @@
(( / )) .----~-.\ \-' .~ \ `. \^-.
///.----..> \ _ -~ `. ^-` ^-_
///-._ _ _ _ _ _ _}^ - - - - ~ ~-- ,.-~
- /.-~}%<<<
-\AddAnimal{dog}%>>>
+ /.-~}%=<<
+\AddAnimal{dog}%>>=
{ \ __
\ .-'\/\
"\ '------.
___/ ( .'_____
- '-----'"""'------"""""'}%<<<
-\AddAnimal{squirrel}%>>>
+ '-----'"""'------"""""'}%=<<
+\AddAnimal{squirrel}%>>=
{ \ ,;:;;,
\ , ;;;;;
.=', ;:;;:,
@@ -174,41 +177,41 @@
@=:__, \,;:;:'
_(\.= ;:;;'
`"_( _/="`
- `"'``}%<<<
-\AddAnimal{snail}%>>>
+ `"'``}%=<<
+\AddAnimal{snail}%>>=
{ \
\ .-""-.
oo ; .-. :
\\__..-: '.__.')._
- "-._.._'.__.-'_.."}%<<<
-\AddAnimal{unicorn}%>>>
+ "-._.._'.__.-'_.."}%=<<
+\AddAnimal{unicorn}%>>=
{ \
\ /((((((\\\\
---====((((((((((\\\\\
(( \\\\\\\
( (* _/ \\\\\\\
- \ / \ \\\\\\_ __,,__
- | | | </ "------"" ((\\\\
- o_| / / \ \\\\ \\\\\\\
- | ._ ( \ \\\\\\\\\\\\\\\\
- | / / / \\\\\\\ \\
- .______/\/ / / / \\\
- / __.____/ _/ ___----( /\
- / / / ________/:______,---' \ / \_
- / / \ \ \ \ \_ \
- ( < \ \ > / \ \
- \/ \\_ / / > )
- \_| / / / /
- _// _//
- /_| /_|}%<<<
-\AddAnimal[tail-count=3,tail-symbol=s]{whale}%>>>
+ \ / \ \\\\\\_ __,,__
+ | | | </ "-----"" ((\\\\
+ o_| / / \ \\\\ \\\\\\\
+ | ._ ( \ \\\\\\\\\\\\\\\\
+ | / / / \\\\\\\ \\
+ .______/\/ / / / \\\
+ / __.____/ _/ _( /\
+ / / / ________/:_ ___,,--' \ / \_
+ / / \ \ """"""" \ \ \_ \
+ ( < \ \ > / \ \
+ \/ \\_ / / > )
+ \_| / / / /
+ _// _//
+ /_| /_|}%=<<
+\AddAnimal[tail-count=3,tail-symbol=s]{whale}%>>=
{ s |-.
s .-""-._ \ \.--|
s / `-..__) ,-'
| . /
\--.__, .__.,'
- `-.___'._\_.'}%<<<
-\AddAnimal[tail-count=3]{yoda}%>>>
+ `-.___'._\_.'}%=<<
+\AddAnimal[tail-count=3]{yoda}%>>=
{ \
\ ____
\ _.' : `._
@@ -244,8 +247,8 @@
\ / .-" /. .'.' ;_:' ;
:-""-.`./-.' / `.___.'
\ `t ._ /
- "-.t-._:'}%<<<
-\AddAnimal[tail-count=3]{yoda-head}%>>>
+ "-.t-._:'}%=<<
+\AddAnimal[tail-count=3]{yoda-head}%>>=
{ \
\ ____
\ _.' : `._
@@ -261,16 +264,16 @@
.-j/'.; ;"""" / .'\"-.
.' /:`. : : /.".''; `.
.-" / ;`.". : ."." : "-.
- .+"-. : : ".".". ."." ;-._ \}%<<<
-\AddAnimal{small-yoda}%>>>
+ .+"-. : : ".".". ."." ;-._ \}%=<<
+\AddAnimal{small-yoda}%>>=
{ \
\
__.-._
'-._"7'
/'.-c
| /T
- _)_/LI}%<<<
-\AddAnimal{r2d2}%>>>
+ _)_/LI}%=<<
+\AddAnimal{r2d2}%>>=
{ \
\ ,-----.
,'_/_|_\_`.
@@ -283,8 +286,8 @@
| |_________| |
| |\_______/| |
/ \ / \ / \
- `---' `---' `---'}%<<<
-\AddAnimal{vader}%>>>
+ `---' `---' `---'}%=<<
+\AddAnimal{vader}%>>=
{ \ _.-'~~~~~~`-._
\ / || \
/ || \
@@ -298,15 +301,15 @@
/ \ /||||||\ / \
/_ \O========O/ _\
`--...__|`-._ _.-'|__...--'
- | `' |}%<<<
-\AddAnimal[tail-symbol=|,tail-count=1]{crusader}%>>>
+ | `' |}%=<<
+\AddAnimal[tail-symbol=|,tail-count=1]{crusader}%>>=
{ |
\[T]/}
\csname bool_if:cT\endcsname {l_ducksay_version_one_bool}
{\AnimalOptions{crusader}{tail-1=|,rel-align=c}}
\csname bool_if:cT\endcsname {l_ducksay_version_two_bool}
- {\AnimalOptions{crusader}{tail-1=|,body-align=c}}%<<<
-\AddAnimal[tail-count=3]{knight}%>>>
+ {\AnimalOptions{crusader}{tail-1=|,body-align=c}}%=<<
+\AddAnimal[tail-count=3]{knight}%>>=
{ \
\ ,-"""-.
\ | === |
@@ -327,7 +330,38 @@
\\ \ | /
\\ /V|V\
\|/ | \
- '--' `--`}%<<<
+ '--' `--`}%=<<
+\AddAnimal{ghost}%>>=
+{ \
+ \ .-.
+ (o o)
+ | O \
+ \ \
+ `~~~'}%=<<
+\AddAnimal{fairy}%>>=
+{ \
+ \ .oOOb
+ .. .oO O
+ '::; d O
+ ;;;;d ..oO
+ * ::O;;;'OooO
+~"\. dp'(O.o.
+ \op 'oOb
+ obU
+ dop
+ dop
+ PO
+ O 'b
+ l P.
+ / ;
+ '}%=<<
+\AddAnimal[tail-symbol=s]{only-tail}%>>=
+{ s
+ s}%=<<
+\AddAnimal[tail-symbol=s,tail-count=3]{only-tail3}%>>=
+{ s
+ s
+ s}%=<<
%%
%%
%% End of file `ducksay.animals.tex'.
diff --git a/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v1.tex b/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v1.tex
index 1d6487c7674..f8cd9ae89b5 100644
--- a/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v1.tex
+++ b/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v1.tex
@@ -32,6 +32,8 @@
%% ducksay.code.v2.tex and
%% ducksay.animals.tex.
%%
+\ProvidesFile{ducksay.code.v1.tex}
+ [\ducksay@date\space v\ducksay@version\space ducksay code version 1]
\cs_new:Npn \ducksay_longest_line:n #1
{
\int_incr:N \l_ducksay_msg_height_int
diff --git a/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v2.tex b/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v2.tex
index 413e221bbaa..130729d0ef9 100644
--- a/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v2.tex
+++ b/Master/texmf-dist/tex/latex/ducksay/ducksay.code.v2.tex
@@ -32,6 +32,8 @@
%% ducksay.code.v2.tex and
%% ducksay.animals.tex.
%%
+\ProvidesFile{ducksay.code.v2.tex}
+ [\ducksay@date\space v\ducksay@version\space ducksay code version 2]
\RequirePackage{array,grabbox}
\msg_new:nnn { ducksay } { justify~unavailable }
{
@@ -91,7 +93,9 @@
,body-align / l .meta:n = { body-to-msg = l , msg-to-body = l }
,body-align / c .meta:n = { body-to-msg = hc , msg-to-body = hc }
,body-align / r .meta:n = { body-to-msg = r , msg-to-body = r }
- ,body-align .initial:n = l
+ ,body-align .initial:n = l
+ ,body-bigger .int_set:N = \l_ducksay_body_bigger_int
+ ,body-bigger .initial:n = \c_zero
,msg-align .choice:
,msg-align / l .code:n = { \tl_set:Nn \l_ducksay_msg_align_tl { l } }
,msg-align / c .code:n = { \tl_set:Nn \l_ducksay_msg_align_tl { c } }
@@ -200,7 +204,7 @@
}
\cs_new:Npn \ducksay_calculate_msg_width_from_int:
{
- \hbox_set:Nn \l_ducksay_tmpa_box { \l_ducksay_msg_fount_tl M }
+ \hbox_set:Nn \l_ducksay_tmpa_box { { \l_ducksay_msg_fount_tl M } }
\dim_set:Nn \l_ducksay_msg_width_dim
{ \l_ducksay_msg_width_int \box_wd:N \l_ducksay_tmpa_box }
}
@@ -217,6 +221,16 @@
{
\end { tabular }
}
+\cs_new:Npn \ducksay_width_case_none_int_dim:nnn #1 #2 #3
+ {
+ \dim_compare:nNnTF { \l_ducksay_msg_width_dim } < { \c_zero_dim }
+ {
+ \int_compare:nNnTF { \l_ducksay_msg_width_int } < { \c_zero_int }
+ { #1 }
+ { #2 }
+ }
+ { #3 }
+ }
\cs_new:Npn \ducksay_digest_options:n #1
{
\group_begin:
@@ -225,56 +239,39 @@
{ \keys_set:nn { ducksay } { default_animal } }
\bool_if:NTF \l_ducksay_eat_arg_box_bool
{
- \dim_compare:nNnTF { \l_ducksay_msg_width_dim } < { \c_zero_dim }
- {
- \int_compare:nNnTF { \l_ducksay_msg_width_int } < { \c_zero_int }
- {
- \cs_set_eq:NN
- \ducksay_eat_argument:w \ducksay_eat_argument_hbox:w
- }
- {
- \cs_set_eq:NN
- \ducksay_eat_argument:w \ducksay_eat_argument_vbox:w
- \ducksay_calculate_msg_width_from_int:
- }
- }
+ \ducksay_width_case_none_int_dim:nnn
+ { \ducksay_eat_argument_hbox:w }
{
- \cs_set_eq:NN \ducksay_eat_argument:w \ducksay_eat_argument_vbox:w
+ \ducksay_calculate_msg_width_from_int:
+ \ducksay_eat_argument_vbox:w
}
+ { \ducksay_eat_argument_vbox:w }
}
{
- \dim_compare:nNnTF { \l_ducksay_msg_width_dim } < { \c_zero_dim }
+ \ducksay_width_case_none_int_dim:nnn
{
- \int_compare:nNnTF { \l_ducksay_msg_width_int } < { \c_zero_int }
+ \tl_if_empty:NT \l_ducksay_msg_tabular_column_tl
{
- \tl_if_empty:NT \l_ducksay_msg_tabular_column_tl
+ \str_case:Vn \l_ducksay_msg_align_tl
{
- \str_case:Vn \l_ducksay_msg_align_tl
+ { l } { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { l } }
+ { c } { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { c } }
+ { r } { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { r } }
+ { j }
{
- { l }
- { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { l } }
- { c }
- { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { c } }
- { r }
- { \tl_set:Nn \l_ducksay_msg_tabular_column_tl { r } }
- { j } {
- \msg_error:nn { ducksay } { justify~unavailable }
- \tl_set:Nn \l_ducksay_msg_tabular_column_tl { l }
- }
+ \msg_error:nn { ducksay } { justify~unavailable }
+ \tl_set:Nn \l_ducksay_msg_tabular_column_tl { l }
}
}
}
- {
- \ducksay_calculate_msg_width_from_int:
- \ducksay_evaluate_message_alignment_fixed_width_tabular:
- }
}
{
+ \ducksay_calculate_msg_width_from_int:
\ducksay_evaluate_message_alignment_fixed_width_tabular:
}
- \cs_set_eq:NN \ducksay_eat_argument:w \ducksay_eat_argument_tabular:w
+ { \ducksay_evaluate_message_alignment_fixed_width_tabular: }
+ \ducksay_eat_argument_tabular:w
}
- \ducksay_eat_argument:w
}
\cs_new:Npn \ducksay_set_bubble_top_kern:
{
@@ -294,6 +291,15 @@
\dim_set:Nn \l_ducksay_bubble_bottom_kern_dim
{ \dim_eval:n { \l_ducksay_bubble_bottom_kern_tl } }
}
+\cs_new:Npn \ducksay_make_body_bigger:
+ {
+ \int_step_function:nN \l_ducksay_body_bigger_int
+ \ducksay_make_body_bigger_aux:n
+ }
+\cs_new:Npn \ducksay_make_body_bigger_aux:n #1
+ {
+ \\
+ }
\cs_new_protected:Npn \ducksay_shipout:
{
\hcoffin_set:Nn \l_ducksay_msg_coffin { \box_use:N \l_ducksay_msg_box }
@@ -417,6 +423,8 @@
\l_ducksay_body_fount_tl
\begin{tabular} { @{} l @{} }
\l_ducksay_animal_tl
+ \ducksay_make_body_bigger:
+ \relax
\end{tabular}
}
\bool_if:NT \l_ducksay_mirrored_body_bool
@@ -464,10 +472,10 @@
\ducksay_eat_argument_tabular_inner:w
{
\group_begin:
- \tex_everyeof:D { \exp_not:N }
+ \__ducksay_everyeof:w { \exp_not:N }
\exp_after:wN
\group_end:
- \tex_scantokens:D { #1 }
+ \__ducksay_scantokens:w { #1 }
}
}
\NewDocumentCommand \ducksay_eat_argument_tabular_normal:w { +m }
@@ -475,26 +483,24 @@
\cs_new_protected_nopar:Npn \ducksay_eat_argument_hbox:w
{
\bool_if:NTF \l_ducksay_msg_strip_spaces_bool
- { \grabbox }
- { \grabbox* }
- \l_ducksay_msg_box [ \l_ducksay_msg_fount_tl ] \hbox \ducksay_shipout:
+ { \@grabbox }
+ { \@grabbox* }
+ {} \l_ducksay_msg_box \l_ducksay_msg_fount_tl \hbox {} \ducksay_shipout:
}
\cs_new_protected_nopar:Npn \ducksay_eat_argument_vbox:w
{
\ducksay_evaluate_message_alignment_fixed_width_vbox:
\bool_if:NTF \l_ducksay_msg_strip_spaces_bool
- { \grabbox }
- { \grabbox* }
- [
+ { \@grabbox }
+ { \@grabbox* }
+ {
\hsize \l_ducksay_msg_width_dim
\linewidth \hsize
- \l_ducksay_msg_fount_tl
\l_ducksay_msg_align_vbox_tl
\@afterindentfalse
\@afterheading
- ]
- \l_ducksay_msg_box
- \vbox \ducksay_shipout:
+ }
+ \l_ducksay_msg_box \l_ducksay_msg_fount_tl \vbox {} \ducksay_shipout:
}
\cs_generate_variant:Nn \coffin_join:NnnNnnnn { NVnNVnnn }
\cs_generate_variant:Nn \coffin_attach:NnnNnnnn { NVnNVnnn }
diff --git a/Master/texmf-dist/tex/latex/ducksay/ducksay.sty b/Master/texmf-dist/tex/latex/ducksay/ducksay.sty
index 98d096c4175..88cf25607d7 100644
--- a/Master/texmf-dist/tex/latex/ducksay/ducksay.sty
+++ b/Master/texmf-dist/tex/latex/ducksay/ducksay.sty
@@ -35,8 +35,8 @@
\NeedsTeXFormat{LaTeX2e}
\RequirePackage{xparse,l3keys2e}
-\def\ducksay@version{2.3}
-\def\ducksay@date{2019-01-13}
+\def\ducksay@version{2.4}
+\def\ducksay@date{2019-06-11}
\ProvidesExplPackage
{ducksay} {\ducksay@date}
@@ -66,8 +66,6 @@
{ \cO(?:\\color\{(.*?)\}) }
\msg_new:nnn { ducksay } { load-time-only }
{ The~`#1`~key~is~to~be~used~only~during~package~load~time. }
-\msg_new:nnn { ducksay } { deprecated-key }
- { The~`\l_keys_key_tl`~key~is~deprecated.~Sorry~for~the~inconvenience. }
\keys_define:nn { ducksay }
{
,bubble .tl_set:N = \l_ducksay_bubble_tl
@@ -114,7 +112,6 @@
\bool_set_true:N \l_ducksay_version_two_bool
}
,version .initial:n = 2
- ,add-think .code:n = \msg_error:nn { ducksay } { deprecated-key }
}
\ProcessKeysOptions { ducksay }
\keys_define:nn { ducksay }
@@ -131,6 +128,8 @@
}
\cs_generate_variant:Nn \tl_replace_once:Nnn { NVn }
\cs_generate_variant:Nn \tl_replace_all:Nnn { NVn }
+\cs_set_eq:NN \__ducksay_everyeof:w \tex_everyeof:D
+\cs_set_eq:NN \__ducksay_scantokens:w \tex_scantokens:D
\cs_new_protected:Npx \ducksay_replace_verb_newline:Nn #1 #2
{
\tl_replace_all:Nnn #1 { \char_generate:nn { 13 } { 12 } } { #2 }