added Line module
fixed some bugs