Initial line drawing function.