A depth of CopyFromParent means the depth is taken from the parent. This mask is the bitwise inclusive OR of the valid attribute mask bits. If valuemask is zero, the attributes are ignored and are not referenced. The XCreateWindow function creates an unmapped subwindow for a specified parent window, returns the window ID of the created window, and causes the X server to generate a CreateNotify event. The created window is placed on top in the stacking order with respect to siblings.
Coordinates are integral, in terms of pixels, and coincide with pixel centers.
Each window and pixmap has its own coordinate system. For a window, the origin is inside the border at the inside, upper-left corner. For class InputOutput , the visual type and depth must be a combination supported for the screen, or a BadMatch error results. The depth need not be the same as the parent, but the parent must not be a window of class InputOnly , or a BadMatch error results. For an InputOnly window, the depth must be zero, and the visual must be one supported by the screen.