FunctionPackage: cgToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 8.2
Unrevised from 8.1 to 8.2.
8.1 version

update-window

Arguments: window

Calling this function causes any pending redisplay of window to be performed sooner than it would be by default. If window was created in the process that is calling update-window, then the redisplay will be immediate, and is guaranteed to be completed by the time that the call to update-window returns. If the window was created in some other thread, than the redisplay may happen sooner than it would be otherwise, though it will still happen asynchronously.

Normally the operating system invokes a window's redisplay-window method only after the process that created the window finishes handling other messages. This design avoids redundant redrawing of windows, which can slow down an application and produce annoying flashing effects. But if this design excessively delays the redrawing of a window, update-window may be called at any time to ensure that the window is brought up-to-date at that time.

See also redisplay-window, invalidate, and with-delayed-redraw.

Technical detail and compatibility note:

Starting with Allegro CL release 6.1, if the window was created in a process other than the process that is calling update-window, the window will not be updated immediately as it was in prior releases. The window will instead be updated only when the window's process (returned by creation-process applied to the window) runs again as usual and after the process has handled any messages that were already queued when update-window was called. This may, however, still update the window sooner than if update-window were not called, because a message is posted to the window telling it to update itself immediately when it gets to that message.

Before this change, a process calling update-window on a window in another process would always block until the other process performed further message handling and redisplayed the window. However, this waiting introduced the potential for deadlocks. With the change, deadlocks are avoided at the cost of perhaps some delay to window updating.

See cg-drawing.htm for a discussion of the uses of redisplay-window, invalidate, and update-window.


Copyright (c) 1998-2016, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 8.1 page.
Created 2010.1.21.

ToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 8.2
Unrevised from 8.1 to 8.2.
8.1 version