Fixed a bug when rotating or reversing foliations.

When calculating the train track map, one train track path was cut off
early, however, this cut is only needed when we transform with respect
to a transverse curve.