mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 12:30:36 +02:00
Qt: implemented teProgress in qt themes.
git-svn-id: trunk@43150 -
This commit is contained in:
parent
88d5245c95
commit
0060290893
@ -173,6 +173,18 @@ begin
|
|||||||
inherited DrawElement(DC, Details, R, ClipRect);
|
inherited DrawElement(DC, Details, R, ClipRect);
|
||||||
qdvControl:
|
qdvControl:
|
||||||
begin
|
begin
|
||||||
|
if (Element.ControlElement in [QStyleCE_ProgressBar, QStyleCE_ProgressBarContents,
|
||||||
|
QStyleCE_ProgressBarGroove]) then
|
||||||
|
begin
|
||||||
|
opt := QStyleOptionProgressBarV2_create;
|
||||||
|
if Element.Features = QtVertical then
|
||||||
|
begin
|
||||||
|
QStyleOptionProgressBarV2_setOrientation(QStyleOptionProgressBarV2H(opt), QtVertical);
|
||||||
|
QStyleOptionProgressBarV2_setInvertedAppearance(QStyleOptionProgressBarV2H(opt), True);
|
||||||
|
QStyleOptionProgressBarV2_setBottomToTop(QStyleOptionProgressBarV2H(opt), True);
|
||||||
|
end else
|
||||||
|
QStyleOptionProgressBarV2_setOrientation(QStyleOptionProgressBarV2H(opt), QtHorizontal);
|
||||||
|
end else
|
||||||
if (Element.ControlElement = QStyleCE_TabBarTabShape) then
|
if (Element.ControlElement = QStyleCE_TabBarTabShape) then
|
||||||
begin
|
begin
|
||||||
opt := QStyleOptionTab_create();
|
opt := QStyleOptionTab_create();
|
||||||
@ -944,6 +956,18 @@ begin
|
|||||||
Result.PrimitiveElement := QStylePE_FrameTabBarBase;
|
Result.PrimitiveElement := QStylePE_FrameTabBarBase;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
teProgress:
|
||||||
|
begin
|
||||||
|
Result.DrawVariant := qdvControl;
|
||||||
|
case Details.Part of
|
||||||
|
PP_CHUNK,PP_CHUNKVERT: Result.ControlElement := QStyleCE_ProgressBarContents;
|
||||||
|
PP_FILL,PP_FILLVERT: Result.ControlElement := QStyleCE_ProgressBarGroove;
|
||||||
|
else
|
||||||
|
Result.ControlElement := QStyleCE_ProgressBar;
|
||||||
|
end;
|
||||||
|
if Byte(Details.Part) in [PP_BARVERT, PP_FILLVERT, PP_CHUNKVERT] then
|
||||||
|
Result.Features := QtVertical;
|
||||||
|
end;
|
||||||
teScrollBar:
|
teScrollBar:
|
||||||
begin
|
begin
|
||||||
Result.DrawVariant := qdvComplexControl;
|
Result.DrawVariant := qdvComplexControl;
|
||||||
|
Loading…
Reference in New Issue
Block a user