Added code for rect and paths. Lines now point to path code.