mirror of
https://github.com/denizsafak/abogen.git
synced 2026-07-18 13:40:27 +02:00
Updated profile and voice mixer icons, better visibility and aesthetics in voice mixer
This commit is contained in:
@@ -8,6 +8,7 @@
|
|||||||
- Fixed voice preview player keeps playing silently at the background after preview ends.
|
- Fixed voice preview player keeps playing silently at the background after preview ends.
|
||||||
- Fixed not writing separate chapters audio when output is OPUS.
|
- Fixed not writing separate chapters audio when output is OPUS.
|
||||||
- Improved input box background color handling, fixed display issues in Linux.
|
- Improved input box background color handling, fixed display issues in Linux.
|
||||||
|
- Updated profile and voice mixer icons, better visibility and aesthetics in voice mixer.
|
||||||
- Better sleep state handling for Linux.
|
- Better sleep state handling for Linux.
|
||||||
- Improvements in documentation and code.
|
- Improvements in documentation and code.
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 241 B After Width: | Height: | Size: 343 B |
Binary file not shown.
|
Before Width: | Height: | Size: 331 B After Width: | Height: | Size: 376 B |
@@ -264,14 +264,12 @@ class HoverLabel(QLabel):
|
|||||||
self.voice_name = voice_name
|
self.voice_name = voice_name
|
||||||
self.setMouseTracking(True)
|
self.setMouseTracking(True)
|
||||||
self.setStyleSheet(
|
self.setStyleSheet(
|
||||||
"background-color: #e0e0e0; border-radius: 4px; padding: 3px 6px 3px 6px; margin: 2px;"
|
"background-color: rgba(140, 140, 140, 0.15); border-radius: 4px; padding: 3px 6px 3px 6px; margin: 2px;"
|
||||||
)
|
)
|
||||||
|
|
||||||
# Create delete button
|
# Create delete button
|
||||||
self.delete_button = QPushButton("×", self)
|
self.delete_button = QPushButton("×", self)
|
||||||
self.delete_button.setFixedSize(16, 16)
|
self.delete_button.setFixedSize(16, 16)
|
||||||
self.delete_button = QPushButton("×", self)
|
|
||||||
self.delete_button.setFixedSize(16, 16)
|
|
||||||
self.delete_button.setStyleSheet(
|
self.delete_button.setStyleSheet(
|
||||||
"""
|
"""
|
||||||
QPushButton {
|
QPushButton {
|
||||||
@@ -734,7 +732,7 @@ class VoiceFormulaDialog(QDialog):
|
|||||||
percentage = weight / total * 100
|
percentage = weight / total * 100
|
||||||
# Make the voice name bold and include percentage
|
# Make the voice name bold and include percentage
|
||||||
voice_label = HoverLabel(
|
voice_label = HoverLabel(
|
||||||
f'<b><span style="color:#1976d2">{name}: {percentage:.1f}%</span></b>',
|
f'<b><span style="color:#007dff">{name}: {percentage:.1f}%</span></b>',
|
||||||
name,
|
name,
|
||||||
)
|
)
|
||||||
voice_label.setSizePolicy(QSizePolicy.Preferred, QSizePolicy.Preferred)
|
voice_label.setSizePolicy(QSizePolicy.Preferred, QSizePolicy.Preferred)
|
||||||
@@ -1326,10 +1324,16 @@ class VoiceFormulaDialog(QDialog):
|
|||||||
item = self.profile_list.item(i)
|
item = self.profile_list.item(i)
|
||||||
name = item.text().lstrip("*")
|
name = item.text().lstrip("*")
|
||||||
if self._virtual_new_profile and name == "New profile":
|
if self._virtual_new_profile and name == "New profile":
|
||||||
item.setBackground(QColor("#fff59d")) # yellow
|
color = QColor("#ffff00") # yellow
|
||||||
|
color.setAlpha(64) # Set transparency
|
||||||
|
item.setBackground(color)
|
||||||
elif item.text().startswith("*"):
|
elif item.text().startswith("*"):
|
||||||
item.setBackground(QColor("#fff59d")) # yellow
|
color = QColor("#ffff00") # yellow
|
||||||
|
color.setAlpha(64) # Set transparency
|
||||||
|
item.setBackground(color)
|
||||||
else:
|
else:
|
||||||
|
item.setBackground(self.profile_list.palette().base().color()) # Use default list item background
|
||||||
|
|
||||||
weights = profiles.get(name, {}).get("voices", [])
|
weights = profiles.get(name, {}).get("voices", [])
|
||||||
# Defensive: only sum if weights is a list of (voice, weight) pairs
|
# Defensive: only sum if weights is a list of (voice, weight) pairs
|
||||||
total = 0
|
total = 0
|
||||||
@@ -1342,9 +1346,9 @@ class VoiceFormulaDialog(QDialog):
|
|||||||
):
|
):
|
||||||
total += entry[1]
|
total += entry[1]
|
||||||
if total == 0:
|
if total == 0:
|
||||||
item.setBackground(QColor("#ffcdd2")) # light red
|
color = QColor("#ff0000") # red
|
||||||
else:
|
color.setAlpha(64) # Set transparency
|
||||||
item.setBackground(QColor("white"))
|
item.setBackground(color)
|
||||||
self.update_profile_save_buttons()
|
self.update_profile_save_buttons()
|
||||||
|
|
||||||
def preview_current_mix(self):
|
def preview_current_mix(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user