Listing Example Description: 1. Create a form, assume that its width is 500, set a button Button1, press this button to put the table as the gradient of the yellow to the left to the right. The code of the 2.Button1 button is as follows: Procedure TFORM1.BUTTON1CLICK (Sender: Tobject); VAR I, J: Integer; DCT: TRECT; Begin J: = form1.height; // Get Form Height for i: = 0 to 255 DO // Set the RGB () in the RGB () in the RGB (), a color value: = RGB (255, 255, i); // DCT: = RECT (i * 2, 0, (i 1) each time you draw rectangles ) * 2, j); // each time the rectangular area canvas.FillRect (DCT); // fill the color End;