[fpc-pascal] fpreport rangeerrors with TFPReportColor

Graeme Geldenhuys mailinglists at geldenhuys.co.uk
Wed Feb 21 20:54:55 CET 2018


On 2018-02-21 08:48, Andreas Frieß wrote:
> 
> The definition is TFPReportColor  = type UInt32;

That was designed and defined to handle AARRGGBB values of $FFFFFFFF 
(max 256 for each color channel and alpha), and that fits perfectly in a 
UInt32 data type.

> Should the definition for TFPReportColor not better TFPColor

I can't remember from memory. Is TFPColor the one where each color 
channel is a Word size (ie: $FFFF)?  When I wrote fpReport, that color 
range was note designed for and I've never seen in used in the 
real-world either.


> Because UInt32 is not a JSON dataformat.

Well, then I'll say that FPC's JSON needs to be extended to support 
UInt32, as it is a perfectly valid Object Pascal data type.


Regards,
   Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp



More information about the fpc-pascal mailing list