I always wondered why I would need this, but finally something popped up and it was a perfect solution.
I have my basic playing card drawing routines in a unit. In that unit is an "animatecard" procedure that moves a card from one point to another. I'm using page flipping to make it work without flickering. The animatecard procedure needs to update the background screen, which is unique for every game, prior to drawing a card at its new location. Using a procedural variable passed by the calling procedure it enables the animatecard procedure to update properly by calling the passed procedural variable.
The animatecard routine gets called as
animatecard(fromx,fromy,tox,toy,reps,card,@paintscreen);
The animatecard uses an unrolled version of brensenham's integer only line algorithm to move the card from the startpoint to the endpoint.