summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2011-09-12 23:13:31 +0000
committerKarl Berry <karl@freefriends.org>2011-09-12 23:13:31 +0000
commit43feab97abfa5a781cd20b13d118c894afee47fb (patch)
tree7436698e3c97e95d9974744d70f92149fa1809dd /Master/texmf-dist/tex
parentc0fc6f08ac435f1171b1349d429fce172e37a3f2 (diff)
CircuiTikZ 0.2.4 (12sep11)
git-svn-id: svn://tug.org/texlive/trunk@23913 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/circuitikz.code.tex46
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/circuitikz.sty25
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/circuitikz1.code.tex27
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcircbipoles.sty262
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcirclabel.sty123
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcircmath.sty27
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcircmonopoles.sty168
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcircquadpoles.sty90
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcircshapes.sty13
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/pgfcirctripoles.sty559
-rw-r--r--Master/texmf-dist/tex/latex/circuitikz/t-circuitikz.tex7
11 files changed, 1154 insertions, 193 deletions
diff --git a/Master/texmf-dist/tex/latex/circuitikz/circuitikz.code.tex b/Master/texmf-dist/tex/latex/circuitikz/circuitikz.code.tex
index d229aa280ff..5a33b71a775 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/circuitikz.code.tex
+++ b/Master/texmf-dist/tex/latex/circuitikz/circuitikz.code.tex
@@ -24,8 +24,20 @@
\ctikzset{nodes width/.initial=.04}
\newdimen\pgf@circ@Rlen
\ctikzset{bipoles/length/.code={\pgf@circ@Rlen = #1}}
+
\ctikzset{monopoles/.is family}
\ctikzset{monopoles/ground/width/.initial=.25}
+\ctikzset{monopoles/tlinestub/width/.initial=.25}
+\ctikzset{monopoles/antenna/width/.initial=.25}
+\ctikzset{monopoles/antenna/label/xanchor/.initial=.4}
+\ctikzset{monopoles/antenna/label/yanchor/.initial=.75}
+\ctikzset{monopoles/txantenna/label/xanchor/.initial=.4}
+\ctikzset{monopoles/txantenna/label/yanchor/.initial=.75}
+\ctikzset{monopoles/txantenna/width/.initial=.25}
+\ctikzset{monopoles/rxantenna/label/xanchor/.initial=.4}
+\ctikzset{monopoles/rxantenna/label/yanchor/.initial=.75}
+\ctikzset{monopoles/rxantenna/width/.initial=.25}
+
\ctikzset{bipoles/resistor/height/.initial=.3}
\ctikzset{bipoles/resistor/width/.initial=.8}
\ctikzset{bipoles/potentiometer/height/.initial=.8}
@@ -61,6 +73,8 @@
\ctikzset{bipoles/isourcesin/width/.initial=.60}
\ctikzset{bipoles/vsourcesin/height/.initial=.60}
\ctikzset{bipoles/vsourcesin/width/.initial=.60}
+\ctikzset{bipoles/vsourcesquare/height/.initial=.60}
+\ctikzset{bipoles/vsourcesquare/width/.initial=.60}
\ctikzset{bipoles/cisource/height/.initial=.7}
\ctikzset{bipoles/cisource/width/.initial=.7}
\ctikzset{bipoles/cisourceam/height/.initial=.7}
@@ -113,11 +127,19 @@
\ctikzset{bipoles/ammeter/width/.initial=.60}
\ctikzset{bipoles/voltmeter/height/.initial=.60}
\ctikzset{bipoles/voltmeter/width/.initial=.60}
+\ctikzset{bipoles/buffer/height/.initial=1}
+\ctikzset{bipoles/buffer/width/.initial=1}
\ctikzset{bipoles/not port/width/.initial=1}
\ctikzset{bipoles/not port/height/.initial=.8}
\ctikzset{bipoles/not port/circle width/.initial=.15}
\ctikzset{bipoles/lamp/height/.initial=.60}
\ctikzset{bipoles/lamp/width/.initial=.60}
+\ctikzset{bipoles/tline/height/.initial=.3}
+\ctikzset{bipoles/tline/width/.initial=.8}
+\ctikzset{bipoles/squid/height/.initial=.60}
+\ctikzset{bipoles/squid/width/.initial=.60}
+\ctikzset{bipoles/barrier/height/.initial=.60}
+\ctikzset{bipoles/barrier/width/.initial=.60}
\newif\ifpgf@circuit@mos@arrows
\ctikzset{tripoles/mos style/.is choice}
@@ -320,6 +342,11 @@
\ctikzset{tripoles/op amp/height/.initial=1.4}
\ctikzset{tripoles/op amp/input height/.initial=.5}
\ctikzset{tripoles/op amp/up pos/.initial=.45}
+\ctikzset{tripoles/plain amp/width/.initial=1.7}
+\ctikzset{tripoles/plain amp/port width/.initial=.7}
+\ctikzset{tripoles/plain amp/height/.initial=1.4}
+\ctikzset{tripoles/plain amp/input height/.initial=.5}
+\ctikzset{tripoles/plain amp/up pos/.initial=.45}
\ctikzset{tripoles/thyristor/height/.initial=1.10}
\ctikzset{tripoles/thyristor/height 2/.initial=.5}
@@ -333,8 +360,18 @@
\ctikzset{tripoles/triac/diode width left/.initial=.3}
\ctikzset{tripoles/triac/diode width right/.initial=.3}
+\ctikzset{tripoles/spdt/width/.initial=.85}
+\ctikzset{tripoles/spdt/height/.initial=.45}
+\ctikzset{tripoles/spdt/margin/.initial=.45}
+
+\ctikzset{tripoles/mixer/height/.initial=.85}
+\ctikzset{tripoles/mixer/width/.initial=.85}
+\ctikzset{tripoles/mixer/margin/.initial=.75}
+
\ctikzset{quadpoles/transformer/width/.initial=1.5}
+\ctikzset{quadpoles/transformer/width1/.initial=.4}
\ctikzset{quadpoles/transformer/height/.initial=1.5}
+\ctikzset{quadpoles/transformer/height1/.initial=.8}
\ctikzset{quadpoles/transformer core/width/.initial=1.5}
\ctikzset{quadpoles/transformer core/height/.initial=1.5}
\ctikzset{quadpoles/transformer core/core height/.initial=.5}
@@ -342,6 +379,8 @@
\ctikzset{quadpoles/gyrator/width/.initial=1.5}
\ctikzset{quadpoles/gyrator/height/.initial=1.5}
+
+
\ctikzset{bipole/.is family}
\ctikzset{bipole/direction/.initial = 0}
\ctikzset{bipole/kind/.initial = }
@@ -387,9 +426,6 @@
\ctikzset{bipole/label/position/.initial=90}
\ctikzset{bipole/label/unit/.initial=}
\ctikzset{bipole/label/name/.initial=}
-
-
-
\ctikzset{bipole/nodes/.is family}
\ctikzset{bipole/nodes/left/.is choice}
\ctikzset{bipole/nodes/left/none/.code={\ctikzsetvalof{bipole/nodes/left}{none}}}
@@ -464,6 +500,10 @@
\ctikzset{current/american/.code = \pgf@circuit@europeancurrentfalse }
\ctikzset{current/european/.code = \pgf@circuit@europeancurrenttrue }
+\ctikzset{label/align/.is choice}
+\ctikzset{label/align/straight/.code={\ctikzsetvalof{label/align}{straight}}}
+\ctikzset{label/align/rotate/.code={\ctikzsetvalof{label/align}{rotate}}}
+\ctikzset{label/align/smart/.code={\ctikzsetvalof{label/align}{smart}}}
%% dependencies
diff --git a/Master/texmf-dist/tex/latex/circuitikz/circuitikz.sty b/Master/texmf-dist/tex/latex/circuitikz/circuitikz.sty
index 7d17188cf48..2d201ce2a5b 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/circuitikz.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/circuitikz.sty
@@ -17,7 +17,7 @@
\NeedsTeXFormat{LaTeX2e}
-\def\pgfcircversion{0.2.3}
+\def\pgfcircversion{0.2.4}
\ProvidesPackage{circuitikz}%
[2009/11/18 The CircuiTikz circuit drawing package version \pgfcircversion]
@@ -110,6 +110,19 @@
\pgf@circuit@mos@arrowsfalse
}
+\DeclareOption{straightlabels}{
+ \ctikzset{label/align = straight}
+}
+
+\DeclareOption{rotatelabels}{
+ \ctikzset{label/align = rotate}
+}
+
+\DeclareOption{smartlabels}{
+ \ctikzset{label/align = smart}
+}
+
+
%%%%%%%%% Compatibility
@@ -169,6 +182,9 @@
\ctikzset{logic ports = european}
}
+\DeclareOption{europeanport}{
+ \ctikzset{logic ports = european}
+}
%%%%%%%%%
@@ -177,7 +193,7 @@
\input circuitikz.code.tex
-\ExecuteOptions{europeancurrents,europeanvoltages,americanports,americanresistors,cuteinductors,nosiunitx,noarrowmos}
+\ExecuteOptions{europeancurrents,europeanvoltages,americanports,americanresistors,cuteinductors,nosiunitx,noarrowmos,smartlabels}
\ProcessOptions\relax
@@ -194,8 +210,3 @@
\endinput
-* Da fare
-
-Uniformare il path dei bipoli e dei transistor
-Perché non ribalda gli induttori?
-Uniformare i casi dell'induttore tra il path del bipolo e la scelta del nodo nel trasformatore
diff --git a/Master/texmf-dist/tex/latex/circuitikz/circuitikz1.code.tex b/Master/texmf-dist/tex/latex/circuitikz/circuitikz1.code.tex
index 5df83a52d05..746d83ebe3b 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/circuitikz1.code.tex
+++ b/Master/texmf-dist/tex/latex/circuitikz/circuitikz1.code.tex
@@ -34,7 +34,9 @@
bipole/voltage/direction=backward, bipole/voltage/label/name=, bipole/voltage/position=below,
bipole/nodes/left=none, bipole/nodes/right=none, bipole/is voltage=false,
bipole/is current=false, bipole/current/label/name=, bipole/current/x position=after,
- bipole/current/y position=above, bipole/current/direction=forward, mirrored=false }
+ bipole/current/y position=above, bipole/current/direction=forward,
+ mirrored=false
+ }
}
@@ -74,8 +76,7 @@
(\ctikzvalof{bipole/name}start.center) -- (\ctikzvalof{bipole/name}.left)
(\ctikzvalof{bipole/name}.right) -- (\ctikzvalof{bipole/name}end.center)
\fi
- \pgf@circ@ifkeyempty{bipole/label/name}\else
- \pgf@circ@drawlabel\fi
+ \pgf@circ@ifkeyempty{bipole/label/name}\else\pgf@circ@drawlabel\fi
\drawpoles
\pgf@circ@ifkeyempty{bipole/voltage/label/name}\else\pgf@circ@drawvoltage\fi
\pgf@circ@ifkeyempty{bipole/current/label/name}\else\pgf@circ@drawcurrent\fi
@@ -140,6 +141,7 @@
\def\pgf@circ@vsourcesin@path#1{\pgf@circ@bipole@path{vsourcesin}{#1}}
\def\pgf@circ@isource@path#1{\pgf@circ@bipole@path{isource}{#1}}
\def\pgf@circ@isourcesin@path#1{\pgf@circ@bipole@path{isourcesin}{#1}}
+\def\pgf@circ@vsourcesquare@path#1{\pgf@circ@bipole@path{vsourcesquare}{#1}}
\def\pgf@circ@isourceam@path#1{\pgf@circ@bipole@path{isourceAM}{#1}}
\def\pgf@circ@cvsource@path#1{\pgf@circ@bipole@path{cvsource}{#1}}
\def\pgf@circ@cvsourceam@path#1{\pgf@circ@bipole@path{cvsourceAM}{#1}}
@@ -176,7 +178,9 @@
\def\pgf@circ@thyristor@path#1{\pgf@circ@bipole@path{thyristor}{#1}}
\def\pgf@circ@memristor@path#1{\pgf@circ@bipole@path{memristor}{#1}}
\def\pgf@circ@triac@path#1{\pgf@circ@bipole@path{triac}{#1}}
-
+\def\pgf@circ@tline@path#1{\pgf@circ@bipole@path{tline}{#1}}
+\def\pgf@circ@squid@path#1{\pgf@circ@bipole@path{squid}{#1}}
+\def\pgf@circ@barrier@path#1{\pgf@circ@bipole@path{barrier}{#1}}
%% Styles
%% Aggiungere per thyristor e tripoli semplici
@@ -209,6 +213,9 @@
\tikzset{variable european inductor/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@veuropeaninductor@path, l=#1}}
\tikzset{variable american inductor/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vamericaninductor@path, l=#1}}
\tikzset{variable cute inductor/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vcuteinductor@path, l=#1}}
+\tikzset{tline/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@tline@path, l=#1}}
+\tikzset{transmission line/.style = {tline = #1}}
+\tikzset{TL/.style = {tline = #1}}
\tikzset{european voltage source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vsource@path, \circuitikzbasekey/bipole/is voltage=true, v=#1}}
\tikzset{american voltage source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vsourceam@path, \circuitikzbasekey/bipole/is voltage=true, v=#1}}
\tikzset{european current source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@isource@path, \circuitikzbasekey/bipole/is current=true, i=#1}}
@@ -218,6 +225,7 @@
\tikzset{european controlled current source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@cisource@path, \circuitikzbasekey/bipole/is current=true, i=#1}}
\tikzset{american controlled current source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@cisourceam@path, \circuitikzbasekey/bipole/is current=true, i=#1}}
\tikzset{sinusoidal voltage source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vsourcesin@path, \circuitikzbasekey/bipole/is voltage=true, v=#1 }}
+\tikzset{square voltage source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@vsourcesquare@path, \circuitikzbasekey/bipole/is voltage=true, v=#1 }}
\tikzset{sinusoidal current source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@isourcesin@path, \circuitikzbasekey/bipole/is current=true, i=#1}}
\tikzset{controlled sinusoidal voltage source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@cvsourcesin@path, \circuitikzbasekey/bipole/is voltage=true, v=#1}}
\tikzset{controlled sinusoidal current source/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@cisourcesin@path, \circuitikzbasekey/bipole/is current=true, i=#1}}
@@ -238,6 +246,11 @@
\tikzset{lamp/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@lamp@path}}
+\tikzset{squid/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@squid@path}}
+\tikzset{barrier/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@barrier@path}}
+
+
+
\tikzset{full diode/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@fulldiode@path}}
\tikzset{full Schottky diode/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@fullsdiode@path}}
\tikzset{full Zener diode/.style = {\circuitikzbasekey, /tikz/to path=\pgf@circ@fullzdiode@path}}
@@ -276,8 +289,9 @@
\tikzset{vsource/.style = {voltage source = #1}}
\tikzset{isource/.style = {current source = #1}}
\tikzset{cisource/.style = {controlled current source = #1}}
-\tikzset{cvsource/.style = {controlled voltage source = #1}}
-\tikzset{vsourcesin/.style = {sinusoidal voltage source = #1}}
+\tikzset{cvsource/.style = {controlled voltage source = #1}}
+\tikzset{vsourcesin/.style = {sinusoidal voltage source = #1}}
+\tikzset{vsourcesquare/.style = {square voltage source = #1}}
\tikzset{isourcesin/.style = {sinusoidal current source = #1}}
\tikzset{cisourcesin/.style = {controlled sinusoidal current source = #1}}
\tikzset{cvsourcesin/.style = {controlled sinusoidal voltage source = #1}}
@@ -298,6 +312,7 @@
\tikzset{V/.style = {voltage source = #1}}
\tikzset{cV/.style = {controlled voltage source = #1}}
\tikzset{sV/.style = {sinusoidal voltage source = #1}}
+\tikzset{sqV/.style = {square voltage source = #1}}
\tikzset{csV/.style = {controlled sinusoidal voltage source = #1}}
\def\pgf@temp#1{
\tikzset{V#1/.style = {voltage source, v#1=##1} }
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcircbipoles.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcircbipoles.sty
index 96cd4ca2551..340b78f14a2 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcircbipoles.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcircbipoles.sty
@@ -395,6 +395,29 @@
}
+
+
+% contributed by Alistair Kwan
+\pgfcircdeclarebipole{}{\ctikzvalof{bipoles/vsourcesquare/height}}{vsourcesquare}{\ctikzvalof{bipoles/vsourcesquare/height}}{\ctikzvalof{bipoles/vsourcesquare/width}}{
+
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfpathellipse{\pgfpointorigin}{\pgfpoint{0}{\pgf@circ@res@up}}{\pgfpoint{\pgf@circ@res@left}{0}}
+ \pgfusepath{draw}
+
+ \pgf@circ@res@up = .5\pgf@circ@res@up
+ \pgfscope
+ \pgftransformrotate{90}
+ \pgfpathmoveto{\pgfpoint{-1\pgf@circ@res@up}{0cm}}
+ \pgfpathlineto{\pgfpoint{-1\pgf@circ@res@up}{1\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0\pgf@circ@res@up}{1\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0\pgf@circ@res@up}{-1\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{1\pgf@circ@res@up}{-1\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{1\pgf@circ@res@up}{0\pgf@circ@res@up}}
+ \pgfusepath{draw}
+ \endpgfscope
+}
+
+
%% Independent current source
\pgfcircdeclarebipole{}{\ctikzvalof{bipoles/isource/height}}{isource}{\ctikzvalof{bipoles/isource/height}}{\ctikzvalof{bipoles/isource/width}}{
@@ -1320,6 +1343,245 @@
\pgfusepath{draw}
}
+% Contributed by Leonardo Azzinnari
+
+\pgfcircdeclarebipole{}{\ctikzvalof{bipoles/tline/height}
+ }{tline}{\ctikzvalof{bipoles/tline/height}
+ }{\ctikzvalof{bipoles/tline/width}
+ }{\pgf@circ@res@step=\ctikzvalof{bipoles/tline/width} \pgf@circ@Rlen
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfpathellipse{\pgfpoint{0.5\pgf@circ@res@step}{0\pgf@circ@res@step}
+ }{\pgfpoint{0.125\pgf@circ@res@step}{0\pgf@circ@res@step}
+ }{\pgfpoint{0\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpathmoveto{\pgfpoint{0.5\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{-0.5\pgf@circ@res@step+0.125\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpatharc{-90}{90}{-0.125\pgf@circ@res@step and -0.25\pgf@circ@res@step}
+ \pgfpathlineto{\pgfpoint{0.5\pgf@circ@res@step}{-0.25\pgf@circ@res@step}}
+ \pgfusepath{draw}
+ }
+
+
+
+
+%% SQUID added by Cor Molenaar 5 March 2010
+
+\pgfcircdeclarebipole{}{\ctikzvalof{bipoles/squid/height}}{squid}{\ctikzvalof{bipoles/squid/height}}{\ctikzvalof{bipoles/squid/width}}{
+
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+
+ \pgfpathellipse{\pgfpointorigin}{\pgfpoint{0}{\pgf@circ@res@up}}{\pgfpoint{\pgf@circ@res@left}{0}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{1.35*\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{0.65*\pgf@circ@res@up}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{0.65*\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{1.35*\pgf@circ@res@up}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{1.35*\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{0.65*\pgf@circ@res@down}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{0.65*\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{1.35*\pgf@circ@res@down}}
+
+ \pgfusepath{draw}
+}
+
+
+
+% Generic barrier added by Cor Molenaar 5 March 2010
+
+\pgfcircdeclarebipole{}{\ctikzvalof{bipoles/barrier/height}}{barrier}{\ctikzvalof{bipoles/barrier/height}}{\ctikzvalof{bipoles/barrier/width}}{
+
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@left}{\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{\pgf@circ@res@right}{\pgf@circ@res@step}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{0.35*\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{0.35*\pgf@circ@res@down}}
+ \pgfpathmoveto{\pgfpoint{0.35*\pgf@circ@res@left}{0.35*\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{0.35*\pgf@circ@res@right}{0.35*\pgf@circ@res@up}}
+
+ \pgfusepath{draw}
+}
+
+
+% Contributed by Danilo Piazzalunga
+
+\pgfdeclareshape{buffer}
+ {
+ \anchor{center}{\pgfpointorigin}
+ \savedanchor\northwest{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/bipoles/buffer/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/bipoles/buffer/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \savedanchor\left{%
+ \pgf@y=0pt
+ }
+ \anchor{in}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{out}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+
+ \backgroundpath{
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+
+
+ \northwest
+ \pgf@circ@res@up = \pgf@y
+ \pgf@circ@res@down = -\pgf@y
+ \pgf@circ@res@right = -\pgf@x
+ \pgf@circ@res@left = \pgf@x
+
+ \pgfscope
+ \pgfsetlinewidth{2\pgflinewidth}
+ \pgftransformxshift{.7\pgf@circ@res@left}
+ \pgf@circ@res@step=\pgf@circ@res@right
+ \advance\pgf@circ@res@step by -\pgf@circ@res@left
+ \pgf@circ@res@step=.7\pgf@circ@res@step
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@step}{0pt}}
+ \pgfpathlineto{\pgfpoint{0pt}{\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0pt}{\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{\pgf@circ@res@step}{0pt}}
+ \pgfusepath{draw}
+ \endpgfscope
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@left}{0pt}}
+ \pgfpathlineto{\pgfpoint{.7\pgf@circ@res@left}{0pt}}
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@right}{0pt}}
+ \pgfpathlineto{\pgfpoint{.7\pgf@circ@res@right}{0pt}}
+
+ \pgfusepath{draw}
+
+ }
+ }
+
+
+
+\pgfdeclareshape{plain amp}
+ {
+ \anchor{center}{\pgfpointorigin}
+ \savedanchor\northwest{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \savedanchor\left{%
+ \pgf@y=0pt
+ }
+ \savedanchor\inOne{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/input height}\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{-}{
+ \inOne
+ }
+ \anchor{+}{
+ \inOne
+ \pgf@y=-\pgf@y
+ }
+ \savedanchor\up{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ \pgf@circ@res@up = \pgf@y
+ \pgf@circ@res@right = -\pgf@x
+ \pgf@circ@res@left = \pgf@x
+ \pgfpointlineattime{
+ \pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/up pos}}{
+ \pgfpoint{
+ \pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/port width}\pgf@circ@res@left}
+ {\pgf@circ@res@up}}
+ {\pgfpoint{.7\pgf@circ@res@right}{0pt}}
+ }
+ \anchor{up}{
+ \up
+ }
+ \anchor{down}{
+ \up
+ \pgf@y=-\pgf@y
+ }
+ \anchor{out}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+
+ \backgroundpath{
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+
+
+ \northwest
+ \pgf@circ@res@up = \pgf@y
+ \pgf@circ@res@down = -\pgf@y
+ \pgf@circ@res@right = -\pgf@x
+ \pgf@circ@res@left = \pgf@x
+
+ \pgfpathmoveto{\pgfpoint
+ {\pgf@circ@res@left}
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/input height}\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/port width}\pgf@circ@res@left}
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/input height}\pgf@circ@res@up}}
+
+
+ \pgfpathmoveto{\pgfpoint
+ {\pgf@circ@res@left}
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/input height}\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/port width}\pgf@circ@res@left}
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/plain amp/input height}\pgf@circ@res@down}}
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@right}{0pt}}
+ \pgfpathlineto{\pgfpoint{.7\pgf@circ@res@right}{0pt}}
+
+ \pgfusepath{draw}
+
+
+ \pgfscope
+ \pgfsetlinewidth{2\pgflinewidth}
+ \pgftransformxshift{.7\pgf@circ@res@left}
+ \pgf@circ@res@step=\pgf@circ@res@right
+ \advance\pgf@circ@res@step by -\pgf@circ@res@left
+ \pgf@circ@res@step=.7\pgf@circ@res@step
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@step}{0pt}}
+ \pgfpathlineto{\pgfpoint{0pt}{\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{0pt}{\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{\pgf@circ@res@step}{0pt}}
+ \pgfusepath{draw}
+ \endpgfscope
+
+
+
+ }
+ }
+
\endinput
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcirclabel.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcirclabel.sty
index 8ce4a72d9a3..120fa7f8cb3 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcirclabel.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcirclabel.sty
@@ -46,69 +46,86 @@
\circuitikzbasekey/bipole/label/position=-90 }
}
+
+
+\def\pgf@circ@drawlabel{
+ \pgfextra{
+ \edef\pgf@temp{\ctikzvalof{label/align}}
+ \def\pgf@circ@temp{straight}
+ }
+ \ifx\pgf@temp\pgf@circ@temp %straight
+ \pgf@circ@drawreglabel
+ \else
+ \pgfextra{\def\pgf@circ@temp{rotate}}
+ \ifx\pgf@temp\pgf@circ@temp %rotate
+ \pgf@circ@drawrotlabel
+ \else % smart
+ \pgf@circ@drawsmartlabel
+ \fi
+ \fi
+}
+
+\def\pgf@circ@drawsmartlabel{
+ \pgfextra{
+ %\pgfmathadd{\pgf@circ@direction}{360}
+ \pgfmathmod{\pgf@circ@direction}{90}
+ \edef\pgfcircmathresult{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
+ }
+ \ifnum \pgfcircmathresult > 20
+ \ifnum \pgfcircmathresult < 70 % NON quasi retto
+ \pgf@circ@drawrotlabel
+ \else
+ \pgf@circ@drawreglabel
+ \fi
+ \else
+ \pgf@circ@drawreglabel
+ \fi
+}
+
%% Output routing
%% #1 - node name
-\def\pgf@circ@drawlabel{
+\def\pgf@circ@drawrotlabel{
\pgfextra{
- \def\pgf@circ@temp{\ctikzvalof{bipole/label/position}}
- \edef\pgf@circ@ffffff{\pgf@circ@direction}
- \def\pgfcircmathresult{\expandafter\pgf@circ@stripdecimals\pgf@circ@ffffff\pgf@nil}
+ % calcolo rotazione label
+ \def\pgf@circ@temp{\ctikzvalof{bipole/label/position}} %%% àncora label
+ \edef\pgfcirclabrot{\pgf@circ@direction} % primo e quarto quadrante
+ \edef\pgfcircmathresult{\expandafter\pgf@circ@stripdecimals\pgf@circ@direction\pgf@nil}
+ \ifnum \pgfcircmathresult > 90 \ifnum \pgfcircmathresult < 270 % terzo e secondo
+ \pgfmathsubtract{\pgf@circ@direction}{180}
+ \edef\pgfcirclabrot{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
+ \pgfmathadd{\pgf@circ@temp}{180} %%%
+ \edef\pgf@circ@temp{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil} %%%
+ \fi\fi
- \ifnum \ctikzvalof{mirror value}=-1
- \pgfmathadd{\pgfcircmathresult}{+180}
- \def\pgfcircmathresult{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
+ \ifnum \ctikzvalof{mirror value} = -1
+ \pgfmathadd{\pgf@circ@temp}{180}
+ \edef\pgf@circ@temp{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
\fi
+ }
+ coordinate (labelcoor) at ($(\ctikzvalof{bipole/name})!2!(\ctikzvalof{bipole/name}.north)$)
+ (labelcoor) node [transform shape, rotate=\pgfcirclabrot] {\pgf@circ@finallabel{}}
+}
+
+\def\pgf@circ@drawreglabel{
+ \pgfextra{
+ \pgfmathsubtract{\pgf@circ@direction}{90}
+ \edef\pgf@circ@labanc{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
- \ifnum\pgfcircmathresult >4 \ifnum\pgfcircmathresult <86
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{south east} \else \def\pgf@circ@dir{north west}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >85 \ifnum\pgfcircmathresult <95
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{east} \else \def\pgf@circ@dir{west}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >94 \ifnum\pgfcircmathresult <176
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{north east} \else \def\pgf@circ@dir{south west}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >175 \ifnum\pgfcircmathresult <185
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{north} \else \def\pgf@circ@dir{south}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >184 \ifnum\pgfcircmathresult <256
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{north west}\else \def\pgf@circ@dir{south east}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >265 \ifnum\pgfcircmathresult <275
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{west} \else \def\pgf@circ@dir{east}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult >284 \ifnum\pgfcircmathresult <356
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{south west} \else \def\pgf@circ@dir{north east}
- \fi
- \fi\fi
- \ifnum\pgfcircmathresult <5
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{south} \else \def\pgf@circ@dir{north}
- \fi
+ \edef\pgf@circ@temp{\ctikzvalof{bipole/label/position}} %%% àncora label
+ \ifnum \pgf@circ@temp < 0
+ \pgfmathadd{\pgf@circ@labanc}{180}
+ \edef\pgf@circ@labanc{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
\fi
- \ifnum\pgfcircmathresult >355
- \ifnum\pgf@circ@temp>0
- \def\pgf@circ@dir{south} \else \def\pgf@circ@dir{north}
- \fi
+
+ \ifnum \ctikzvalof{mirror value} = -1
+ \pgfmathadd{\pgf@circ@labanc}{180}
+ \edef\pgf@circ@labanc{\expandafter\pgf@circ@stripdecimals\pgfmathresult\pgf@nil}
\fi
}
- node [anchor=\pgf@circ@dir] at (\ctikzvalof{bipole/name}.\pgf@circ@temp) {
- \pgf@circ@finallabel{}
- }
+ node [ anchor = \pgf@circ@labanc]
+ at (\ctikzvalof{bipole/name}.\pgf@circ@temp) {\pgf@circ@finallabel{}}
}
+
\endinput
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcircmath.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcircmath.sty
index f7095d337a2..bcde183dd9a 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcircmath.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcircmath.sty
@@ -20,15 +20,23 @@
\pgf@process{#2}%
\advance\pgf@x by-\pgf@xa%
\advance\pgf@y by-\pgf@ya%
- \ifdim\pgf@x=0pt
- \ifdim\pgf@y<0pt
- \def\pgfmathresult{-90.0}
- \else
- \def\pgfmathresult{+90.0}
- \fi
- \else
- \pgfmathdivide{\pgf@y}{\pgf@x}
- \pgfmathatan{\pgfmathresult}
+ \ifdim\pgf@x<0.0001pt
+ \ifdim\pgf@x>-0.0001pt % vertical
+ \ifdim\pgf@y<0pt
+ \def\pgfmathresult{-90.0}
+ \else
+ \def\pgfmathresult{+90.0}
+ \fi
+ \else % oblique with dx < 0
+ \pgfmathdivide{\pgf@y}{\pgf@x}
+ \pgfmathatan{\pgfmathresult}
+ \ifdim\pgf@x<0pt
+ \pgfmathsubtract{\pgfmathresult}{+180}
+ \fi
+ \fi
+ \else % oblique with dx > 0
+ \pgfmathdivide{\pgf@y}{\pgf@x}
+ \pgfmathatan{\pgfmathresult}
\ifdim\pgf@x<0pt
\pgfmathsubtract{\pgfmathresult}{+180}
\fi
@@ -40,3 +48,4 @@
}
\endinput
+
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcircmonopoles.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcircmonopoles.sty
index 1d8f46376d2..569c12039e6 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcircmonopoles.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcircmonopoles.sty
@@ -49,4 +49,172 @@
}
+
+% Contributed by Leonardo Azzinnari
+\pgfdeclareshape{tlinestub}{
+ \anchor{center}{\pgfpointorigin}
+ \behindforegroundpath{
+ \pgfstartlinewidth=\pgflinewidth
+
+ \pgf@circ@res@step=\ctikzvalof{bipoles/tline/width} \pgf@circ@Rlen
+ \pgfpathmoveto{\pgfpoint{0.5\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathlineto{\pgfpoint{0.5\pgf@circ@res@step}{0pt}}
+ \pgfusepath{draw}
+ \pgfscope
+ \pgfpathellipse{\pgfpoint{0.5\pgf@circ@res@step}{0\pgf@circ@res@step}}{\pgfpoint{0.125\pgf@circ@res@step}{0\pgf@circ@res@step}}{\pgfpoint{0\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpathmoveto{\pgfpoint{0.5\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{1.5\pgf@circ@res@step}{0.25\pgf@circ@res@step}}
+ \pgfpatharc{90}{-90}{0.125\pgf@circ@res@step and 0.25\pgf@circ@res@step}
+ \pgfpathlineto{\pgfpoint{0.5\pgf@circ@res@step}{-0.25\pgf@circ@res@step}}
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+ }
+}
+
+
+
+
+\pgfdeclareshape{antenna}{
+\anchor{center}{\pgfpointorigin}
+ \savedanchor{\northeast}{
+ \pgf@circ@res@step=\ctikzvalof{monopoles/antenna/width}\pgf@circ@Rlen
+ \pgf@x=5\pgf@circ@res@step%-0.5\pgflinewidth
+ \pgf@y=6\pgf@circ@res@step
+ }
+ \anchor{text}{
+ \northeast
+ \pgf@x=\ctikzvalof{monopoles/antenna/label/xanchor}\pgf@x
+ \pgf@y=\ctikzvalof{monopoles/antenna/label/yanchor}\pgf@y
+ }
+ \behindforegroundpath{
+ \pgfstartlinewidth=\pgflinewidth
+ \pgf@circ@res@step=\ctikzvalof{monopoles/antenna/width}\pgf@circ@Rlen
+
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step}{0pt}}
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{0pt}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+
+ \pgfusepath{draw}
+
+ \pgfscope
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{5\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{4\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{3\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+ \pgfsetlinewidth{\pgfstartlinewidth}
+
+ }
+ }
+
+
+\pgfdeclareshape{txantenna}{
+ \anchor{center}{\pgfpointorigin}
+ \savedanchor{\northeast}{
+ \pgf@circ@res@step=\ctikzvalof{monopoles/txantenna/width}\pgf@circ@Rlen
+ \pgf@x=5\pgf@circ@res@step%-0.5\pgflinewidth
+ \pgf@y=6\pgf@circ@res@step
+ }
+ \anchor{text}{
+ \northeast
+ \pgf@x=\ctikzvalof{monopoles/txantenna/label/xanchor}\pgf@x
+ \pgf@y=\ctikzvalof{monopoles/txantenna/label/yanchor}\pgf@y
+ }
+ \behindforegroundpath{
+ \pgfstartlinewidth=\pgflinewidth
+ \pgf@circ@res@step=\ctikzvalof{monopoles/txantenna/width}\pgf@circ@Rlen
+
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step}{0pt}}
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{0pt}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+
+ \pgfusepath{draw}
+
+ \pgfscope
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{5\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{4\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{3\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+ \pgfpathmoveto{\pgfpoint{5.5\pgf@circ@res@step}{6\pgf@circ@res@step}}
+% \pgfpatharc{60}{-60}{\pgf@circ@res@step and \pgf@circ@res@step}
+ \pgfpatharc{30}{-30}{2\pgf@circ@res@step} \pgfpathmoveto{\pgfpoint{6\pgf@circ@res@step}{6.25\pgf@circ@res@step}}
+ \pgfpatharc{30}{-30}{2.5\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{6.5\pgf@circ@res@step}{6.5\pgf@circ@res@step}}
+ \pgfpatharc{30}{-30}{3\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{7\pgf@circ@res@step}{6.75\pgf@circ@res@step}}
+ \pgfpatharc{30}{-30}{3.5\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{7.5\pgf@circ@res@step}{7\pgf@circ@res@step}}
+ \pgfpatharc{30}{-30}{4\pgf@circ@res@step}
+ \pgfusepath{draw}
+ \pgfsetlinewidth{\pgfstartlinewidth}
+
+ }
+ }
+
+
+\pgfdeclareshape{rxantenna}{
+ \anchor{center}{\pgfpointorigin}
+ \savedanchor{\northeast}{
+ \pgf@circ@res@step=\ctikzvalof{monopoles/txantenna/width}\pgf@circ@Rlen
+ \pgf@x=5\pgf@circ@res@step%-0.5\pgflinewidth
+ \pgf@y=6\pgf@circ@res@step
+ }
+ \anchor{text}{
+ \northeast
+ \pgf@x=\ctikzvalof{monopoles/rxantenna/label/xanchor}\pgf@x
+ \pgf@y=\ctikzvalof{monopoles/rxantenna/label/yanchor}\pgf@y
+ }
+ \behindforegroundpath{
+ \pgfstartlinewidth=\pgflinewidth
+ \pgf@circ@res@step=\ctikzvalof{monopoles/rxantenna/width}\pgf@circ@Rlen
+
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step}{0pt}}
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{0pt}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+
+ \pgfusepath{draw}
+
+ \pgfscope
+ \pgfpathmoveto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{5\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{4\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{3\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfpathlineto{\pgfpoint{4\pgf@circ@res@step-0.5\pgflinewidth}{6\pgf@circ@res@step}}
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+ \pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgfstartlinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+
+ \pgfpathmoveto{\pgfpoint{6\pgf@circ@res@step}{7\pgf@circ@res@step}}
+% \pgfpatharc{60}{-60}{\pgf@circ@res@step and \pgf@circ@res@step}
+ \pgfpatharc{150}{210}{4\pgf@circ@res@step} \pgfpathmoveto{\pgfpoint{6.5\pgf@circ@res@step}{6.75\pgf@circ@res@step}}
+ \pgfpatharc{150}{210}{3.5\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{7\pgf@circ@res@step}{6.5\pgf@circ@res@step}}
+ \pgfpatharc{150}{210}{3\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{7.5\pgf@circ@res@step}{6.25\pgf@circ@res@step}}
+ \pgfpatharc{150}{210}{2.5\pgf@circ@res@step}
+ \pgfpathmoveto{\pgfpoint{8\pgf@circ@res@step}{6\pgf@circ@res@step}}
+ \pgfpatharc{150}{210}{2\pgf@circ@res@step}
+ \pgfusepath{draw}
+ \pgfsetlinewidth{\pgfstartlinewidth}
+
+ }
+}
+
+
\endinput
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcircquadpoles.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcircquadpoles.sty
index 8a736173244..33e63e6be85 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcircquadpoles.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcircquadpoles.sty
@@ -10,7 +10,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Quadripoles
-\long\def\pgfcircdeclarequadpole#1#2{
+\long\def\pgfcircdeclarequadpole#1#2#3{
\pgfdeclareshape{#1}
{
\anchor{center}{
@@ -25,46 +25,61 @@
\pgf@x=.5\pgf@x
\pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/quadpoles/#1/width}\pgf@x
}
- \anchor{south west}{
+ \anchor{A2}{
\northwest
\pgf@y=-\pgf@y
}
- \anchor{north east}{
+ \anchor{B1}{
\northwest
\pgf@x=-\pgf@x
}
- \anchor{north west}{
+ \anchor{A1}{
\northwest
}
- \anchor{south east}{
+ \anchor{B2}{
\northwest
\pgf@x=-\pgf@x
\pgf@y=-\pgf@y
}
- \anchor{A2}{
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{west}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{east}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+ \anchor{south west}{
\northwest
\pgf@y=-\pgf@y
}
- \anchor{B1}{
+ \anchor{north east}{
\northwest
\pgf@x=-\pgf@x
}
- \anchor{A1}{
+ \anchor{north west}{
\northwest
}
- \anchor{B2}{
+ \anchor{south east}{
\northwest
\pgf@x=-\pgf@x
\pgf@y=-\pgf@y
- }
- \anchor{north}{
- \northwest
- \pgf@x=0pt
- }
+ }
\anchor{base}{
\northwest
\pgf@x=0pt
}
+ #3
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
@@ -74,7 +89,7 @@
\pgf@circ@res@right = -\pgf@x
\pgf@circ@res@left = \pgf@x
- \pgf@circ@Rlen=\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ %\pgf@circ@Rlen=\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
#2
@@ -84,9 +99,40 @@
-\def\pgf@circ@drawtransformerbasic{
+\def\pgf@circ@drawtransformerbasicanchor{
+ \pgfkeysvalueof{/tikz/circuitikz/quadpoles/trans/height}
+ \anchor{AA2}{
+ \northwest
+ \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/width1}\pgf@x
+ \pgf@x=.7\pgf@x
+ \pgf@y=-\pgf@y
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/height1}\pgf@y
+ }
+ \anchor{BB1}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/width1}\pgf@x
+ \pgf@x=.7\pgf@x
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/height1}\pgf@y
+ }
+ \anchor{AA1}{
+ \northwest
+ \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/width1}\pgf@x
+ \pgf@x=.7\pgf@x
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/height1}\pgf@y
+ }
+ \anchor{BB2}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/width1}\pgf@x
+ \pgf@x=.7\pgf@x
+ \pgf@y=-\pgf@y
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/quadpoles/transformer/height1}\pgf@y
+ }
+}
-\def\stretto{.4}
+\def\pgf@circ@drawtransformerbasicbody{
+ \def\stretto{.4}
\pgfscope
\pgfslopedattimetrue
\pgfallowupsidedownattimetrue
@@ -166,13 +212,13 @@
\pgfcircdeclarequadpole{transformer}{
- \pgf@circ@drawtransformerbasic
+ \pgf@circ@drawtransformerbasicbody
-}
+}{\pgf@circ@drawtransformerbasicanchor}
\pgfcircdeclarequadpole{transformer core}{
- \pgf@circ@drawtransformerbasic
+ \pgf@circ@drawtransformerbasicbody
\pgfmoveto{\pgfpoint%
{\ctikzvalof{quadpoles/transformer core/core width}\pgf@circ@res@right}%
@@ -196,7 +242,7 @@
\pgfsetlinewidth{\pgfkeysvalueof{/tikz/circuitikz/bipoles/thickness}\pgflinewidth}
\pgfusepath{draw}
-}
+}{\pgf@circ@drawtransformerbasicanchor}
\pgfcircdeclarequadpole{gyrator}{
@@ -223,4 +269,4 @@
\pgfpatharc{-90}{90}{.7*\stretto\pgf@circ@res@down}
\pgfusepath{draw}
-}
+}{}
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcircshapes.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcircshapes.sty
index c2f1826db5a..52ee97a00c8 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcircshapes.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcircshapes.sty
@@ -50,6 +50,12 @@
\anchor{center}{
\pgfpointorigin
}
+ \anchorborder{
+ \pgf@circ@res@left=\pgf@x
+ \pgf@circ@res@up=\pgf@y
+ \pgfpointborderellipse{\pgfpoint{\pgf@circ@res@left}{\pgf@circ@res@up}
+}{\pgfpoint{\pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}{\pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}}
+ }
\behindforegroundpath{
\pgfscope
@@ -67,6 +73,13 @@
\anchor{center}{
\pgfpointorigin
}
+ \anchorborder{
+ \pgf@circ@res@left=\pgf@x
+ \pgf@circ@res@up=\pgf@y
+ \pgfpointborderellipse{\pgfpoint{\pgf@circ@res@left}{\pgf@circ@res@up}
+}{\pgfpoint{\pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}{\pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}}
+ }
+
\behindforegroundpath{
\pgfscope
diff --git a/Master/texmf-dist/tex/latex/circuitikz/pgfcirctripoles.sty b/Master/texmf-dist/tex/latex/circuitikz/pgfcirctripoles.sty
index 6fae7459b46..d077f87b73b 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/pgfcirctripoles.sty
+++ b/Master/texmf-dist/tex/latex/circuitikz/pgfcirctripoles.sty
@@ -11,6 +11,243 @@
%% Tripoles
+%\long\def\pgfcircdeclaremixed{
+ \pgfdeclareshape{mixer}
+ {
+ \savedanchor\northwest{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/mixer/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/mixer/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{left}{%
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{in 1}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{in}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{in 2}{
+ \northwest
+ \pgf@y=-\pgf@y
+ \pgf@x=0pt
+ }
+ \anchor{out}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+ \anchor{center}{
+ \pgf@y=0pt
+ \pgf@x=0pt
+ }
+ \anchor{east}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+ \anchor{west}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south west}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{north west}{
+ \northwest
+ }
+ \anchor{south east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
+ \backgroundpath{
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+
+
+ \northwest
+ \pgf@circ@res@up = \pgf@y
+ \pgf@circ@res@down = -\pgf@y
+ \pgf@circ@res@right = -\pgf@x
+ \pgf@circ@res@left = \pgf@x
+ \pgf@circ@res@other = \pgfkeysvalueof{/tikz/circuitikz/tripoles/mixer/margin}\pgf@circ@res@up
+
+ \pgfscope
+ \pgfpathellipse
+ {\pgfpoint{0pt}{0pt}}
+ {\pgfpoint{\pgf@circ@res@other}{0pt}}
+ {\pgfpoint{0pt}{\pgf@circ@res@other}}
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathmoveto{\pgfpointpolar{135}{\pgf@circ@res@other}}
+ \pgfpathlineto{\pgfpointpolar{-45}{\pgf@circ@res@other}}
+ \pgfpathmoveto{\pgfpointorigin}
+ \pgfpathmoveto{\pgfpointpolar{45}{\pgf@circ@res@other}}
+ \pgfpathlineto{\pgfpointpolar{-135}{\pgf@circ@res@other}}
+ \pgfsetlinewidth{2\pgflinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+
+ \pgfpathmoveto{\pgfpoint{0pt}{-\pgf@circ@res@other}}
+ \pgfpathlineto{\pgfpoint{0pt}{-\pgf@circ@res@up}}
+ \pgfpathmoveto{\pgfpoint{-\pgf@circ@res@other}{0pt}}
+ \pgfpathlineto{\pgfpoint{-\pgf@circ@res@up}{0pt}}
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@other}{0pt}}
+ \pgfpathlineto{\pgfpoint{\pgf@circ@res@up}{0pt}}
+
+ \pgfusepath{draw}
+
+ }
+ }
+%}
+
+
+
+ \pgfdeclareshape{spdt}
+ {
+ \savedanchor\northwest{%
+ \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/spdt/height}\pgf@y
+ \pgf@y=.5\pgf@y
+ \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+ \pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/spdt/width}\pgf@x
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{left}{%
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{in}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{out 1}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{out 2}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
+ \anchor{center}{
+ \pgf@y=0pt
+ \pgf@x=0pt
+ }
+ \anchor{east}{
+ \northwest
+ \pgf@y=0pt
+ \pgf@x=-\pgf@x
+ }
+ \anchor{west}{
+ \northwest
+ \pgf@y=0pt
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south west}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{north west}{
+ \northwest
+ }
+ \anchor{south east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
+ \backgroundpath{
+ \pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
+
+
+ \northwest
+ \pgf@circ@res@up = \pgf@y
+ \pgf@circ@res@down = -\pgf@y
+ \pgf@circ@res@right = -\pgf@x
+ \pgf@circ@res@left = \pgf@x
+ \pgf@circ@res@other = \pgfkeysvalueof{/tikz/circuitikz/tripoles/spdt/margin}\pgf@circ@res@left
+
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@right}{\pgf@circ@res@up}}
+ \pgfpathlineto{\pgfpoint{-\pgf@circ@res@other}{\pgf@circ@res@up}}
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@right}{\pgf@circ@res@down}}
+ \pgfpathlineto{\pgfpoint{-\pgf@circ@res@other}{\pgf@circ@res@down}}
+
+ \pgfpathmoveto{\pgfpoint{\pgf@circ@res@left}{0pt}}
+ \pgfpathlineto{\pgfpoint{\pgf@circ@res@other}{0pt}}
+
+ \pgfusepath{draw}
+
+ \pgfscope
+ \pgftransformshift{\pgfpoint{-\pgf@circ@res@other}{\pgf@circ@res@up}}
+ \pgfnode{ocirc}{center}{}{spdt1}{\pgfusepath{stroke}}
+ \endpgfscope
+ \pgfscope
+ \pgftransformshift{\pgfpoint{-\pgf@circ@res@other}{\pgf@circ@res@down}}
+ \pgfnode{ocirc}{center}{}{}{\pgfusepath{stroke}}
+ \endpgfscope
+ \pgfscope
+ \pgftransformshift{\pgfpoint{\pgf@circ@res@other}{0pt}}
+ \pgfnode{ocirc}{center}{}{spdt2}{\pgfusepath{stroke}}
+ \endpgfscope
+
+
+ \pgfscope
+ \pgfpathmoveto{\pgfpointshapeborder{spdt2}{\pgfpointorigin}}
+ \pgfpathlineto{
+ \pgfpointadd{\pgfpointshapeborder{spdt1}{\pgfpoint{-\pgf@circ@res@other}{-100pt}}}
+ {\pgfpoint{-.05\pgf@circ@res@up}{-.05\pgf@circ@res@up}}
+ }
+ \pgfsetlinewidth{2\pgflinewidth}
+ \pgfusepath{draw}
+ \endpgfscope
+ }
+ }
+
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%%
+%% Logic ports
+%%
+
+
+
+
+
\long\def\pgfcircdeclarelogicport#1#2{
\pgfdeclareshape{american #1 port}
@@ -23,10 +260,6 @@
\pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/american #1 port/width}\pgf@x
\pgf@x=.5\pgf@x
}
- \anchor{south}{
- \north
- \pgf@y=-\pgf@y
- }
\savedanchor\left{%
\pgf@y=0pt
}
@@ -59,7 +292,38 @@
\pgf@y=0pt
\pgf@x=-.8\pgf@x
}
-
+ \anchor{east}{
+ \left
+ \pgf@x=-.8\pgf@x
+ }
+ \anchor{west}{
+ \left
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south west}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{north west}{
+ \northwest
+ }
+ \anchor{south east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
@@ -416,10 +680,6 @@
\pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/bipoles/not port/width}\pgf@x
\pgf@x=.5\pgf@x
}
- \anchor{south}{
- \northwest
- \pgf@y=-\pgf@y
- }
\savedanchor\left{%
\pgf@y=0pt
}
@@ -435,7 +695,38 @@
\anchor{center}{
\pgfpointorigin
}
-
+ \anchor{east}{
+ \left
+ \pgf@x=-.8\pgf@x
+ }
+ \anchor{west}{
+ \left
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south west}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{north west}{
+ \northwest
+ }
+ \anchor{south east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
@@ -501,10 +792,6 @@
\pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/european #1 port/width}\pgf@x
\pgf@x=.5\pgf@x
}
- \anchor{south}{
- \north
- \pgf@y=-\pgf@y
- }
\savedanchor\left{%
\pgf@y=0pt
}
@@ -537,7 +824,38 @@
\pgf@y=0pt
\pgf@x=-.8\pgf@x
}
-
+ \anchor{east}{
+ \left
+ \pgf@x=-.8\pgf@x
+ }
+ \anchor{west}{
+ \left
+ }
+ \anchor{south}{
+ \northwest
+ \pgf@x=0pt
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north}{
+ \northwest
+ \pgf@x=0pt
+ }
+ \anchor{south west}{
+ \northwest
+ \pgf@y=-\pgf@y
+ }
+ \anchor{north east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ }
+ \anchor{north west}{
+ \northwest
+ }
+ \anchor{south east}{
+ \northwest
+ \pgf@x=-\pgf@x
+ \pgf@y=-\pgf@y
+ }
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
\northwest
@@ -610,53 +928,91 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
\long\def\pgfcircdeclaretransistor#1#2#3{
\pgfdeclareshape{#1}
{
- \anchor{center}{\pgfpointorigin}
- \savedanchor\north{%
+ \anchor{center}{\pgfpointorigin}
+ \savedanchor\northeast{% upper right
\pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
\pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/height}\pgf@y
\pgf@y=.5\pgf@y
\pgf@x=0pt
}
- \savedanchor\northeast{%
- \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
- \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/height}\pgf@y
- \pgf@y=.5\pgf@y
- \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
- \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/width}\pgf@x
- }
- \anchor{south}{
- \north
- \pgf@y=-\pgf@y
- }
- \savedanchor\left{%
+% \savedanchor\northeast{%
+% \pgf@y= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+% \pgf@y=\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/height}\pgf@y
+% \pgf@y=.5\pgf@y
+% \pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
+% \pgf@x=\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/width}\pgf@x
+% }
+ \savedanchor\left{%center left
\pgf@y=0pt
\pgf@x= \pgfkeysvalueof{/tikz/circuitikz/bipoles/length}
\pgf@x=-\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/width}\pgf@x
}
\anchor{text}{
- \north
- \pgfpoint
- {12\pgf@circ@res@right +0.2*(\pgf@circ@res@right-\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/gate width}\pgf@circ@res@left)}
- {0.6\pgf@y}
+ \northeast
+ \pgfpoint
+ {12\pgf@circ@res@right +0.2*(\pgf@circ@res@right-\pgfkeysvalueof{/tikz/circuitikz/tripoles/#1/gate width}\pgf@circ@res@left)}
+ {0.6\pgf@y}
}
%
% pseudo-bipole
- \anchor{left}{
- \north
+ \anchor{left}{ % south
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{right}{
- \north
+ \northeast
+ }
+ \anchor{north}{
+ \northeast
+ \pgf@circ@res@step=\pgf@y
+ \left
+ \pgf@y=\pgf@circ@res@step
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{west}{
+ \left
+ }
+ \anchor{east}{
+ \pgf@x=0pt
+ \pgf@y=0pt
}
+ \anchor{south}{
+ \northeast
+ \pgf@circ@res@step=\pgf@y
+ \left
+ \pgf@y=-\pgf@circ@res@step
+ \pgf@x=.5\pgf@x
+ }
+ \anchor{south west}{
+ \northeast
+ \pgf@circ@res@step=\pgf@y
+ \left
+ \pgf@y=-\pgf@circ@res@step
+ }
+ \anchor{north east}{
+ \northeast
+ }
+ \anchor{north west}{
+ \northeast
+ \pgf@circ@res@step=\pgf@y
+ \left
+ \pgf@y=\pgf@circ@res@step
+ }
+ \anchor{south east}{
+ \northeast
+ \pgf@y=-\pgf@y
+ }
+
#2
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
%
%
- \north
+ \northeast
\pgf@circ@res@up = \pgf@y
\pgf@circ@res@down = -\pgf@y
\pgf@circ@res@right = \pgf@x
@@ -705,17 +1061,17 @@
\pgfcircdeclaremos{nmos}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -781,17 +1137,17 @@
\pgfcircdeclaremos{pmos}{
\anchor{S}{
- \north
+ \northeast
}
\anchor{source}{
- \north
+ \northeast
}
\anchor{D}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{drain}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -846,11 +1202,18 @@
{\pgfkeysvalueof{/tikz/circuitikz/tripoles/pmos/gate width}\pgf@circ@res@left}
{\pgfkeysvalueof{/tikz/circuitikz/tripoles/pmos/gate height}\pgf@circ@res@down}}
+
\pgfpathmoveto{\pgfpoint
{\pgfkeysvalueof{/tikz/circuitikz/tripoles/pmos/gate width}\pgf@circ@res@left}
{\pgf@circ@res@up+\pgf@circ@res@down}}
\pgfpathlineto{\pgfpoint{\pgf@circ@res@left}{\pgf@circ@res@up+\pgf@circ@res@down}}
\pgfusepath{draw}
+
+ \pgfpathcircle{\pgfpoint
+ {\pgfkeysvalueof{/tikz/circuitikz/tripoles/pmos/gate width}\pgf@circ@res@left - \pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}
+ {\pgf@circ@res@up+\pgf@circ@res@down}}{\pgfkeysvalueof{/tikz/circuitikz/nodes width}*\pgfkeysvalueof{/tikz/circuitikz/bipoles/length}}
+ \pgfusepath{draw,fill}
+
}
@@ -861,10 +1224,10 @@
\pgfcircdeclaretransistor{pnp}{
\anchor{E}{
- \north
+ \northeast
}
\anchor{emitter}{
- \north
+ \northeast
}
\anchor{B}{
\left
@@ -873,11 +1236,11 @@
\left
}
\anchor{C}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{collector}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{
@@ -938,10 +1301,10 @@
\pgfcircdeclaretransistor{npn}{
\anchor{C}{
- \north
+ \northeast
}
\anchor{collector}{
- \north
+ \northeast
}
\anchor{B}{
\left
@@ -950,11 +1313,11 @@
\left
}
\anchor{E}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{emitter}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1013,10 +1376,10 @@
\pgfcircdeclaretransistor{pigbt}{
\anchor{E}{
- \north
+ \northeast
}
\anchor{emitter}{
- \north
+ \northeast
}
\anchor{B}{
\left
@@ -1025,11 +1388,11 @@
\left
}
\anchor{C}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{collector}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{
@@ -1100,10 +1463,10 @@
\pgfcircdeclaretransistor{nigbt}{
\anchor{C}{
- \north
+ \northeast
}
\anchor{collector}{
- \north
+ \northeast
}
\anchor{B}{
\left
@@ -1112,11 +1475,11 @@
\left
}
\anchor{E}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{emitter}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{
@@ -1230,17 +1593,17 @@
\pgfcircdeclarefet{nfet}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
@@ -1323,17 +1686,17 @@
\pgfcircdeclarefet{pfet}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1423,17 +1786,17 @@
% N-CHANNEL IGFET ENHANCEMENT TYPE
\pgfcircdeclarefet{nigfete}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1524,17 +1887,17 @@
% N-CHANNEL IGFET DEPLETION TYPE
\pgfcircdeclarefet{nigfetd}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1614,17 +1977,17 @@
% P-CHANNEL IGFET ENHANCEMENT TYPE
\pgfcircdeclarefet{pigfete}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1723,17 +2086,17 @@
% P-CHANNEL IGFET DEPLETION TYPE
\pgfcircdeclarefet{pigfetd}{
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1848,17 +2211,17 @@
\pgf@y=-.5\pgf@y
}
\anchor{D}{
- \north
+ \northeast
}
\anchor{drain}{
- \north
+ \northeast
}
\anchor{S}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{source}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -1929,17 +2292,17 @@
\pgf@y=.5\pgf@y
}
\anchor{S}{
- \north
+ \northeast
}
\anchor{source}{
- \north
+ \northeast
}
\anchor{D}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
\anchor{drain}{
- \north
+ \northeast
\pgf@y=-\pgf@y
}
}{%
@@ -2161,6 +2524,9 @@
\northwest
\pgf@y=-\pgf@y
}
+ \anchor{north}{
+ \northwest
+ }
\savedanchor\left{%
\pgf@y=0pt
}
@@ -2209,6 +2575,13 @@
\pgf@y=0pt
\pgf@x=-\pgf@x
}
+ \anchor{west}{
+ \left
+ }
+ \anchor{east}{
+ \left
+ \pgf@x=-\pgf@x
+ }
\backgroundpath{
\pgfsetcolor{\pgfkeysvalueof{/tikz/circuitikz/color}}
diff --git a/Master/texmf-dist/tex/latex/circuitikz/t-circuitikz.tex b/Master/texmf-dist/tex/latex/circuitikz/t-circuitikz.tex
index 12671123ff3..0af74491c15 100644
--- a/Master/texmf-dist/tex/latex/circuitikz/t-circuitikz.tex
+++ b/Master/texmf-dist/tex/latex/circuitikz/t-circuitikz.tex
@@ -24,6 +24,13 @@
american=>\ctikzset{ current=american}
]
+\processaction[\currentmoduleparameter{label}]
+ [
+ straight=>\ctikzset{label/align = straight}
+ align=>\ctikzset{label/align = rotate}
+ smart=>\ctikzset{label/align = smart}
+ ]
+
\processaction[\currentmoduleparameter{resistor}]
[ european=>\ctikzset{ resistor=european},
american=>\ctikzset{ resistor=american}