Added progress bar. Opening, parsing and plotting files (File->Open...) is now done in the background and shown in progress bar.

This commit is contained in:
Juan Pablo Caram
2014-01-12 22:07:24 -05:00
parent 1e85c54266
commit d664d40ad0
4 changed files with 401 additions and 117 deletions

View File

@@ -1,12 +1,3 @@
#import cairo
#from string import *
#from math import *
#from random import *
#from struct import *
#import os
#import sys
from numpy import arctan2, Inf, array, sqrt, pi, ceil, sin, cos
from matplotlib.figure import Figure
@@ -346,7 +337,7 @@ class Excellon(Geometry):
class CNCjob(Geometry):
def __init__(self, units="in", kind="generic", z_move = 0.1,
feedrate = 3.0, z_cut = -0.002):
feedrate = 3.0, z_cut = -0.002, tooldia = 0.0):
# Options
self.kind = kind
@@ -354,6 +345,7 @@ class CNCjob(Geometry):
self.z_cut = z_cut
self.z_move = z_move
self.feedrate = feedrate
self.tooldia = tooldia
# Constants
self.unitcode = {"in": "G20", "mm": "G21"}
@@ -367,8 +359,7 @@ class CNCjob(Geometry):
# Bounds of geometry given to CNCjob.generate_from_geometry()
self.input_geometry_bounds = None
# Tool diameter given to CNCjob.generate_from_geometry()
self.tooldia = 0
# Output generated by CNCjob.create_gcode_geometry()
#self.G_geometry = None