diff --git a/src/main.py b/src/main.py index f019188..0e1512f 100644 --- a/src/main.py +++ b/src/main.py @@ -21,6 +21,7 @@ def __init__(self, text, interval, type_enter, chars_per_stroke, randomize_inter self.mistake_percentage = mistake_percentage self.running = True self.keyboard = Controller() + print(f"TypingThread initialized with randomize_interval: {self.randomize_interval}") # Debug print def run(self): i = 0 @@ -35,9 +36,11 @@ def run(self): i += self.chars_per_stroke if self.randomize_interval: - current_interval = self.interval * random.uniform(0.4, 1.8) + current_interval = self.interval * random.uniform(0.1, 3) + print(f"Randomized interval: {current_interval}") # Debug print else: current_interval = self.interval + print(f"Fixed interval: {current_interval}") # Debug print time.sleep(current_interval) self.progress.emit(int(i / len(self.text) * 100)) @@ -97,6 +100,8 @@ def start_typing(self): QMessageBox.critical(self, "Error", "Invalid input for delay, interval, chars per stroke, or mistake percentage.") return + print(f"Starting typing with randomize_interval: {randomize_interval}") # Debug print + self.startButton.setEnabled(False) self.stopButton.setEnabled(True) if delay > 0: