修改 arcarrow

修改 arcarrow

我在这里找到了这个 PDCA 循环(计划、执行、检查、行动)

http://www.texample.net/tikz/examples/pdca-cycle/

% PDCA cycle
% Author: tikzanfaenger, Helmut, and Bartman
\documentclass[tikz,border=10pt]{standalone}
\usetikzlibrary{decorations.text}
\definecolor{mygray}{RGB}{208,208,208}
\definecolor{mymagenta}{RGB}{226,0,116}
\newcommand*{\mytextstyle}{\sffamily\Large\bfseries\color{black!85}}
\newcommand{\arcarrow}[3]{%
   % inner radius, middle radius, outer radius, start angle,
   % end angle, tip protusion angle, options, text
   \pgfmathsetmacro{\rin}{1.7}
   \pgfmathsetmacro{\rmid}{2.2}
   \pgfmathsetmacro{\rout}{2.7}
   \pgfmathsetmacro{\astart}{#1}
   \pgfmathsetmacro{\aend}{#2}
   \pgfmathsetmacro{\atip}{5}
   \fill[mygray, very thick] (\astart+\atip:\rin)
                         arc (\astart+\atip:\aend:\rin)
      -- (\aend-\atip:\rmid)
      -- (\aend:\rout)   arc (\aend:\astart+\atip:\rout)
      -- (\astart:\rmid) -- cycle;
   \path[
      decoration = {
         text along path,
         text = {|\mytextstyle|#3},
         text align = {align = center},
         raise = -1.0ex
      },
      decorate
   ](\astart+\atip:\rmid) arc (\astart+\atip:\aend+\atip:\rmid);
}
\begin{document}
\begin{tikzpicture}
   \fill[even odd rule,mymagenta] circle (1.5);

   \node at (0,0) [
      font  = \mytextstyle,
      color = white,
      align = center
   ]{
      PDCA\\
      Cycle
   };
   \arcarrow{ 85}{  3}{ PLAN  }
   \arcarrow{270}{357}{ DO    }
   \arcarrow{182}{269}{ CHECK }
   \arcarrow{176}{ 96}{ ACT   }
\end{tikzpicture}
\end{document}

我怎样才能去除箭头形状并采取简单的曲线矩形? 在此处输入图片描述

也就是说,我想删除产生拼图效果和首选方向的弧形箭头对象的起点和终点。

在此处输入图片描述

答案1

写下答案可能比将信息分散在太多评论中更加清晰。

\documentclass[tikz,border=10pt]{standalone}
\usetikzlibrary{decorations.text}
\definecolor{mygray}{RGB}{208,208,208}
\definecolor{mymagenta}{RGB}{226,0,116}
\newcommand*{\mytextstyle}{\sffamily\Large\bfseries\color{black!85}}
\begin{document}
\begin{tikzpicture}
   \fill[mymagenta] circle (1.35);
   \node at (0,0) [
      font  = \mytextstyle,
      color = white,
      align = center
   ]{
      PDCA\\
      Cycle
   };
   \pgfmathsetmacro{\mydist}{2}
   \pgfmathsetmacro{\Radius}{2}
    \foreach \X [count=\Y] in {PLAN,DO,CHECK,ACT}
    {\pgfmathtruncatemacro{\itest}{sign(sin(180-\mydist-90*\Y))}
    \ifnum\itest>0
    \draw[mygray,line width=1cm,postaction={decoration = {
         text along path,
         text = {|\mytextstyle|\X},
         text align = {align = center},
         raise = -1.0ex
      },
      decorate}] (180-\mydist-90*\Y:\Radius) arc(180-\mydist-90*\Y:90+\mydist-90*\Y:\Radius);
    \else
    \draw[mygray,line width=1cm,postaction={decoration = {
         text along path,
         text = {|\mytextstyle|\X},
         text align = {align = center},
         raise = -1.0ex
      },
      decorate}] (90+\mydist-90*\Y:\Radius) arc(90+\mydist-90*\Y:180-\mydist-90*\Y:\Radius);
    \fi  
      } 
\end{tikzpicture}
\end{document}

在此处输入图片描述

答案2

轮图我写的包,可以使用。

初始设置为value=\WCvarAslices style=\WCvarBdata=\WCvarC。对于此图,我们设置value=1为使每个切片具有相同的大小。我们还将键设置data为空。

弧线中的文本由键指定。此文本的方向取决于键中使用的arc data弧线中间的角度。此文本的位置由键决定。\WCmidanglearc data dirarc data pos

切片之间的间隙是通过密钥获得的gap

在此处输入图片描述

\documentclass[border=6pt]{standalone}
\usepackage{wheelchart}
\usetikzlibrary{decorations.text}
\definecolor{mygray}{RGB}{208,208,208}
\definecolor{mymagenta}{RGB}{226,0,116}
\begin{document}
\begin{tikzpicture}
\sffamily\Large\bfseries\color{black!85}
\fill[mymagenta] (0,0) circle[radius=1.5];
\wheelchart[
  arc data=\WCvarA,
  arc data dir={\WCmidangle<180?1:-1},
  arc data pos=0.5,
  data=,
  gap,
  middle=PDCA\\Cycle,
  radius={1.7}{2.7},
  slices style=mygray,
  value=1
]{PLAN,DO,CHECK,ACT}
\end{tikzpicture}
\end{document}

相关内容