[Xcb] Window closed event and xcb_connect return value.

Eamon Walsh ewalsh at tycho.nsa.gov
Fri Apr 24 13:20:35 PDT 2009


Julien Danjou wrote:
> At 1240571698 time_t, shuLhan wrote:
>   
>> 1. how to get window-closed event ?
>>     
>
> Select unmap or destroy notify on the window.
>
>   
>> 2. how do i check fail in xcb_connect() ?
>>
>> 	when i check in xcb_util.c, xcb_connect return
>> 	(xcb_connection_t *) 1 if error. since xcb_connection_t is
>> 	(struct) opaque type how do i cast this to integer ?
>>     
>
> Just cast it.
>
> Cheers,
>   

use xcb_connection_has_error(), documented in xcb.h

The whole thing with the 1 is not part of the api IIUC.


More information about the Xcb mailing list