mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 16:16:05 +02:00
TAChart: Fix bar series drawing so that Source.Color, if set, overrides both BarBrush.Color and Styles.Brush.Color.
Fixes issue #18810 git-svn-id: trunk@29657 -
This commit is contained in:
parent
c8f3c56e61
commit
d48841a758
@ -756,11 +756,15 @@ var
|
||||
var
|
||||
sz: TSize;
|
||||
defaultDrawing: Boolean = true;
|
||||
c: TColor;
|
||||
begin
|
||||
ADrawer.Brush := BarBrush;
|
||||
ADrawer.Pen := BarPen;
|
||||
if Styles <> nil then
|
||||
Styles.Apply(ADrawer, stackIndex);
|
||||
c := Source[pointIndex]^.Color;
|
||||
if c <> clTAColor then
|
||||
ADrawer.BrushColor := c;
|
||||
sz := Size(AR);
|
||||
if (sz.cx <= 2) or (sz.cy <= 2) then begin
|
||||
// Bars are too small to distinguish the border from the interior.
|
||||
@ -835,7 +839,6 @@ begin
|
||||
Exchange(p.X, p.Y);
|
||||
p.X += ofs;
|
||||
cumulHeight := z;
|
||||
ADrawer.BrushColor := GetColor(pointIndex);
|
||||
stackIndex := 0;
|
||||
BuildBar(p.Y - z);
|
||||
for stackIndex := 1 to Source.YCount - 1 do
|
||||
|
Loading…
Reference in New Issue
Block a user