rotate
ShowableShowable functions can be customized with show
rules.
Showable functions can be customized with
show
rules.Rotate content with affecting layout.
Rotate an element by a given angle. The layout will act as if the element was not rotated.
Example
#{
range(16)
.map(i => rotate(24deg * i)[X])
.join(h(1fr))
}

ParametersParameters are the inputs to a function. They are specified in parentheses after the function name.
Parameters are the inputs to a function. They are specified in parentheses after the function name.
rotate()
body
The content to rotate.
angle
The amount of rotation.
#rotate(angle: -1.571rad)[To space!]

origin
alignment2d alignmentSettableSettable parameters can be customized for all following uses of the function with a set
rule.
Settable parameters can be customized for all following uses of the function with a
set
rule.The origin of the rotation.
By default, the origin is the center of the rotated element. If,
however, you wanted the bottom left corner of the rotated element to
stay aligned with the baseline, you would set the origin to bottom + left
.
#set text(spacing: 8pt)
#let square = square.with(width: 8pt)
#square()
#rotate(angle: 30deg, origin: center, square())
#rotate(angle: 30deg, origin: top + left, square())
#rotate(angle: 30deg, origin: bottom + right, square())
