Open jakeanq opened 1 year ago
Python
Using QMessageBox.question with a short example text and several buttons collapses one of the buttons - see the example code below.
If commenting out the setStyleSheet line, everything looks good.
setStyleSheet
Using PySide2 or a different computer also exhibits the issue.
The left button is cut off:
The layout should look like this (but with the dark theme ;) )
from PySide2 import QtWidgets import sys import qdarkstyle if __name__ == "__main__": app = QtWidgets.QApplication(sys.argv) app.setStyleSheet(qdarkstyle.load_stylesheet(qt_api="pyside2")) QtWidgets.QMessageBox.question( None, "ExampleApp9000", "You have 42 unsaved changes", QtWidgets.QMessageBox.Save | QtWidgets.QMessageBox.Discard | QtWidgets.QMessageBox.Cancel, )
Describe Your Environment
qdarkstyle --all
``` /home/jake/rsp-testing/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py:142: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives return original_import(name, *args, **kwargs) * OPERATING SYSTEM--------------------------------------------------------------- - System........................ Linux - Release....................... 6.0.9-arch1-1 - Platform...................... Linux-6.0.9-arch1-1-x86_64-with-glibc2.36 - Version....................... #1 SMP PREEMPT_DYNAMIC Wed, 16 Nov 2022 17:01:17 +0000 * PYTHON DISTRIBUTION------------------------------------------------------------ - Version....................... 3.10.8 - C Compiler.................... GCC 12.2.0 - C API Version................. 1013 - Implementation................ cpython - Implementation Version........ 3.10.8 * QT BINDINGS-------------------------------------------------------------------- - PyQt5 Version................. 5.15.7 - PyQt5 Qt Version.............. 5.15.2 - PySide2 Version............... 5.15.2.1 - PySide2 Qt Version............ 5.15.2 * QT ABSTRACTIONS---------------------------------------------------------------- - qtpy Version.................. 1.11.3 - qtpy Binding.................. pyqt5 - qtpy Binding Variable......... os.environ['QT_API'] - qtpy Import Name.............. qtpy - qtpy Status................... OK - Qt Version.................... 1.3.6 - Qt Binding.................... PySide2 - Qt Binding Variable........... Qt.__binding__ - Qt Import Name................ Qt - Qt Status..................... OK * PYTHON PACKAGES---------------------------------------------------------------- - helpdev....................... 0.7.1 - QDarkStyle.................... 3.1 ```Language
Python
Description / Steps to Reproduce
Using QMessageBox.question with a short example text and several buttons collapses one of the buttons - see the example code below.
If commenting out the
setStyleSheet
line, everything looks good.Using PySide2 or a different computer also exhibits the issue.
Actual Result
The left button is cut off:
Expected Results / Proposed Result
The layout should look like this (but with the dark theme ;) )![image](https://user-images.githubusercontent.com/3282717/207237290-5b6ffdbb-5851-46f7-9701-16bb2ec5a63a.png)
Relevant Code