From b9f1b106c3006f1dddb1279ae9622630a29d18c7 Mon Sep 17 00:00:00 2001 From: Paulo Henrique Silva Date: Mon, 25 Jan 2016 12:42:12 -0200 Subject: Excellon format detection uses ExcelonFile.bounds now Long term we should have only one .bounds method. But ExcellonParser right now is not correct for cases with two drills in the same line (it will report one dimension being zero) --- gerber/excellon.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gerber') diff --git a/gerber/excellon.py b/gerber/excellon.py index b1b94df..b29f7f0 100755 --- a/gerber/excellon.py +++ b/gerber/excellon.py @@ -604,8 +604,8 @@ def detect_excellon_format(data=None, filename=None): settings = FileSettings(zeros=zeros, format=fmt) try: p = ExcellonParser(settings) - p.parse_raw(data) - size = tuple([t[0] - t[1] for t in p.bounds]) + ef = p.parse_raw(data) + size = tuple([t[0] - t[1] for t in ef.bounds]) hole_area = 0.0 for hit in p.hits: tool = hit.tool -- cgit