无法更改 circuitikz 中的标签位置

无法更改 circuitikz 中的标签位置

当我在 circuitikz 中以一定角度绘制组件时,我无法通过l_=label参数更改标签的位置。但是,水平或垂直绘制对标签放置有相反的影响l_=labell=label

水平、垂直和倾斜组件

这是预期的行为吗?我想将二极管标签放置在桥式整流器电路之外,但不知道如何操作。我正在使用 MacTeX 2016。

\documentclass[12pt,a4paper]{article}
\usepackage{circuitikz}
\begin{document}
\begin{circuitikz}
\draw (0,0) to[Do,l=D] (2,0);\draw (4,0) to[Do,l_=D] (6,0);
\draw (8,-1) to[Do,l=D] (8,1);\draw (10,-1) to[Do,l_=D] (10,1);
\end{circuitikz}
\vskip 0.1in
The underscore sign changes label position.
\vskip 0.1in\hrule\vskip 0.1in
\begin{circuitikz}
\draw (0,1) to[Do,l=D] (2,-1);\draw (3,1) to[Do,l_=D] (5,-1);
\draw (6,-1) to[Do,l=D] (8,1);\draw (9,-1) to[Do,l_=D] (11,1);
\end{circuitikz}
\vskip 0.1in
The underscore sign does not change label position.
\vskip 0.1in\hrule\vskip 0.1in
\begin{circuitikz}
\draw (0,0) to[R,l=R] (2,0);\draw (4,0) to[R,l_=R] (6,0);
\draw (8,-1) to[R,l=R] (8,1);\draw (10,-1) to[R,l_=R] (10,1);
\end{circuitikz}
\vskip 0.1in
The underscore sign changes label position.
\vskip 0.1in\hrule\vskip 0.1in
\begin{circuitikz}
\draw (0,-1) to[R,l=R] (2,1);\draw (3,-1) to[R,l_=R] (5,1);
\draw (6,1) to[R,l=R] (8,-1);\draw (9,1) to[R,l_=R] (11,-1);
\end{circuitikz}
\vskip 0.1in
The underscore sign does not change label position.
\end{document}

答案1

我可以正常编译它并获得所需的结果,这可能是版本或编译器的问题。

我的软件详细信息:

pdfTeX, Version 3.14159265-2.6-1.40.19 (MiKTeX 2.9.6670 64-bit)
LaTeX2e <2018-04-01> patch level 3
Circuitikz and Tikz is loaded on the fly by Miktex (without intalling or download)
Means that it uses the latest available version (29/05/2017)

结果:

在此处输入图片描述

相关内容