summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty')
-rw-r--r--Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty25
1 files changed, 18 insertions, 7 deletions
diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty
index 80c2222b9b2..22b88d4c7d7 100644
--- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty
+++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty
@@ -12,7 +12,7 @@
% See http://www.latex-project.org/lppl.txt
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-\ProvidesPackage{tikzlings-coatis}[2020/12/04 version v0.4 Drawing coatis in TikZ]
+\ProvidesPackage{tikzlings-coatis}[2021/03/17 version v0.5 Drawing coatis in TikZ]
\RequirePackage{tikz}
\RequirePackage{tikzlings-addons}
@@ -31,6 +31,7 @@
\newif\ifcoati@threeD
\newif\ifcoati@sideward
\newif\ifcoati@back
+\newif\ifcoati@contour
\tikzset{
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -47,6 +48,8 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
body/.code = \def\coati@body{#1},
body = brown!50!darkgray!97!yellow,
+ eye/.code = \def\coati@eye{#1},
+ eye = \coati@body!50!black,
rotatehead/.code = \def\coati@rotatehead{#1},
rotate head/.forward to = /coati/rotatehead,
rotatehead = 0,
@@ -58,6 +61,10 @@
3D/.code = \coati@threeDtrue,
sideward/.code = \coati@sidewardtrue,
back/.code = \coati@backtrue,
+ contour/.code = \coati@contourtrue
+ \def\coati@contour{#1},
+ contour/.default = black,
+ outline/.forward to = /coati/contour,
}
\def\coati@draw{%
@@ -81,14 +88,18 @@
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
-% switch between 2D and 3D, from
+% switch between 2D, 3D and contours, from
% https://chat.stackexchange.com/transcript/message/45991801#45991801
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ifcoati@threeD
\def\coati@part@draw[##1]{\shade[ball color=##1]}
\else
- \def\coati@part@draw[##1]{\fill[##1]}
+ \ifcoati@contour
+ \def\coati@part@draw[##1]{\draw[##1,\coati@contour,fill=white,line width=\scalingfactor*0.4pt]}
+ \else
+ \def\coati@part@draw[##1]{\fill[##1]}
+ \fi
\fi
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -163,8 +174,8 @@
%
% Eyes %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ifcoati@back\else
- \coati@part@draw[\coati@body!50!black] (0.007, 1.624) ellipse[x radius=0.04, y radius=0.06];
- \coati@part@draw[\coati@body!50!black] (-0.38, 1.865) ellipse[x radius=0.035, y radius=0.055];
+ \coati@part@draw[\coati@eye] (0.007, 1.624) ellipse[x radius=0.04, y radius=0.06];
+ \coati@part@draw[\coati@eye] (-0.38, 1.865) ellipse[x radius=0.035, y radius=0.055];
\fi
%
% Right Ear %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -195,8 +206,8 @@
%
% Eyes %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ifcoati@back\else
- \coati@part@draw[\coati@body!50!black] (0.23, 1.62) circle[radius=0.05];
- \coati@part@draw[\coati@body!50!black] (-0.23, 1.62) circle[radius=0.05];
+ \coati@part@draw[\coati@eye] (0.23, 1.62) circle[radius=0.05];
+ \coati@part@draw[\coati@eye] (-0.23, 1.62) circle[radius=0.05];
\fi
%
% Ears %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%