修改配色 & 静态资源 & 软件名

This commit is contained in:
2025-05-28 23:04:53 +08:00
parent 735a8e9a51
commit 75750180cc
12 changed files with 766 additions and 17 deletions

View File

@@ -1,6 +1,5 @@
from PySide6.QtGui import QDesktopServices, Qt
from PySide6.QtWidgets import QVBoxLayout, QHBoxLayout
from pyparsing import version_info
from qfluentwidgets import PrimaryPushSettingCard, FluentIcon, GroupHeaderCardWidget, PushButton, ImageLabel, TitleLabel
from ui.components.widget import Widget
@@ -13,7 +12,7 @@ class AboutWidget(Widget):
self.logoImage = ImageLabel(':/images/logo.png')
self.logoImage.scaledToHeight(100)
self.appNameLabel = TitleLabel('建工工具箱🛠️')
self.appNameLabel = TitleLabel('教学工具箱 🛠️')
self.hBox = QHBoxLayout()
self.hBox.addWidget(self.logoImage, 0, Qt.AlignLeft)
@@ -52,10 +51,10 @@ class AboutWidget(Widget):
self.vbox.addWidget(self.group_card)
self.vbox.addStretch(1)
self.group_card.addGroup("", "PySide6", self.url_list[0], self.button_list[0])
self.group_card.addGroup("", "QFluentWidgets", self.url_list[1], self.button_list[1])
self.group_card.addGroup("", "openpyxl", self.url_list[2], self.button_list[2])
self.group_card.addGroup("", "python-docx", self.url_list[3], self.button_list[3])
self.group_card.addGroup(":/images/3rd/qt.png", "PySide6", self.url_list[0], self.button_list[0])
self.group_card.addGroup(":/images/3rd/qfluentwidgets", "QFluentWidgets", self.url_list[1], self.button_list[1])
self.group_card.addGroup(FluentIcon.LAYOUT, "openpyxl", self.url_list[2], self.button_list[2])
self.group_card.addGroup(FluentIcon.LAYOUT, "python-docx", self.url_list[3], self.button_list[3])
self.version_card.clicked.connect(
lambda: QDesktopServices.openUrl("https://cantyonion.site/git/cantyonion/DefenseTopicGenerator")

View File

@@ -4,13 +4,14 @@ from typing import Callable, Literal
from PySide6.QtCore import Qt, Signal, QThread
from PySide6.QtWidgets import QVBoxLayout, QFileDialog, QHBoxLayout
from qfluentwidgets import GroupHeaderCardWidget, FluentIcon, PushButton, LineEdit, IconWidget, InfoBarIcon, BodyLabel, \
from qfluentwidgets import GroupHeaderCardWidget, FluentIcon, PushButton, LineEdit, IconWidget, BodyLabel, \
PrimaryPushButton, SwitchButton
from module import LOGLEVEL
from module.worker import ARGWorker
from ui.components.infobar import ProgressInfoBar
from ui.components.widget import Widget
from ui import MAIN_THEME_COLOR
class InputSettingCard(GroupHeaderCardWidget):
@@ -56,12 +57,13 @@ class OutputSettingCard(GroupHeaderCardWidget):
self.autoOpenSwitch.setChecked(True)
self.bottomLayout = QHBoxLayout()
self.hintIcon = IconWidget(InfoBarIcon.INFORMATION)
self.hintIcon = IconWidget(FluentIcon.INFO.icon(color=MAIN_THEME_COLOR))
self.hintLabel = BodyLabel("点击开始按钮以开始生成 👉")
self.startButton.setEnabled(False)
# 设置底部工具栏布局
self.hintIcon.setFixedSize(16, 16)
self.hintIcon.autoFillBackground()
self.bottomLayout.setSpacing(10)
self.bottomLayout.setContentsMargins(24, 15, 24, 20)
self.bottomLayout.addWidget(self.hintIcon, 0, Qt.AlignLeft)

View File

@@ -3,12 +3,13 @@ from typing import Literal, Callable
from PySide6.QtCore import Qt, Signal, QThread
from PySide6.QtWidgets import QHBoxLayout, QVBoxLayout, QFileDialog
from qfluentwidgets import GroupHeaderCardWidget, PushButton, IconWidget, InfoBarIcon, \
BodyLabel, PrimaryPushButton, FluentIcon, LineEdit
from qfluentwidgets import GroupHeaderCardWidget, PushButton, IconWidget, BodyLabel, PrimaryPushButton, FluentIcon, \
LineEdit
from module.worker import DTGWorker
from ui.components.infobar import ProgressInfoBar
from ui.components.widget import Widget
from ui import MAIN_THEME_COLOR
class InitSettingCard(GroupHeaderCardWidget):
@@ -61,7 +62,7 @@ class ExportSettingsCard(GroupHeaderCardWidget):
self.exportFileNameLineEdit = LineEdit()
self.startButton = PrimaryPushButton(FluentIcon.PLAY_SOLID, "开始")
self.hintIcon = IconWidget(InfoBarIcon.INFORMATION)
self.hintIcon = IconWidget(FluentIcon.INFO.icon(color=MAIN_THEME_COLOR))
self.hintLabel = BodyLabel("点击开始按钮以开始生成 👉")
self.chooseExportDirectoryButton.setFixedWidth(120)
self.startButton.setFixedWidth(120)

6
ui/pyui/picker_ui.py Normal file
View File

@@ -0,0 +1,6 @@
from ui.components.widget import Widget
class PickerWidget(Widget):
def __init__(self, key: str, parent=None):
super().__init__(key, parent)