XCB Property Functions

These functions ease the handling of X propertiess received. More...

Functions

xcb_get_property_cookie_t xcb_get_any_property (xcb_connection_t *c, uint8_t del, xcb_window_t window, xcb_atom_t name, uint32_t long_len)
 Get any property from a window, from any format.
xcb_get_property_cookie_t xcb_get_any_property_unchecked (xcb_connection_t *c, uint8_t del, xcb_window_t window, xcb_atom_t name, uint32_t long_len)
void xcb_property_handlers_init (xcb_property_handlers_t *prophs, xcb_event_handlers_t *evenths)
 Initialize a property handlers structure.
void xcb_property_handlers_wipe (xcb_property_handlers_t *prophs)
 Wipe a property handler structure.
xcb_event_handlers_t * xcb_property_get_event_handlers (xcb_property_handlers_t *prophs)
 Get a event handlers from a property handlers data structure.
uint8_t xcb_property_set_handler (xcb_property_handlers_t *prophs, xcb_atom_t name, uint32_t long_len, xcb_generic_property_handler_t handler, void *data)
 Set a property handler for an event.
uint8_t xcb_property_set_default_handler (xcb_property_handlers_t *prophs, uint32_t long_len, xcb_generic_property_handler_t handler, void *data)
 Set the default property handler.
int xcb_property_changed (xcb_property_handlers_t *prophs, uint8_t state, xcb_window_t window, xcb_atom_t atom)
 Notify that a property has changed and call handler function callback as needed.

Detailed Description

These functions ease the handling of X propertiess received.


Function Documentation

xcb_get_property_cookie_t xcb_get_any_property ( xcb_connection_t *  c,
uint8_t  del,
xcb_window_t  window,
xcb_atom_t  name,
uint32_t  long_len 
)

Get any property from a window, from any format.

Parameters:
c The connection to the X server.
del Boolean value that determines whether the property is deleted.
window The window to get property from.
name The property atom name.
long_len The maximum length of the property.
Returns:
A cookie.

Referenced by xcb_get_text_property().

xcb_get_property_cookie_t xcb_get_any_property_unchecked ( xcb_connection_t *  c,
uint8_t  del,
xcb_window_t  window,
xcb_atom_t  name,
uint32_t  long_len 
)

int xcb_property_changed ( xcb_property_handlers_t *  prophs,
uint8_t  state,
xcb_window_t  window,
xcb_atom_t  atom 
)

Notify that a property has changed and call handler function callback as needed.

Parameters:
prophs The property handlers.
state The property state.
window The window.
atom The property atom name.

References xcb_event_get_xcb_connection(), and xcb_property_get_event_handlers().

xcb_event_handlers_t* xcb_property_get_event_handlers ( xcb_property_handlers_t *  prophs  ) 

Get a event handlers from a property handlers data structure.

Parameters:
prophs The property handlers.
Returns:
The event handlers data structure which was set if any, NULL otherwise.

Referenced by xcb_property_changed().

void xcb_property_handlers_init ( xcb_property_handlers_t *  prophs,
xcb_event_handlers_t *  evenths 
)

Initialize a property handlers structure.

Parameters:
prophs The property handlers data structure pointer.
evenths The event handlers.

void xcb_property_handlers_wipe ( xcb_property_handlers_t *  prophs  ) 

Wipe a property handler structure.

Parameters:
prophs The property handlers data structure pointer.

uint8_t xcb_property_set_default_handler ( xcb_property_handlers_t *  prophs,
uint32_t  long_len,
xcb_generic_property_handler_t  handler,
void *  data 
)

Set the default property handler.

If a property does not have its own handler function, this one will be used.

Parameters:
prophs The property handlers.
name The property atom name.
long_len The maximum length of the property value that will be handled.
handler The handler callback function.
data Optional data that will be passed as argument of the handler callback function. Can be NULL safely if you do not need it.
Returns:
Return 1 on success, 0 otherwise.

uint8_t xcb_property_set_handler ( xcb_property_handlers_t *  prophs,
xcb_atom_t  name,
uint32_t  long_len,
xcb_generic_property_handler_t  handler,
void *  data 
)

Set a property handler for an event.

Parameters:
prophs The property handlers.
name The property atom name.
long_len The maximum length of the property value that will be handled.
handler The handler callback function.
data Optional data that will be passed as argument of the handler callback function. Can be NULL safely if you do not need it.
Returns:
Return 1 on success, 0 otherwise.

Referenced by xcb_watch_wm_client_machine(), xcb_watch_wm_icon_name(), and xcb_watch_wm_name().


Generated on Thu Feb 25 16:28:36 2010 for XCBUtility by  doxygen 1.5.6