This distortion should not be possible at all. z moves run on all stepps the same number of steps so all distortions in xy plane stay the same over z height.
The only way to print in that direction is having the rotation matrix tilt print direction, but then the bottom/top would also have the same rotation, so it would still be a cube.
One thing I could imagine is that one motor belt has a different resolution maybe just due to different tenson. Then you might get something like that, bit with tension the error normally is very small so I hope your example is exaggerated.