Solved the lineshape selection problem.