I have a basic pic ("brick") that I rotate/flip/shift within other pics (e.g. "wall"). These pics ("wall") then get drawn in my tikzpicture, possibly themselves rotated/flipped/shifted.

The brick pic renders fine, the wall pic renders fine, but I cannot seem to scale or rotate the wall pic (I can shift it with xshift and yshift though).

I have followed this nested pics question which was resolved by replacing the \draw in the wall pic with \path. However, that question did not deal with rotations and scalings.

How can I rotate/scale my wall pic? At the moment my ugly workaround is to put the tikz for brick into a macro which I call in the wall code (as opposed to drawing the brick pic), but this does not seem to be the tikz way.

enter image description here

In the above, shifting the wall works (blue), but the x-mirrored wall (red) does not mirror. (Obviously not intended to be bricks and walls, unless I am constructionally challenged).

    \draw (0, 0) -- (1, 3) -- (2, 1.5) -- cycle;
    \path pic {brick};
    \path pic [xshift=1cm,yshift=2cm,scale=0.5] {brick};
  \draw (-3, -1) rectangle (3, 4);% bounding box
  \node at (0, 0) {.}; % origin

  \draw pic {wall};
  % scaling does not work
  \path pic [red,ultra thin,xscale=-1] {wall};
  % shifting works
  \path pic [blue,ultra thin,xshift=1cm] {wall};
  • I had such an issue before, and it was recommended to use pics (see comments below post). It turned out that mirroring doesn't work with pics.
    – gernot
    Commented Dec 9, 2016 at 14:26
  • 3
    Need transform shape.
    – Symbol 1
    Commented Dec 10, 2016 at 16:32
  • @Symbol1 thanks so much! I put transform shape into the tikzpiture \path pic, and it worked. (I think I'll every node/.style={transform shape}). If you would like to post it as an answer I can mark the question as closed. Otherwise I'll post your answer as an answer (for posterity) tomorrow some time. Commented Dec 11, 2016 at 11:49

1 Answer 1


This question is somewhat related to Why does the pic option get passed through to the entire object?

Drawing a pic is essentially drawing a node, so everything you know about node applies. For example: a node is not rotated/scaled but only shifted. However a node is rotated/scaled if you said transform shape. And this is indeed the answer to your question.

To clarify:

% does not work
\path pic [red,ultra thin,xscale=-1] {wall};
% works
\path pic [red,ultra thin,xscale=-1,transform shape] {wall};

To make things easier, one could add [every node/.style=transform shape] into the tikzpicture options or similar.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .