Two different mechanisms of planar cell intercalation leading to tissue elongation