collapse lines