this fixed #33, but introduced problems in line contain logic in linetree