withRotation function

Widget withRotation(
  1. Widget child,
  2. {double x = 0,
  3. double y = 0,
  4. double z = 0}
)

Implementation

Widget withRotation(Widget child, {double x = 0, double y = 0, double z = 0}) {
  return Transform(
      transform: Matrix4.rotationX(x)
        ..rotateY(x)
        ..rotateZ(z),
      child: child);
}