summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2012-11-30 16:01:47 +0000
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2012-11-30 16:01:47 +0000
commit269d14b00140f054b182b8805756d994f5e9d828 (patch)
tree2cce2c7d7bb507e93aab2234141c62d351f007e7 /src/gui
parentff06e4037e8bc6daff07393c01f6a134f2293a62 (diff)
downloadfpGUI-269d14b00140f054b182b8805756d994f5e9d828.tar.xz
Fixes compiler warning about using a deprecated type... TFPColor
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/fpg_gauge.pas12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/gui/fpg_gauge.pas b/src/gui/fpg_gauge.pas
index e980c817..2b947442 100644
--- a/src/gui/fpg_gauge.pas
+++ b/src/gui/fpg_gauge.pas
@@ -127,12 +127,12 @@ uses
to be moved in CanvasBase? }
procedure FillArcGradient(canvas: TfpgCanvas; X,Y,W,H: TfpgCoord; a1,a2: double; Astart,Astop: TfpgColor);
var
- RGBStart: TFPColor;
- RGBStop: TFPColor;
+ RGBStart: TRGBTriple;
+ RGBStop: TRGBTriple;
RDiff, GDiff, BDiff: Integer;
count: Integer;
i: Integer;
- newcolor: TFPColor;
+ newcolor: TRGBTriple;
begin
if Astart = Astop then
begin { No gradient, just solid color}
@@ -141,8 +141,8 @@ begin
Exit; //==>
end;
- RGBStart := fpgColorToFPColor(fpgColorToRGB(AStart));
- RGBStop := fpgColorToFPColor(fpgColorToRGB(AStop));
+ RGBStart := fpgColorToRGBTriple(fpgColorToRGB(AStart));
+ RGBStop := fpgColorToRGBTriple(fpgColorToRGB(AStop));
count := min(H,W);
count := count div 2;
@@ -168,7 +168,7 @@ begin
newcolor.Red := RGBStart.Red + (i * RDiff) div count;
newcolor.Green := RGBStart.Green + (i * GDiff) div count;
newcolor.Blue := RGBStart.Blue + (i * BDiff) div count;
- canvas.SetColor(FPColorTofpgColor(newcolor));
+ canvas.SetColor(RGBTripleTofpgColor(newcolor));
canvas.DrawArc(X, Y, W, H, a1, a2);
end;
end;