完整图表(重复代码)

完整图表(重复代码)

使用乳胶beamer我有:

\documentclass{beamer}

\usepackage{tikz}

\usetikzlibrary{decorations.text,calc,arrows.meta}
\begin{document}

\begin{frame}
\begin{tikzpicture}
\coordinate (O) at (0,0);



\begin{scope}[xshift=6cm]
\coordinate (O) at (0,0);

\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);


\draw[decoration={text along path,reverse path,text align={align=center},text={Boooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={aiiiii}},decorate] (1.3,0) arc (0:180:1.3);

\end{scope}
\coordinate (O) at (0,4);


\begin{scope}[xshift=2cm]
\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);


\draw[decoration={text along path,reverse path,text align={align=center},text={boooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={aiai}},decorate] (1.3,0) arc (0:180:1.3);

\end{scope}

\coordinate (O) at (-2,-2);


\begin{scope}[xshift=2cm]
\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);


\draw[decoration={text along path,reverse path,text align={align=center},text={loooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={nana}},decorate] (1.3,0) arc (0:180:1.3);

\end{scope}



\end{tikzpicture}




\end{frame}
\end{document}

这可行,但我想绘制另外两个这种形状,一个在该形状的左侧,另一个在其他形状的下方和之间。

我再次添加了类似的代码,但它不起作用。我知道应该更改数字,但范围应该改成什么?

答案1

快速而肮脏:

\documentclass{beamer}
\usepackage{tikz}
\usetikzlibrary{decorations.text,calc,arrows.meta}
\begin{document}
\begin{frame}
\centering
\begin{tikzpicture}
\coordinate (O) at (0,0);
\begin{scope}[xshift=0cm,scale=1]
\coordinate (O) at (0,0);
\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);
\draw[decoration={text along path,reverse path,text align={align=center},text={Boooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={aiiiii}},decorate] (1.3,0) arc (0:180:1.3);
\end{scope}

\begin{scope}[xshift=7cm,scale=1]
\coordinate (O) at (0,0);
\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);
\draw[decoration={text along path,reverse path,text align={align=center},text={Boooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={aiiiii}},decorate] (1.3,0) arc (0:180:1.3);
\end{scope}

\begin{scope}[xshift=3.5cm,yshift=-4cm,scale=1]
\coordinate (O) at (0,0);
\draw[fill=blue!40] (O) circle (2);
\draw[fill=pink!70] (O) circle (1.00);
\draw[decoration={text along path,reverse path,text align={align=center},text={Boooo}},decorate] (0.5,0) arc (0:180:0.5);
\draw[decoration={text along path,reverse path,text align={align=center},text={aiiiii}},decorate] (1.3,0) arc (0:180:1.3);
\end{scope}
\end{tikzpicture}
\end{frame}
\end{document}

在此处输入图片描述

相关内容