diff --git a/countdown.py b/countdown.py index baa5bb1..cc06437 100644 --- a/countdown.py +++ b/countdown.py @@ -107,7 +107,7 @@ class TimerApp(QWidget): def __init__(self): super().__init__() self.config = { - 'duration': 300, + 'duration': 240, 'alarm_offset': 30, 'stay_on_top': True, 'opacity': 1.0, @@ -129,19 +129,19 @@ class TimerApp(QWidget): self.setAttribute(Qt.WA_TranslucentBackground) self.setStyleSheet(""" QWidget#MainFrame { - background-color: #2c3e50; + background-color: #e8f4f8; border-radius: 15px; - border: 2px solid #34495e; + border: 2px solid #b0d4e3; } - QLabel { color: #ecf0f1; font-family: 'Segoe UI', Arial; } + QLabel { color: #2c3e50; font-family: 'Segoe UI', Arial; } QPushButton { - background-color: #3498db; + background-color: #5dade2; color: white; border-radius: 5px; padding: 8px; font-weight: bold; } - QPushButton:hover { background-color: #2980b9; } + QPushButton:hover { background-color: #3498db; } """) self.main_layout = QVBoxLayout(self) @@ -168,16 +168,13 @@ class TimerApp(QWidget): # 按钮区域 self.btn_area = QWidget() self.btn_layout = QHBoxLayout(self.btn_area) - self.btn_5m = QPushButton("5分钟") - self.btn_6m = QPushButton("6分钟") + self.btn_4m = QPushButton("4分钟") self.btn_other = QPushButton("其它") - self.btn_5m.clicked.connect(lambda: self.start_countdown(300)) - self.btn_6m.clicked.connect(lambda: self.start_countdown(360)) + self.btn_4m.clicked.connect(lambda: self.start_countdown(240)) self.btn_other.clicked.connect(self.open_config) - self.btn_layout.addWidget(self.btn_5m) - self.btn_layout.addWidget(self.btn_6m) + self.btn_layout.addWidget(self.btn_4m) self.btn_layout.addWidget(self.btn_other) self.content_layout.addWidget(self.btn_area) @@ -301,7 +298,7 @@ class TimerApp(QWidget): if hasattr(self, 'color_anim') and self.color_anim is not None: self.color_anim.stop() - self.label_time.setStyleSheet("color: #ecf0f1;") + self.label_time.setStyleSheet("color: #2c3e50;") self.is_running = True diff --git a/操作手册.md b/操作手册.md index 58ffae2..303419f 100644 --- a/操作手册.md +++ b/操作手册.md @@ -2,7 +2,7 @@ ## 一、概述 -述职计时器是一款专为述职演讲设计的倒计时工具,支持快捷计时、提前告警、微缩悬浮窗口等功能。 +述职计时器是一款专为述职演讲设计的倒计时工具。 ## 二、快速开始 @@ -26,7 +26,7 @@ | 配置项 | 说明 | |--------|------| -| 自定义秒数 | 设置自定义倒计时时长(1-3600秒) | +| 自定义秒数 | 设置自定义倒计时时长(1-3600秒)可用来测试 | | 提前告警(秒) | 设置提前播放告警音的时间(0-300秒) | | 窗口置顶 | 勾选后窗口始终保持在其他窗口上方 | | 透明度 | 调节窗口透明度(10%-100%) | @@ -54,24 +54,7 @@ - 将 `alarm.wav` 音频文件放置在 **exe 同目录** 或 **当前工作目录** - 程序会优先从外部目录加载,若未找到则使用内置音频 -## 五、打包说明 - -### 5.1 打包命令 - -```bash -pyinstaller --onefile --windowed --noconsole --icon=Timer.ico countdown.py -``` - -参数说明: -- `--onefile`:打包成单个exe文件 -- `--windowed` / `--noconsole`:不显示控制台窗口 -- `--icon`:指定程序图标 - -### 5.2 清理残留文件 - -运行 `clean.py` 可自动清理打包残留文件并重新生成exe。 - -## 六、注意事项 +## 五、注意事项 1. 首次运行请确保 `alarm.wav` 与 exe 在同一目录,否则告警功能不可用 2. 微缩窗口位置可在配置中自定义