The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



TOnBeforeBoxDrawEvent


Unit:SDL_boxplot
Class: TBoxPlot
Declaration: TOnBeforeBoxDrawEvent = procedure (Sender: TObject; Column: integer; var ColorLines, ColorBody, ColorMinMax, Color90Perc, ColorMean, ColorMedian: TColor) of object;

The type TOnBeforeBoxDrawEvent declares the event which is triggered before the box of a boxplot is drawn. The parameter Column specifies the column of the Data array for which the box will be drawn. The parameters ColorLines, ColorBody, ColorMinMax, Color90Perc, ColorMean, and ColorMedian contain the default colors on entry of the event and may be altered in the event handler to adjust to the specific needs of the program.

Example: The following simple event handler forces a red box for the first column of the data array, and a blue one for any other column:
procedure TFrmProtoc.BoxPlotProtocBeforeBoxDraw(Sender: TObject;
  Column: Integer; var IntColorLines, IntColorBody, IntColorMinMax,
  IntColor90Perc, IntColorMean, IntColorMedian: TColor);

begin
if Column = 1
  then IntColorBody := clRed
  else IntColorBody := clBlue;
end;



Last Update: 2012-Oct-20