withTranslate function

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

Implementation

Widget withTranslate(
  Widget child, {
  double x = 0,
  double y = 0,
  double z = 0,
}) {
  return Transform(transform: Matrix4.translationValues(x, y, z), child: child);
}