XWithdrawWindow can generate a BadWindow error. The XReconfigureWMWindow function issues a ConfigureWindow request on the specified top-level window. If the stacking mode is changed and the request fails with a BadMatch error, the error is trapped by Xlib and a synthetic ConfigureRe- questEvent containing the same configuration parameters is sent to the root of the specified window. Window managers may elect to receive this event and treat it as a request to reconfigure the indicated window. XReconfigureWMWindow can generate BadValue and BadWindow errors.
Some numeric value falls outside the range of values accepted by the request.
Unless a specific range is specified for an argument, the full range defined by the argument's type is accepted. Any argument defined as a set of alternatives can gen- erate this error. BadWindow A value for a Window argument does not name a defined Window.