Bug fixes for Qt6.

main
Alex Huszagh 2022-05-07 12:34:49 -05:00
parent 53be089f6a
commit 3c7306469e
2 changed files with 3 additions and 5 deletions

View File

@ -62,7 +62,7 @@ class LCD(QtWidgets.QLCDNumber):
self.setStyleSheet(f'QLCDNumber {{ color: rgba{color}; }}') self.setStyleSheet(f'QLCDNumber {{ color: rgba{color}; }}')
palette = self.palette() palette = self.palette()
palette.setColor(compat.BackgroundPalette, colors.Background) palette.setColor(compat.WindowPalette, colors.Background)
palette.setColor(compat.LightPalette, colors.Selected) palette.setColor(compat.LightPalette, colors.Selected)
palette.setColor(compat.DarkPalette, colors.Notch) palette.setColor(compat.DarkPalette, colors.Notch)
self.setPalette(palette) self.setPalette(palette)

View File

@ -246,9 +246,8 @@ def get_compat_definitions(args):
ns.MouseMove = ns.EventType.MouseMove ns.MouseMove = ns.EventType.MouseMove
ns.WindowPalette = ns.ColorRole.Window ns.WindowPalette = ns.ColorRole.Window
ns.WindowTextPalette = ns.ColorRole.WindowText ns.WindowTextPalette = ns.ColorRole.WindowText
ns.BackgroundPalette = ns.ColorRole.Background ns.LightPalette = ns.ColorRole.Light
ns.LightPalette = ns.ColorRole.LightPalette ns.DarkPalette = ns.ColorRole.Dark
ns.DarkPalette = ns.ColorRole.DarkPalette
ns.PlaceholderText = ns.ColorRole.PlaceholderText ns.PlaceholderText = ns.ColorRole.PlaceholderText
ns.ToolTipBase = ns.ColorRole.ToolTipBase ns.ToolTipBase = ns.ColorRole.ToolTipBase
ns.ToolTipText = ns.ColorRole.ToolTipText ns.ToolTipText = ns.ColorRole.ToolTipText
@ -531,7 +530,6 @@ def get_compat_definitions(args):
ns.MouseMove = QtCore.QEvent.MouseMove ns.MouseMove = QtCore.QEvent.MouseMove
ns.WindowPalette = QtGui.QPalette.Window ns.WindowPalette = QtGui.QPalette.Window
ns.WindowTextPalette = QtGui.QPalette.WindowText ns.WindowTextPalette = QtGui.QPalette.WindowText
ns.BackgroundPalette = QtGui.QPalette.Background
ns.LightPalette = QtGui.QPalette.Light ns.LightPalette = QtGui.QPalette.Light
ns.DarkPalette = QtGui.QPalette.Dark ns.DarkPalette = QtGui.QPalette.Dark
ns.PlaceholderText = QtGui.QPalette.PlaceholderText ns.PlaceholderText = QtGui.QPalette.PlaceholderText