{"id":45963,"library":"qt-material","title":"Qt-Material","description":"Material-inspired stylesheets for PySide6 and PyQt6 applications. Provides a modern Material Design theme with light/dark variants, customizable colors, and automatic layout support. Current version 2.17, released irregularly. Requires Python ≥3.7.","status":"active","version":"2.17","language":"python","source_language":"en","source_url":"https://github.com/dunderlab/qt-material.git","tags":["material-design","pyside6","pyqt6","stylesheet","theme","gui"],"install":[{"cmd":"pip install qt-material","lang":"bash","label":"default"}],"dependencies":[{"reason":"Runtime dependency (or PyQt6 alternative)","package":"PySide6","optional":true},{"reason":"Runtime dependency (or PySide6 alternative)","package":"PyQt6","optional":true}],"imports":[{"note":"Class name is plural: QtStyleTools","wrong":"from qt_material import QtStyleTool","symbol":"QtStyleTools","correct":"from qt_material import QtStyleTools"},{"note":"apply_stylesheet is directly in qt_material","wrong":"from qt_material.styles import apply_stylesheet","symbol":"apply_stylesheet","correct":"from qt_material import apply_stylesheet"},{"note":"list_themes is a top-level function","wrong":"from qt_material.themes import list_themes","symbol":"list_themes","correct":"from qt_material import list_themes"}],"quickstart":{"code":"import sys\nfrom PySide6 import QtWidgets\nfrom qt_material import apply_stylesheet\n\napp = QtWidgets.QApplication(sys.argv)\napply_stylesheet(app, theme='dark_teal.xml')\nwindow = QtWidgets.QMainWindow()\nwindow.show()\nsys.exit(app.exec())","lang":"python","description":"Create a QApplication, apply a Material theme, and launch a window."},"warnings":[{"fix":"Upgrade to PySide6 or PyQt6, or use qt-material 1.x (if you must stay on older Qt bindings).","message":"qt-material 2.x is not compatible with PyQt5 or PySide2. Only PySide6 and PyQt6 are supported.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Use only the theme name (e.g., 'dark_teal.xml') and ensure theme files are bundled with the package.","message":"The function `apply_stylesheet` parameter `theme` expects theme file name (e.g., 'dark_teal.xml') not a path. Using a full path may cause issues in some cases.","severity":"deprecated","affected_versions":"all"},{"fix":"Call apply_stylesheet immediately after creating QApplication, before any window.show().","message":"Applying a stylesheet after showing the window may cause visual glitches. Always apply before showing any widgets.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"search_vec":"'2.17':30 '3.7':35 'applic':12 'automat':25 'color':23 'current':28 'customiz':22 'design':17,38 'gui':43 'inspir':6 'irregular':32 'layout':26 'light/dark':20 'materi':3,5,16,37 'material-design':36 'material-inspir':4 'modern':15 'provid':13 'pyqt6':11,40 'pyside6':9,39 'python':34 'qt':2 'qt-materi':1 'releas':31 'requir':33 'stylesheet':7,41 'support':27 'theme':18,42 'variant':21 'version':29","created_at":"2026-06-07T12:57:35.410655+00:00","updated_at":"2026-06-07T12:57:35.410655+00:00","problems":[{"fix":"Run `pip install qt-material`.","cause":"The library is not installed.","error":"ModuleNotFoundError: No module named 'qt_material'"},{"fix":"Use `from qt_material import apply_stylesheet` and ensure qt-material >=2.0.0.","cause":"The import path is wrong or an old version is installed.","error":"AttributeError: module 'qt_material' has no attribute 'apply_stylesheet'"},{"fix":"Use full filename with .xml, e.g., 'dark_teal.xml'.","cause":"Theme name missing the .xml extension.","error":"qt_material.exceptions.ThemeNotFoundError: Theme 'dark_teal' not found."}],"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/dunderlab/qt-material.git","github":"https://github.com/dunderlab/qt-material.git","docs":null,"changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["devops"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-06-29","last_verified":"2026-06-29","next_check":"2026-07-29","install_tag":null}}