Es demasiado corto tu mensaje para comprender a fondo lo que estás haciendo, usando qué y por qué. Sin embargo, quizá debas dibujar esas líneas en el evento OnPaint del formulario.
De la ayuda de Delphi:
Cita:
OnPaint event (TCustomForm)
Delphi syntax:
property OnPaint: TNotifyEvent;
Description
Use OnPaint to perform special processing when the form is redrawn. Any special painting on the form should be done in this event. OnPaint occurs before any controls on the form are painted.
To determine which portions of the form’s canvas need to be repainted, use the ClipRect property of the canvas.
If you use the form’s Canvas property outside the OnPaint event, it will be erased and drawn-over by the next OnPaint event.
|