I was under the impression that 'Depth' values is all thats required to control draw order between a hierarchy of UIWidget, UITextures and UISprites.
But I ran into a situation where I have a root UIWidget (depth: 0), a child UITexture (depth: -1) as a background image, a child UITexture (depth: 10) as a foreground image, a child UIWidget (depth: 5) w/ children UISprites (depth: 5) buttons, and a UIScrollView/UIPanel (depth: 1) w/ UIWidget + UITexture (depth: 1) elements under it.
And the draw order isn't as I expected (buttons and foreground are behind the UIScrollView elements). I was able to resolve the issue by adjusting the Z values, but is there a more proper way to setup the Depth values?