XGrabPointer generates EnterNotify and LeaveNotify events. If the pointer is actively grabbed by some other client, it fails and returns AlreadyGrabbed. If the pointer is frozen by an active grab of another client, it fails and returns GrabFrozen. The XUngrabPointer function releases the pointer and any queued events if this client has actively grabbed the pointer from XGrabPointer, XGrabButton, or from a normal button press. It also generates EnterNotify and LeaveNotify events.
Some numeric value falls outside the range of values accepted by the request.
Unless a spe cific 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 generate this error. BadWindow A value for a Window argument does not name a defined Window.