'Flutter: How to flip an icon to get mirror effect?

I want to flip this replay material icon so that it can be used as forward.

Present Icon:

Preset Icon

Required Result:

enter image description here



Solution 1:[1]

Before:

enter image description here


After:

enter image description here

import 'dart:math' as math; // import this

Transform(
  alignment: Alignment.center,
  transform: Matrix4.rotationY(math.pi),
  child: Icon(Icons.rotate_left, size: 100,),
)

Solution 2:[2]

The accepted answer works, but to add my two cents, you can use the following:

Transform.scale(
  scaleX: -1,
  child: Icon(
    Icons.rotate_left, 
    size: 100,
  ),
)

Same effect, but without an import statement or any explicit matrices specification

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 CopsOnRoad
Solution 2