added parameter to specify which layer you use in eagle for your dimension, a user contacted me about his eagle board file where he uses layer 50 for the dimensions

added some error handling for not closed shapes in dimension or milling layers