Hi DF!
Ich folgendes Problem:
Ich zeichne auf eine PaintBox, sobald das OnPaintevent abgesetzt wird. Ich sehe dann blaue Schlieren, also zeichnet er - aber nicht permanent?! Und wenn sich etwas über die besagte PaintBox legt, passiert auch nichts. Irgendwas ist da faul. Hier mein Code:
Delphi-Quelltext
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16:
| procedure TForm1.FormPaint(Sender: TObject); var ColI, RowI : Integer; begin if RectLength < RectBroads then ShowMessage('Achtung! Das Schlachtfeld kann nicht ordnungsgemäß gezeichnet werden'); with PLY_Map do begin for ColI := 0 to Cols - 1 do for RowI := 0 to Rows - 1 do Canvas.Rectangle(ColI * RectBroads, RowI * RectBroads, ColI * RectBroads + RectLength ,RowI * RectBroads + RectLength); end; end; |
Die Lösung ist nicht siebzehn.