Add smooth tab widget with fade transitions

Introduce SmoothTabWidget and a FadingStackedWidget to provide cross-fade transitions between tabs. Added ytsage/gui/ytsage_smooth_tab_widget.py which implements a QTabBar + FadingStackedWidget (default 300ms fade) and overlay-based fade logic. Updated ytsage/gui/ytsage_gui_dialogs/ytsage_dialogs_custom.py to use SmoothTabWidget instead of QTabWidget and adjusted the stylesheet selector to target the new content frame (#tabContent) so existing styles continue to apply.
This commit is contained in:
oop7
2026-02-01 14:30:54 +02:00
parent 79a85cf707
commit 2935eb01c1
2 changed files with 126 additions and 2 deletions
@@ -29,6 +29,7 @@ from PySide6.QtWidgets import (
QWidget,
)
from ..ytsage_smooth_tab_widget import SmoothTabWidget
from ...core.ytsage_yt_dlp import get_yt_dlp_path
from ...core.ytsage_utils import update_auto_update_settings
from ...utils.ytsage_constants import YTDLP_DOCS_URL
@@ -115,7 +116,7 @@ class CustomOptionsDialog(QDialog):
layout = QVBoxLayout(self)
# Create tab widget to organize content
self.tab_widget = QTabWidget()
self.tab_widget = SmoothTabWidget()
layout.addWidget(self.tab_widget)
# === Cookies Tab ===
@@ -542,7 +543,7 @@ class CustomOptionsDialog(QDialog):
QDialog {
background-color: #15181b;
}
QTabWidget::pane {
QFrame#tabContent {
border: 1px solid #3d3d3d;
background-color: #15181b;
}