I am trying to create a beamer animation using tikz, but I can't even get basic rotating of a tikz image working as desired.
I have a rectangle specified by
\draw[rounded corners,dotted] (-3.5,0) rectangle (-0.5,2);
I would like to rotate this rectangle about the point (-1,.5) (which is near the bottom right corner of the rectangle). I've tried:
{\rotatebox[origin=c,x=-1,y=.5]{130}{
\draw[rounded corners,dotted] (-3.5,0) rectangle (-0.5,2);}}
But this produces an error. If I just use the origin=c
option, it compiles, but it rotates the rectangle about the point (0,0). I've also tried it with just the x=-1,y=.5
(without the origin option), and it fails to compile.
I have searched the documentation, which is where I learned about the options x=xdim
and y=ydim
. However, I can't find a single example demonstrating how these options should be used.
Any suggestions would be greatly appreciated.
Also, if there is a better command for rotating things that will be more suitable for use in a beamer animation, please let me know. Thanks!