Skip to content

🚀 A comprehensive collection of enhanced Qt StyleSheets with modern design patterns, complete widget coverage, and integrated SVG icon system

Notifications You must be signed in to change notification settings

hammam999/Enhanced-Qt-StyleSheets-Collection

Repository files navigation

Enhanced Qt StyleSheets Collection

🎨 Enhanced Qt StyleSheets Collection

Qt Version Python PyQt6 License GitHub Stars

🚀 A comprehensive collection of enhanced Qt StyleSheets with modern design patterns, complete widget coverage, and integrated SVG icon system

🎯 Features📦 Installation🎨 Themes🧪 Testing📚 Documentation


🌟 Overview

This is an enhanced collection of Qt StyleSheets (QSS) with custom SVG icons and improved component coverage. Built upon the excellent foundation by Jaime A. Quiroga P. (GTRONICK) and enhanced with modern UI/UX principles.

✨ Features

🎨 Custom SVG Icons
Scalable vector icons for all UI elements
🚀 Enhanced Themes
Improved versions of popular themes
🔧 Complete Widget Coverage
Support for all major Qt widgets
📱 Modern Design
Updated with contemporary UI/UX principles
Accessibility
Better contrast and usability
Performance Optimized
Efficient CSS rendering and loading

🎨 Available Themes

🌟 Enhanced Themes (New)

MacOS Enhanced
MacOS-Enhanced.qss
Modern macOS-style with custom SVG icons
Material Dark Enhanced
MaterialDark-Enhanced.qss
Material Design dark theme enhanced
Ubuntu Enhanced
Ubuntu-Enhanced.qss
Ubuntu-inspired with enhanced components

📦 Original Themes

Ubuntu
Ubuntu.qss
ElegantDark
ElegantDark.qss
MaterialDark
MaterialDark.qss
ConsoleStyle
ConsoleStyle.qss
AMOLED
AMOLED.qss
Aqua
Aqua.qss
ManjaroMix
ManjaroMix.qss
NeonButtons
NeonButtons.qss
MacOS
MacOS.qss

🎯 Icon System

📁 SVG Icons Collection

Navigation
arrow-up.svgarrow-down.svg
arrow-left.svgarrow-right.svg

✨ Icon Features

📏 Scalable
Vector-based for any size without quality loss
🎨 Customizable
Easy to modify colors, strokes, and styles
🎯 Consistent
Unified design language across all themes
Performance
Optimized SVG code for fast rendering

📦 Installation

🚀 Quick Start

Step 1
git clone https://github.com/GTRONICK/QSS.git
Step 2
pip install -r requirements.txt
Step 3
python theme_tester.py

💻 Usage

🔧 C++ Integration

#include <QApplication>
#include <QFile>
#include <QTextStream>

int main(int argc, char *argv[])
{
    QApplication app(argc, argv);
    
    // 📁 Load stylesheet from file
    QFile file("MacOS-Enhanced.qss");
    if (file.open(QFile::ReadOnly | QFile::Text)) {
        QTextStream stream(&file);
        QString styleSheet = stream.readAll();
        app.setStyleSheet(styleSheet);
        file.close();
    }
    
    return app.exec();
}

🐍 Python Integration

import sys
from PyQt6.QtWidgets import QApplication
from PyQt6.QtCore import QFile, QTextStream

def load_stylesheet(file_path):
    """Load QSS stylesheet from file"""
    file = QFile(file_path)
    if file.open(QFile.OpenModeFlag.ReadOnly | QFile.OpenModeFlag.Text):
        stream = QTextStream(file)
        stylesheet = stream.readAll()
        file.close()
        return stylesheet
    return ""

app = QApplication(sys.argv)

# 🎨 Apply enhanced theme
stylesheet = load_stylesheet("MaterialDark-Enhanced.qss")
app.setStyleSheet(stylesheet)

# Your application code here...
sys.exit(app.exec())

📦 Resource File Integration

<!-- resources.qrc -->
<RCC>
    <qresource prefix="/themes">
        <file>MacOS-Enhanced.qss</file>
        <file>MaterialDark-Enhanced.qss</file>
        <file>Ubuntu-Enhanced.qss</file>
    </qresource>
    <qresource prefix="/icons">
        <file>icons/svg/arrow-up.svg</file>
        <file>icons/svg/arrow-down.svg</file>
        <file>icons/svg/checkbox-checked.svg</file>
        <file>icons/svg/radio-checked.svg</file>
        <!-- Add all other SVG icons -->
    </qresource>
</RCC>

🧩 Supported Components

🎯 Enhanced Widget Coverage

Windows
QMainWindowQDialogQWidget
Controls
QPushButtonQToolButtonQCheckBoxQRadioButton
Input
QLineEditQTextEditQComboBoxQSpinBox
Progress
QSliderQProgressBarQScrollBar
Navigation
QMenuBarQMenuQTabWidgetQStatusBar
Data Views
QTreeViewQListViewQTableViewQHeaderView
Layout
QGroupBoxQSplitterQToolBoxQDockWidget
Special
QCalendarWidgetQToolTipQFrame

✨ Enhanced Features

🎯 Focus States
Better visual feedback for focused elements
🚫 Disabled States
Proper styling for disabled components
🎭 Hover Effects
Smooth hover transitions and animations
🎨 Custom Icons
SVG-based icons for all interactive elements
📝 Better Typography
Improved font choices and sizing
Accessibility
Enhanced contrast ratios and usability
📐 Modern Spacing
Consistent padding and margins

🧪 Theme Tester Application

Theme Tester

🚀 Interactive theme testing application with live preview and comprehensive widget showcase

📸 Theme Gallery

🌊 Aqua Theme

