
I'm writing a pretty complex script (that I'm going to share with the community) that simply won't reliably draw without toFront() and toBack() working properly. I have a mix of graphics and paths where I need to be able to control the Z-order, and I find toFront() and toBack() to have no effect. Thanks to The Aaron for pointing out a workaround: run toBack() against objects in series with a delay of 50ms between each operation. (The same process for toFront() failed even with delays up to 1000ms). Successes: Natural insertion of paths (if no graphics are involved). toBack() of mixed graphics and paths if delayed in series. Failures: Natural insertion of graphics. Natural insertion of mixed graphics and paths. toFront(). toBack() without delays. I have a thread in the API forum about this as well, as it's API-related, but I haven't gotten a response there: API forum thread I also wrote a script that illustrates the error (and can be used for debugging) - the pic above was generated by this script: tester script