1 /* 2 * This file generated automatically from xfixes.xml by c_client.py. 3 * Edit at your peril. 4 */ 5 6 #include <string.h> 7 #include <assert.h> 8 #include "xcbext.h" 9 #include "xfixes.h" 10 #include "xproto.h" 11 #include "render.h" 12 #include "shape.h" 13 14 xcb_extension_t xcb_xfixes_id = { "XFIXES", 0 }; 15 16 17 /***************************************************************************** 18 ** 19 ** xcb_xfixes_query_version_cookie_t xcb_xfixes_query_version 20 ** 21 ** @param xcb_connection_t *c 22 ** @param uint32_t client_major_version 23 ** @param uint32_t client_minor_version 24 ** @returns xcb_xfixes_query_version_cookie_t 25 ** 26 *****************************************************************************/ 27 28 xcb_xfixes_query_version_cookie_t 29 xcb_xfixes_query_version (xcb_connection_t *c /**< */, 30 uint32_t client_major_version /**< */, 31 uint32_t client_minor_version /**< */) 32 { 33 static const xcb_protocol_request_t xcb_req = { 34 /* count */ 2, 35 /* ext */ &xcb_xfixes_id, 36 /* opcode */ XCB_XFIXES_QUERY_VERSION, 37 /* isvoid */ 0 38 }; 39 40 struct iovec xcb_parts[4]; 41 xcb_xfixes_query_version_cookie_t xcb_ret; 42 xcb_xfixes_query_version_request_t xcb_out; 43 44 xcb_out.client_major_version = client_major_version; 45 xcb_out.client_minor_version = client_minor_version; 46 47 xcb_parts[2].iov_base = (char *) &xcb_out; 48 xcb_parts[2].iov_len = sizeof(xcb_out); 49 xcb_parts[3].iov_base = 0; 50 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 51 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 52 return xcb_ret; 53 } 54 55 56 /***************************************************************************** 57 ** 58 ** xcb_xfixes_query_version_cookie_t xcb_xfixes_query_version_unchecked 59 ** 60 ** @param xcb_connection_t *c 61 ** @param uint32_t client_major_version 62 ** @param uint32_t client_minor_version 63 ** @returns xcb_xfixes_query_version_cookie_t 64 ** 65 *****************************************************************************/ 66 67 xcb_xfixes_query_version_cookie_t 68 xcb_xfixes_query_version_unchecked (xcb_connection_t *c /**< */, 69 uint32_t client_major_version /**< */, 70 uint32_t client_minor_version /**< */) 71 { 72 static const xcb_protocol_request_t xcb_req = { 73 /* count */ 2, 74 /* ext */ &xcb_xfixes_id, 75 /* opcode */ XCB_XFIXES_QUERY_VERSION, 76 /* isvoid */ 0 77 }; 78 79 struct iovec xcb_parts[4]; 80 xcb_xfixes_query_version_cookie_t xcb_ret; 81 xcb_xfixes_query_version_request_t xcb_out; 82 83 xcb_out.client_major_version = client_major_version; 84 xcb_out.client_minor_version = client_minor_version; 85 86 xcb_parts[2].iov_base = (char *) &xcb_out; 87 xcb_parts[2].iov_len = sizeof(xcb_out); 88 xcb_parts[3].iov_base = 0; 89 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 90 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 91 return xcb_ret; 92 } 93 94 95 /***************************************************************************** 96 ** 97 ** xcb_xfixes_query_version_reply_t * xcb_xfixes_query_version_reply 98 ** 99 ** @param xcb_connection_t *c 100 ** @param xcb_xfixes_query_version_cookie_t cookie 101 ** @param xcb_generic_error_t **e 102 ** @returns xcb_xfixes_query_version_reply_t * 103 ** 104 *****************************************************************************/ 105 106 xcb_xfixes_query_version_reply_t * 107 xcb_xfixes_query_version_reply (xcb_connection_t *c /**< */, 108 xcb_xfixes_query_version_cookie_t cookie /**< */, 109 xcb_generic_error_t **e /**< */) 110 { 111 return (xcb_xfixes_query_version_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 112 } 113 114 115 /***************************************************************************** 116 ** 117 ** xcb_void_cookie_t xcb_xfixes_change_save_set_checked 118 ** 119 ** @param xcb_connection_t *c 120 ** @param uint8_t mode 121 ** @param uint8_t target 122 ** @param uint8_t map 123 ** @param xcb_window_t window 124 ** @returns xcb_void_cookie_t 125 ** 126 *****************************************************************************/ 127 128 xcb_void_cookie_t 129 xcb_xfixes_change_save_set_checked (xcb_connection_t *c /**< */, 130 uint8_t mode /**< */, 131 uint8_t target /**< */, 132 uint8_t map /**< */, 133 xcb_window_t window /**< */) 134 { 135 static const xcb_protocol_request_t xcb_req = { 136 /* count */ 2, 137 /* ext */ &xcb_xfixes_id, 138 /* opcode */ XCB_XFIXES_CHANGE_SAVE_SET, 139 /* isvoid */ 1 140 }; 141 142 struct iovec xcb_parts[4]; 143 xcb_void_cookie_t xcb_ret; 144 xcb_xfixes_change_save_set_request_t xcb_out; 145 146 xcb_out.mode = mode; 147 xcb_out.target = target; 148 xcb_out.map = map; 149 xcb_out.pad0 = 0; 150 xcb_out.window = window; 151 152 xcb_parts[2].iov_base = (char *) &xcb_out; 153 xcb_parts[2].iov_len = sizeof(xcb_out); 154 xcb_parts[3].iov_base = 0; 155 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 156 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 157 return xcb_ret; 158 } 159 160 161 /***************************************************************************** 162 ** 163 ** xcb_void_cookie_t xcb_xfixes_change_save_set 164 ** 165 ** @param xcb_connection_t *c 166 ** @param uint8_t mode 167 ** @param uint8_t target 168 ** @param uint8_t map 169 ** @param xcb_window_t window 170 ** @returns xcb_void_cookie_t 171 ** 172 *****************************************************************************/ 173 174 xcb_void_cookie_t 175 xcb_xfixes_change_save_set (xcb_connection_t *c /**< */, 176 uint8_t mode /**< */, 177 uint8_t target /**< */, 178 uint8_t map /**< */, 179 xcb_window_t window /**< */) 180 { 181 static const xcb_protocol_request_t xcb_req = { 182 /* count */ 2, 183 /* ext */ &xcb_xfixes_id, 184 /* opcode */ XCB_XFIXES_CHANGE_SAVE_SET, 185 /* isvoid */ 1 186 }; 187 188 struct iovec xcb_parts[4]; 189 xcb_void_cookie_t xcb_ret; 190 xcb_xfixes_change_save_set_request_t xcb_out; 191 192 xcb_out.mode = mode; 193 xcb_out.target = target; 194 xcb_out.map = map; 195 xcb_out.pad0 = 0; 196 xcb_out.window = window; 197 198 xcb_parts[2].iov_base = (char *) &xcb_out; 199 xcb_parts[2].iov_len = sizeof(xcb_out); 200 xcb_parts[3].iov_base = 0; 201 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 202 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 203 return xcb_ret; 204 } 205 206 207 /***************************************************************************** 208 ** 209 ** xcb_void_cookie_t xcb_xfixes_select_selection_input_checked 210 ** 211 ** @param xcb_connection_t *c 212 ** @param xcb_window_t window 213 ** @param xcb_atom_t selection 214 ** @param uint32_t event_mask 215 ** @returns xcb_void_cookie_t 216 ** 217 *****************************************************************************/ 218 219 xcb_void_cookie_t 220 xcb_xfixes_select_selection_input_checked (xcb_connection_t *c /**< */, 221 xcb_window_t window /**< */, 222 xcb_atom_t selection /**< */, 223 uint32_t event_mask /**< */) 224 { 225 static const xcb_protocol_request_t xcb_req = { 226 /* count */ 2, 227 /* ext */ &xcb_xfixes_id, 228 /* opcode */ XCB_XFIXES_SELECT_SELECTION_INPUT, 229 /* isvoid */ 1 230 }; 231 232 struct iovec xcb_parts[4]; 233 xcb_void_cookie_t xcb_ret; 234 xcb_xfixes_select_selection_input_request_t xcb_out; 235 236 xcb_out.window = window; 237 xcb_out.selection = selection; 238 xcb_out.event_mask = event_mask; 239 240 xcb_parts[2].iov_base = (char *) &xcb_out; 241 xcb_parts[2].iov_len = sizeof(xcb_out); 242 xcb_parts[3].iov_base = 0; 243 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 244 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 245 return xcb_ret; 246 } 247 248 249 /***************************************************************************** 250 ** 251 ** xcb_void_cookie_t xcb_xfixes_select_selection_input 252 ** 253 ** @param xcb_connection_t *c 254 ** @param xcb_window_t window 255 ** @param xcb_atom_t selection 256 ** @param uint32_t event_mask 257 ** @returns xcb_void_cookie_t 258 ** 259 *****************************************************************************/ 260 261 xcb_void_cookie_t 262 xcb_xfixes_select_selection_input (xcb_connection_t *c /**< */, 263 xcb_window_t window /**< */, 264 xcb_atom_t selection /**< */, 265 uint32_t event_mask /**< */) 266 { 267 static const xcb_protocol_request_t xcb_req = { 268 /* count */ 2, 269 /* ext */ &xcb_xfixes_id, 270 /* opcode */ XCB_XFIXES_SELECT_SELECTION_INPUT, 271 /* isvoid */ 1 272 }; 273 274 struct iovec xcb_parts[4]; 275 xcb_void_cookie_t xcb_ret; 276 xcb_xfixes_select_selection_input_request_t xcb_out; 277 278 xcb_out.window = window; 279 xcb_out.selection = selection; 280 xcb_out.event_mask = event_mask; 281 282 xcb_parts[2].iov_base = (char *) &xcb_out; 283 xcb_parts[2].iov_len = sizeof(xcb_out); 284 xcb_parts[3].iov_base = 0; 285 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 286 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 287 return xcb_ret; 288 } 289 290 291 /***************************************************************************** 292 ** 293 ** xcb_void_cookie_t xcb_xfixes_select_cursor_input_checked 294 ** 295 ** @param xcb_connection_t *c 296 ** @param xcb_window_t window 297 ** @param uint32_t event_mask 298 ** @returns xcb_void_cookie_t 299 ** 300 *****************************************************************************/ 301 302 xcb_void_cookie_t 303 xcb_xfixes_select_cursor_input_checked (xcb_connection_t *c /**< */, 304 xcb_window_t window /**< */, 305 uint32_t event_mask /**< */) 306 { 307 static const xcb_protocol_request_t xcb_req = { 308 /* count */ 2, 309 /* ext */ &xcb_xfixes_id, 310 /* opcode */ XCB_XFIXES_SELECT_CURSOR_INPUT, 311 /* isvoid */ 1 312 }; 313 314 struct iovec xcb_parts[4]; 315 xcb_void_cookie_t xcb_ret; 316 xcb_xfixes_select_cursor_input_request_t xcb_out; 317 318 xcb_out.window = window; 319 xcb_out.event_mask = event_mask; 320 321 xcb_parts[2].iov_base = (char *) &xcb_out; 322 xcb_parts[2].iov_len = sizeof(xcb_out); 323 xcb_parts[3].iov_base = 0; 324 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 325 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 326 return xcb_ret; 327 } 328 329 330 /***************************************************************************** 331 ** 332 ** xcb_void_cookie_t xcb_xfixes_select_cursor_input 333 ** 334 ** @param xcb_connection_t *c 335 ** @param xcb_window_t window 336 ** @param uint32_t event_mask 337 ** @returns xcb_void_cookie_t 338 ** 339 *****************************************************************************/ 340 341 xcb_void_cookie_t 342 xcb_xfixes_select_cursor_input (xcb_connection_t *c /**< */, 343 xcb_window_t window /**< */, 344 uint32_t event_mask /**< */) 345 { 346 static const xcb_protocol_request_t xcb_req = { 347 /* count */ 2, 348 /* ext */ &xcb_xfixes_id, 349 /* opcode */ XCB_XFIXES_SELECT_CURSOR_INPUT, 350 /* isvoid */ 1 351 }; 352 353 struct iovec xcb_parts[4]; 354 xcb_void_cookie_t xcb_ret; 355 xcb_xfixes_select_cursor_input_request_t xcb_out; 356 357 xcb_out.window = window; 358 xcb_out.event_mask = event_mask; 359 360 xcb_parts[2].iov_base = (char *) &xcb_out; 361 xcb_parts[2].iov_len = sizeof(xcb_out); 362 xcb_parts[3].iov_base = 0; 363 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 364 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 365 return xcb_ret; 366 } 367 368 369 /***************************************************************************** 370 ** 371 ** xcb_xfixes_get_cursor_image_cookie_t xcb_xfixes_get_cursor_image 372 ** 373 ** @param xcb_connection_t *c 374 ** @returns xcb_xfixes_get_cursor_image_cookie_t 375 ** 376 *****************************************************************************/ 377 378 xcb_xfixes_get_cursor_image_cookie_t 379 xcb_xfixes_get_cursor_image (xcb_connection_t *c /**< */) 380 { 381 static const xcb_protocol_request_t xcb_req = { 382 /* count */ 2, 383 /* ext */ &xcb_xfixes_id, 384 /* opcode */ XCB_XFIXES_GET_CURSOR_IMAGE, 385 /* isvoid */ 0 386 }; 387 388 struct iovec xcb_parts[4]; 389 xcb_xfixes_get_cursor_image_cookie_t xcb_ret; 390 xcb_xfixes_get_cursor_image_request_t xcb_out; 391 392 393 xcb_parts[2].iov_base = (char *) &xcb_out; 394 xcb_parts[2].iov_len = sizeof(xcb_out); 395 xcb_parts[3].iov_base = 0; 396 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 397 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 398 return xcb_ret; 399 } 400 401 402 /***************************************************************************** 403 ** 404 ** xcb_xfixes_get_cursor_image_cookie_t xcb_xfixes_get_cursor_image_unchecked 405 ** 406 ** @param xcb_connection_t *c 407 ** @returns xcb_xfixes_get_cursor_image_cookie_t 408 ** 409 *****************************************************************************/ 410 411 xcb_xfixes_get_cursor_image_cookie_t 412 xcb_xfixes_get_cursor_image_unchecked (xcb_connection_t *c /**< */) 413 { 414 static const xcb_protocol_request_t xcb_req = { 415 /* count */ 2, 416 /* ext */ &xcb_xfixes_id, 417 /* opcode */ XCB_XFIXES_GET_CURSOR_IMAGE, 418 /* isvoid */ 0 419 }; 420 421 struct iovec xcb_parts[4]; 422 xcb_xfixes_get_cursor_image_cookie_t xcb_ret; 423 xcb_xfixes_get_cursor_image_request_t xcb_out; 424 425 426 xcb_parts[2].iov_base = (char *) &xcb_out; 427 xcb_parts[2].iov_len = sizeof(xcb_out); 428 xcb_parts[3].iov_base = 0; 429 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 430 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 431 return xcb_ret; 432 } 433 434 435 /***************************************************************************** 436 ** 437 ** uint32_t * xcb_xfixes_get_cursor_image_cursor_image 438 ** 439 ** @param const xcb_xfixes_get_cursor_image_reply_t *R 440 ** @returns uint32_t * 441 ** 442 *****************************************************************************/ 443 444 uint32_t * 445 xcb_xfixes_get_cursor_image_cursor_image (const xcb_xfixes_get_cursor_image_reply_t *R /**< */) 446 { 447 return (uint32_t *) (R + 1); 448 } 449 450 451 /***************************************************************************** 452 ** 453 ** int xcb_xfixes_get_cursor_image_cursor_image_length 454 ** 455 ** @param const xcb_xfixes_get_cursor_image_reply_t *R 456 ** @returns int 457 ** 458 *****************************************************************************/ 459 460 int 461 xcb_xfixes_get_cursor_image_cursor_image_length (const xcb_xfixes_get_cursor_image_reply_t *R /**< */) 462 { 463 return (R->width * R->height); 464 } 465 466 467 /***************************************************************************** 468 ** 469 ** xcb_generic_iterator_t xcb_xfixes_get_cursor_image_cursor_image_end 470 ** 471 ** @param const xcb_xfixes_get_cursor_image_reply_t *R 472 ** @returns xcb_generic_iterator_t 473 ** 474 *****************************************************************************/ 475 476 xcb_generic_iterator_t 477 xcb_xfixes_get_cursor_image_cursor_image_end (const xcb_xfixes_get_cursor_image_reply_t *R /**< */) 478 { 479 xcb_generic_iterator_t i; 480 i.data = ((uint32_t *) (R + 1)) + ((R->width * R->height)); 481 i.rem = 0; 482 i.index = (char *) i.data - (char *) R; 483 return i; 484 } 485 486 487 /***************************************************************************** 488 ** 489 ** xcb_xfixes_get_cursor_image_reply_t * xcb_xfixes_get_cursor_image_reply 490 ** 491 ** @param xcb_connection_t *c 492 ** @param xcb_xfixes_get_cursor_image_cookie_t cookie 493 ** @param xcb_generic_error_t **e 494 ** @returns xcb_xfixes_get_cursor_image_reply_t * 495 ** 496 *****************************************************************************/ 497 498 xcb_xfixes_get_cursor_image_reply_t * 499 xcb_xfixes_get_cursor_image_reply (xcb_connection_t *c /**< */, 500 xcb_xfixes_get_cursor_image_cookie_t cookie /**< */, 501 xcb_generic_error_t **e /**< */) 502 { 503 return (xcb_xfixes_get_cursor_image_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 504 } 505 506 507 /***************************************************************************** 508 ** 509 ** void xcb_xfixes_region_next 510 ** 511 ** @param xcb_xfixes_region_iterator_t *i 512 ** @returns void 513 ** 514 *****************************************************************************/ 515 516 void 517 xcb_xfixes_region_next (xcb_xfixes_region_iterator_t *i /**< */) 518 { 519 --i->rem; 520 ++i->data; 521 i->index += sizeof(xcb_xfixes_region_t); 522 } 523 524 525 /***************************************************************************** 526 ** 527 ** xcb_generic_iterator_t xcb_xfixes_region_end 528 ** 529 ** @param xcb_xfixes_region_iterator_t i 530 ** @returns xcb_generic_iterator_t 531 ** 532 *****************************************************************************/ 533 534 xcb_generic_iterator_t 535 xcb_xfixes_region_end (xcb_xfixes_region_iterator_t i /**< */) 536 { 537 xcb_generic_iterator_t ret; 538 ret.data = i.data + i.rem; 539 ret.index = i.index + ((char *) ret.data - (char *) i.data); 540 ret.rem = 0; 541 return ret; 542 } 543 544 545 /***************************************************************************** 546 ** 547 ** xcb_void_cookie_t xcb_xfixes_create_region_checked 548 ** 549 ** @param xcb_connection_t *c 550 ** @param xcb_xfixes_region_t region 551 ** @param uint32_t rectangles_len 552 ** @param const xcb_rectangle_t *rectangles 553 ** @returns xcb_void_cookie_t 554 ** 555 *****************************************************************************/ 556 557 xcb_void_cookie_t 558 xcb_xfixes_create_region_checked (xcb_connection_t *c /**< */, 559 xcb_xfixes_region_t region /**< */, 560 uint32_t rectangles_len /**< */, 561 const xcb_rectangle_t *rectangles /**< */) 562 { 563 static const xcb_protocol_request_t xcb_req = { 564 /* count */ 4, 565 /* ext */ &xcb_xfixes_id, 566 /* opcode */ XCB_XFIXES_CREATE_REGION, 567 /* isvoid */ 1 568 }; 569 570 struct iovec xcb_parts[6]; 571 xcb_void_cookie_t xcb_ret; 572 xcb_xfixes_create_region_request_t xcb_out; 573 574 xcb_out.region = region; 575 576 xcb_parts[2].iov_base = (char *) &xcb_out; 577 xcb_parts[2].iov_len = sizeof(xcb_out); 578 xcb_parts[3].iov_base = 0; 579 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 580 xcb_parts[4].iov_base = (char *) rectangles; 581 xcb_parts[4].iov_len = rectangles_len * sizeof(xcb_rectangle_t); 582 xcb_parts[5].iov_base = 0; 583 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 584 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 585 return xcb_ret; 586 } 587 588 589 /***************************************************************************** 590 ** 591 ** xcb_void_cookie_t xcb_xfixes_create_region 592 ** 593 ** @param xcb_connection_t *c 594 ** @param xcb_xfixes_region_t region 595 ** @param uint32_t rectangles_len 596 ** @param const xcb_rectangle_t *rectangles 597 ** @returns xcb_void_cookie_t 598 ** 599 *****************************************************************************/ 600 601 xcb_void_cookie_t 602 xcb_xfixes_create_region (xcb_connection_t *c /**< */, 603 xcb_xfixes_region_t region /**< */, 604 uint32_t rectangles_len /**< */, 605 const xcb_rectangle_t *rectangles /**< */) 606 { 607 static const xcb_protocol_request_t xcb_req = { 608 /* count */ 4, 609 /* ext */ &xcb_xfixes_id, 610 /* opcode */ XCB_XFIXES_CREATE_REGION, 611 /* isvoid */ 1 612 }; 613 614 struct iovec xcb_parts[6]; 615 xcb_void_cookie_t xcb_ret; 616 xcb_xfixes_create_region_request_t xcb_out; 617 618 xcb_out.region = region; 619 620 xcb_parts[2].iov_base = (char *) &xcb_out; 621 xcb_parts[2].iov_len = sizeof(xcb_out); 622 xcb_parts[3].iov_base = 0; 623 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 624 xcb_parts[4].iov_base = (char *) rectangles; 625 xcb_parts[4].iov_len = rectangles_len * sizeof(xcb_rectangle_t); 626 xcb_parts[5].iov_base = 0; 627 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 628 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 629 return xcb_ret; 630 } 631 632 633 /***************************************************************************** 634 ** 635 ** xcb_void_cookie_t xcb_xfixes_create_region_from_bitmap_checked 636 ** 637 ** @param xcb_connection_t *c 638 ** @param xcb_xfixes_region_t region 639 ** @param xcb_pixmap_t bitmap 640 ** @returns xcb_void_cookie_t 641 ** 642 *****************************************************************************/ 643 644 xcb_void_cookie_t 645 xcb_xfixes_create_region_from_bitmap_checked (xcb_connection_t *c /**< */, 646 xcb_xfixes_region_t region /**< */, 647 xcb_pixmap_t bitmap /**< */) 648 { 649 static const xcb_protocol_request_t xcb_req = { 650 /* count */ 2, 651 /* ext */ &xcb_xfixes_id, 652 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_BITMAP, 653 /* isvoid */ 1 654 }; 655 656 struct iovec xcb_parts[4]; 657 xcb_void_cookie_t xcb_ret; 658 xcb_xfixes_create_region_from_bitmap_request_t xcb_out; 659 660 xcb_out.region = region; 661 xcb_out.bitmap = bitmap; 662 663 xcb_parts[2].iov_base = (char *) &xcb_out; 664 xcb_parts[2].iov_len = sizeof(xcb_out); 665 xcb_parts[3].iov_base = 0; 666 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 667 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 668 return xcb_ret; 669 } 670 671 672 /***************************************************************************** 673 ** 674 ** xcb_void_cookie_t xcb_xfixes_create_region_from_bitmap 675 ** 676 ** @param xcb_connection_t *c 677 ** @param xcb_xfixes_region_t region 678 ** @param xcb_pixmap_t bitmap 679 ** @returns xcb_void_cookie_t 680 ** 681 *****************************************************************************/ 682 683 xcb_void_cookie_t 684 xcb_xfixes_create_region_from_bitmap (xcb_connection_t *c /**< */, 685 xcb_xfixes_region_t region /**< */, 686 xcb_pixmap_t bitmap /**< */) 687 { 688 static const xcb_protocol_request_t xcb_req = { 689 /* count */ 2, 690 /* ext */ &xcb_xfixes_id, 691 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_BITMAP, 692 /* isvoid */ 1 693 }; 694 695 struct iovec xcb_parts[4]; 696 xcb_void_cookie_t xcb_ret; 697 xcb_xfixes_create_region_from_bitmap_request_t xcb_out; 698 699 xcb_out.region = region; 700 xcb_out.bitmap = bitmap; 701 702 xcb_parts[2].iov_base = (char *) &xcb_out; 703 xcb_parts[2].iov_len = sizeof(xcb_out); 704 xcb_parts[3].iov_base = 0; 705 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 706 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 707 return xcb_ret; 708 } 709 710 711 /***************************************************************************** 712 ** 713 ** xcb_void_cookie_t xcb_xfixes_create_region_from_window_checked 714 ** 715 ** @param xcb_connection_t *c 716 ** @param xcb_xfixes_region_t region 717 ** @param xcb_window_t window 718 ** @param xcb_shape_kind_t kind 719 ** @returns xcb_void_cookie_t 720 ** 721 *****************************************************************************/ 722 723 xcb_void_cookie_t 724 xcb_xfixes_create_region_from_window_checked (xcb_connection_t *c /**< */, 725 xcb_xfixes_region_t region /**< */, 726 xcb_window_t window /**< */, 727 xcb_shape_kind_t kind /**< */) 728 { 729 static const xcb_protocol_request_t xcb_req = { 730 /* count */ 2, 731 /* ext */ &xcb_xfixes_id, 732 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_WINDOW, 733 /* isvoid */ 1 734 }; 735 736 struct iovec xcb_parts[4]; 737 xcb_void_cookie_t xcb_ret; 738 xcb_xfixes_create_region_from_window_request_t xcb_out; 739 740 xcb_out.region = region; 741 xcb_out.window = window; 742 xcb_out.kind = kind; 743 memset(xcb_out.pad0, 0, 3); 744 745 xcb_parts[2].iov_base = (char *) &xcb_out; 746 xcb_parts[2].iov_len = sizeof(xcb_out); 747 xcb_parts[3].iov_base = 0; 748 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 749 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 750 return xcb_ret; 751 } 752 753 754 /***************************************************************************** 755 ** 756 ** xcb_void_cookie_t xcb_xfixes_create_region_from_window 757 ** 758 ** @param xcb_connection_t *c 759 ** @param xcb_xfixes_region_t region 760 ** @param xcb_window_t window 761 ** @param xcb_shape_kind_t kind 762 ** @returns xcb_void_cookie_t 763 ** 764 *****************************************************************************/ 765 766 xcb_void_cookie_t 767 xcb_xfixes_create_region_from_window (xcb_connection_t *c /**< */, 768 xcb_xfixes_region_t region /**< */, 769 xcb_window_t window /**< */, 770 xcb_shape_kind_t kind /**< */) 771 { 772 static const xcb_protocol_request_t xcb_req = { 773 /* count */ 2, 774 /* ext */ &xcb_xfixes_id, 775 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_WINDOW, 776 /* isvoid */ 1 777 }; 778 779 struct iovec xcb_parts[4]; 780 xcb_void_cookie_t xcb_ret; 781 xcb_xfixes_create_region_from_window_request_t xcb_out; 782 783 xcb_out.region = region; 784 xcb_out.window = window; 785 xcb_out.kind = kind; 786 memset(xcb_out.pad0, 0, 3); 787 788 xcb_parts[2].iov_base = (char *) &xcb_out; 789 xcb_parts[2].iov_len = sizeof(xcb_out); 790 xcb_parts[3].iov_base = 0; 791 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 792 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 793 return xcb_ret; 794 } 795 796 797 /***************************************************************************** 798 ** 799 ** xcb_void_cookie_t xcb_xfixes_create_region_from_gc_checked 800 ** 801 ** @param xcb_connection_t *c 802 ** @param xcb_xfixes_region_t region 803 ** @param xcb_gcontext_t gc 804 ** @returns xcb_void_cookie_t 805 ** 806 *****************************************************************************/ 807 808 xcb_void_cookie_t 809 xcb_xfixes_create_region_from_gc_checked (xcb_connection_t *c /**< */, 810 xcb_xfixes_region_t region /**< */, 811 xcb_gcontext_t gc /**< */) 812 { 813 static const xcb_protocol_request_t xcb_req = { 814 /* count */ 2, 815 /* ext */ &xcb_xfixes_id, 816 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_GC, 817 /* isvoid */ 1 818 }; 819 820 struct iovec xcb_parts[4]; 821 xcb_void_cookie_t xcb_ret; 822 xcb_xfixes_create_region_from_gc_request_t xcb_out; 823 824 xcb_out.region = region; 825 xcb_out.gc = gc; 826 827 xcb_parts[2].iov_base = (char *) &xcb_out; 828 xcb_parts[2].iov_len = sizeof(xcb_out); 829 xcb_parts[3].iov_base = 0; 830 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 831 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 832 return xcb_ret; 833 } 834 835 836 /***************************************************************************** 837 ** 838 ** xcb_void_cookie_t xcb_xfixes_create_region_from_gc 839 ** 840 ** @param xcb_connection_t *c 841 ** @param xcb_xfixes_region_t region 842 ** @param xcb_gcontext_t gc 843 ** @returns xcb_void_cookie_t 844 ** 845 *****************************************************************************/ 846 847 xcb_void_cookie_t 848 xcb_xfixes_create_region_from_gc (xcb_connection_t *c /**< */, 849 xcb_xfixes_region_t region /**< */, 850 xcb_gcontext_t gc /**< */) 851 { 852 static const xcb_protocol_request_t xcb_req = { 853 /* count */ 2, 854 /* ext */ &xcb_xfixes_id, 855 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_GC, 856 /* isvoid */ 1 857 }; 858 859 struct iovec xcb_parts[4]; 860 xcb_void_cookie_t xcb_ret; 861 xcb_xfixes_create_region_from_gc_request_t xcb_out; 862 863 xcb_out.region = region; 864 xcb_out.gc = gc; 865 866 xcb_parts[2].iov_base = (char *) &xcb_out; 867 xcb_parts[2].iov_len = sizeof(xcb_out); 868 xcb_parts[3].iov_base = 0; 869 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 870 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 871 return xcb_ret; 872 } 873 874 875 /***************************************************************************** 876 ** 877 ** xcb_void_cookie_t xcb_xfixes_create_region_from_picture_checked 878 ** 879 ** @param xcb_connection_t *c 880 ** @param xcb_xfixes_region_t region 881 ** @param xcb_render_picture_t picture 882 ** @returns xcb_void_cookie_t 883 ** 884 *****************************************************************************/ 885 886 xcb_void_cookie_t 887 xcb_xfixes_create_region_from_picture_checked (xcb_connection_t *c /**< */, 888 xcb_xfixes_region_t region /**< */, 889 xcb_render_picture_t picture /**< */) 890 { 891 static const xcb_protocol_request_t xcb_req = { 892 /* count */ 2, 893 /* ext */ &xcb_xfixes_id, 894 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_PICTURE, 895 /* isvoid */ 1 896 }; 897 898 struct iovec xcb_parts[4]; 899 xcb_void_cookie_t xcb_ret; 900 xcb_xfixes_create_region_from_picture_request_t xcb_out; 901 902 xcb_out.region = region; 903 xcb_out.picture = picture; 904 905 xcb_parts[2].iov_base = (char *) &xcb_out; 906 xcb_parts[2].iov_len = sizeof(xcb_out); 907 xcb_parts[3].iov_base = 0; 908 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 909 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 910 return xcb_ret; 911 } 912 913 914 /***************************************************************************** 915 ** 916 ** xcb_void_cookie_t xcb_xfixes_create_region_from_picture 917 ** 918 ** @param xcb_connection_t *c 919 ** @param xcb_xfixes_region_t region 920 ** @param xcb_render_picture_t picture 921 ** @returns xcb_void_cookie_t 922 ** 923 *****************************************************************************/ 924 925 xcb_void_cookie_t 926 xcb_xfixes_create_region_from_picture (xcb_connection_t *c /**< */, 927 xcb_xfixes_region_t region /**< */, 928 xcb_render_picture_t picture /**< */) 929 { 930 static const xcb_protocol_request_t xcb_req = { 931 /* count */ 2, 932 /* ext */ &xcb_xfixes_id, 933 /* opcode */ XCB_XFIXES_CREATE_REGION_FROM_PICTURE, 934 /* isvoid */ 1 935 }; 936 937 struct iovec xcb_parts[4]; 938 xcb_void_cookie_t xcb_ret; 939 xcb_xfixes_create_region_from_picture_request_t xcb_out; 940 941 xcb_out.region = region; 942 xcb_out.picture = picture; 943 944 xcb_parts[2].iov_base = (char *) &xcb_out; 945 xcb_parts[2].iov_len = sizeof(xcb_out); 946 xcb_parts[3].iov_base = 0; 947 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 948 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 949 return xcb_ret; 950 } 951 952 953 /***************************************************************************** 954 ** 955 ** xcb_void_cookie_t xcb_xfixes_destroy_region_checked 956 ** 957 ** @param xcb_connection_t *c 958 ** @param xcb_xfixes_region_t region 959 ** @returns xcb_void_cookie_t 960 ** 961 *****************************************************************************/ 962 963 xcb_void_cookie_t 964 xcb_xfixes_destroy_region_checked (xcb_connection_t *c /**< */, 965 xcb_xfixes_region_t region /**< */) 966 { 967 static const xcb_protocol_request_t xcb_req = { 968 /* count */ 2, 969 /* ext */ &xcb_xfixes_id, 970 /* opcode */ XCB_XFIXES_DESTROY_REGION, 971 /* isvoid */ 1 972 }; 973 974 struct iovec xcb_parts[4]; 975 xcb_void_cookie_t xcb_ret; 976 xcb_xfixes_destroy_region_request_t xcb_out; 977 978 xcb_out.region = region; 979 980 xcb_parts[2].iov_base = (char *) &xcb_out; 981 xcb_parts[2].iov_len = sizeof(xcb_out); 982 xcb_parts[3].iov_base = 0; 983 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 984 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 985 return xcb_ret; 986 } 987 988 989 /***************************************************************************** 990 ** 991 ** xcb_void_cookie_t xcb_xfixes_destroy_region 992 ** 993 ** @param xcb_connection_t *c 994 ** @param xcb_xfixes_region_t region 995 ** @returns xcb_void_cookie_t 996 ** 997 *****************************************************************************/ 998 999 xcb_void_cookie_t 1000 xcb_xfixes_destroy_region (xcb_connection_t *c /**< */, 1001 xcb_xfixes_region_t region /**< */) 1002 { 1003 static const xcb_protocol_request_t xcb_req = { 1004 /* count */ 2, 1005 /* ext */ &xcb_xfixes_id, 1006 /* opcode */ XCB_XFIXES_DESTROY_REGION, 1007 /* isvoid */ 1 1008 }; 1009 1010 struct iovec xcb_parts[4]; 1011 xcb_void_cookie_t xcb_ret; 1012 xcb_xfixes_destroy_region_request_t xcb_out; 1013 1014 xcb_out.region = region; 1015 1016 xcb_parts[2].iov_base = (char *) &xcb_out; 1017 xcb_parts[2].iov_len = sizeof(xcb_out); 1018 xcb_parts[3].iov_base = 0; 1019 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1020 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1021 return xcb_ret; 1022 } 1023 1024 1025 /***************************************************************************** 1026 ** 1027 ** xcb_void_cookie_t xcb_xfixes_set_region_checked 1028 ** 1029 ** @param xcb_connection_t *c 1030 ** @param xcb_xfixes_region_t region 1031 ** @param uint32_t rectangles_len 1032 ** @param const xcb_rectangle_t *rectangles 1033 ** @returns xcb_void_cookie_t 1034 ** 1035 *****************************************************************************/ 1036 1037 xcb_void_cookie_t 1038 xcb_xfixes_set_region_checked (xcb_connection_t *c /**< */, 1039 xcb_xfixes_region_t region /**< */, 1040 uint32_t rectangles_len /**< */, 1041 const xcb_rectangle_t *rectangles /**< */) 1042 { 1043 static const xcb_protocol_request_t xcb_req = { 1044 /* count */ 4, 1045 /* ext */ &xcb_xfixes_id, 1046 /* opcode */ XCB_XFIXES_SET_REGION, 1047 /* isvoid */ 1 1048 }; 1049 1050 struct iovec xcb_parts[6]; 1051 xcb_void_cookie_t xcb_ret; 1052 xcb_xfixes_set_region_request_t xcb_out; 1053 1054 xcb_out.region = region; 1055 1056 xcb_parts[2].iov_base = (char *) &xcb_out; 1057 xcb_parts[2].iov_len = sizeof(xcb_out); 1058 xcb_parts[3].iov_base = 0; 1059 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1060 xcb_parts[4].iov_base = (char *) rectangles; 1061 xcb_parts[4].iov_len = rectangles_len * sizeof(xcb_rectangle_t); 1062 xcb_parts[5].iov_base = 0; 1063 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 1064 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1065 return xcb_ret; 1066 } 1067 1068 1069 /***************************************************************************** 1070 ** 1071 ** xcb_void_cookie_t xcb_xfixes_set_region 1072 ** 1073 ** @param xcb_connection_t *c 1074 ** @param xcb_xfixes_region_t region 1075 ** @param uint32_t rectangles_len 1076 ** @param const xcb_rectangle_t *rectangles 1077 ** @returns xcb_void_cookie_t 1078 ** 1079 *****************************************************************************/ 1080 1081 xcb_void_cookie_t 1082 xcb_xfixes_set_region (xcb_connection_t *c /**< */, 1083 xcb_xfixes_region_t region /**< */, 1084 uint32_t rectangles_len /**< */, 1085 const xcb_rectangle_t *rectangles /**< */) 1086 { 1087 static const xcb_protocol_request_t xcb_req = { 1088 /* count */ 4, 1089 /* ext */ &xcb_xfixes_id, 1090 /* opcode */ XCB_XFIXES_SET_REGION, 1091 /* isvoid */ 1 1092 }; 1093 1094 struct iovec xcb_parts[6]; 1095 xcb_void_cookie_t xcb_ret; 1096 xcb_xfixes_set_region_request_t xcb_out; 1097 1098 xcb_out.region = region; 1099 1100 xcb_parts[2].iov_base = (char *) &xcb_out; 1101 xcb_parts[2].iov_len = sizeof(xcb_out); 1102 xcb_parts[3].iov_base = 0; 1103 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1104 xcb_parts[4].iov_base = (char *) rectangles; 1105 xcb_parts[4].iov_len = rectangles_len * sizeof(xcb_rectangle_t); 1106 xcb_parts[5].iov_base = 0; 1107 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 1108 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1109 return xcb_ret; 1110 } 1111 1112 1113 /***************************************************************************** 1114 ** 1115 ** xcb_void_cookie_t xcb_xfixes_copy_region_checked 1116 ** 1117 ** @param xcb_connection_t *c 1118 ** @param xcb_xfixes_region_t source 1119 ** @param xcb_xfixes_region_t destination 1120 ** @returns xcb_void_cookie_t 1121 ** 1122 *****************************************************************************/ 1123 1124 xcb_void_cookie_t 1125 xcb_xfixes_copy_region_checked (xcb_connection_t *c /**< */, 1126 xcb_xfixes_region_t source /**< */, 1127 xcb_xfixes_region_t destination /**< */) 1128 { 1129 static const xcb_protocol_request_t xcb_req = { 1130 /* count */ 2, 1131 /* ext */ &xcb_xfixes_id, 1132 /* opcode */ XCB_XFIXES_COPY_REGION, 1133 /* isvoid */ 1 1134 }; 1135 1136 struct iovec xcb_parts[4]; 1137 xcb_void_cookie_t xcb_ret; 1138 xcb_xfixes_copy_region_request_t xcb_out; 1139 1140 xcb_out.source = source; 1141 xcb_out.destination = destination; 1142 1143 xcb_parts[2].iov_base = (char *) &xcb_out; 1144 xcb_parts[2].iov_len = sizeof(xcb_out); 1145 xcb_parts[3].iov_base = 0; 1146 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1147 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1148 return xcb_ret; 1149 } 1150 1151 1152 /***************************************************************************** 1153 ** 1154 ** xcb_void_cookie_t xcb_xfixes_copy_region 1155 ** 1156 ** @param xcb_connection_t *c 1157 ** @param xcb_xfixes_region_t source 1158 ** @param xcb_xfixes_region_t destination 1159 ** @returns xcb_void_cookie_t 1160 ** 1161 *****************************************************************************/ 1162 1163 xcb_void_cookie_t 1164 xcb_xfixes_copy_region (xcb_connection_t *c /**< */, 1165 xcb_xfixes_region_t source /**< */, 1166 xcb_xfixes_region_t destination /**< */) 1167 { 1168 static const xcb_protocol_request_t xcb_req = { 1169 /* count */ 2, 1170 /* ext */ &xcb_xfixes_id, 1171 /* opcode */ XCB_XFIXES_COPY_REGION, 1172 /* isvoid */ 1 1173 }; 1174 1175 struct iovec xcb_parts[4]; 1176 xcb_void_cookie_t xcb_ret; 1177 xcb_xfixes_copy_region_request_t xcb_out; 1178 1179 xcb_out.source = source; 1180 xcb_out.destination = destination; 1181 1182 xcb_parts[2].iov_base = (char *) &xcb_out; 1183 xcb_parts[2].iov_len = sizeof(xcb_out); 1184 xcb_parts[3].iov_base = 0; 1185 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1186 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1187 return xcb_ret; 1188 } 1189 1190 1191 /***************************************************************************** 1192 ** 1193 ** xcb_void_cookie_t xcb_xfixes_union_region_checked 1194 ** 1195 ** @param xcb_connection_t *c 1196 ** @param xcb_xfixes_region_t source1 1197 ** @param xcb_xfixes_region_t source2 1198 ** @param xcb_xfixes_region_t destination 1199 ** @returns xcb_void_cookie_t 1200 ** 1201 *****************************************************************************/ 1202 1203 xcb_void_cookie_t 1204 xcb_xfixes_union_region_checked (xcb_connection_t *c /**< */, 1205 xcb_xfixes_region_t source1 /**< */, 1206 xcb_xfixes_region_t source2 /**< */, 1207 xcb_xfixes_region_t destination /**< */) 1208 { 1209 static const xcb_protocol_request_t xcb_req = { 1210 /* count */ 2, 1211 /* ext */ &xcb_xfixes_id, 1212 /* opcode */ XCB_XFIXES_UNION_REGION, 1213 /* isvoid */ 1 1214 }; 1215 1216 struct iovec xcb_parts[4]; 1217 xcb_void_cookie_t xcb_ret; 1218 xcb_xfixes_union_region_request_t xcb_out; 1219 1220 xcb_out.source1 = source1; 1221 xcb_out.source2 = source2; 1222 xcb_out.destination = destination; 1223 1224 xcb_parts[2].iov_base = (char *) &xcb_out; 1225 xcb_parts[2].iov_len = sizeof(xcb_out); 1226 xcb_parts[3].iov_base = 0; 1227 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1228 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1229 return xcb_ret; 1230 } 1231 1232 1233 /***************************************************************************** 1234 ** 1235 ** xcb_void_cookie_t xcb_xfixes_union_region 1236 ** 1237 ** @param xcb_connection_t *c 1238 ** @param xcb_xfixes_region_t source1 1239 ** @param xcb_xfixes_region_t source2 1240 ** @param xcb_xfixes_region_t destination 1241 ** @returns xcb_void_cookie_t 1242 ** 1243 *****************************************************************************/ 1244 1245 xcb_void_cookie_t 1246 xcb_xfixes_union_region (xcb_connection_t *c /**< */, 1247 xcb_xfixes_region_t source1 /**< */, 1248 xcb_xfixes_region_t source2 /**< */, 1249 xcb_xfixes_region_t destination /**< */) 1250 { 1251 static const xcb_protocol_request_t xcb_req = { 1252 /* count */ 2, 1253 /* ext */ &xcb_xfixes_id, 1254 /* opcode */ XCB_XFIXES_UNION_REGION, 1255 /* isvoid */ 1 1256 }; 1257 1258 struct iovec xcb_parts[4]; 1259 xcb_void_cookie_t xcb_ret; 1260 xcb_xfixes_union_region_request_t xcb_out; 1261 1262 xcb_out.source1 = source1; 1263 xcb_out.source2 = source2; 1264 xcb_out.destination = destination; 1265 1266 xcb_parts[2].iov_base = (char *) &xcb_out; 1267 xcb_parts[2].iov_len = sizeof(xcb_out); 1268 xcb_parts[3].iov_base = 0; 1269 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1270 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1271 return xcb_ret; 1272 } 1273 1274 1275 /***************************************************************************** 1276 ** 1277 ** xcb_void_cookie_t xcb_xfixes_intersect_region_checked 1278 ** 1279 ** @param xcb_connection_t *c 1280 ** @param xcb_xfixes_region_t source1 1281 ** @param xcb_xfixes_region_t source2 1282 ** @param xcb_xfixes_region_t destination 1283 ** @returns xcb_void_cookie_t 1284 ** 1285 *****************************************************************************/ 1286 1287 xcb_void_cookie_t 1288 xcb_xfixes_intersect_region_checked (xcb_connection_t *c /**< */, 1289 xcb_xfixes_region_t source1 /**< */, 1290 xcb_xfixes_region_t source2 /**< */, 1291 xcb_xfixes_region_t destination /**< */) 1292 { 1293 static const xcb_protocol_request_t xcb_req = { 1294 /* count */ 2, 1295 /* ext */ &xcb_xfixes_id, 1296 /* opcode */ XCB_XFIXES_INTERSECT_REGION, 1297 /* isvoid */ 1 1298 }; 1299 1300 struct iovec xcb_parts[4]; 1301 xcb_void_cookie_t xcb_ret; 1302 xcb_xfixes_intersect_region_request_t xcb_out; 1303 1304 xcb_out.source1 = source1; 1305 xcb_out.source2 = source2; 1306 xcb_out.destination = destination; 1307 1308 xcb_parts[2].iov_base = (char *) &xcb_out; 1309 xcb_parts[2].iov_len = sizeof(xcb_out); 1310 xcb_parts[3].iov_base = 0; 1311 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1312 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1313 return xcb_ret; 1314 } 1315 1316 1317 /***************************************************************************** 1318 ** 1319 ** xcb_void_cookie_t xcb_xfixes_intersect_region 1320 ** 1321 ** @param xcb_connection_t *c 1322 ** @param xcb_xfixes_region_t source1 1323 ** @param xcb_xfixes_region_t source2 1324 ** @param xcb_xfixes_region_t destination 1325 ** @returns xcb_void_cookie_t 1326 ** 1327 *****************************************************************************/ 1328 1329 xcb_void_cookie_t 1330 xcb_xfixes_intersect_region (xcb_connection_t *c /**< */, 1331 xcb_xfixes_region_t source1 /**< */, 1332 xcb_xfixes_region_t source2 /**< */, 1333 xcb_xfixes_region_t destination /**< */) 1334 { 1335 static const xcb_protocol_request_t xcb_req = { 1336 /* count */ 2, 1337 /* ext */ &xcb_xfixes_id, 1338 /* opcode */ XCB_XFIXES_INTERSECT_REGION, 1339 /* isvoid */ 1 1340 }; 1341 1342 struct iovec xcb_parts[4]; 1343 xcb_void_cookie_t xcb_ret; 1344 xcb_xfixes_intersect_region_request_t xcb_out; 1345 1346 xcb_out.source1 = source1; 1347 xcb_out.source2 = source2; 1348 xcb_out.destination = destination; 1349 1350 xcb_parts[2].iov_base = (char *) &xcb_out; 1351 xcb_parts[2].iov_len = sizeof(xcb_out); 1352 xcb_parts[3].iov_base = 0; 1353 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1354 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1355 return xcb_ret; 1356 } 1357 1358 1359 /***************************************************************************** 1360 ** 1361 ** xcb_void_cookie_t xcb_xfixes_subtract_region_checked 1362 ** 1363 ** @param xcb_connection_t *c 1364 ** @param xcb_xfixes_region_t source1 1365 ** @param xcb_xfixes_region_t source2 1366 ** @param xcb_xfixes_region_t destination 1367 ** @returns xcb_void_cookie_t 1368 ** 1369 *****************************************************************************/ 1370 1371 xcb_void_cookie_t 1372 xcb_xfixes_subtract_region_checked (xcb_connection_t *c /**< */, 1373 xcb_xfixes_region_t source1 /**< */, 1374 xcb_xfixes_region_t source2 /**< */, 1375 xcb_xfixes_region_t destination /**< */) 1376 { 1377 static const xcb_protocol_request_t xcb_req = { 1378 /* count */ 2, 1379 /* ext */ &xcb_xfixes_id, 1380 /* opcode */ XCB_XFIXES_SUBTRACT_REGION, 1381 /* isvoid */ 1 1382 }; 1383 1384 struct iovec xcb_parts[4]; 1385 xcb_void_cookie_t xcb_ret; 1386 xcb_xfixes_subtract_region_request_t xcb_out; 1387 1388 xcb_out.source1 = source1; 1389 xcb_out.source2 = source2; 1390 xcb_out.destination = destination; 1391 1392 xcb_parts[2].iov_base = (char *) &xcb_out; 1393 xcb_parts[2].iov_len = sizeof(xcb_out); 1394 xcb_parts[3].iov_base = 0; 1395 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1396 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1397 return xcb_ret; 1398 } 1399 1400 1401 /***************************************************************************** 1402 ** 1403 ** xcb_void_cookie_t xcb_xfixes_subtract_region 1404 ** 1405 ** @param xcb_connection_t *c 1406 ** @param xcb_xfixes_region_t source1 1407 ** @param xcb_xfixes_region_t source2 1408 ** @param xcb_xfixes_region_t destination 1409 ** @returns xcb_void_cookie_t 1410 ** 1411 *****************************************************************************/ 1412 1413 xcb_void_cookie_t 1414 xcb_xfixes_subtract_region (xcb_connection_t *c /**< */, 1415 xcb_xfixes_region_t source1 /**< */, 1416 xcb_xfixes_region_t source2 /**< */, 1417 xcb_xfixes_region_t destination /**< */) 1418 { 1419 static const xcb_protocol_request_t xcb_req = { 1420 /* count */ 2, 1421 /* ext */ &xcb_xfixes_id, 1422 /* opcode */ XCB_XFIXES_SUBTRACT_REGION, 1423 /* isvoid */ 1 1424 }; 1425 1426 struct iovec xcb_parts[4]; 1427 xcb_void_cookie_t xcb_ret; 1428 xcb_xfixes_subtract_region_request_t xcb_out; 1429 1430 xcb_out.source1 = source1; 1431 xcb_out.source2 = source2; 1432 xcb_out.destination = destination; 1433 1434 xcb_parts[2].iov_base = (char *) &xcb_out; 1435 xcb_parts[2].iov_len = sizeof(xcb_out); 1436 xcb_parts[3].iov_base = 0; 1437 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1438 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1439 return xcb_ret; 1440 } 1441 1442 1443 /***************************************************************************** 1444 ** 1445 ** xcb_void_cookie_t xcb_xfixes_invert_region_checked 1446 ** 1447 ** @param xcb_connection_t *c 1448 ** @param xcb_xfixes_region_t source 1449 ** @param xcb_rectangle_t bounds 1450 ** @param xcb_xfixes_region_t destination 1451 ** @returns xcb_void_cookie_t 1452 ** 1453 *****************************************************************************/ 1454 1455 xcb_void_cookie_t 1456 xcb_xfixes_invert_region_checked (xcb_connection_t *c /**< */, 1457 xcb_xfixes_region_t source /**< */, 1458 xcb_rectangle_t bounds /**< */, 1459 xcb_xfixes_region_t destination /**< */) 1460 { 1461 static const xcb_protocol_request_t xcb_req = { 1462 /* count */ 2, 1463 /* ext */ &xcb_xfixes_id, 1464 /* opcode */ XCB_XFIXES_INVERT_REGION, 1465 /* isvoid */ 1 1466 }; 1467 1468 struct iovec xcb_parts[4]; 1469 xcb_void_cookie_t xcb_ret; 1470 xcb_xfixes_invert_region_request_t xcb_out; 1471 1472 xcb_out.source = source; 1473 xcb_out.bounds = bounds; 1474 xcb_out.destination = destination; 1475 1476 xcb_parts[2].iov_base = (char *) &xcb_out; 1477 xcb_parts[2].iov_len = sizeof(xcb_out); 1478 xcb_parts[3].iov_base = 0; 1479 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1480 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1481 return xcb_ret; 1482 } 1483 1484 1485 /***************************************************************************** 1486 ** 1487 ** xcb_void_cookie_t xcb_xfixes_invert_region 1488 ** 1489 ** @param xcb_connection_t *c 1490 ** @param xcb_xfixes_region_t source 1491 ** @param xcb_rectangle_t bounds 1492 ** @param xcb_xfixes_region_t destination 1493 ** @returns xcb_void_cookie_t 1494 ** 1495 *****************************************************************************/ 1496 1497 xcb_void_cookie_t 1498 xcb_xfixes_invert_region (xcb_connection_t *c /**< */, 1499 xcb_xfixes_region_t source /**< */, 1500 xcb_rectangle_t bounds /**< */, 1501 xcb_xfixes_region_t destination /**< */) 1502 { 1503 static const xcb_protocol_request_t xcb_req = { 1504 /* count */ 2, 1505 /* ext */ &xcb_xfixes_id, 1506 /* opcode */ XCB_XFIXES_INVERT_REGION, 1507 /* isvoid */ 1 1508 }; 1509 1510 struct iovec xcb_parts[4]; 1511 xcb_void_cookie_t xcb_ret; 1512 xcb_xfixes_invert_region_request_t xcb_out; 1513 1514 xcb_out.source = source; 1515 xcb_out.bounds = bounds; 1516 xcb_out.destination = destination; 1517 1518 xcb_parts[2].iov_base = (char *) &xcb_out; 1519 xcb_parts[2].iov_len = sizeof(xcb_out); 1520 xcb_parts[3].iov_base = 0; 1521 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1522 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1523 return xcb_ret; 1524 } 1525 1526 1527 /***************************************************************************** 1528 ** 1529 ** xcb_void_cookie_t xcb_xfixes_translate_region_checked 1530 ** 1531 ** @param xcb_connection_t *c 1532 ** @param xcb_xfixes_region_t region 1533 ** @param int16_t dx 1534 ** @param int16_t dy 1535 ** @returns xcb_void_cookie_t 1536 ** 1537 *****************************************************************************/ 1538 1539 xcb_void_cookie_t 1540 xcb_xfixes_translate_region_checked (xcb_connection_t *c /**< */, 1541 xcb_xfixes_region_t region /**< */, 1542 int16_t dx /**< */, 1543 int16_t dy /**< */) 1544 { 1545 static const xcb_protocol_request_t xcb_req = { 1546 /* count */ 2, 1547 /* ext */ &xcb_xfixes_id, 1548 /* opcode */ XCB_XFIXES_TRANSLATE_REGION, 1549 /* isvoid */ 1 1550 }; 1551 1552 struct iovec xcb_parts[4]; 1553 xcb_void_cookie_t xcb_ret; 1554 xcb_xfixes_translate_region_request_t xcb_out; 1555 1556 xcb_out.region = region; 1557 xcb_out.dx = dx; 1558 xcb_out.dy = dy; 1559 1560 xcb_parts[2].iov_base = (char *) &xcb_out; 1561 xcb_parts[2].iov_len = sizeof(xcb_out); 1562 xcb_parts[3].iov_base = 0; 1563 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1564 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1565 return xcb_ret; 1566 } 1567 1568 1569 /***************************************************************************** 1570 ** 1571 ** xcb_void_cookie_t xcb_xfixes_translate_region 1572 ** 1573 ** @param xcb_connection_t *c 1574 ** @param xcb_xfixes_region_t region 1575 ** @param int16_t dx 1576 ** @param int16_t dy 1577 ** @returns xcb_void_cookie_t 1578 ** 1579 *****************************************************************************/ 1580 1581 xcb_void_cookie_t 1582 xcb_xfixes_translate_region (xcb_connection_t *c /**< */, 1583 xcb_xfixes_region_t region /**< */, 1584 int16_t dx /**< */, 1585 int16_t dy /**< */) 1586 { 1587 static const xcb_protocol_request_t xcb_req = { 1588 /* count */ 2, 1589 /* ext */ &xcb_xfixes_id, 1590 /* opcode */ XCB_XFIXES_TRANSLATE_REGION, 1591 /* isvoid */ 1 1592 }; 1593 1594 struct iovec xcb_parts[4]; 1595 xcb_void_cookie_t xcb_ret; 1596 xcb_xfixes_translate_region_request_t xcb_out; 1597 1598 xcb_out.region = region; 1599 xcb_out.dx = dx; 1600 xcb_out.dy = dy; 1601 1602 xcb_parts[2].iov_base = (char *) &xcb_out; 1603 xcb_parts[2].iov_len = sizeof(xcb_out); 1604 xcb_parts[3].iov_base = 0; 1605 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1606 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1607 return xcb_ret; 1608 } 1609 1610 1611 /***************************************************************************** 1612 ** 1613 ** xcb_void_cookie_t xcb_xfixes_region_extents_checked 1614 ** 1615 ** @param xcb_connection_t *c 1616 ** @param xcb_xfixes_region_t source 1617 ** @param xcb_xfixes_region_t destination 1618 ** @returns xcb_void_cookie_t 1619 ** 1620 *****************************************************************************/ 1621 1622 xcb_void_cookie_t 1623 xcb_xfixes_region_extents_checked (xcb_connection_t *c /**< */, 1624 xcb_xfixes_region_t source /**< */, 1625 xcb_xfixes_region_t destination /**< */) 1626 { 1627 static const xcb_protocol_request_t xcb_req = { 1628 /* count */ 2, 1629 /* ext */ &xcb_xfixes_id, 1630 /* opcode */ XCB_XFIXES_REGION_EXTENTS, 1631 /* isvoid */ 1 1632 }; 1633 1634 struct iovec xcb_parts[4]; 1635 xcb_void_cookie_t xcb_ret; 1636 xcb_xfixes_region_extents_request_t xcb_out; 1637 1638 xcb_out.source = source; 1639 xcb_out.destination = destination; 1640 1641 xcb_parts[2].iov_base = (char *) &xcb_out; 1642 xcb_parts[2].iov_len = sizeof(xcb_out); 1643 xcb_parts[3].iov_base = 0; 1644 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1645 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1646 return xcb_ret; 1647 } 1648 1649 1650 /***************************************************************************** 1651 ** 1652 ** xcb_void_cookie_t xcb_xfixes_region_extents 1653 ** 1654 ** @param xcb_connection_t *c 1655 ** @param xcb_xfixes_region_t source 1656 ** @param xcb_xfixes_region_t destination 1657 ** @returns xcb_void_cookie_t 1658 ** 1659 *****************************************************************************/ 1660 1661 xcb_void_cookie_t 1662 xcb_xfixes_region_extents (xcb_connection_t *c /**< */, 1663 xcb_xfixes_region_t source /**< */, 1664 xcb_xfixes_region_t destination /**< */) 1665 { 1666 static const xcb_protocol_request_t xcb_req = { 1667 /* count */ 2, 1668 /* ext */ &xcb_xfixes_id, 1669 /* opcode */ XCB_XFIXES_REGION_EXTENTS, 1670 /* isvoid */ 1 1671 }; 1672 1673 struct iovec xcb_parts[4]; 1674 xcb_void_cookie_t xcb_ret; 1675 xcb_xfixes_region_extents_request_t xcb_out; 1676 1677 xcb_out.source = source; 1678 xcb_out.destination = destination; 1679 1680 xcb_parts[2].iov_base = (char *) &xcb_out; 1681 xcb_parts[2].iov_len = sizeof(xcb_out); 1682 xcb_parts[3].iov_base = 0; 1683 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1684 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1685 return xcb_ret; 1686 } 1687 1688 1689 /***************************************************************************** 1690 ** 1691 ** xcb_xfixes_fetch_region_cookie_t xcb_xfixes_fetch_region 1692 ** 1693 ** @param xcb_connection_t *c 1694 ** @param xcb_xfixes_region_t region 1695 ** @returns xcb_xfixes_fetch_region_cookie_t 1696 ** 1697 *****************************************************************************/ 1698 1699 xcb_xfixes_fetch_region_cookie_t 1700 xcb_xfixes_fetch_region (xcb_connection_t *c /**< */, 1701 xcb_xfixes_region_t region /**< */) 1702 { 1703 static const xcb_protocol_request_t xcb_req = { 1704 /* count */ 2, 1705 /* ext */ &xcb_xfixes_id, 1706 /* opcode */ XCB_XFIXES_FETCH_REGION, 1707 /* isvoid */ 0 1708 }; 1709 1710 struct iovec xcb_parts[4]; 1711 xcb_xfixes_fetch_region_cookie_t xcb_ret; 1712 xcb_xfixes_fetch_region_request_t xcb_out; 1713 1714 xcb_out.region = region; 1715 1716 xcb_parts[2].iov_base = (char *) &xcb_out; 1717 xcb_parts[2].iov_len = sizeof(xcb_out); 1718 xcb_parts[3].iov_base = 0; 1719 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1720 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1721 return xcb_ret; 1722 } 1723 1724 1725 /***************************************************************************** 1726 ** 1727 ** xcb_xfixes_fetch_region_cookie_t xcb_xfixes_fetch_region_unchecked 1728 ** 1729 ** @param xcb_connection_t *c 1730 ** @param xcb_xfixes_region_t region 1731 ** @returns xcb_xfixes_fetch_region_cookie_t 1732 ** 1733 *****************************************************************************/ 1734 1735 xcb_xfixes_fetch_region_cookie_t 1736 xcb_xfixes_fetch_region_unchecked (xcb_connection_t *c /**< */, 1737 xcb_xfixes_region_t region /**< */) 1738 { 1739 static const xcb_protocol_request_t xcb_req = { 1740 /* count */ 2, 1741 /* ext */ &xcb_xfixes_id, 1742 /* opcode */ XCB_XFIXES_FETCH_REGION, 1743 /* isvoid */ 0 1744 }; 1745 1746 struct iovec xcb_parts[4]; 1747 xcb_xfixes_fetch_region_cookie_t xcb_ret; 1748 xcb_xfixes_fetch_region_request_t xcb_out; 1749 1750 xcb_out.region = region; 1751 1752 xcb_parts[2].iov_base = (char *) &xcb_out; 1753 xcb_parts[2].iov_len = sizeof(xcb_out); 1754 xcb_parts[3].iov_base = 0; 1755 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1756 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1757 return xcb_ret; 1758 } 1759 1760 1761 /***************************************************************************** 1762 ** 1763 ** xcb_rectangle_t * xcb_xfixes_fetch_region_rectangles 1764 ** 1765 ** @param const xcb_xfixes_fetch_region_reply_t *R 1766 ** @returns xcb_rectangle_t * 1767 ** 1768 *****************************************************************************/ 1769 1770 xcb_rectangle_t * 1771 xcb_xfixes_fetch_region_rectangles (const xcb_xfixes_fetch_region_reply_t *R /**< */) 1772 { 1773 return (xcb_rectangle_t *) (R + 1); 1774 } 1775 1776 1777 /***************************************************************************** 1778 ** 1779 ** int xcb_xfixes_fetch_region_rectangles_length 1780 ** 1781 ** @param const xcb_xfixes_fetch_region_reply_t *R 1782 ** @returns int 1783 ** 1784 *****************************************************************************/ 1785 1786 int 1787 xcb_xfixes_fetch_region_rectangles_length (const xcb_xfixes_fetch_region_reply_t *R /**< */) 1788 { 1789 return (R->length / 2); 1790 } 1791 1792 1793 /***************************************************************************** 1794 ** 1795 ** xcb_rectangle_iterator_t xcb_xfixes_fetch_region_rectangles_iterator 1796 ** 1797 ** @param const xcb_xfixes_fetch_region_reply_t *R 1798 ** @returns xcb_rectangle_iterator_t 1799 ** 1800 *****************************************************************************/ 1801 1802 xcb_rectangle_iterator_t 1803 xcb_xfixes_fetch_region_rectangles_iterator (const xcb_xfixes_fetch_region_reply_t *R /**< */) 1804 { 1805 xcb_rectangle_iterator_t i; 1806 i.data = (xcb_rectangle_t *) (R + 1); 1807 i.rem = (R->length / 2); 1808 i.index = (char *) i.data - (char *) R; 1809 return i; 1810 } 1811 1812 1813 /***************************************************************************** 1814 ** 1815 ** xcb_xfixes_fetch_region_reply_t * xcb_xfixes_fetch_region_reply 1816 ** 1817 ** @param xcb_connection_t *c 1818 ** @param xcb_xfixes_fetch_region_cookie_t cookie 1819 ** @param xcb_generic_error_t **e 1820 ** @returns xcb_xfixes_fetch_region_reply_t * 1821 ** 1822 *****************************************************************************/ 1823 1824 xcb_xfixes_fetch_region_reply_t * 1825 xcb_xfixes_fetch_region_reply (xcb_connection_t *c /**< */, 1826 xcb_xfixes_fetch_region_cookie_t cookie /**< */, 1827 xcb_generic_error_t **e /**< */) 1828 { 1829 return (xcb_xfixes_fetch_region_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 1830 } 1831 1832 1833 /***************************************************************************** 1834 ** 1835 ** xcb_void_cookie_t xcb_xfixes_set_gc_clip_region_checked 1836 ** 1837 ** @param xcb_connection_t *c 1838 ** @param xcb_gcontext_t gc 1839 ** @param xcb_xfixes_region_t region 1840 ** @param int16_t x_origin 1841 ** @param int16_t y_origin 1842 ** @returns xcb_void_cookie_t 1843 ** 1844 *****************************************************************************/ 1845 1846 xcb_void_cookie_t 1847 xcb_xfixes_set_gc_clip_region_checked (xcb_connection_t *c /**< */, 1848 xcb_gcontext_t gc /**< */, 1849 xcb_xfixes_region_t region /**< */, 1850 int16_t x_origin /**< */, 1851 int16_t y_origin /**< */) 1852 { 1853 static const xcb_protocol_request_t xcb_req = { 1854 /* count */ 2, 1855 /* ext */ &xcb_xfixes_id, 1856 /* opcode */ XCB_XFIXES_SET_GC_CLIP_REGION, 1857 /* isvoid */ 1 1858 }; 1859 1860 struct iovec xcb_parts[4]; 1861 xcb_void_cookie_t xcb_ret; 1862 xcb_xfixes_set_gc_clip_region_request_t xcb_out; 1863 1864 xcb_out.gc = gc; 1865 xcb_out.region = region; 1866 xcb_out.x_origin = x_origin; 1867 xcb_out.y_origin = y_origin; 1868 1869 xcb_parts[2].iov_base = (char *) &xcb_out; 1870 xcb_parts[2].iov_len = sizeof(xcb_out); 1871 xcb_parts[3].iov_base = 0; 1872 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1873 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1874 return xcb_ret; 1875 } 1876 1877 1878 /***************************************************************************** 1879 ** 1880 ** xcb_void_cookie_t xcb_xfixes_set_gc_clip_region 1881 ** 1882 ** @param xcb_connection_t *c 1883 ** @param xcb_gcontext_t gc 1884 ** @param xcb_xfixes_region_t region 1885 ** @param int16_t x_origin 1886 ** @param int16_t y_origin 1887 ** @returns xcb_void_cookie_t 1888 ** 1889 *****************************************************************************/ 1890 1891 xcb_void_cookie_t 1892 xcb_xfixes_set_gc_clip_region (xcb_connection_t *c /**< */, 1893 xcb_gcontext_t gc /**< */, 1894 xcb_xfixes_region_t region /**< */, 1895 int16_t x_origin /**< */, 1896 int16_t y_origin /**< */) 1897 { 1898 static const xcb_protocol_request_t xcb_req = { 1899 /* count */ 2, 1900 /* ext */ &xcb_xfixes_id, 1901 /* opcode */ XCB_XFIXES_SET_GC_CLIP_REGION, 1902 /* isvoid */ 1 1903 }; 1904 1905 struct iovec xcb_parts[4]; 1906 xcb_void_cookie_t xcb_ret; 1907 xcb_xfixes_set_gc_clip_region_request_t xcb_out; 1908 1909 xcb_out.gc = gc; 1910 xcb_out.region = region; 1911 xcb_out.x_origin = x_origin; 1912 xcb_out.y_origin = y_origin; 1913 1914 xcb_parts[2].iov_base = (char *) &xcb_out; 1915 xcb_parts[2].iov_len = sizeof(xcb_out); 1916 xcb_parts[3].iov_base = 0; 1917 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1918 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 1919 return xcb_ret; 1920 } 1921 1922 1923 /***************************************************************************** 1924 ** 1925 ** xcb_void_cookie_t xcb_xfixes_set_window_shape_region_checked 1926 ** 1927 ** @param xcb_connection_t *c 1928 ** @param xcb_window_t dest 1929 ** @param xcb_shape_kind_t dest_kind 1930 ** @param int16_t x_offset 1931 ** @param int16_t y_offset 1932 ** @param xcb_xfixes_region_t region 1933 ** @returns xcb_void_cookie_t 1934 ** 1935 *****************************************************************************/ 1936 1937 xcb_void_cookie_t 1938 xcb_xfixes_set_window_shape_region_checked (xcb_connection_t *c /**< */, 1939 xcb_window_t dest /**< */, 1940 xcb_shape_kind_t dest_kind /**< */, 1941 int16_t x_offset /**< */, 1942 int16_t y_offset /**< */, 1943 xcb_xfixes_region_t region /**< */) 1944 { 1945 static const xcb_protocol_request_t xcb_req = { 1946 /* count */ 2, 1947 /* ext */ &xcb_xfixes_id, 1948 /* opcode */ XCB_XFIXES_SET_WINDOW_SHAPE_REGION, 1949 /* isvoid */ 1 1950 }; 1951 1952 struct iovec xcb_parts[4]; 1953 xcb_void_cookie_t xcb_ret; 1954 xcb_xfixes_set_window_shape_region_request_t xcb_out; 1955 1956 xcb_out.dest = dest; 1957 xcb_out.dest_kind = dest_kind; 1958 memset(xcb_out.pad0, 0, 3); 1959 xcb_out.x_offset = x_offset; 1960 xcb_out.y_offset = y_offset; 1961 xcb_out.region = region; 1962 1963 xcb_parts[2].iov_base = (char *) &xcb_out; 1964 xcb_parts[2].iov_len = sizeof(xcb_out); 1965 xcb_parts[3].iov_base = 0; 1966 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 1967 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 1968 return xcb_ret; 1969 } 1970 1971 1972 /***************************************************************************** 1973 ** 1974 ** xcb_void_cookie_t xcb_xfixes_set_window_shape_region 1975 ** 1976 ** @param xcb_connection_t *c 1977 ** @param xcb_window_t dest 1978 ** @param xcb_shape_kind_t dest_kind 1979 ** @param int16_t x_offset 1980 ** @param int16_t y_offset 1981 ** @param xcb_xfixes_region_t region 1982 ** @returns xcb_void_cookie_t 1983 ** 1984 *****************************************************************************/ 1985 1986 xcb_void_cookie_t 1987 xcb_xfixes_set_window_shape_region (xcb_connection_t *c /**< */, 1988 xcb_window_t dest /**< */, 1989 xcb_shape_kind_t dest_kind /**< */, 1990 int16_t x_offset /**< */, 1991 int16_t y_offset /**< */, 1992 xcb_xfixes_region_t region /**< */) 1993 { 1994 static const xcb_protocol_request_t xcb_req = { 1995 /* count */ 2, 1996 /* ext */ &xcb_xfixes_id, 1997 /* opcode */ XCB_XFIXES_SET_WINDOW_SHAPE_REGION, 1998 /* isvoid */ 1 1999 }; 2000 2001 struct iovec xcb_parts[4]; 2002 xcb_void_cookie_t xcb_ret; 2003 xcb_xfixes_set_window_shape_region_request_t xcb_out; 2004 2005 xcb_out.dest = dest; 2006 xcb_out.dest_kind = dest_kind; 2007 memset(xcb_out.pad0, 0, 3); 2008 xcb_out.x_offset = x_offset; 2009 xcb_out.y_offset = y_offset; 2010 xcb_out.region = region; 2011 2012 xcb_parts[2].iov_base = (char *) &xcb_out; 2013 xcb_parts[2].iov_len = sizeof(xcb_out); 2014 xcb_parts[3].iov_base = 0; 2015 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2016 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2017 return xcb_ret; 2018 } 2019 2020 2021 /***************************************************************************** 2022 ** 2023 ** xcb_void_cookie_t xcb_xfixes_set_picture_clip_region_checked 2024 ** 2025 ** @param xcb_connection_t *c 2026 ** @param xcb_render_picture_t picture 2027 ** @param xcb_xfixes_region_t region 2028 ** @param int16_t x_origin 2029 ** @param int16_t y_origin 2030 ** @returns xcb_void_cookie_t 2031 ** 2032 *****************************************************************************/ 2033 2034 xcb_void_cookie_t 2035 xcb_xfixes_set_picture_clip_region_checked (xcb_connection_t *c /**< */, 2036 xcb_render_picture_t picture /**< */, 2037 xcb_xfixes_region_t region /**< */, 2038 int16_t x_origin /**< */, 2039 int16_t y_origin /**< */) 2040 { 2041 static const xcb_protocol_request_t xcb_req = { 2042 /* count */ 2, 2043 /* ext */ &xcb_xfixes_id, 2044 /* opcode */ XCB_XFIXES_SET_PICTURE_CLIP_REGION, 2045 /* isvoid */ 1 2046 }; 2047 2048 struct iovec xcb_parts[4]; 2049 xcb_void_cookie_t xcb_ret; 2050 xcb_xfixes_set_picture_clip_region_request_t xcb_out; 2051 2052 xcb_out.picture = picture; 2053 xcb_out.region = region; 2054 xcb_out.x_origin = x_origin; 2055 xcb_out.y_origin = y_origin; 2056 2057 xcb_parts[2].iov_base = (char *) &xcb_out; 2058 xcb_parts[2].iov_len = sizeof(xcb_out); 2059 xcb_parts[3].iov_base = 0; 2060 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2061 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2062 return xcb_ret; 2063 } 2064 2065 2066 /***************************************************************************** 2067 ** 2068 ** xcb_void_cookie_t xcb_xfixes_set_picture_clip_region 2069 ** 2070 ** @param xcb_connection_t *c 2071 ** @param xcb_render_picture_t picture 2072 ** @param xcb_xfixes_region_t region 2073 ** @param int16_t x_origin 2074 ** @param int16_t y_origin 2075 ** @returns xcb_void_cookie_t 2076 ** 2077 *****************************************************************************/ 2078 2079 xcb_void_cookie_t 2080 xcb_xfixes_set_picture_clip_region (xcb_connection_t *c /**< */, 2081 xcb_render_picture_t picture /**< */, 2082 xcb_xfixes_region_t region /**< */, 2083 int16_t x_origin /**< */, 2084 int16_t y_origin /**< */) 2085 { 2086 static const xcb_protocol_request_t xcb_req = { 2087 /* count */ 2, 2088 /* ext */ &xcb_xfixes_id, 2089 /* opcode */ XCB_XFIXES_SET_PICTURE_CLIP_REGION, 2090 /* isvoid */ 1 2091 }; 2092 2093 struct iovec xcb_parts[4]; 2094 xcb_void_cookie_t xcb_ret; 2095 xcb_xfixes_set_picture_clip_region_request_t xcb_out; 2096 2097 xcb_out.picture = picture; 2098 xcb_out.region = region; 2099 xcb_out.x_origin = x_origin; 2100 xcb_out.y_origin = y_origin; 2101 2102 xcb_parts[2].iov_base = (char *) &xcb_out; 2103 xcb_parts[2].iov_len = sizeof(xcb_out); 2104 xcb_parts[3].iov_base = 0; 2105 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2106 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2107 return xcb_ret; 2108 } 2109 2110 2111 /***************************************************************************** 2112 ** 2113 ** xcb_void_cookie_t xcb_xfixes_set_cursor_name_checked 2114 ** 2115 ** @param xcb_connection_t *c 2116 ** @param xcb_cursor_t cursor 2117 ** @param uint16_t nbytes 2118 ** @param const char *name 2119 ** @returns xcb_void_cookie_t 2120 ** 2121 *****************************************************************************/ 2122 2123 xcb_void_cookie_t 2124 xcb_xfixes_set_cursor_name_checked (xcb_connection_t *c /**< */, 2125 xcb_cursor_t cursor /**< */, 2126 uint16_t nbytes /**< */, 2127 const char *name /**< */) 2128 { 2129 static const xcb_protocol_request_t xcb_req = { 2130 /* count */ 4, 2131 /* ext */ &xcb_xfixes_id, 2132 /* opcode */ XCB_XFIXES_SET_CURSOR_NAME, 2133 /* isvoid */ 1 2134 }; 2135 2136 struct iovec xcb_parts[6]; 2137 xcb_void_cookie_t xcb_ret; 2138 xcb_xfixes_set_cursor_name_request_t xcb_out; 2139 2140 xcb_out.cursor = cursor; 2141 xcb_out.nbytes = nbytes; 2142 memset(xcb_out.pad0, 0, 2); 2143 2144 xcb_parts[2].iov_base = (char *) &xcb_out; 2145 xcb_parts[2].iov_len = sizeof(xcb_out); 2146 xcb_parts[3].iov_base = 0; 2147 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2148 xcb_parts[4].iov_base = (char *) name; 2149 xcb_parts[4].iov_len = nbytes * sizeof(char); 2150 xcb_parts[5].iov_base = 0; 2151 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 2152 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2153 return xcb_ret; 2154 } 2155 2156 2157 /***************************************************************************** 2158 ** 2159 ** xcb_void_cookie_t xcb_xfixes_set_cursor_name 2160 ** 2161 ** @param xcb_connection_t *c 2162 ** @param xcb_cursor_t cursor 2163 ** @param uint16_t nbytes 2164 ** @param const char *name 2165 ** @returns xcb_void_cookie_t 2166 ** 2167 *****************************************************************************/ 2168 2169 xcb_void_cookie_t 2170 xcb_xfixes_set_cursor_name (xcb_connection_t *c /**< */, 2171 xcb_cursor_t cursor /**< */, 2172 uint16_t nbytes /**< */, 2173 const char *name /**< */) 2174 { 2175 static const xcb_protocol_request_t xcb_req = { 2176 /* count */ 4, 2177 /* ext */ &xcb_xfixes_id, 2178 /* opcode */ XCB_XFIXES_SET_CURSOR_NAME, 2179 /* isvoid */ 1 2180 }; 2181 2182 struct iovec xcb_parts[6]; 2183 xcb_void_cookie_t xcb_ret; 2184 xcb_xfixes_set_cursor_name_request_t xcb_out; 2185 2186 xcb_out.cursor = cursor; 2187 xcb_out.nbytes = nbytes; 2188 memset(xcb_out.pad0, 0, 2); 2189 2190 xcb_parts[2].iov_base = (char *) &xcb_out; 2191 xcb_parts[2].iov_len = sizeof(xcb_out); 2192 xcb_parts[3].iov_base = 0; 2193 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2194 xcb_parts[4].iov_base = (char *) name; 2195 xcb_parts[4].iov_len = nbytes * sizeof(char); 2196 xcb_parts[5].iov_base = 0; 2197 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 2198 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2199 return xcb_ret; 2200 } 2201 2202 2203 /***************************************************************************** 2204 ** 2205 ** xcb_xfixes_get_cursor_name_cookie_t xcb_xfixes_get_cursor_name 2206 ** 2207 ** @param xcb_connection_t *c 2208 ** @param xcb_cursor_t cursor 2209 ** @returns xcb_xfixes_get_cursor_name_cookie_t 2210 ** 2211 *****************************************************************************/ 2212 2213 xcb_xfixes_get_cursor_name_cookie_t 2214 xcb_xfixes_get_cursor_name (xcb_connection_t *c /**< */, 2215 xcb_cursor_t cursor /**< */) 2216 { 2217 static const xcb_protocol_request_t xcb_req = { 2218 /* count */ 2, 2219 /* ext */ &xcb_xfixes_id, 2220 /* opcode */ XCB_XFIXES_GET_CURSOR_NAME, 2221 /* isvoid */ 0 2222 }; 2223 2224 struct iovec xcb_parts[4]; 2225 xcb_xfixes_get_cursor_name_cookie_t xcb_ret; 2226 xcb_xfixes_get_cursor_name_request_t xcb_out; 2227 2228 xcb_out.cursor = cursor; 2229 2230 xcb_parts[2].iov_base = (char *) &xcb_out; 2231 xcb_parts[2].iov_len = sizeof(xcb_out); 2232 xcb_parts[3].iov_base = 0; 2233 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2234 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2235 return xcb_ret; 2236 } 2237 2238 2239 /***************************************************************************** 2240 ** 2241 ** xcb_xfixes_get_cursor_name_cookie_t xcb_xfixes_get_cursor_name_unchecked 2242 ** 2243 ** @param xcb_connection_t *c 2244 ** @param xcb_cursor_t cursor 2245 ** @returns xcb_xfixes_get_cursor_name_cookie_t 2246 ** 2247 *****************************************************************************/ 2248 2249 xcb_xfixes_get_cursor_name_cookie_t 2250 xcb_xfixes_get_cursor_name_unchecked (xcb_connection_t *c /**< */, 2251 xcb_cursor_t cursor /**< */) 2252 { 2253 static const xcb_protocol_request_t xcb_req = { 2254 /* count */ 2, 2255 /* ext */ &xcb_xfixes_id, 2256 /* opcode */ XCB_XFIXES_GET_CURSOR_NAME, 2257 /* isvoid */ 0 2258 }; 2259 2260 struct iovec xcb_parts[4]; 2261 xcb_xfixes_get_cursor_name_cookie_t xcb_ret; 2262 xcb_xfixes_get_cursor_name_request_t xcb_out; 2263 2264 xcb_out.cursor = cursor; 2265 2266 xcb_parts[2].iov_base = (char *) &xcb_out; 2267 xcb_parts[2].iov_len = sizeof(xcb_out); 2268 xcb_parts[3].iov_base = 0; 2269 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2270 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2271 return xcb_ret; 2272 } 2273 2274 2275 /***************************************************************************** 2276 ** 2277 ** char * xcb_xfixes_get_cursor_name_name 2278 ** 2279 ** @param const xcb_xfixes_get_cursor_name_reply_t *R 2280 ** @returns char * 2281 ** 2282 *****************************************************************************/ 2283 2284 char * 2285 xcb_xfixes_get_cursor_name_name (const xcb_xfixes_get_cursor_name_reply_t *R /**< */) 2286 { 2287 return (char *) (R + 1); 2288 } 2289 2290 2291 /***************************************************************************** 2292 ** 2293 ** int xcb_xfixes_get_cursor_name_name_length 2294 ** 2295 ** @param const xcb_xfixes_get_cursor_name_reply_t *R 2296 ** @returns int 2297 ** 2298 *****************************************************************************/ 2299 2300 int 2301 xcb_xfixes_get_cursor_name_name_length (const xcb_xfixes_get_cursor_name_reply_t *R /**< */) 2302 { 2303 return R->nbytes; 2304 } 2305 2306 2307 /***************************************************************************** 2308 ** 2309 ** xcb_generic_iterator_t xcb_xfixes_get_cursor_name_name_end 2310 ** 2311 ** @param const xcb_xfixes_get_cursor_name_reply_t *R 2312 ** @returns xcb_generic_iterator_t 2313 ** 2314 *****************************************************************************/ 2315 2316 xcb_generic_iterator_t 2317 xcb_xfixes_get_cursor_name_name_end (const xcb_xfixes_get_cursor_name_reply_t *R /**< */) 2318 { 2319 xcb_generic_iterator_t i; 2320 i.data = ((char *) (R + 1)) + (R->nbytes); 2321 i.rem = 0; 2322 i.index = (char *) i.data - (char *) R; 2323 return i; 2324 } 2325 2326 2327 /***************************************************************************** 2328 ** 2329 ** xcb_xfixes_get_cursor_name_reply_t * xcb_xfixes_get_cursor_name_reply 2330 ** 2331 ** @param xcb_connection_t *c 2332 ** @param xcb_xfixes_get_cursor_name_cookie_t cookie 2333 ** @param xcb_generic_error_t **e 2334 ** @returns xcb_xfixes_get_cursor_name_reply_t * 2335 ** 2336 *****************************************************************************/ 2337 2338 xcb_xfixes_get_cursor_name_reply_t * 2339 xcb_xfixes_get_cursor_name_reply (xcb_connection_t *c /**< */, 2340 xcb_xfixes_get_cursor_name_cookie_t cookie /**< */, 2341 xcb_generic_error_t **e /**< */) 2342 { 2343 return (xcb_xfixes_get_cursor_name_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 2344 } 2345 2346 2347 /***************************************************************************** 2348 ** 2349 ** xcb_xfixes_get_cursor_image_and_name_cookie_t xcb_xfixes_get_cursor_image_and_name 2350 ** 2351 ** @param xcb_connection_t *c 2352 ** @returns xcb_xfixes_get_cursor_image_and_name_cookie_t 2353 ** 2354 *****************************************************************************/ 2355 2356 xcb_xfixes_get_cursor_image_and_name_cookie_t 2357 xcb_xfixes_get_cursor_image_and_name (xcb_connection_t *c /**< */) 2358 { 2359 static const xcb_protocol_request_t xcb_req = { 2360 /* count */ 2, 2361 /* ext */ &xcb_xfixes_id, 2362 /* opcode */ XCB_XFIXES_GET_CURSOR_IMAGE_AND_NAME, 2363 /* isvoid */ 0 2364 }; 2365 2366 struct iovec xcb_parts[4]; 2367 xcb_xfixes_get_cursor_image_and_name_cookie_t xcb_ret; 2368 xcb_xfixes_get_cursor_image_and_name_request_t xcb_out; 2369 2370 2371 xcb_parts[2].iov_base = (char *) &xcb_out; 2372 xcb_parts[2].iov_len = sizeof(xcb_out); 2373 xcb_parts[3].iov_base = 0; 2374 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2375 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2376 return xcb_ret; 2377 } 2378 2379 2380 /***************************************************************************** 2381 ** 2382 ** xcb_xfixes_get_cursor_image_and_name_cookie_t xcb_xfixes_get_cursor_image_and_name_unchecked 2383 ** 2384 ** @param xcb_connection_t *c 2385 ** @returns xcb_xfixes_get_cursor_image_and_name_cookie_t 2386 ** 2387 *****************************************************************************/ 2388 2389 xcb_xfixes_get_cursor_image_and_name_cookie_t 2390 xcb_xfixes_get_cursor_image_and_name_unchecked (xcb_connection_t *c /**< */) 2391 { 2392 static const xcb_protocol_request_t xcb_req = { 2393 /* count */ 2, 2394 /* ext */ &xcb_xfixes_id, 2395 /* opcode */ XCB_XFIXES_GET_CURSOR_IMAGE_AND_NAME, 2396 /* isvoid */ 0 2397 }; 2398 2399 struct iovec xcb_parts[4]; 2400 xcb_xfixes_get_cursor_image_and_name_cookie_t xcb_ret; 2401 xcb_xfixes_get_cursor_image_and_name_request_t xcb_out; 2402 2403 2404 xcb_parts[2].iov_base = (char *) &xcb_out; 2405 xcb_parts[2].iov_len = sizeof(xcb_out); 2406 xcb_parts[3].iov_base = 0; 2407 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2408 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2409 return xcb_ret; 2410 } 2411 2412 2413 /***************************************************************************** 2414 ** 2415 ** char * xcb_xfixes_get_cursor_image_and_name_name 2416 ** 2417 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2418 ** @returns char * 2419 ** 2420 *****************************************************************************/ 2421 2422 char * 2423 xcb_xfixes_get_cursor_image_and_name_name (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2424 { 2425 return (char *) (R + 1); 2426 } 2427 2428 2429 /***************************************************************************** 2430 ** 2431 ** int xcb_xfixes_get_cursor_image_and_name_name_length 2432 ** 2433 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2434 ** @returns int 2435 ** 2436 *****************************************************************************/ 2437 2438 int 2439 xcb_xfixes_get_cursor_image_and_name_name_length (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2440 { 2441 return R->nbytes; 2442 } 2443 2444 2445 /***************************************************************************** 2446 ** 2447 ** xcb_generic_iterator_t xcb_xfixes_get_cursor_image_and_name_name_end 2448 ** 2449 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2450 ** @returns xcb_generic_iterator_t 2451 ** 2452 *****************************************************************************/ 2453 2454 xcb_generic_iterator_t 2455 xcb_xfixes_get_cursor_image_and_name_name_end (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2456 { 2457 xcb_generic_iterator_t i; 2458 i.data = ((char *) (R + 1)) + (R->nbytes); 2459 i.rem = 0; 2460 i.index = (char *) i.data - (char *) R; 2461 return i; 2462 } 2463 2464 2465 /***************************************************************************** 2466 ** 2467 ** uint32_t * xcb_xfixes_get_cursor_image_and_name_cursor_image 2468 ** 2469 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2470 ** @returns uint32_t * 2471 ** 2472 *****************************************************************************/ 2473 2474 uint32_t * 2475 xcb_xfixes_get_cursor_image_and_name_cursor_image (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2476 { 2477 xcb_generic_iterator_t prev = xcb_xfixes_get_cursor_image_and_name_name_end(R); 2478 return (uint32_t *) ((char *) prev.data + XCB_TYPE_PAD(uint32_t, prev.index) + 0); 2479 } 2480 2481 2482 /***************************************************************************** 2483 ** 2484 ** int xcb_xfixes_get_cursor_image_and_name_cursor_image_length 2485 ** 2486 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2487 ** @returns int 2488 ** 2489 *****************************************************************************/ 2490 2491 int 2492 xcb_xfixes_get_cursor_image_and_name_cursor_image_length (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2493 { 2494 return (R->width * R->height); 2495 } 2496 2497 2498 /***************************************************************************** 2499 ** 2500 ** xcb_generic_iterator_t xcb_xfixes_get_cursor_image_and_name_cursor_image_end 2501 ** 2502 ** @param const xcb_xfixes_get_cursor_image_and_name_reply_t *R 2503 ** @returns xcb_generic_iterator_t 2504 ** 2505 *****************************************************************************/ 2506 2507 xcb_generic_iterator_t 2508 xcb_xfixes_get_cursor_image_and_name_cursor_image_end (const xcb_xfixes_get_cursor_image_and_name_reply_t *R /**< */) 2509 { 2510 xcb_generic_iterator_t i; 2511 xcb_generic_iterator_t child = xcb_xfixes_get_cursor_image_and_name_name_end(R); 2512 i.data = ((uint32_t *) child.data) + ((R->width * R->height)); 2513 i.rem = 0; 2514 i.index = (char *) i.data - (char *) R; 2515 return i; 2516 } 2517 2518 2519 /***************************************************************************** 2520 ** 2521 ** xcb_xfixes_get_cursor_image_and_name_reply_t * xcb_xfixes_get_cursor_image_and_name_reply 2522 ** 2523 ** @param xcb_connection_t *c 2524 ** @param xcb_xfixes_get_cursor_image_and_name_cookie_t cookie 2525 ** @param xcb_generic_error_t **e 2526 ** @returns xcb_xfixes_get_cursor_image_and_name_reply_t * 2527 ** 2528 *****************************************************************************/ 2529 2530 xcb_xfixes_get_cursor_image_and_name_reply_t * 2531 xcb_xfixes_get_cursor_image_and_name_reply (xcb_connection_t *c /**< */, 2532 xcb_xfixes_get_cursor_image_and_name_cookie_t cookie /**< */, 2533 xcb_generic_error_t **e /**< */) 2534 { 2535 return (xcb_xfixes_get_cursor_image_and_name_reply_t *) xcb_wait_for_reply(c, cookie.sequence, e); 2536 } 2537 2538 2539 /***************************************************************************** 2540 ** 2541 ** xcb_void_cookie_t xcb_xfixes_change_cursor_checked 2542 ** 2543 ** @param xcb_connection_t *c 2544 ** @param xcb_cursor_t source 2545 ** @param xcb_cursor_t destination 2546 ** @returns xcb_void_cookie_t 2547 ** 2548 *****************************************************************************/ 2549 2550 xcb_void_cookie_t 2551 xcb_xfixes_change_cursor_checked (xcb_connection_t *c /**< */, 2552 xcb_cursor_t source /**< */, 2553 xcb_cursor_t destination /**< */) 2554 { 2555 static const xcb_protocol_request_t xcb_req = { 2556 /* count */ 2, 2557 /* ext */ &xcb_xfixes_id, 2558 /* opcode */ XCB_XFIXES_CHANGE_CURSOR, 2559 /* isvoid */ 1 2560 }; 2561 2562 struct iovec xcb_parts[4]; 2563 xcb_void_cookie_t xcb_ret; 2564 xcb_xfixes_change_cursor_request_t xcb_out; 2565 2566 xcb_out.source = source; 2567 xcb_out.destination = destination; 2568 2569 xcb_parts[2].iov_base = (char *) &xcb_out; 2570 xcb_parts[2].iov_len = sizeof(xcb_out); 2571 xcb_parts[3].iov_base = 0; 2572 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2573 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2574 return xcb_ret; 2575 } 2576 2577 2578 /***************************************************************************** 2579 ** 2580 ** xcb_void_cookie_t xcb_xfixes_change_cursor 2581 ** 2582 ** @param xcb_connection_t *c 2583 ** @param xcb_cursor_t source 2584 ** @param xcb_cursor_t destination 2585 ** @returns xcb_void_cookie_t 2586 ** 2587 *****************************************************************************/ 2588 2589 xcb_void_cookie_t 2590 xcb_xfixes_change_cursor (xcb_connection_t *c /**< */, 2591 xcb_cursor_t source /**< */, 2592 xcb_cursor_t destination /**< */) 2593 { 2594 static const xcb_protocol_request_t xcb_req = { 2595 /* count */ 2, 2596 /* ext */ &xcb_xfixes_id, 2597 /* opcode */ XCB_XFIXES_CHANGE_CURSOR, 2598 /* isvoid */ 1 2599 }; 2600 2601 struct iovec xcb_parts[4]; 2602 xcb_void_cookie_t xcb_ret; 2603 xcb_xfixes_change_cursor_request_t xcb_out; 2604 2605 xcb_out.source = source; 2606 xcb_out.destination = destination; 2607 2608 xcb_parts[2].iov_base = (char *) &xcb_out; 2609 xcb_parts[2].iov_len = sizeof(xcb_out); 2610 xcb_parts[3].iov_base = 0; 2611 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2612 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2613 return xcb_ret; 2614 } 2615 2616 2617 /***************************************************************************** 2618 ** 2619 ** xcb_void_cookie_t xcb_xfixes_change_cursor_by_name_checked 2620 ** 2621 ** @param xcb_connection_t *c 2622 ** @param xcb_cursor_t src 2623 ** @param uint16_t nbytes 2624 ** @param const char *name 2625 ** @returns xcb_void_cookie_t 2626 ** 2627 *****************************************************************************/ 2628 2629 xcb_void_cookie_t 2630 xcb_xfixes_change_cursor_by_name_checked (xcb_connection_t *c /**< */, 2631 xcb_cursor_t src /**< */, 2632 uint16_t nbytes /**< */, 2633 const char *name /**< */) 2634 { 2635 static const xcb_protocol_request_t xcb_req = { 2636 /* count */ 4, 2637 /* ext */ &xcb_xfixes_id, 2638 /* opcode */ XCB_XFIXES_CHANGE_CURSOR_BY_NAME, 2639 /* isvoid */ 1 2640 }; 2641 2642 struct iovec xcb_parts[6]; 2643 xcb_void_cookie_t xcb_ret; 2644 xcb_xfixes_change_cursor_by_name_request_t xcb_out; 2645 2646 xcb_out.src = src; 2647 xcb_out.nbytes = nbytes; 2648 memset(xcb_out.pad0, 0, 2); 2649 2650 xcb_parts[2].iov_base = (char *) &xcb_out; 2651 xcb_parts[2].iov_len = sizeof(xcb_out); 2652 xcb_parts[3].iov_base = 0; 2653 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2654 xcb_parts[4].iov_base = (char *) name; 2655 xcb_parts[4].iov_len = nbytes * sizeof(char); 2656 xcb_parts[5].iov_base = 0; 2657 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 2658 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2659 return xcb_ret; 2660 } 2661 2662 2663 /***************************************************************************** 2664 ** 2665 ** xcb_void_cookie_t xcb_xfixes_change_cursor_by_name 2666 ** 2667 ** @param xcb_connection_t *c 2668 ** @param xcb_cursor_t src 2669 ** @param uint16_t nbytes 2670 ** @param const char *name 2671 ** @returns xcb_void_cookie_t 2672 ** 2673 *****************************************************************************/ 2674 2675 xcb_void_cookie_t 2676 xcb_xfixes_change_cursor_by_name (xcb_connection_t *c /**< */, 2677 xcb_cursor_t src /**< */, 2678 uint16_t nbytes /**< */, 2679 const char *name /**< */) 2680 { 2681 static const xcb_protocol_request_t xcb_req = { 2682 /* count */ 4, 2683 /* ext */ &xcb_xfixes_id, 2684 /* opcode */ XCB_XFIXES_CHANGE_CURSOR_BY_NAME, 2685 /* isvoid */ 1 2686 }; 2687 2688 struct iovec xcb_parts[6]; 2689 xcb_void_cookie_t xcb_ret; 2690 xcb_xfixes_change_cursor_by_name_request_t xcb_out; 2691 2692 xcb_out.src = src; 2693 xcb_out.nbytes = nbytes; 2694 memset(xcb_out.pad0, 0, 2); 2695 2696 xcb_parts[2].iov_base = (char *) &xcb_out; 2697 xcb_parts[2].iov_len = sizeof(xcb_out); 2698 xcb_parts[3].iov_base = 0; 2699 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2700 xcb_parts[4].iov_base = (char *) name; 2701 xcb_parts[4].iov_len = nbytes * sizeof(char); 2702 xcb_parts[5].iov_base = 0; 2703 xcb_parts[5].iov_len = -xcb_parts[4].iov_len & 3; 2704 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2705 return xcb_ret; 2706 } 2707 2708 2709 /***************************************************************************** 2710 ** 2711 ** xcb_void_cookie_t xcb_xfixes_expand_region_checked 2712 ** 2713 ** @param xcb_connection_t *c 2714 ** @param xcb_xfixes_region_t source 2715 ** @param xcb_xfixes_region_t destination 2716 ** @param uint16_t left 2717 ** @param uint16_t right 2718 ** @param uint16_t top 2719 ** @param uint16_t bottom 2720 ** @returns xcb_void_cookie_t 2721 ** 2722 *****************************************************************************/ 2723 2724 xcb_void_cookie_t 2725 xcb_xfixes_expand_region_checked (xcb_connection_t *c /**< */, 2726 xcb_xfixes_region_t source /**< */, 2727 xcb_xfixes_region_t destination /**< */, 2728 uint16_t left /**< */, 2729 uint16_t right /**< */, 2730 uint16_t top /**< */, 2731 uint16_t bottom /**< */) 2732 { 2733 static const xcb_protocol_request_t xcb_req = { 2734 /* count */ 2, 2735 /* ext */ &xcb_xfixes_id, 2736 /* opcode */ XCB_XFIXES_EXPAND_REGION, 2737 /* isvoid */ 1 2738 }; 2739 2740 struct iovec xcb_parts[4]; 2741 xcb_void_cookie_t xcb_ret; 2742 xcb_xfixes_expand_region_request_t xcb_out; 2743 2744 xcb_out.source = source; 2745 xcb_out.destination = destination; 2746 xcb_out.left = left; 2747 xcb_out.right = right; 2748 xcb_out.top = top; 2749 xcb_out.bottom = bottom; 2750 2751 xcb_parts[2].iov_base = (char *) &xcb_out; 2752 xcb_parts[2].iov_len = sizeof(xcb_out); 2753 xcb_parts[3].iov_base = 0; 2754 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2755 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2756 return xcb_ret; 2757 } 2758 2759 2760 /***************************************************************************** 2761 ** 2762 ** xcb_void_cookie_t xcb_xfixes_expand_region 2763 ** 2764 ** @param xcb_connection_t *c 2765 ** @param xcb_xfixes_region_t source 2766 ** @param xcb_xfixes_region_t destination 2767 ** @param uint16_t left 2768 ** @param uint16_t right 2769 ** @param uint16_t top 2770 ** @param uint16_t bottom 2771 ** @returns xcb_void_cookie_t 2772 ** 2773 *****************************************************************************/ 2774 2775 xcb_void_cookie_t 2776 xcb_xfixes_expand_region (xcb_connection_t *c /**< */, 2777 xcb_xfixes_region_t source /**< */, 2778 xcb_xfixes_region_t destination /**< */, 2779 uint16_t left /**< */, 2780 uint16_t right /**< */, 2781 uint16_t top /**< */, 2782 uint16_t bottom /**< */) 2783 { 2784 static const xcb_protocol_request_t xcb_req = { 2785 /* count */ 2, 2786 /* ext */ &xcb_xfixes_id, 2787 /* opcode */ XCB_XFIXES_EXPAND_REGION, 2788 /* isvoid */ 1 2789 }; 2790 2791 struct iovec xcb_parts[4]; 2792 xcb_void_cookie_t xcb_ret; 2793 xcb_xfixes_expand_region_request_t xcb_out; 2794 2795 xcb_out.source = source; 2796 xcb_out.destination = destination; 2797 xcb_out.left = left; 2798 xcb_out.right = right; 2799 xcb_out.top = top; 2800 xcb_out.bottom = bottom; 2801 2802 xcb_parts[2].iov_base = (char *) &xcb_out; 2803 xcb_parts[2].iov_len = sizeof(xcb_out); 2804 xcb_parts[3].iov_base = 0; 2805 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2806 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2807 return xcb_ret; 2808 } 2809 2810 2811 /***************************************************************************** 2812 ** 2813 ** xcb_void_cookie_t xcb_xfixes_hide_cursor_checked 2814 ** 2815 ** @param xcb_connection_t *c 2816 ** @param xcb_window_t window 2817 ** @returns xcb_void_cookie_t 2818 ** 2819 *****************************************************************************/ 2820 2821 xcb_void_cookie_t 2822 xcb_xfixes_hide_cursor_checked (xcb_connection_t *c /**< */, 2823 xcb_window_t window /**< */) 2824 { 2825 static const xcb_protocol_request_t xcb_req = { 2826 /* count */ 2, 2827 /* ext */ &xcb_xfixes_id, 2828 /* opcode */ XCB_XFIXES_HIDE_CURSOR, 2829 /* isvoid */ 1 2830 }; 2831 2832 struct iovec xcb_parts[4]; 2833 xcb_void_cookie_t xcb_ret; 2834 xcb_xfixes_hide_cursor_request_t xcb_out; 2835 2836 xcb_out.window = window; 2837 2838 xcb_parts[2].iov_base = (char *) &xcb_out; 2839 xcb_parts[2].iov_len = sizeof(xcb_out); 2840 xcb_parts[3].iov_base = 0; 2841 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2842 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2843 return xcb_ret; 2844 } 2845 2846 2847 /***************************************************************************** 2848 ** 2849 ** xcb_void_cookie_t xcb_xfixes_hide_cursor 2850 ** 2851 ** @param xcb_connection_t *c 2852 ** @param xcb_window_t window 2853 ** @returns xcb_void_cookie_t 2854 ** 2855 *****************************************************************************/ 2856 2857 xcb_void_cookie_t 2858 xcb_xfixes_hide_cursor (xcb_connection_t *c /**< */, 2859 xcb_window_t window /**< */) 2860 { 2861 static const xcb_protocol_request_t xcb_req = { 2862 /* count */ 2, 2863 /* ext */ &xcb_xfixes_id, 2864 /* opcode */ XCB_XFIXES_HIDE_CURSOR, 2865 /* isvoid */ 1 2866 }; 2867 2868 struct iovec xcb_parts[4]; 2869 xcb_void_cookie_t xcb_ret; 2870 xcb_xfixes_hide_cursor_request_t xcb_out; 2871 2872 xcb_out.window = window; 2873 2874 xcb_parts[2].iov_base = (char *) &xcb_out; 2875 xcb_parts[2].iov_len = sizeof(xcb_out); 2876 xcb_parts[3].iov_base = 0; 2877 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2878 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2879 return xcb_ret; 2880 } 2881 2882 2883 /***************************************************************************** 2884 ** 2885 ** xcb_void_cookie_t xcb_xfixes_show_cursor_checked 2886 ** 2887 ** @param xcb_connection_t *c 2888 ** @param xcb_window_t window 2889 ** @returns xcb_void_cookie_t 2890 ** 2891 *****************************************************************************/ 2892 2893 xcb_void_cookie_t 2894 xcb_xfixes_show_cursor_checked (xcb_connection_t *c /**< */, 2895 xcb_window_t window /**< */) 2896 { 2897 static const xcb_protocol_request_t xcb_req = { 2898 /* count */ 2, 2899 /* ext */ &xcb_xfixes_id, 2900 /* opcode */ XCB_XFIXES_SHOW_CURSOR, 2901 /* isvoid */ 1 2902 }; 2903 2904 struct iovec xcb_parts[4]; 2905 xcb_void_cookie_t xcb_ret; 2906 xcb_xfixes_show_cursor_request_t xcb_out; 2907 2908 xcb_out.window = window; 2909 2910 xcb_parts[2].iov_base = (char *) &xcb_out; 2911 xcb_parts[2].iov_len = sizeof(xcb_out); 2912 xcb_parts[3].iov_base = 0; 2913 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2914 xcb_ret.sequence = xcb_send_request(c, XCB_REQUEST_CHECKED, xcb_parts + 2, &xcb_req); 2915 return xcb_ret; 2916 } 2917 2918 2919 /***************************************************************************** 2920 ** 2921 ** xcb_void_cookie_t xcb_xfixes_show_cursor 2922 ** 2923 ** @param xcb_connection_t *c 2924 ** @param xcb_window_t window 2925 ** @returns xcb_void_cookie_t 2926 ** 2927 *****************************************************************************/ 2928 2929 xcb_void_cookie_t 2930 xcb_xfixes_show_cursor (xcb_connection_t *c /**< */, 2931 xcb_window_t window /**< */) 2932 { 2933 static const xcb_protocol_request_t xcb_req = { 2934 /* count */ 2, 2935 /* ext */ &xcb_xfixes_id, 2936 /* opcode */ XCB_XFIXES_SHOW_CURSOR, 2937 /* isvoid */ 1 2938 }; 2939 2940 struct iovec xcb_parts[4]; 2941 xcb_void_cookie_t xcb_ret; 2942 xcb_xfixes_show_cursor_request_t xcb_out; 2943 2944 xcb_out.window = window; 2945 2946 xcb_parts[2].iov_base = (char *) &xcb_out; 2947 xcb_parts[2].iov_len = sizeof(xcb_out); 2948 xcb_parts[3].iov_base = 0; 2949 xcb_parts[3].iov_len = -xcb_parts[2].iov_len & 3; 2950 xcb_ret.sequence = xcb_send_request(c, 0, xcb_parts + 2, &xcb_req); 2951 return xcb_ret; 2952 } 2953 2954