'Pauses the print, saving the current position.'

def pause(self):

    if (not self.printing):
        return False
    self.paused = True
    self.printing = False
    try:
        self.print_thread.join()
    except RuntimeError as e:
        if (e.message == 'cannot    join    current    thread'):
            pass
        else:
            self.logError(traceback.format_exc())
    except:
        self.logError(traceback.format_exc())
    self.print_thread = None
    self.pauseX = self.analyzer.abs_x
    self.pauseY = self.analyzer.abs_y
    self.pauseZ = self.analyzer.abs_z
    self.pauseE = self.analyzer.abs_e
    self.pauseF = self.analyzer.current_f
    self.pauseRelative = self.analyzer.relative