Aqua Theme - Main Interface
Main Interface
Clean aqua-blue design with modern gradients
Aqua Theme - Widget Gallery
Widget Gallery
Comprehensive component showcase

🍎 macOS Theme

macOS Theme - Main Interface
macOS Style Interface
Native macOS look and feel
macOS Theme - Controls
Control Elements
Apple-inspired design patterns

🐧 Ubuntu Theme

Ubuntu Theme - Complete Interface
Ubuntu-Inspired Design
Orange accents with modern Ubuntu styling and comprehensive widget coverage

✨ Theme Features Showcase

Live Preview
🎯 Real-time Testing
Switch themes instantly and see changes immediately
Widget Gallery
🧩 Complete Coverage
All Qt widgets organized in intuitive categories
Interactive Demo
🎮 Interactive Elements
Test hover, focus, and disabled states

🎯 Features

  • 🎨 Live Theme Switching - Change themes instantly without restart
  • 📱 Comprehensive Widget Gallery - All Qt widgets in organized tabs
  • 🔧 Interactive Examples - Test hover, focus, and disabled states
  • 📊 Performance Monitoring - Theme loading times and resource usage
  • 🌐 Arabic Interface - Right-to-left layout support

🚀 Quick Start

# Run the theme tester
python theme_tester.py

# Or use the helper script
python run_theme_tester.py

📋 Widget Categories

Basic
Buttons, Checkboxes, Radio buttons
Input
Text fields, Combo boxes, Spin boxes
Display
Sliders, Progress bars, Lists, Tables
Containers
Splitters, Tool boxes, Tab widgets

📊 Theme Comparison

🎨 Feature MacOS Enhanced Material Enhanced Ubuntu Enhanced
🎭 Style Modern macOS Material Design Ubuntu-inspired
🎨 Colors Blue accents Green accents Orange accents
🎯 Icons ✅ Custom SVG ✅ Custom SVG ✅ Custom SVG
🌈 Gradients Subtle Minimal Rich
📐 Borders Rounded Sharp/Rounded Rounded
🎯 Best For Desktop apps Modern apps Linux apps

🛠️ Customization

🎨 Easy Theme Customization

Colors
Color Schemes
Icons
Custom Icons
Fonts
Typography

🎨 Changing Colors

/* 🎯 Change accent color */
QPushButton {
    border-color: #your-accent-color;
    background-color: #your-background-color;
}

/* 🌈 Selection colors */
QWidget {
    selection-background-color: #your-selection-color;
    selection-color: #your-text-color;
}

🖼️ Custom Icons

Replace SVG files in icons/svg/ directory:

# 📁 Icon structure
icons/svg/
├── arrow-up.svg      # ⬆️ Navigation
├── checkbox-*.svg    # ☑️ Form controls
└── radio-*.svg       # 🔘 Radio buttons

📝 Font Customization

/* 🔤 Global font settings */
QWidget {
    font-family: "Segoe UI", "SF Pro Display", "Ubuntu", sans-serif;
    font-size: 14px;
    font-weight: 400;
}

/* 📱 Platform-specific fonts */
QWidget[platform="windows"] { font-family: "Segoe UI"; }
QWidget[platform="macos"] { font-family: "SF Pro Display"; }
QWidget[platform="linux"] { font-family: "Ubuntu"; }

⚡ Performance & Compatibility

Qt 5.12+ Qt 6.x Cross Platform

🚀 Performance Tips

  • 📦 Icon Optimization: Use compressed SVG files
  • 🌈 Gradient Limits: Minimize complex gradients
  • 🎯 Selector Specificity: Use targeted CSS selectors
  • 💾 Resource Bundling: Package assets in Qt resource files

🤝 Contributing

Contributions Welcome

🎨 Adding New Icons

  1. 📐 Create SVG with 16x16 viewBox
  2. 🎨 Use currentColor for dynamic coloring
  3. ⚡ Optimize SVG code for performance
  4. 📁 Add to icons/svg/ directory
  5. 🔗 Reference in theme files

🎭 Creating New Themes

  1. 📋 Copy enhanced theme as base
  2. 🎨 Modify color scheme variables
  3. 🔧 Adjust component styling
  4. 🧪 Test with theme tester application
  5. 📚 Document theme characteristics

📄 License & Credits

MIT License
MIT License
Same as original QSS collection
Original Author
Jaime A. Quiroga P.
Original QSS collection creator

🙏 Acknowledgments

  • 🎨 Enhanced Version: Modern UI/UX improvements
  • 🎯 Custom Icons: Scalable SVG icon system
  • 🧪 Testing: Community feedback and testing
  • 📚 Documentation: Comprehensive guides and examples

📈 Changelog

🌟 Version 2.0 (2025) - Enhanced Edition

Custom SVG Icon System
Scalable vector graphics for all UI elements
🎨 Enhanced Theme Versions
MacOS, MaterialDark, and Ubuntu themes improved
🔧 Complete Widget Coverage
Support for all major Qt widgets
📱 Modern Design Principles
Contemporary UI/UX patterns
Accessibility Features
Better contrast and usability
🧪 Theme Tester Application
Interactive testing and preview tool

📦 Version 1.0 (Original)

  • Initial theme collection by GTRONICK
  • Basic component styling
  • System-dependent icons

🆘 Support & Issues

Need Help

For bug reports and feature requests, please provide:

🖥️ System Info
Qt version, Platform, OS version
🎨 Theme Details
Which theme and component affected
🐛 Bug Description
Expected vs actual behavior
📷 Screenshots
Visual examples when possible

🎉 Thank you for using Enhanced Qt StyleSheets! 🎉

GitHub Qt

About

🚀 A comprehensive collection of enhanced Qt StyleSheets with modern design patterns, complete widget coverage, and integrated SVG icon system

Topics

Resources

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages