View Issue Details

IDProjectCategoryView StatusLast Update
0038589LazarusWidgetsetpublic2021-03-05 19:48
ReporterZoë Peterson Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
Product Version2.0.13 (SVN) 
Summary0038589: LCLQT controls don't update properly when changing the application palette
DescriptionIf you change the application palette using QApplication_setPalette, the cached system colors are cleared and a some of the interface updates appropriately, but forms and edits are still drawn with the old background color. Recreating the form's handle updates the appearance, but shouldn't be necessary. Creating a form/button/edit with raw QT commands will result in that window updating its appearance immediately.
Steps To ReproduceThe attached app demonstrates the problem. It creates two top level windows, one is an LCL TForm and the other is a raw QMainWindowH, both with buttons and an edit on them. Run it with "-style cde" to get the most noticeable results. Tested on Linux Mint.

The buttons on the main window are:
* Default Palette: Set the application palette to the active style's standardPalette.
* Light Palette/Dark Palette: Set the application palette to a fixed light or dark set of colors.
* RecreateWnd: Call RecreateWnd on the LCL form

When pressing any of the Palette buttons, the appearance of the raw QT window updates immediately, On the LCL form, a bunch of the drawing updates, but the form's background and the edit background are drawn incorrectly until you click the RecreateWnd button.
TagsNo tags attached.
Fixed in Revision
LazTarget
WidgetsetQT5
Attached Files

Activities

Zoë Peterson

2021-03-05 19:48

reporter  

QtPaletteChange.tar.gz (111,038 bytes)

Issue History

Date Modified Username Field Change
2021-03-05 19:48 Zoë Peterson New Issue
2021-03-05 19:48 Zoë Peterson File Added: QtPaletteChange.tar.gz