Added German 105 keys keyboard.
[wine/multimedia.git] / server / protocol.def
blob6cc06b5c51d3568ac72a49e17da9a440540d03e7
1 /* -*- C -*-
3 * Wine server protocol definition
5 * Copyright (C) 2001 Alexandre Julliard
7 * This file is used by tools/make_requests to build the
8 * protocol structures in include/wine/server_protocol.h
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation; either
13 * version 2.1 of the License, or (at your option) any later version.
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 @HEADER /* start of C declarations */
27 #include <stdlib.h>
28 #include <time.h>
29 #include "winbase.h"
31 struct request_header
33 int req; /* request code */
34 size_t request_size; /* request variable part size */
35 size_t reply_size; /* reply variable part maximum size */
38 struct reply_header
40 unsigned int error; /* error result */
41 size_t reply_size; /* reply variable part size */
44 /* placeholder structure for the maximum allowed request size */
45 /* this is used to construct the generic_request union */
46 struct request_max_size
48 int pad[16]; /* the max request size is 16 ints */
51 /* max size of the variable part of a request */
52 #define REQUEST_MAX_VAR_SIZE 1024
54 typedef int handle_t;
55 typedef unsigned short atom_t;
56 typedef unsigned int user_handle_t;
58 #define FIRST_USER_HANDLE 0x0020 /* first possible value for low word of user handle */
59 #define LAST_USER_HANDLE 0xffef /* last possible value for low word of user handle */
62 /* definitions of the event data depending on the event code */
63 struct debug_event_exception
65 EXCEPTION_RECORD record; /* exception record */
66 int first; /* first chance exception? */
68 struct debug_event_create_thread
70 handle_t handle; /* handle to the new thread */
71 void *teb; /* thread teb (in debugged process address space) */
72 void *start; /* thread startup routine */
74 struct debug_event_create_process
76 handle_t file; /* handle to the process exe file */
77 handle_t process; /* handle to the new process */
78 handle_t thread; /* handle to the new thread */
79 void *base; /* base of executable image */
80 int dbg_offset; /* offset of debug info in file */
81 int dbg_size; /* size of debug info */
82 void *teb; /* thread teb (in debugged process address space) */
83 void *start; /* thread startup routine */
84 void *name; /* image name (optional) */
85 int unicode; /* is it Unicode? */
87 struct debug_event_exit
89 int exit_code; /* thread or process exit code */
91 struct debug_event_load_dll
93 handle_t handle; /* file handle for the dll */
94 void *base; /* base address of the dll */
95 int dbg_offset; /* offset of debug info in file */
96 int dbg_size; /* size of debug info */
97 void *name; /* image name (optional) */
98 int unicode; /* is it Unicode? */
100 struct debug_event_unload_dll
102 void *base; /* base address of the dll */
104 struct debug_event_output_string
106 void *string; /* string to display (in debugged process address space) */
107 int unicode; /* is it Unicode? */
108 int length; /* string length */
110 struct debug_event_rip_info
112 int error; /* ??? */
113 int type; /* ??? */
115 union debug_event_data
117 struct debug_event_exception exception;
118 struct debug_event_create_thread create_thread;
119 struct debug_event_create_process create_process;
120 struct debug_event_exit exit;
121 struct debug_event_load_dll load_dll;
122 struct debug_event_unload_dll unload_dll;
123 struct debug_event_output_string output_string;
124 struct debug_event_rip_info rip_info;
127 /* debug event data */
128 typedef struct
130 int code; /* event code */
131 union debug_event_data info; /* event information */
132 } debug_event_t;
134 /* structure used in sending an fd from client to server */
135 struct send_fd
137 void *tid; /* thread id */
138 int fd; /* file descriptor on client-side */
141 /* structure sent by the server on the wait fifo */
142 struct wake_up_reply
144 void *cookie; /* magic cookie that was passed in select_request */
145 int signaled; /* wait result */
148 /* structure returned in the list of window properties */
149 typedef struct
151 atom_t atom; /* property atom */
152 short string; /* was atom a string originally? */
153 handle_t handle; /* handle stored in property */
154 } property_data_t;
156 /* structure to specify window rectangles */
157 typedef struct
159 int left;
160 int top;
161 int right;
162 int bottom;
163 } rectangle_t;
165 /* structure for console char/attribute info */
166 typedef struct
168 WCHAR ch;
169 unsigned short attr;
170 } char_info_t;
172 /****************************************************************/
173 /* Request declarations */
175 /* Create a new process from the context of the parent */
176 @REQ(new_process)
177 int inherit_all; /* inherit all handles from parent */
178 int create_flags; /* creation flags */
179 int start_flags; /* flags from startup info */
180 handle_t exe_file; /* file handle for main exe */
181 handle_t hstdin; /* handle for stdin */
182 handle_t hstdout; /* handle for stdout */
183 handle_t hstderr; /* handle for stderr */
184 int cmd_show; /* main window show mode */
185 VARARG(filename,string); /* file name of main exe */
186 @REPLY
187 handle_t info; /* new process info handle */
188 @END
191 /* Retrieve information about a newly started process */
192 @REQ(get_new_process_info)
193 handle_t info; /* info handle returned from new_process_request */
194 int pinherit; /* process handle inherit flag */
195 int tinherit; /* thread handle inherit flag */
196 @REPLY
197 void* pid; /* process id */
198 handle_t phandle; /* process handle (in the current process) */
199 void* tid; /* thread id */
200 handle_t thandle; /* thread handle (in the current process) */
201 handle_t event; /* event handle to signal startup */
202 @END
205 /* Create a new thread from the context of the parent */
206 @REQ(new_thread)
207 int suspend; /* new thread should be suspended on creation */
208 int inherit; /* inherit flag */
209 int request_fd; /* fd for request pipe */
210 @REPLY
211 void* tid; /* thread id */
212 handle_t handle; /* thread handle (in the current process) */
213 @END
216 /* Signal that we are finished booting on the client side */
217 @REQ(boot_done)
218 int debug_level; /* new debug level */
219 @END
222 /* Initialize a process; called from the new process context */
223 @REQ(init_process)
224 void* ldt_copy; /* addr of LDT copy */
225 int ppid; /* parent Unix pid */
226 @REPLY
227 int create_flags; /* creation flags */
228 int start_flags; /* flags from startup info */
229 unsigned int server_start; /* server start time (GetTickCount) */
230 handle_t exe_file; /* file handle for main exe */
231 handle_t hstdin; /* handle for stdin */
232 handle_t hstdout; /* handle for stdout */
233 handle_t hstderr; /* handle for stderr */
234 int cmd_show; /* main window show mode */
235 VARARG(filename,string); /* file name of main exe */
236 @END
239 /* Signal the end of the process initialization */
240 @REQ(init_process_done)
241 void* module; /* main module base address */
242 void* entry; /* process entry point */
243 void* name; /* ptr to ptr to name (in process addr space) */
244 handle_t exe_file; /* file handle for main exe */
245 int gui; /* is it a GUI process? */
246 @REPLY
247 int debugged; /* being debugged? */
248 @END
251 /* Initialize a thread; called from the child after fork()/clone() */
252 @REQ(init_thread)
253 int unix_pid; /* Unix pid of new thread */
254 void* teb; /* TEB of new thread (in thread address space) */
255 void* entry; /* thread entry point (in thread address space) */
256 int reply_fd; /* fd for reply pipe */
257 int wait_fd; /* fd for blocking calls pipe */
258 @REPLY
259 void* pid; /* process id of the new thread's process */
260 void* tid; /* thread id of the new thread */
261 int boot; /* is this the boot thread? */
262 int version; /* protocol version */
263 @END
266 /* Terminate a process */
267 @REQ(terminate_process)
268 handle_t handle; /* process handle to terminate */
269 int exit_code; /* process exit code */
270 @REPLY
271 int self; /* suicide? */
272 @END
275 /* Terminate a thread */
276 @REQ(terminate_thread)
277 handle_t handle; /* thread handle to terminate */
278 int exit_code; /* thread exit code */
279 @REPLY
280 int self; /* suicide? */
281 int last; /* last thread in this process? */
282 @END
285 /* Retrieve information about a process */
286 @REQ(get_process_info)
287 handle_t handle; /* process handle */
288 @REPLY
289 void* pid; /* server process id */
290 int debugged; /* debugged? */
291 int exit_code; /* process exit code */
292 int priority; /* priority class */
293 int process_affinity; /* process affinity mask */
294 int system_affinity; /* system affinity mask */
295 @END
298 /* Set a process informations */
299 @REQ(set_process_info)
300 handle_t handle; /* process handle */
301 int mask; /* setting mask (see below) */
302 int priority; /* priority class */
303 int affinity; /* affinity mask */
304 @END
305 #define SET_PROCESS_INFO_PRIORITY 0x01
306 #define SET_PROCESS_INFO_AFFINITY 0x02
309 /* Retrieve information about a thread */
310 @REQ(get_thread_info)
311 handle_t handle; /* thread handle */
312 void* tid_in; /* thread id (optional) */
313 @REPLY
314 void* tid; /* server thread id */
315 void* teb; /* thread teb pointer */
316 int exit_code; /* thread exit code */
317 int priority; /* thread priority level */
318 @END
321 /* Set a thread informations */
322 @REQ(set_thread_info)
323 handle_t handle; /* thread handle */
324 int mask; /* setting mask (see below) */
325 int priority; /* priority class */
326 int affinity; /* affinity mask */
327 @END
328 #define SET_THREAD_INFO_PRIORITY 0x01
329 #define SET_THREAD_INFO_AFFINITY 0x02
332 /* Suspend a thread */
333 @REQ(suspend_thread)
334 handle_t handle; /* thread handle */
335 @REPLY
336 int count; /* new suspend count */
337 @END
340 /* Resume a thread */
341 @REQ(resume_thread)
342 handle_t handle; /* thread handle */
343 @REPLY
344 int count; /* new suspend count */
345 @END
348 /* Notify the server that a dll has been loaded */
349 @REQ(load_dll)
350 handle_t handle; /* file handle */
351 void* base; /* base address */
352 int dbg_offset; /* debug info offset */
353 int dbg_size; /* debug info size */
354 void* name; /* ptr to ptr to name (in process addr space) */
355 @END
358 /* Notify the server that a dll is being unloaded */
359 @REQ(unload_dll)
360 void* base; /* base address */
361 @END
364 /* Queue an APC for a thread */
365 @REQ(queue_apc)
366 handle_t handle; /* thread handle */
367 int user; /* user or system apc? */
368 void* func; /* function to call */
369 void* param; /* param for function to call */
370 @END
373 /* Get next APC to call */
374 @REQ(get_apc)
375 int alertable; /* is thread alertable? */
376 @REPLY
377 void* func; /* function to call */
378 int type; /* function type */
379 VARARG(args,ptrs); /* function arguments */
380 @END
381 enum apc_type { APC_NONE, APC_USER, APC_TIMER, APC_ASYNC };
384 /* Close a handle for the current process */
385 @REQ(close_handle)
386 handle_t handle; /* handle to close */
387 @REPLY
388 int fd; /* associated fd to close */
389 @END
392 /* Set a handle information */
393 @REQ(set_handle_info)
394 handle_t handle; /* handle we are interested in */
395 int flags; /* new handle flags */
396 int mask; /* mask for flags to set */
397 int fd; /* file descriptor or -1 */
398 @REPLY
399 int old_flags; /* old flag value */
400 int cur_fd; /* current file descriptor */
401 @END
404 /* Duplicate a handle */
405 @REQ(dup_handle)
406 handle_t src_process; /* src process handle */
407 handle_t src_handle; /* src handle to duplicate */
408 handle_t dst_process; /* dst process handle */
409 unsigned int access; /* wanted access rights */
410 int inherit; /* inherit flag */
411 int options; /* duplicate options (see below) */
412 @REPLY
413 handle_t handle; /* duplicated handle in dst process */
414 int fd; /* associated fd to close */
415 @END
416 #define DUP_HANDLE_CLOSE_SOURCE DUPLICATE_CLOSE_SOURCE
417 #define DUP_HANDLE_SAME_ACCESS DUPLICATE_SAME_ACCESS
418 #define DUP_HANDLE_MAKE_GLOBAL 0x80000000 /* Not a Windows flag */
421 /* Open a handle to a process */
422 @REQ(open_process)
423 void* pid; /* process id to open */
424 unsigned int access; /* wanted access rights */
425 int inherit; /* inherit flag */
426 @REPLY
427 handle_t handle; /* handle to the process */
428 @END
431 /* Wait for handles */
432 @REQ(select)
433 int flags; /* wait flags (see below) */
434 void* cookie; /* magic cookie to return to client */
435 int sec; /* absolute timeout */
436 int usec; /* absolute timeout */
437 VARARG(handles,handles); /* handles to select on */
438 @END
439 #define SELECT_ALL 1
440 #define SELECT_ALERTABLE 2
441 #define SELECT_INTERRUPTIBLE 4
442 #define SELECT_TIMEOUT 8
445 /* Create an event */
446 @REQ(create_event)
447 int manual_reset; /* manual reset event */
448 int initial_state; /* initial state of the event */
449 int inherit; /* inherit flag */
450 VARARG(name,unicode_str); /* object name */
451 @REPLY
452 handle_t handle; /* handle to the event */
453 @END
455 /* Event operation */
456 @REQ(event_op)
457 handle_t handle; /* handle to event */
458 int op; /* event operation (see below) */
459 @END
460 enum event_op { PULSE_EVENT, SET_EVENT, RESET_EVENT };
463 /* Open an event */
464 @REQ(open_event)
465 unsigned int access; /* wanted access rights */
466 int inherit; /* inherit flag */
467 VARARG(name,unicode_str); /* object name */
468 @REPLY
469 handle_t handle; /* handle to the event */
470 @END
473 /* Create a mutex */
474 @REQ(create_mutex)
475 int owned; /* initially owned? */
476 int inherit; /* inherit flag */
477 VARARG(name,unicode_str); /* object name */
478 @REPLY
479 handle_t handle; /* handle to the mutex */
480 @END
483 /* Release a mutex */
484 @REQ(release_mutex)
485 handle_t handle; /* handle to the mutex */
486 @END
489 /* Open a mutex */
490 @REQ(open_mutex)
491 unsigned int access; /* wanted access rights */
492 int inherit; /* inherit flag */
493 VARARG(name,unicode_str); /* object name */
494 @REPLY
495 handle_t handle; /* handle to the mutex */
496 @END
499 /* Create a semaphore */
500 @REQ(create_semaphore)
501 unsigned int initial; /* initial count */
502 unsigned int max; /* maximum count */
503 int inherit; /* inherit flag */
504 VARARG(name,unicode_str); /* object name */
505 @REPLY
506 handle_t handle; /* handle to the semaphore */
507 @END
510 /* Release a semaphore */
511 @REQ(release_semaphore)
512 handle_t handle; /* handle to the semaphore */
513 unsigned int count; /* count to add to semaphore */
514 @REPLY
515 unsigned int prev_count; /* previous semaphore count */
516 @END
519 /* Open a semaphore */
520 @REQ(open_semaphore)
521 unsigned int access; /* wanted access rights */
522 int inherit; /* inherit flag */
523 VARARG(name,unicode_str); /* object name */
524 @REPLY
525 handle_t handle; /* handle to the semaphore */
526 @END
529 /* Create a file */
530 @REQ(create_file)
531 unsigned int access; /* wanted access rights */
532 int inherit; /* inherit flag */
533 unsigned int sharing; /* sharing flags */
534 int create; /* file create action */
535 unsigned int attrs; /* file attributes for creation */
536 int drive_type; /* type of drive the file is on */
537 VARARG(filename,string); /* file name */
538 @REPLY
539 handle_t handle; /* handle to the file */
540 @END
543 /* Allocate a file handle for a Unix fd */
544 @REQ(alloc_file_handle)
545 unsigned int access; /* wanted access rights */
546 int inherit; /* inherit flag */
547 int fd; /* file descriptor on the client side */
548 @REPLY
549 handle_t handle; /* handle to the file */
550 @END
553 /* Get a Unix fd to access a file */
554 @REQ(get_handle_fd)
555 handle_t handle; /* handle to the file */
556 unsigned int access; /* wanted access rights */
557 @REPLY
558 int fd; /* file descriptor */
559 int type; /* the type of file (see below) */
560 int flags; /* file read/write flags (see below) */
561 @END
562 enum fd_type
564 FD_TYPE_INVALID,
565 FD_TYPE_DEFAULT,
566 FD_TYPE_CONSOLE,
567 FD_TYPE_SMB
569 #define FD_FLAG_OVERLAPPED 0x01
570 #define FD_FLAG_TIMEOUT 0x02
573 /* Set a file current position */
574 @REQ(set_file_pointer)
575 handle_t handle; /* handle to the file */
576 int low; /* position low word */
577 int high; /* position high word */
578 int whence; /* whence to seek */
579 @REPLY
580 int new_low; /* new position low word */
581 int new_high; /* new position high word */
582 @END
585 /* Truncate (or extend) a file */
586 @REQ(truncate_file)
587 handle_t handle; /* handle to the file */
588 @END
591 /* Set a file access and modification times */
592 @REQ(set_file_time)
593 handle_t handle; /* handle to the file */
594 time_t access_time; /* last access time */
595 time_t write_time; /* last write time */
596 @END
599 /* Flush a file buffers */
600 @REQ(flush_file)
601 handle_t handle; /* handle to the file */
602 @END
605 /* Get information about a file */
606 @REQ(get_file_info)
607 handle_t handle; /* handle to the file */
608 @REPLY
609 int type; /* file type */
610 int attr; /* file attributes */
611 time_t access_time; /* last access time */
612 time_t write_time; /* last write time */
613 int size_high; /* file size */
614 int size_low; /* file size */
615 int links; /* number of links */
616 int index_high; /* unique index */
617 int index_low; /* unique index */
618 unsigned int serial; /* volume serial number */
619 @END
622 /* Lock a region of a file */
623 @REQ(lock_file)
624 handle_t handle; /* handle to the file */
625 unsigned int offset_low; /* offset of start of lock */
626 unsigned int offset_high; /* offset of start of lock */
627 unsigned int count_low; /* count of bytes to lock */
628 unsigned int count_high; /* count of bytes to lock */
629 @END
632 /* Unlock a region of a file */
633 @REQ(unlock_file)
634 handle_t handle; /* handle to the file */
635 unsigned int offset_low; /* offset of start of unlock */
636 unsigned int offset_high; /* offset of start of unlock */
637 unsigned int count_low; /* count of bytes to unlock */
638 unsigned int count_high; /* count of bytes to unlock */
639 @END
642 /* Create an anonymous pipe */
643 @REQ(create_pipe)
644 int inherit; /* inherit flag */
645 @REPLY
646 handle_t handle_read; /* handle to the read-side of the pipe */
647 handle_t handle_write; /* handle to the write-side of the pipe */
648 @END
651 /* Create a socket */
652 @REQ(create_socket)
653 unsigned int access; /* wanted access rights */
654 int inherit; /* inherit flag */
655 int family; /* family, see socket manpage */
656 int type; /* type, see socket manpage */
657 int protocol; /* protocol, see socket manpage */
658 unsigned int flags; /* socket flags */
659 @REPLY
660 handle_t handle; /* handle to the new socket */
661 @END
664 /* Accept a socket */
665 @REQ(accept_socket)
666 handle_t lhandle; /* handle to the listening socket */
667 unsigned int access; /* wanted access rights */
668 int inherit; /* inherit flag */
669 @REPLY
670 handle_t handle; /* handle to the new socket */
671 @END
674 /* Set socket event parameters */
675 @REQ(set_socket_event)
676 handle_t handle; /* handle to the socket */
677 unsigned int mask; /* event mask */
678 handle_t event; /* event object */
679 @END
682 /* Get socket event parameters */
683 @REQ(get_socket_event)
684 handle_t handle; /* handle to the socket */
685 int service; /* clear pending? */
686 handle_t s_event; /* "expected" event object */
687 handle_t c_event; /* event to clear */
688 @REPLY
689 unsigned int mask; /* event mask */
690 unsigned int pmask; /* pending events */
691 unsigned int state; /* status bits */
692 VARARG(errors,ints); /* event errors */
693 @END
696 /* Reenable pending socket events */
697 @REQ(enable_socket_event)
698 handle_t handle; /* handle to the socket */
699 unsigned int mask; /* events to re-enable */
700 unsigned int sstate; /* status bits to set */
701 unsigned int cstate; /* status bits to clear */
702 @END
705 /* Allocate a console (only used by a console renderer) */
706 @REQ(alloc_console)
707 unsigned int access; /* wanted access rights */
708 int inherit; /* inherit flag */
709 void* pid; /* pid of process which shall be attached to the console */
710 @REPLY
711 handle_t handle_in; /* handle to console input */
712 handle_t event; /* handle to renderer events change notification */
713 @END
716 /* Free the console of the current process */
717 @REQ(free_console)
718 @END
721 #define CONSOLE_RENDERER_NONE_EVENT 0x00
722 #define CONSOLE_RENDERER_TITLE_EVENT 0x01
723 #define CONSOLE_RENDERER_ACTIVE_SB_EVENT 0x02
724 #define CONSOLE_RENDERER_SB_RESIZE_EVENT 0x03
725 #define CONSOLE_RENDERER_UPDATE_EVENT 0x04
726 #define CONSOLE_RENDERER_CURSOR_POS_EVENT 0x05
727 #define CONSOLE_RENDERER_CURSOR_GEOM_EVENT 0x06
728 #define CONSOLE_RENDERER_DISPLAY_EVENT 0x07
729 #define CONSOLE_RENDERER_EXIT_EVENT 0x08
730 struct console_renderer_event
732 short event;
733 union
735 struct update
737 short top;
738 short bottom;
739 } update;
740 struct resize
742 short width;
743 short height;
744 } resize;
745 struct cursor_pos
747 short x;
748 short y;
749 } cursor_pos;
750 struct cursor_geom
752 short visible;
753 short size;
754 } cursor_geom;
755 struct display
757 short left;
758 short top;
759 short width;
760 short height;
761 } display;
762 } u;
765 /* retrieve console events for the renderer */
766 @REQ(get_console_renderer_events)
767 handle_t handle; /* handle to console input events */
768 @REPLY
769 VARARG(data,bytes); /* the various console_renderer_events */
770 @END
773 /* Open a handle to the process console */
774 @REQ(open_console)
775 int from; /* 0 (resp 1) input (resp output) of current process console */
776 /* otherwise console_in handle to get active screen buffer? */
777 unsigned int access; /* wanted access rights */
778 int inherit; /* inherit flag */
779 int share; /* share mask (only for output handles) */
780 @REPLY
781 handle_t handle; /* handle to the console */
782 @END
785 /* Get a console mode (input or output) */
786 @REQ(get_console_mode)
787 handle_t handle; /* handle to the console */
788 @REPLY
789 int mode; /* console mode */
790 @END
793 /* Set a console mode (input or output) */
794 @REQ(set_console_mode)
795 handle_t handle; /* handle to the console */
796 int mode; /* console mode */
797 @END
800 /* Set info about a console (input only) */
801 @REQ(set_console_input_info)
802 handle_t handle; /* handle to console input, or 0 for process' console */
803 int mask; /* setting mask (see below) */
804 handle_t active_sb; /* active screen buffer */
805 int history_mode; /* whether we duplicate lines in history */
806 int history_size; /* number of lines in history */
807 VARARG(title,unicode_str); /* console title */
808 @END
809 #define SET_CONSOLE_INPUT_INFO_ACTIVE_SB 0x01
810 #define SET_CONSOLE_INPUT_INFO_TITLE 0x02
811 #define SET_CONSOLE_INPUT_INFO_HISTORY_MODE 0x04
812 #define SET_CONSOLE_INPUT_INFO_HISTORY_SIZE 0x08
815 /* Get info about a console (input only) */
816 @REQ(get_console_input_info)
817 handle_t handle; /* handle to console input, or 0 for process' console */
818 @REPLY
819 int history_mode; /* whether we duplicate lines in history */
820 int history_size; /* number of lines in history */
821 int history_index; /* number of used lines in history */
822 VARARG(title,unicode_str); /* console title */
823 @END
826 /* appends a string to console's history */
827 @REQ(append_console_input_history)
828 handle_t handle; /* handle to console input, or 0 for process' console */
829 VARARG(line,unicode_str); /* line to add */
830 @END
833 /* appends a string to console's history */
834 @REQ(get_console_input_history)
835 handle_t handle; /* handle to console input, or 0 for process' console */
836 int index; /* index to get line from */
837 @REPLY
838 int total; /* total length of line in Unicode chars */
839 VARARG(line,unicode_str); /* line to add */
840 @END
843 /* creates a new screen buffer on process' console */
844 @REQ(create_console_output)
845 handle_t handle_in; /* handle to console input, or 0 for process' console */
846 int access; /* wanted access rights */
847 int share; /* sharing credentials */
848 int inherit; /* inherit flag */
849 @REPLY
850 handle_t handle_out; /* handle to the screen buffer */
851 @END
854 /* Set info about a console (output only) */
855 @REQ(set_console_output_info)
856 handle_t handle; /* handle to the console */
857 int mask; /* setting mask (see below) */
858 short int cursor_size; /* size of cursor (percentage filled) */
859 short int cursor_visible;/* cursor visibility flag */
860 short int cursor_x; /* position of cursor (x, y) */
861 short int cursor_y;
862 short int width; /* width of the screen buffer */
863 short int height; /* height of the screen buffer */
864 short int attr; /* default attribute */
865 short int win_left; /* window actually displayed by renderer */
866 short int win_top; /* the rect area is expressed withing the */
867 short int win_right; /* boundaries of the screen buffer */
868 short int win_bottom;
869 short int max_width; /* maximum size (width x height) for the window */
870 short int max_height;
871 @END
872 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x01
873 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x02
874 #define SET_CONSOLE_OUTPUT_INFO_SIZE 0x04
875 #define SET_CONSOLE_OUTPUT_INFO_ATTR 0x08
876 #define SET_CONSOLE_OUTPUT_INFO_DISPLAY_WINDOW 0x10
877 #define SET_CONSOLE_OUTPUT_INFO_MAX_SIZE 0x20
880 /* Get info about a console (output only) */
881 @REQ(get_console_output_info)
882 handle_t handle; /* handle to the console */
883 @REPLY
884 short int cursor_size; /* size of cursor (percentage filled) */
885 short int cursor_visible;/* cursor visibility flag */
886 short int cursor_x; /* position of cursor (x, y) */
887 short int cursor_y;
888 short int width; /* width of the screen buffer */
889 short int height; /* height of the screen buffer */
890 short int attr; /* default attribute */
891 short int win_left; /* window actually displayed by renderer */
892 short int win_top; /* the rect area is expressed withing the */
893 short int win_right; /* boundaries of the screen buffer */
894 short int win_bottom;
895 short int max_width; /* maximum size (width x height) for the window */
896 short int max_height;
897 @END
899 /* Add input records to a console input queue */
900 @REQ(write_console_input)
901 handle_t handle; /* handle to the console input */
902 VARARG(rec,input_records); /* input records */
903 @REPLY
904 int written; /* number of records written */
905 @END
908 /* Fetch input records from a console input queue */
909 @REQ(read_console_input)
910 handle_t handle; /* handle to the console input */
911 int flush; /* flush the retrieved records from the queue? */
912 @REPLY
913 int read; /* number of records read */
914 VARARG(rec,input_records); /* input records */
915 @END
918 /* write data (chars and/or attributes) in a screen buffer */
919 @REQ(write_console_output)
920 handle_t handle; /* handle to the console output */
921 int x; /* position where to start writing */
922 int y;
923 int mode; /* char info (see below) */
924 int wrap; /* wrap around at end of line? */
925 VARARG(data,bytes); /* info to write */
926 @REPLY
927 int written; /* number of char infos actually written */
928 int width; /* width of screen buffer */
929 int height; /* height of screen buffer */
930 @END
931 enum char_info_mode
933 CHAR_INFO_MODE_TEXT, /* characters only */
934 CHAR_INFO_MODE_ATTR, /* attributes only */
935 CHAR_INFO_MODE_TEXTATTR, /* both characters and attributes */
936 CHAR_INFO_MODE_TEXTSTDATTR /* characters but use standard attributes */
940 /* fill a screen buffer with constant data (chars and/or attributes) */
941 @REQ(fill_console_output)
942 handle_t handle; /* handle to the console output */
943 int x; /* position where to start writing */
944 int y;
945 int mode; /* char info mode */
946 int count; /* number to write */
947 int wrap; /* wrap around at end of line? */
948 char_info_t data; /* data to write */
949 @REPLY
950 int written; /* number of char infos actually written */
951 @END
954 /* read data (chars and/or attributes) from a screen buffer */
955 @REQ(read_console_output)
956 handle_t handle; /* handle to the console output */
957 int x; /* position (x,y) where to start reading */
958 int y;
959 int mode; /* char info mode */
960 int wrap; /* wrap around at end of line? */
961 @REPLY
962 int width; /* width of screen buffer */
963 int height; /* height of screen buffer */
964 VARARG(data,bytes);
965 @END
967 /* move a rect (of data) in screen buffer content */
968 @REQ(move_console_output)
969 handle_t handle; /* handle to the console output */
970 short int x_src; /* position (x, y) of rect to start moving from */
971 short int y_src;
972 short int x_dst; /* position (x, y) of rect to move to */
973 short int y_dst;
974 short int w; /* size of the rect (width, height) to move */
975 short int h;
976 @END
979 /* Create a change notification */
980 @REQ(create_change_notification)
981 int subtree; /* watch all the subtree */
982 int filter; /* notification filter */
983 @REPLY
984 handle_t handle; /* handle to the change notification */
985 @END
988 /* Create a file mapping */
989 @REQ(create_mapping)
990 int size_high; /* mapping size */
991 int size_low; /* mapping size */
992 int protect; /* protection flags (see below) */
993 int inherit; /* inherit flag */
994 handle_t file_handle; /* file handle */
995 VARARG(name,unicode_str); /* object name */
996 @REPLY
997 handle_t handle; /* handle to the mapping */
998 @END
999 /* protection flags */
1000 #define VPROT_READ 0x01
1001 #define VPROT_WRITE 0x02
1002 #define VPROT_EXEC 0x04
1003 #define VPROT_WRITECOPY 0x08
1004 #define VPROT_GUARD 0x10
1005 #define VPROT_NOCACHE 0x20
1006 #define VPROT_COMMITTED 0x40
1007 #define VPROT_IMAGE 0x80
1010 /* Open a mapping */
1011 @REQ(open_mapping)
1012 unsigned int access; /* wanted access rights */
1013 int inherit; /* inherit flag */
1014 VARARG(name,unicode_str); /* object name */
1015 @REPLY
1016 handle_t handle; /* handle to the mapping */
1017 @END
1020 /* Get information about a file mapping */
1021 @REQ(get_mapping_info)
1022 handle_t handle; /* handle to the mapping */
1023 @REPLY
1024 int size_high; /* mapping size */
1025 int size_low; /* mapping size */
1026 int protect; /* protection flags */
1027 int header_size; /* header size (for VPROT_IMAGE mapping) */
1028 void* base; /* default base addr (for VPROT_IMAGE mapping) */
1029 handle_t shared_file; /* shared mapping file handle */
1030 int shared_size; /* shared mapping size */
1031 int drive_type; /* type of drive the file is on */
1032 @END
1035 /* Create a device */
1036 @REQ(create_device)
1037 unsigned int access; /* wanted access rights */
1038 int inherit; /* inherit flag */
1039 int id; /* client private id */
1040 @REPLY
1041 handle_t handle; /* handle to the device */
1042 @END
1045 /* Create a snapshot */
1046 @REQ(create_snapshot)
1047 int inherit; /* inherit flag */
1048 int flags; /* snapshot flags (TH32CS_*) */
1049 void* pid; /* process id */
1050 @REPLY
1051 handle_t handle; /* handle to the snapshot */
1052 @END
1055 /* Get the next process from a snapshot */
1056 @REQ(next_process)
1057 handle_t handle; /* handle to the snapshot */
1058 int reset; /* reset snapshot position? */
1059 @REPLY
1060 int count; /* process usage count */
1061 void* pid; /* process id */
1062 int threads; /* number of threads */
1063 int priority; /* process priority */
1064 @END
1067 /* Get the next thread from a snapshot */
1068 @REQ(next_thread)
1069 handle_t handle; /* handle to the snapshot */
1070 int reset; /* reset snapshot position? */
1071 @REPLY
1072 int count; /* thread usage count */
1073 void* pid; /* process id */
1074 void* tid; /* thread id */
1075 int base_pri; /* base priority */
1076 int delta_pri; /* delta priority */
1077 @END
1080 /* Get the next module from a snapshot */
1081 @REQ(next_module)
1082 handle_t handle; /* handle to the snapshot */
1083 int reset; /* reset snapshot position? */
1084 @REPLY
1085 void* pid; /* process id */
1086 void* base; /* module base address */
1087 @END
1090 /* Wait for a debug event */
1091 @REQ(wait_debug_event)
1092 int get_handle; /* should we alloc a handle for waiting? */
1093 @REPLY
1094 void* pid; /* process id */
1095 void* tid; /* thread id */
1096 handle_t wait; /* wait handle if no event ready */
1097 VARARG(event,debug_event); /* debug event data */
1098 @END
1101 /* Queue an exception event */
1102 @REQ(queue_exception_event)
1103 int first; /* first chance exception? */
1104 VARARG(record,exc_event); /* thread context followed by exception record */
1105 @REPLY
1106 handle_t handle; /* handle to the queued event */
1107 @END
1110 /* Retrieve the status of an exception event */
1111 @REQ(get_exception_status)
1112 handle_t handle; /* handle to the queued event */
1113 @REPLY
1114 int status; /* event continuation status */
1115 VARARG(context,context); /* modified thread context */
1116 @END
1119 /* Send an output string to the debugger */
1120 @REQ(output_debug_string)
1121 void* string; /* string to display (in debugged process address space) */
1122 int unicode; /* is it Unicode? */
1123 int length; /* string length */
1124 @END
1127 /* Continue a debug event */
1128 @REQ(continue_debug_event)
1129 void* pid; /* process id to continue */
1130 void* tid; /* thread id to continue */
1131 int status; /* continuation status */
1132 @END
1135 /* Start/stop debugging an existing process */
1136 @REQ(debug_process)
1137 void* pid; /* id of the process to debug */
1138 int attach; /* 1=attaching / 0=detaching from the process */
1139 @END
1142 /* Simulate a breakpoint in a process */
1143 @REQ(debug_break)
1144 handle_t handle; /* process handle */
1145 @REPLY
1146 int self; /* was it the caller itself? */
1147 @END
1150 /* Set debugger kill on exit flag */
1151 @REQ(set_debugger_kill_on_exit)
1152 int kill_on_exit; /* 0=detach/1=kill debuggee when debugger dies */
1153 @END
1156 /* Read data from a process address space */
1157 @REQ(read_process_memory)
1158 handle_t handle; /* process handle */
1159 void* addr; /* addr to read from */
1160 @REPLY
1161 VARARG(data,bytes); /* result data */
1162 @END
1165 /* Write data to a process address space */
1166 @REQ(write_process_memory)
1167 handle_t handle; /* process handle */
1168 void* addr; /* addr to write to (must be int-aligned) */
1169 unsigned int first_mask; /* mask for first word */
1170 unsigned int last_mask; /* mask for last word */
1171 VARARG(data,bytes); /* data to write */
1172 @END
1175 /* Create a registry key */
1176 @REQ(create_key)
1177 handle_t parent; /* handle to the parent key */
1178 unsigned int access; /* desired access rights */
1179 unsigned int options; /* creation options */
1180 time_t modif; /* last modification time */
1181 size_t namelen; /* length of key name in bytes */
1182 VARARG(name,unicode_str,namelen); /* key name */
1183 VARARG(class,unicode_str); /* class name */
1184 @REPLY
1185 handle_t hkey; /* handle to the created key */
1186 int created; /* has it been newly created? */
1187 @END
1189 /* Open a registry key */
1190 @REQ(open_key)
1191 handle_t parent; /* handle to the parent key */
1192 unsigned int access; /* desired access rights */
1193 VARARG(name,unicode_str); /* key name */
1194 @REPLY
1195 handle_t hkey; /* handle to the open key */
1196 @END
1199 /* Delete a registry key */
1200 @REQ(delete_key)
1201 handle_t hkey; /* handle to the key */
1202 @END
1205 /* Enumerate registry subkeys */
1206 @REQ(enum_key)
1207 handle_t hkey; /* handle to registry key */
1208 int index; /* index of subkey (or -1 for current key) */
1209 int info_class; /* requested information class */
1210 @REPLY
1211 int subkeys; /* number of subkeys */
1212 int max_subkey; /* longest subkey name */
1213 int max_class; /* longest class name */
1214 int values; /* number of values */
1215 int max_value; /* longest value name */
1216 int max_data; /* longest value data */
1217 time_t modif; /* last modification time */
1218 size_t total; /* total length needed for full name and class */
1219 size_t namelen; /* length of key name in bytes */
1220 VARARG(name,unicode_str,namelen); /* key name */
1221 VARARG(class,unicode_str); /* class name */
1222 @END
1225 /* Set a value of a registry key */
1226 @REQ(set_key_value)
1227 handle_t hkey; /* handle to registry key */
1228 int type; /* value type */
1229 size_t namelen; /* length of value name in bytes */
1230 VARARG(name,unicode_str,namelen); /* value name */
1231 VARARG(data,bytes); /* value data */
1232 @END
1235 /* Retrieve the value of a registry key */
1236 @REQ(get_key_value)
1237 handle_t hkey; /* handle to registry key */
1238 VARARG(name,unicode_str); /* value name */
1239 @REPLY
1240 int type; /* value type */
1241 size_t total; /* total length needed for data */
1242 VARARG(data,bytes); /* value data */
1243 @END
1246 /* Enumerate a value of a registry key */
1247 @REQ(enum_key_value)
1248 handle_t hkey; /* handle to registry key */
1249 int index; /* value index */
1250 int info_class; /* requested information class */
1251 @REPLY
1252 int type; /* value type */
1253 size_t total; /* total length needed for full name and data */
1254 size_t namelen; /* length of value name in bytes */
1255 VARARG(name,unicode_str,namelen); /* value name */
1256 VARARG(data,bytes); /* value data */
1257 @END
1260 /* Delete a value of a registry key */
1261 @REQ(delete_key_value)
1262 handle_t hkey; /* handle to registry key */
1263 VARARG(name,unicode_str); /* value name */
1264 @END
1267 /* Load a registry branch from a file */
1268 @REQ(load_registry)
1269 handle_t hkey; /* root key to load to */
1270 handle_t file; /* file to load from */
1271 VARARG(name,unicode_str); /* subkey name */
1272 @END
1275 /* Save a registry branch to a file */
1276 @REQ(save_registry)
1277 handle_t hkey; /* key to save */
1278 handle_t file; /* file to save to */
1279 @END
1282 /* Save a registry branch at server exit */
1283 @REQ(save_registry_atexit)
1284 handle_t hkey; /* key to save */
1285 VARARG(file,string); /* file to save to */
1286 @END
1289 /* Set the current and saving level for the registry */
1290 @REQ(set_registry_levels)
1291 int current; /* new current level */
1292 int saving; /* new saving level */
1293 int period; /* duration between periodic saves (milliseconds) */
1294 @END
1297 /* Create a waitable timer */
1298 @REQ(create_timer)
1299 int inherit; /* inherit flag */
1300 int manual; /* manual reset */
1301 VARARG(name,unicode_str); /* object name */
1302 @REPLY
1303 handle_t handle; /* handle to the timer */
1304 @END
1307 /* Open a waitable timer */
1308 @REQ(open_timer)
1309 unsigned int access; /* wanted access rights */
1310 int inherit; /* inherit flag */
1311 VARARG(name,unicode_str); /* object name */
1312 @REPLY
1313 handle_t handle; /* handle to the timer */
1314 @END
1316 /* Set a waitable timer */
1317 @REQ(set_timer)
1318 handle_t handle; /* handle to the timer */
1319 int sec; /* next expiration absolute time */
1320 int usec; /* next expiration absolute time */
1321 int period; /* timer period in ms */
1322 void* callback; /* callback function */
1323 void* arg; /* callback argument */
1324 @END
1326 /* Cancel a waitable timer */
1327 @REQ(cancel_timer)
1328 handle_t handle; /* handle to the timer */
1329 @END
1332 /* Retrieve the current context of a thread */
1333 @REQ(get_thread_context)
1334 handle_t handle; /* thread handle */
1335 unsigned int flags; /* context flags */
1336 @REPLY
1337 VARARG(context,context); /* thread context */
1338 @END
1341 /* Set the current context of a thread */
1342 @REQ(set_thread_context)
1343 handle_t handle; /* thread handle */
1344 unsigned int flags; /* context flags */
1345 VARARG(context,context); /* thread context */
1346 @END
1349 /* Fetch a selector entry for a thread */
1350 @REQ(get_selector_entry)
1351 handle_t handle; /* thread handle */
1352 int entry; /* LDT entry */
1353 @REPLY
1354 unsigned int base; /* selector base */
1355 unsigned int limit; /* selector limit */
1356 unsigned char flags; /* selector flags */
1357 @END
1360 /* Add an atom */
1361 @REQ(add_atom)
1362 int local; /* is atom in local process table? */
1363 VARARG(name,unicode_str); /* atom name */
1364 @REPLY
1365 atom_t atom; /* resulting atom */
1366 @END
1369 /* Delete an atom */
1370 @REQ(delete_atom)
1371 atom_t atom; /* atom handle */
1372 int local; /* is atom in local process table? */
1373 @END
1376 /* Find an atom */
1377 @REQ(find_atom)
1378 int local; /* is atom in local process table? */
1379 VARARG(name,unicode_str); /* atom name */
1380 @REPLY
1381 atom_t atom; /* atom handle */
1382 @END
1385 /* Get an atom name */
1386 @REQ(get_atom_name)
1387 atom_t atom; /* atom handle */
1388 int local; /* is atom in local process table? */
1389 @REPLY
1390 int count; /* atom lock count */
1391 VARARG(name,unicode_str); /* atom name */
1392 @END
1395 /* Init the process atom table */
1396 @REQ(init_atom_table)
1397 int entries; /* number of entries */
1398 @END
1401 /* Get the message queue of the current thread */
1402 @REQ(get_msg_queue)
1403 @REPLY
1404 handle_t handle; /* handle to the queue */
1405 @END
1408 /* Set the current message queue wakeup mask */
1409 @REQ(set_queue_mask)
1410 unsigned int wake_mask; /* wakeup bits mask */
1411 unsigned int changed_mask; /* changed bits mask */
1412 int skip_wait; /* will we skip waiting if signaled? */
1413 @REPLY
1414 unsigned int wake_bits; /* current wake bits */
1415 unsigned int changed_bits; /* current changed bits */
1416 @END
1419 /* Get the current message queue status */
1420 @REQ(get_queue_status)
1421 int clear; /* should we clear the change bits? */
1422 @REPLY
1423 unsigned int wake_bits; /* wake bits */
1424 unsigned int changed_bits; /* changed bits since last time */
1425 @END
1428 /* Wait for a process to start waiting on input */
1429 @REQ(wait_input_idle)
1430 handle_t handle; /* process handle */
1431 int timeout; /* timeout */
1432 @REPLY
1433 handle_t event; /* handle to idle event */
1434 @END
1437 /* Send a message to a thread queue */
1438 @REQ(send_message)
1439 void* id; /* thread id */
1440 int type; /* message type (see below) */
1441 user_handle_t win; /* window handle */
1442 unsigned int msg; /* message code */
1443 unsigned int wparam; /* parameters */
1444 unsigned int lparam; /* parameters */
1445 int x; /* x position */
1446 int y; /* y position */
1447 unsigned int time; /* message time */
1448 unsigned int info; /* extra info */
1449 int timeout; /* timeout for reply */
1450 VARARG(data,bytes); /* message data for sent messages */
1451 @END
1453 enum message_type
1455 MSG_ASCII, /* Ascii message (from SendMessageA) */
1456 MSG_UNICODE, /* Unicode message (from SendMessageW) */
1457 MSG_NOTIFY, /* notify message (from SendNotifyMessageW), always Unicode */
1458 MSG_CALLBACK, /* callback message (from SendMessageCallbackW), always Unicode */
1459 MSG_OTHER_PROCESS, /* sent from other process, may include vararg data, always Unicode */
1460 MSG_POSTED, /* posted message (from PostMessageW), always Unicode */
1461 MSG_HARDWARE_RAW, /* raw hardware message */
1462 MSG_HARDWARE_COOKED /* cooked hardware message */
1466 /* Get a message from the current queue */
1467 @REQ(get_message)
1468 int flags; /* see below */
1469 user_handle_t get_win; /* window handle to get */
1470 unsigned int get_first; /* first message code to get */
1471 unsigned int get_last; /* last message code to get */
1472 @REPLY
1473 int type; /* message type */
1474 user_handle_t win; /* window handle */
1475 unsigned int msg; /* message code */
1476 unsigned int wparam; /* parameters */
1477 unsigned int lparam; /* parameters */
1478 int x; /* x position */
1479 int y; /* y position */
1480 unsigned int time; /* message time */
1481 unsigned int info; /* extra info */
1482 size_t total; /* total size of extra data */
1483 VARARG(data,bytes); /* message data for sent messages */
1484 @END
1485 #define GET_MSG_REMOVE 1 /* remove the message */
1486 #define GET_MSG_SENT_ONLY 2 /* only get sent messages */
1487 #define GET_MSG_REMOVE_LAST 4 /* remove last message returned before checking for a new one */
1489 /* Reply to a sent message */
1490 @REQ(reply_message)
1491 unsigned int result; /* message result */
1492 int remove; /* should we remove the message? */
1493 VARARG(data,bytes); /* message data for sent messages */
1494 @END
1497 /* Retrieve the reply for the last message sent */
1498 @REQ(get_message_reply)
1499 int cancel; /* cancel message if not ready? */
1500 @REPLY
1501 unsigned int result; /* message result */
1502 VARARG(data,bytes); /* message data for sent messages */
1503 @END
1506 /* Set a window timer */
1507 @REQ(set_win_timer)
1508 user_handle_t win; /* window handle */
1509 unsigned int msg; /* message to post */
1510 unsigned int id; /* timer id */
1511 unsigned int rate; /* timer rate in ms */
1512 unsigned int lparam; /* message lparam (callback proc) */
1513 @END
1516 /* Kill a window timer */
1517 @REQ(kill_win_timer)
1518 user_handle_t win; /* window handle */
1519 unsigned int msg; /* message to post */
1520 unsigned int id; /* timer id */
1521 @END
1524 /* Open a serial port */
1525 @REQ(create_serial)
1526 unsigned int access; /* wanted access rights */
1527 int inherit; /* inherit flag */
1528 unsigned int attributes; /* eg. FILE_FLAG_OVERLAPPED */
1529 unsigned int sharing; /* sharing flags */
1530 VARARG(name,string); /* file name */
1531 @REPLY
1532 handle_t handle; /* handle to the port */
1533 @END
1536 /* Retrieve info about a serial port */
1537 @REQ(get_serial_info)
1538 handle_t handle; /* handle to comm port */
1539 @REPLY
1540 unsigned int readinterval;
1541 unsigned int readconst;
1542 unsigned int readmult;
1543 unsigned int writeconst;
1544 unsigned int writemult;
1545 unsigned int eventmask;
1546 unsigned int commerror;
1547 @END
1550 /* Set info about a serial port */
1551 @REQ(set_serial_info)
1552 handle_t handle; /* handle to comm port */
1553 int flags; /* bitmask to set values (see below) */
1554 unsigned int readinterval;
1555 unsigned int readconst;
1556 unsigned int readmult;
1557 unsigned int writeconst;
1558 unsigned int writemult;
1559 unsigned int eventmask;
1560 unsigned int commerror;
1561 @END
1562 #define SERIALINFO_SET_TIMEOUTS 0x01
1563 #define SERIALINFO_SET_MASK 0x02
1564 #define SERIALINFO_SET_ERROR 0x04
1567 /* Create/Destroy an async I/O */
1568 @REQ(register_async)
1569 handle_t handle; /* handle to comm port, socket or file */
1570 void* func;
1571 int type;
1572 void* overlapped;
1573 int count;
1574 unsigned int status;
1575 @END
1576 #define ASYNC_TYPE_NONE 0x00
1577 #define ASYNC_TYPE_READ 0x01
1578 #define ASYNC_TYPE_WRITE 0x02
1579 #define ASYNC_TYPE_WAIT 0x03
1582 /* Create a named pipe */
1583 @REQ(create_named_pipe)
1584 unsigned int openmode;
1585 unsigned int pipemode;
1586 unsigned int maxinstances;
1587 unsigned int outsize;
1588 unsigned int insize;
1589 unsigned int timeout;
1590 VARARG(name,unicode_str); /* pipe name */
1591 @REPLY
1592 handle_t handle; /* handle to the pipe */
1593 @END
1596 /* Open an existing named pipe */
1597 @REQ(open_named_pipe)
1598 unsigned int access;
1599 VARARG(name,unicode_str); /* pipe name */
1600 @REPLY
1601 handle_t handle; /* handle to the pipe */
1602 @END
1605 /* Connect to a named pipe */
1606 @REQ(connect_named_pipe)
1607 handle_t handle;
1608 void* overlapped;
1609 void* func;
1610 @END
1613 /* Wait for a named pipe */
1614 @REQ(wait_named_pipe)
1615 unsigned int timeout;
1616 void* overlapped;
1617 void* func;
1618 VARARG(name,unicode_str); /* pipe name */
1619 @END
1622 /* Disconnect a named pipe */
1623 @REQ(disconnect_named_pipe)
1624 handle_t handle;
1625 @END
1628 @REQ(get_named_pipe_info)
1629 handle_t handle;
1630 @REPLY
1631 unsigned int flags;
1632 unsigned int maxinstances;
1633 unsigned int outsize;
1634 unsigned int insize;
1635 @END
1638 @REQ(create_smb)
1639 int fd;
1640 unsigned int tree_id;
1641 unsigned int user_id;
1642 unsigned int file_id;
1643 unsigned int dialect;
1644 @REPLY
1645 handle_t handle;
1646 @END
1649 @REQ(get_smb_info)
1650 handle_t handle;
1651 unsigned int flags;
1652 unsigned int offset;
1653 @REPLY
1654 unsigned int tree_id;
1655 unsigned int user_id;
1656 unsigned int dialect;
1657 unsigned int file_id;
1658 unsigned int offset;
1659 @END
1660 #define SMBINFO_SET_OFFSET 0x01
1663 /* Create a window */
1664 @REQ(create_window)
1665 user_handle_t parent; /* parent window */
1666 user_handle_t owner; /* owner window */
1667 atom_t atom; /* class atom */
1668 @REPLY
1669 user_handle_t handle; /* created window */
1670 @END
1673 /* Link a window into the tree */
1674 @REQ(link_window)
1675 user_handle_t handle; /* handle to the window */
1676 user_handle_t parent; /* handle to the parent */
1677 user_handle_t previous; /* previous child in Z-order */
1678 @REPLY
1679 user_handle_t full_parent; /* full handle of new parent */
1680 @END
1683 /* Destroy a window */
1684 @REQ(destroy_window)
1685 user_handle_t handle; /* handle to the window */
1686 @END
1689 /* Set a window owner */
1690 @REQ(set_window_owner)
1691 user_handle_t handle; /* handle to the window */
1692 user_handle_t owner; /* new owner */
1693 @REPLY
1694 user_handle_t full_owner; /* full handle of new owner */
1695 @END
1698 /* Get information from a window handle */
1699 @REQ(get_window_info)
1700 user_handle_t handle; /* handle to the window */
1701 @REPLY
1702 user_handle_t full_handle; /* full 32-bit handle */
1703 void* pid; /* process owning the window */
1704 void* tid; /* thread owning the window */
1705 atom_t atom; /* class atom */
1706 @END
1709 /* Set some information in a window */
1710 @REQ(set_window_info)
1711 user_handle_t handle; /* handle to the window */
1712 unsigned int flags; /* flags for fields to set (see below) */
1713 unsigned int style; /* window style */
1714 unsigned int ex_style; /* window extended style */
1715 unsigned int id; /* window id */
1716 void* instance; /* creator instance */
1717 void* user_data; /* user-specific data */
1718 @REPLY
1719 unsigned int old_style; /* old window style */
1720 unsigned int old_ex_style; /* old window extended style */
1721 unsigned int old_id; /* old window id */
1722 void* old_instance; /* old creator instance */
1723 void* old_user_data; /* old user-specific data */
1724 @END
1725 #define SET_WIN_STYLE 0x01
1726 #define SET_WIN_EXSTYLE 0x02
1727 #define SET_WIN_ID 0x04
1728 #define SET_WIN_INSTANCE 0x08
1729 #define SET_WIN_USERDATA 0x10
1732 /* Get a list of the window parents, up to the root of the tree */
1733 @REQ(get_window_parents)
1734 user_handle_t handle; /* handle to the window */
1735 @REPLY
1736 int count; /* total count of parents */
1737 VARARG(parents,user_handles); /* parent handles */
1738 @END
1741 /* Get a list of the window children */
1742 @REQ(get_window_children)
1743 user_handle_t parent; /* parent window */
1744 atom_t atom; /* class atom for the listed children */
1745 void* tid; /* thread owning the listed children */
1746 @REPLY
1747 int count; /* total count of children */
1748 VARARG(children,user_handles); /* children handles */
1749 @END
1752 /* Get window tree information from a window handle */
1753 @REQ(get_window_tree)
1754 user_handle_t handle; /* handle to the window */
1755 @REPLY
1756 user_handle_t parent; /* parent window */
1757 user_handle_t owner; /* owner window */
1758 user_handle_t next_sibling; /* next sibling in Z-order */
1759 user_handle_t prev_sibling; /* prev sibling in Z-order */
1760 user_handle_t first_sibling; /* first sibling in Z-order */
1761 user_handle_t last_sibling; /* last sibling in Z-order */
1762 user_handle_t first_child; /* first child */
1763 user_handle_t last_child; /* last child */
1764 @END
1766 /* Set the window and client rectangles of a window */
1767 @REQ(set_window_rectangles)
1768 user_handle_t handle; /* handle to the window */
1769 rectangle_t window; /* window rectangle */
1770 rectangle_t client; /* client rectangle */
1771 @END
1774 /* Get the window and client rectangles of a window */
1775 @REQ(get_window_rectangles)
1776 user_handle_t handle; /* handle to the window */
1777 @REPLY
1778 rectangle_t window; /* window rectangle */
1779 rectangle_t client; /* client rectangle */
1780 @END
1783 /* Get the window text */
1784 @REQ(get_window_text)
1785 user_handle_t handle; /* handle to the window */
1786 @REPLY
1787 VARARG(text,unicode_str); /* window text */
1788 @END
1791 /* Set the window text */
1792 @REQ(set_window_text)
1793 user_handle_t handle; /* handle to the window */
1794 VARARG(text,unicode_str); /* window text */
1795 @END
1798 /* Increment the window paint count */
1799 @REQ(inc_window_paint_count)
1800 user_handle_t handle; /* handle to the window */
1801 int incr; /* increment (can be negative) */
1802 @END
1805 /* Get the coordinates offset between two windows */
1806 @REQ(get_windows_offset)
1807 user_handle_t from; /* handle to the first window */
1808 user_handle_t to; /* handle to the second window */
1809 @REPLY
1810 int x; /* x coordinate offset */
1811 int y; /* y coordinate offset */
1812 @END
1815 /* Set a window property */
1816 @REQ(set_window_property)
1817 user_handle_t window; /* handle to the window */
1818 atom_t atom; /* property atom (high-word set if it was a string) */
1819 int string; /* was atom a string originally? */
1820 handle_t handle; /* handle to store */
1821 @END
1824 /* Remove a window property */
1825 @REQ(remove_window_property)
1826 user_handle_t window; /* handle to the window */
1827 atom_t atom; /* property atom */
1828 @REPLY
1829 handle_t handle; /* handle stored in property */
1830 @END
1833 /* Get a window property */
1834 @REQ(get_window_property)
1835 user_handle_t window; /* handle to the window */
1836 atom_t atom; /* property atom */
1837 @REPLY
1838 handle_t handle; /* handle stored in property */
1839 @END
1842 /* Get the list of properties of a window */
1843 @REQ(get_window_properties)
1844 user_handle_t window; /* handle to the window */
1845 @REPLY
1846 int total; /* total number of properties */
1847 VARARG(props,properties); /* list of properties */
1848 @END