Zorder for graphical objects
leira:
If I create overlapping graphical objects programatically, they are stacked in the order of creation. I want to have more control the same way as for click events with property OBJPROP_ZORDER. In the following example, the red rectangle (test2) is drawn on top of the white rectangle (test1) because it was created after that object (test1).
Is there a way to keep the red rectangle (test2) below the white rectangle (test1)?
Why not create it before ? Or
ObjectSetInteger(id,"test2",OBJPROP_BACK,true);
If I create overlapping graphical objects programatically, they are stacked in the order of creation. I want to have more control the same way as for click events with property OBJPROP_ZORDER. In the following example, the red rectangle (test2) is drawn on top of the white rectangle (test1) because it was created after that object (test1).
Is there a way to keep the red rectangle (test2) below the white rectangle (test1)?