mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-27 13:57:25 +01:00
Qt: fixed color changing of TCustomPanel. issue #26607
git-svn-id: trunk@46089 -
This commit is contained in:
parent
108f83e4ef
commit
36ab86d76e
@ -779,7 +779,7 @@ type
|
|||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
procedure ReloadPaletteBegin; // used in QEventPaletteChange !
|
procedure ReloadPaletteBegin; // used in QEventPaletteChange !
|
||||||
procedure ReloadPaletteEnd; // used in QEventPaletteChange !
|
procedure ReloadPaletteEnd; // used in QEventPaletteChange !
|
||||||
procedure setColor(const AColor: PQColor); overload;
|
procedure setColor(const AColor: PQColor);
|
||||||
procedure setTextColor(const AColor: PQColor);
|
procedure setTextColor(const AColor: PQColor);
|
||||||
property Handle: QPaletteH read FHandle;
|
property Handle: QPaletteH read FHandle;
|
||||||
property CurrentColor: TQColor read FCurrentColor;
|
property CurrentColor: TQColor read FCurrentColor;
|
||||||
|
|||||||
@ -2412,7 +2412,14 @@ begin
|
|||||||
begin
|
begin
|
||||||
AWidget := HwndFromWidgetH(QtDC.Parent);
|
AWidget := HwndFromWidgetH(QtDC.Parent);
|
||||||
if (AWidget <> 0) and Assigned(TQtWidget(AWidget).LCLObject) then
|
if (AWidget <> 0) and Assigned(TQtWidget(AWidget).LCLObject) then
|
||||||
|
begin
|
||||||
ATransparent := not (csOpaque in TQtWidget(AWidget).LCLObject.ControlStyle);
|
ATransparent := not (csOpaque in TQtWidget(AWidget).LCLObject.ControlStyle);
|
||||||
|
// issue #26607
|
||||||
|
if ATransparent and (TQtWidget(AWidget).LCLObject is TCustomPanel) and
|
||||||
|
(TQtWidget(AWidget).LCLObject.Color <> clDefault) and
|
||||||
|
not TCustomPanel(TQtWidget(AWidget).LCLObject).ParentColor then
|
||||||
|
ATransparent := False;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
case Style of
|
case Style of
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user