Is there a way to get label text to rotate with the TikZ node to which it is attached. I can rotate the node and its text; but labels do not rotate along with the node, and instead remain "level":
\tikzset{fig/.style={regular polygon, regular polygon sides=3, label=60:A,label=below:B}}
\begin{tikzpicture}
\foreach \i in {0,1,2,3}{\node[fig,rotate=20*\i,draw] at(\i*4,0) {Text};}
\end{tikzpicture}
In general, I'd like to find a way to rotate a "composite" element, consisting of more than just a single, simple node and it's labels; for example, a shape, in which the corners have been "marked" with symbols or other shapes:
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{shapes}
% Not needed for MWE but used in my code:
%\usetikzlibrary{positioning}
%\usetikzlibrary{petri}
\begin{document}
\tikzset{fig/.style={regular polygon, regular polygon sides=3, label=60:A,label=below:B}}
\begin{tikzpicture}
\foreach \i in {0,1,2,3}{\node[fig,rotate=20*\i,draw] at(\i*4,0) {Text};}
\end{tikzpicture}
% I don't know how to create the images in the second illustration
\end{document}
\documentclass
and the appropriate packages so that those trying to help don't have to recreate it. Especially withtikz
since there are so many libraries.\begin{tikzpicture} \node[draw,regular polygon,regular polygon sides=3,minimum height=1cm] (a) {}; \node[anchor=north,regular polygon,regular polygon sides=3,fill=gray!50,minimum height=0.3cm,inner sep=0] at (a.north) {}; \node[fill,circle,inner sep=1.5pt] at ([shift={(-2mm,1.2mm)}]a.corner 3) {}; \end{tikzpicture}
Otherwise, you can declare a new shape and inherit the important parts from a triangle.