At 5:42 PM -0500 3/4/06, Maurice Volaski wrote:
It appears that there are two issues, one that DrawPicture takes too long to
draw and the other is drawing within a method in a canvas ignores all
drawing commands but the last one.

Well frankly I don't see any problems.

The first one marches a grid across my screen without any flicker...

The second one is a coding problem.

OSX is double buffered meaning it intentionally draws your graphics commands to an offscreen buffer and then flushes them on screen all at once. RB assumes that you're done drawing when you return to the main event loop. If you want your graphics operations to show up sooner, you need to call UpdateNow on your window.

Additionally you need to allow some time for your first color to register in your viewer's eye/brain before changing to the second color. Otherwise nothing will be perceived even though the first color showed for a brief period. Here's an updated method that shows how to do both...

  me.graphics.ForeColor = RGB( 20, 80, 160 ) // BLUE
  me.graphics.FillRect(0,0,me.graphics.width,me.graphics.height)

  Window.UpdateNow  //Flush the Blue rect to the screen

  Dim DoneTicks as integer = Ticks + 30
  While Ticks < Doneticks
   //Allow the blue rect to linger for half a second
  Wend

  me.graphics.ClearRect(0,0,me.graphics.width,me.graphics.height)
  me.graphics.ForeColor = RGB( 160, 80, 20 ) // ORANGE
  me.graphics.FillRect(0,0,me.graphics.width,me.graphics.height)


Hope this helps,
Joe
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to