Frage

I have the following problem: I want to draw many pictures in a row on the same place using cycles with a short brake (using sleep(n);) between each of them. But the only picture draws always after ale cycles are ended up. Is there any possibility to abort the cycle for a while, draw on a canvas and then repeat it until the cycle is at the end? Thank you for your answer and sorry for my strange explanation.

War es hilfreich?

Lösung

Not by simple draw and sleep sequences. The LCL is event driven and drawing is done in .paint methods in an event triggered by the mainloop.

The best way to do this is use a TTimer, set it to the frequency, and draw the next one if the timer fires.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top