mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-06 17:03:36 +01:00
carbon: implemented theme tree item drawing. changed highlight colors
git-svn-id: trunk@24852 -
This commit is contained in:
parent
2947939f60
commit
92b400b9d8
@ -19,7 +19,7 @@ uses
|
||||
// lcl
|
||||
LCLType, LCLProc, LCLIntf, Graphics, Themes, TmSchema,
|
||||
// widgetset
|
||||
CarbonProc, CarbonCanvas;
|
||||
CarbonProc, CarbonCanvas, CarbonGDIObjects;
|
||||
|
||||
type
|
||||
{ TCarbonThemeServices }
|
||||
@ -284,8 +284,17 @@ function TCarbonThemeServices.DrawTreeviewElement(DC: TCarbonDeviceContext;
|
||||
var
|
||||
ButtonDrawInfo: HIThemeButtonDrawInfo;
|
||||
LabelRect: HIRect;
|
||||
b: TCarbonBrush;
|
||||
begin
|
||||
if Details.Part in [TVP_GLYPH, TVP_HOTGLYPH] then
|
||||
case Details.Part of
|
||||
TVP_TREEITEM:
|
||||
begin
|
||||
b:=TCarbonBrush.Create(False);
|
||||
b.SetColor( ColorToRGB(clHighlight), True);
|
||||
DC.FillRect(R, b);
|
||||
b.Free;
|
||||
end;
|
||||
TVP_GLYPH, TVP_HOTGLYPH:
|
||||
begin
|
||||
ButtonDrawInfo.version := 0;
|
||||
ButtonDrawInfo.State := GetDrawState(Details);
|
||||
@ -305,6 +314,7 @@ begin
|
||||
|
||||
Result := CGRectToRect(LabelRect);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
|
||||
@ -1908,9 +1908,12 @@ begin
|
||||
COLOR_APPWORKSPACE:
|
||||
R := GetThemeBrushAsColor(kThemeBrushUtilityWindowBackgroundActive, Depth, True, C);
|
||||
COLOR_HIGHLIGHT:
|
||||
R := GetThemeBrushAsColor(kThemeBrushPrimaryHighlightColor, Depth, True, C);
|
||||
// kThemeBrushAlternatePrimaryHighlightColor is used as highlight in Finder
|
||||
R := GetThemeBrushAsColor(kThemeBrushAlternatePrimaryHighlightColor, Depth, True, C);
|
||||
//R := GetThemeBrushAsColor(kThemeBrushPrimaryHighlightColor, Depth, True, C);
|
||||
COLOR_HIGHLIGHTTEXT:
|
||||
R := GetThemeTextColor(kThemeTextColorPushButtonPressed, Depth, True, C);
|
||||
R := GetThemeTextColor(kThemeTextColorWhite, Depth, True, C);
|
||||
//R := GetThemeTextColor(kThemeTextColorPushButtonPressed, Depth, True, C);
|
||||
COLOR_SCROLLBAR, COLOR_BTNFACE:
|
||||
R := GetThemeBrushAsColor(kThemeBrushButtonFaceActive, Depth, True, C);
|
||||
COLOR_BTNSHADOW:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user