Arnould Nazarian wrote:
> OK, but it is preferrable that the programmer does not forget to
> call that code everytime it is needed.

Actually the code is called by Windows whenever it's needed.
In pseudo-SBasic a Hello World app would look somewhat like this:

REMark Simple hello world application
Invalidate
QUIT
:
DEFine PROCedure Paint
  CLS
  PRINT "Hello world"
END DEFine

The "Invalidate" tells Windows that some area is dirty and needs to be
repainted. As a reaction Windows calls the Paint procedure.
Furthermore this procedure is called everytime the window is brought
to the top after it was buried. If only a part is shown Windows makes
sure that only this part is actually repainted.

In practise current Windows application development is so high level
that most programers don't need to be aware of this underlying
mechanism. All components like list boxes, buttons, edit lines, scroll
bars etc know how to repaint themselves, it's no concern to the
programmer.

BTW: If anybody is waiting for some private mail from me, I'm coming
to that. Currently I'm dead tired.

Marcel

Reply via email to