CLIM mail archive

[Prev][Next][Index][Thread]

Replacing presentations



Having been unsuccessful in my previous approach to "rolling my own"
incremental redisplay, I've revised my plan and found another way to fail.


Goal:
Cause some presentations in a window to change color under program control.


Approach #1 (previous attempt):
a) SETF the PRESENTATION-TYPE of each presentation
b) call REPLAY-OUTPUT-RECORD on each

Problem #1:
No change appears on the screen.


Approach #2 (current attempt):
a) get the BOUNDING-RECTANGLE-MIN-X, BOUNDING-RECTANGLE-MIN-Y, and
   OUTPUT-RECORD-PARENT of each presentation
b) remove the orginal presentation using ERASE-OUTPUT-RECORD
c) create a new presentation using PRESENT inside of
   WITH-OUTPUT-RECORDING-OPTIONS (STREAM :DRAW NIL :RECORD T)
d) add the new presentation (output record) to the parent of the old one
   (which happens to be a STANDARD-CELL-OUTPUT-RECORD in this case)
   using ADD-OUTPUT-RECORD
e) fix the coordinates of the new presentation using OUTPUT-RECORD-SET-POSITION
f) call REPLAY on the new presentation

Problem #2:
Something in the output recording protocol becomes seriously broken. One clear
aspect of this is that presentations disappear and reappear in new positions
when the window is scrolled.


Surely there must be a simple way to achieve my very modest goal.
Would someone please put me out of my misery and tell me what it is? :-)


Main Index | Thread Index