+ self.focus_points_file = None
+
+ def save_to_file(self, path):
+ bn = os.path.basename(path)
+ name = os.path.splitext(bn)[0]
+
+ cp = ConfigParser()
+ cp.set('Project', 'image', self.image)
+ cp.set('Project', 'width', self.width)
+ cp.set('Project', 'height', self.height)
+
+ cp.write(open(path, 'w'))
+
+ @staticmethod
+ def parse_file(path):
+ cp = ConfigParser()
+ cp.read(path)
+
+ image = cp.get('Project', 'image')
+ width = cp.getint('Project', 'width')
+ height = cp.getint('Project', 'height')
+ x = cp.getint('Project', 'height')
+
+ proj = Project(image, width, height)
+ proj.focus_points_file = cp.get('Project', 'focus_points')
+
+ return proj