1 /*
2  * This file is part of gtkD.
3  *
4  * gtkD is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License
6  * as published by the Free Software Foundation; either version 3
7  * of the License, or (at your option) any later version, with
8  * some exceptions, please read the COPYING file.
9  *
10  * gtkD is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with gtkD; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
18  */
19  
20 // generated automatically - do not change
21 // find conversion definition on APILookup.txt
22 // implement new conversion functionalities on the wrap.utils pakage
23 
24 module gtkc.gdktypes;
25 
26 
27 public import gtkc.glibtypes;
28 public import gtkc.gobjecttypes;
29 public import gtkc.giotypes;
30 public import gtkc.pangotypes;
31 public import gtkc.gdkpixbuftypes;
32 
33 const int GDK_MAX_TIMECOORD_AXES = 128;
34 
35 alias Rectangle GdkRectangle;
36 
37 /**
38  * typedef cairo_rectangle_int_t GdkRectangle;
39  * Defines the position and size of a rectangle. It is identical to
40  * cairo_rectangle_int_t.
41  */
42 public alias cairo_rectangle_int_t Rectangle;
43 
44 /**
45  * typedef void GdkXEvent;	 /+* Can be cast to window system specific
46  * Used to represent native events (XEvents for the X11
47  * backend, MSGs for Win32).
48  */
49 public alias void GdkXEvent;
50 
51 enum GdkModifierIntent
52 {
53 	PRIMARY_ACCELERATOR,
54 	CONTEXT_MENU,
55 	EXTEND_SELECTION,
56 	MODIFY_SELECTION,
57 	NO_TEXT_INPUT,
58 	SHIFT_GROUP
59 }
60 public alias GdkModifierIntent ModifierIntent;
61 
62 /**
63  * Returned by gdk_device_grab(), gdk_pointer_grab() and gdk_keyboard_grab() to
64  * indicate success or the reason for the failure of the grab attempt.
65  * GDK_GRAB_SUCCESS
66  * the resource was successfully grabbed.
67  * GDK_GRAB_ALREADY_GRABBED
68  * the resource is actively grabbed by another client.
69  * GDK_GRAB_INVALID_TIME
70  * the resource was grabbed more recently than the
71  *  specified time.
72  * GDK_GRAB_NOT_VIEWABLE
73  * the grab window or the confine_to window are not
74  *  viewable.
75  * GDK_GRAB_FROZEN
76  * the resource is frozen by an active grab of another client.
77  */
78 public enum GdkGrabStatus
79 {
80 	SUCCESS = 0,
81 	ALREADY_GRABBED = 1,
82 	INVALID_TIME = 2,
83 	NOT_VIEWABLE = 3,
84 	FROZEN = 4
85 }
86 alias GdkGrabStatus GrabStatus;
87 
88 /**
89  * An enumeration describing the type of an input device in general terms.
90  * GDK_SOURCE_MOUSE
91  * the device is a mouse. (This will be reported for the core
92  *  pointer, even if it is something else, such as a trackball.)
93  * GDK_SOURCE_PEN
94  * the device is a stylus of a graphics tablet or similar device.
95  * GDK_SOURCE_ERASER
96  * the device is an eraser. Typically, this would be the other end
97  *  of a stylus on a graphics tablet.
98  * GDK_SOURCE_CURSOR
99  * the device is a graphics tablet "puck" or similar device.
100  * GDK_SOURCE_KEYBOARD
101  * the device is a keyboard.
102  * GDK_SOURCE_TOUCHSCREEN
103  * the device is a direct-input touch device, such
104  *  as a touchscreen or tablet. This device type has been added in 3.4.
105  * GDK_SOURCE_TOUCHPAD
106  * the device is an indirect touch device, such
107  *  as a touchpad. This device type has been added in 3.4.
108  */
109 public enum GdkInputSource
110 {
111 	SOURCE_MOUSE,
112 	SOURCE_PEN,
113 	SOURCE_ERASER,
114 	SOURCE_CURSOR,
115 	SOURCE_KEYBOARD,
116 	SOURCE_TOUCHSCREEN,
117 	SOURCE_TOUCHPAD
118 }
119 alias GdkInputSource InputSource;
120 
121 /**
122  * An enumeration that describes the mode of an input device.
123  * GDK_MODE_DISABLED
124  * the device is disabled and will not report any events.
125  * GDK_MODE_SCREEN
126  * the device is enabled. The device's coordinate space
127  *  maps to the entire screen.
128  * GDK_MODE_WINDOW
129  * the device is enabled. The device's coordinate space
130  *  is mapped to a single window. The manner in which this window
131  *  is chosen is undefined, but it will typically be the same
132  *  way in which the focus window for key events is determined.
133  */
134 public enum GdkInputMode
135 {
136 	MODE_DISABLED,
137 	MODE_SCREEN,
138 	MODE_WINDOW
139 }
140 alias GdkInputMode InputMode;
141 
142 /**
143  * An enumeration describing the way in which a device
144  * axis (valuator) maps onto the predefined valuator
145  * types that GTK+ understands.
146  * GDK_AXIS_IGNORE
147  * the axis is ignored.
148  * GDK_AXIS_X
149  * the axis is used as the x axis.
150  * GDK_AXIS_Y
151  * the axis is used as the y axis.
152  * GDK_AXIS_PRESSURE
153  * the axis is used for pressure information.
154  * GDK_AXIS_XTILT
155  * the axis is used for x tilt information.
156  * GDK_AXIS_YTILT
157  * the axis is used for y tilt information.
158  * GDK_AXIS_WHEEL
159  * the axis is used for wheel information.
160  * GDK_AXIS_LAST
161  * a constant equal to the numerically highest axis value.
162  */
163 public enum GdkAxisUse
164 {
165 	IGNORE,
166 	X,
167 	Y,
168 	PRESSURE,
169 	XTILT,
170 	YTILT,
171 	WHEEL,
172 	LAST
173 }
174 alias GdkAxisUse AxisUse;
175 
176 /**
177  * Indicates the device type. See above
178  * for more information about the meaning of these device types.
179  * GDK_DEVICE_TYPE_MASTER
180  * Device is a master (or virtual) device. There will
181  *  be an associated focus indicator on the screen.
182  * GDK_DEVICE_TYPE_SLAVE
183  * Device is a slave (or physical) device.
184  * GDK_DEVICE_TYPE_FLOATING
185  * Device is a physical device, currently not attached to
186  *  any virtual device.
187  */
188 public enum GdkDeviceType
189 {
190 	TYPE_MASTER,
191 	TYPE_SLAVE,
192 	TYPE_FLOATING
193 }
194 alias GdkDeviceType DeviceType;
195 
196 /**
197  * Defines how device grabs interact with other devices.
198  * GDK_OWNERSHIP_NONE
199  * All other devices' events are allowed.
200  * GDK_OWNERSHIP_WINDOW
201  * Other devices' events are blocked for the grab window.
202  * GDK_OWNERSHIP_APPLICATION
203  * Other devices' events are blocked for the whole application.
204  */
205 public enum GdkGrabOwnership
206 {
207 	OWNERSHIP_NONE,
208 	OWNERSHIP_WINDOW,
209 	OWNERSHIP_APPLICATION
210 }
211 alias GdkGrabOwnership GrabOwnership;
212 
213 /**
214  * An error code in the GDK_PIXBUF_ERROR domain. Many gdk-pixbuf;
215  * operations can cause errors in this domain, or in the G_FILE_ERROR
216  * domain.
217  * GDK_PIXBUF_ERROR_CORRUPT_IMAGE
218  * An image file was broken somehow.
219  * GDK_PIXBUF_ERROR_INSUFFICIENT_MEMORY
220  * Not enough memory.
221  * GDK_PIXBUF_ERROR_BAD_OPTION
222  * A bad option was passed to a pixbuf save module.
223  * GDK_PIXBUF_ERROR_UNKNOWN_TYPE
224  * Unknown image type.
225  * GDK_PIXBUF_ERROR_UNSUPPORTED_OPERATION
226  * Don't know how to perform the
227  *  given operation on the type of image at hand.
228  * GDK_PIXBUF_ERROR_FAILED
229  * Generic failure code, something went wrong.
230  */
231 public enum GdkPixbufError
232 {
233 	CORRUPT_IMAGE,
234 	/+* no mem to load image +/
235 	INSUFFICIENT_MEMORY,
236 	/+* bad option passed to save routine +/
237 	BAD_OPTION,
238 	/+* unsupported image type (sort of an ENOSYS) +/
239 	UNKNOWN_TYPE,
240 	/+* unsupported operation (load, save) for image type +/
241 	UNSUPPORTED_OPERATION,
242 	FAILED
243 }
244 alias GdkPixbufError PixbufError;
245 
246 /**
247  * This enumeration defines the color spaces that are supported by
248  * the gdk-pixbuf; library. Currently only RGB is supported.
249  * GDK_COLORSPACE_RGB
250  * Indicates a red/green/blue additive color space.
251  */
252 public enum GdkColorspace
253 {
254 	RGB
255 }
256 alias GdkColorspace Colorspace;
257 
258 /**
259  * These values can be passed to
260  * gdk_pixbuf_render_to_drawable_alpha() to control how the alpha
261  * channel of an image should be handled. This function can create a
262  * bilevel clipping mask (black and white) and use it while painting
263  * the image. In the future, when the X Window System gets an alpha
264  * channel extension, it will be possible to do full alpha
265  * compositing onto arbitrary drawables. For now both cases fall
266  * back to a bilevel clipping mask.
267  * GDK_PIXBUF_ALPHA_BILEVEL
268  * A bilevel clipping mask (black and white)
269  *  will be created and used to draw the image. Pixels below 0.5 opacity
270  *  will be considered fully transparent, and all others will be
271  *  considered fully opaque.
272  * GDK_PIXBUF_ALPHA_FULL
273  * For now falls back to GDK_PIXBUF_ALPHA_BILEVEL.
274  *  In the future it will do full alpha compositing.
275  */
276 public enum GdkPixbufAlphaMode
277 {
278 	BILEVEL,
279 	FULL
280 }
281 alias GdkPixbufAlphaMode PixbufAlphaMode;
282 
283 /**
284  * This enumeration describes the different interpolation modes that
285  *  can be used with the scaling functions. GDK_INTERP_NEAREST is
286  *  the fastest scaling method, but has horrible quality when
287  *  scaling down. GDK_INTERP_BILINEAR is the best choice if you
288  *  aren't sure what to choose, it has a good speed/quality balance.
289  * Note
290  * 	Cubic filtering is missing from the list; hyperbolic
291  * 	interpolation is just as fast and results in higher quality.
292  * GDK_INTERP_NEAREST
293  * Nearest neighbor sampling; this is the fastest
294  *  and lowest quality mode. Quality is normally unacceptable when scaling
295  *  down, but may be OK when scaling up.
296  * GDK_INTERP_TILES
297  * This is an accurate simulation of the PostScript
298  *  image operator without any interpolation enabled. Each pixel is
299  *  rendered as a tiny parallelogram of solid color, the edges of which
300  *  are implemented with antialiasing. It resembles nearest neighbor for
301  *  enlargement, and bilinear for reduction.
302  * GDK_INTERP_BILINEAR
303  * Best quality/speed balance; use this mode by
304  *  default. Bilinear interpolation. For enlargement, it is
305  *  equivalent to point-sampling the ideal bilinear-interpolated image.
306  *  For reduction, it is equivalent to laying down small tiles and
307  *  integrating over the coverage area.
308  * GDK_INTERP_HYPER
309  * This is the slowest and highest quality
310  *  reconstruction function. It is derived from the hyperbolic filters in
311  *  Wolberg's "Digital Image Warping", and is formally defined as the
312  *  hyperbolic-filter sampling the ideal hyperbolic-filter interpolated
313  *  image (the filter is designed to be idempotent for 1:1 pixel mapping).
314  */
315 public enum GdkInterpType
316 {
317 	NEAREST,
318 	TILES,
319 	BILINEAR,
320 	HYPER
321 }
322 alias GdkInterpType InterpType;
323 
324 /**
325  * The possible rotations which can be passed to gdk_pixbuf_rotate_simple().
326  * To make them easier to use, their numerical values are the actual degrees.
327  * GDK_PIXBUF_ROTATE_NONE
328  * No rotation.
329  * GDK_PIXBUF_ROTATE_COUNTERCLOCKWISE
330  * Rotate by 90 degrees.
331  * GDK_PIXBUF_ROTATE_UPSIDEDOWN
332  * Rotate by 180 degrees.
333  * GDK_PIXBUF_ROTATE_CLOCKWISE
334  * Rotate by 270 degrees.
335  */
336 public enum GdkPixbufRotation
337 {
338 	ROTATE_NONE = 0,
339 	ROTATE_COUNTERCLOCKWISE = 90,
340 	ROTATE_UPSIDEDOWN = 180,
341 	ROTATE_CLOCKWISE = 270
342 }
343 alias GdkPixbufRotation PixbufRotation;
344 
345 /**
346  * A set of values that describe the manner in which the pixel values
347  * for a visual are converted into RGB values for display.
348  * GDK_VISUAL_STATIC_GRAY
349  * Each pixel value indexes a grayscale value
350  *  directly.
351  * GDK_VISUAL_GRAYSCALE
352  * Each pixel is an index into a color map that
353  *  maps pixel values into grayscale values. The color map can be
354  *  changed by an application.
355  * GDK_VISUAL_STATIC_COLOR
356  * Each pixel value is an index into a predefined,
357  *  unmodifiable color map that maps pixel values into RGB values.
358  * GDK_VISUAL_PSEUDO_COLOR
359  * Each pixel is an index into a color map that
360  *  maps pixel values into rgb values. The color map can be changed by
361  *  an application.
362  * GDK_VISUAL_TRUE_COLOR
363  * Each pixel value directly contains red, green,
364  *  and blue components. Use gdk_visual_get_red_pixel_details(), etc,
365  *  to obtain information about how the components are assembled into
366  *  a pixel value.
367  * GDK_VISUAL_DIRECT_COLOR
368  * Each pixel value contains red, green, and blue
369  *  components as for GDK_VISUAL_TRUE_COLOR, but the components are
370  *  mapped via a color table into the final output table instead of
371  *  being converted directly.
372  */
373 public enum GdkVisualType
374 {
375 	STATIC_GRAY,
376 	GRAYSCALE,
377 	STATIC_COLOR,
378 	PSEUDO_COLOR,
379 	TRUE_COLOR,
380 	DIRECT_COLOR
381 }
382 alias GdkVisualType VisualType;
383 
384 /**
385  * A set of values describing the possible byte-orders
386  * for storing pixel values in memory.
387  * GDK_LSB_FIRST
388  * The values are stored with the least-significant byte
389  *  first. For instance, the 32-bit value 0xffeecc would be stored
390  *  in memory as 0xcc, 0xee, 0xff, 0x00.
391  * GDK_MSB_FIRST
392  * The values are stored with the most-significant byte
393  *  first. For instance, the 32-bit value 0xffeecc would be stored
394  *  in memory as 0x00, 0xff, 0xee, 0xcc.
395  */
396 public enum GdkByteOrder
397 {
398 	LSB_FIRST,
399 	MSB_FIRST
400 }
401 alias GdkByteOrder ByteOrder;
402 
403 /**
404  * The standard cursors available.
405  * GDK_X_CURSOR
406  * GDK_ARROW
407  * GDK_BASED_ARROW_DOWN
408  * GDK_BASED_ARROW_UP
409  * GDK_BOAT
410  * GDK_BOGOSITY
411  * GDK_BOTTOM_LEFT_CORNER
412  * GDK_BOTTOM_RIGHT_CORNER
413  * GDK_BOTTOM_SIDE
414  * GDK_BOTTOM_TEE
415  * GDK_BOX_SPIRAL
416  * GDK_CENTER_PTR
417  * GDK_CIRCLE
418  * GDK_CLOCK
419  * GDK_COFFEE_MUG
420  * GDK_CROSS
421  * GDK_CROSS_REVERSE
422  * GDK_CROSSHAIR
423  * GDK_DIAMOND_CROSS
424  * GDK_DOT
425  * GDK_DOTBOX
426  * GDK_DOUBLE_ARROW
427  * GDK_DRAFT_LARGE
428  * GDK_DRAFT_SMALL
429  * GDK_DRAPED_BOX
430  * GDK_EXCHANGE
431  * GDK_FLEUR
432  * GDK_GOBBLER
433  * GDK_GUMBY
434  * GDK_HAND1
435  * GDK_HAND2
436  * GDK_HEART
437  * GDK_ICON
438  * GDK_IRON_CROSS
439  * GDK_LEFT_PTR
440  * GDK_LEFT_SIDE
441  * GDK_LEFT_TEE
442  * GDK_LEFTBUTTON
443  * GDK_LL_ANGLE
444  * GDK_LR_ANGLE
445  * GDK_MAN
446  * GDK_MIDDLEBUTTON
447  * GDK_MOUSE
448  * GDK_PENCIL
449  * GDK_PIRATE
450  * GDK_PLUS
451  * GDK_QUESTION_ARROW
452  * GDK_RIGHT_PTR
453  * GDK_RIGHT_SIDE
454  * GDK_RIGHT_TEE
455  * GDK_RIGHTBUTTON
456  * GDK_RTL_LOGO
457  * GDK_SAILBOAT
458  * GDK_SB_DOWN_ARROW
459  * GDK_SB_H_DOUBLE_ARROW
460  * GDK_SB_LEFT_ARROW
461  * GDK_SB_RIGHT_ARROW
462  * GDK_SB_UP_ARROW
463  * GDK_SB_V_DOUBLE_ARROW
464  * GDK_SHUTTLE
465  * GDK_SIZING
466  * GDK_SPIDER
467  * GDK_SPRAYCAN
468  * GDK_STAR
469  * GDK_TARGET
470  * GDK_TCROSS
471  * GDK_TOP_LEFT_ARROW
472  * GDK_TOP_LEFT_CORNER
473  * GDK_TOP_RIGHT_CORNER
474  * GDK_TOP_SIDE
475  * GDK_TOP_TEE
476  * GDK_TREK
477  * GDK_UL_ANGLE
478  * GDK_UMBRELLA
479  * GDK_UR_ANGLE
480  * GDK_WATCH
481  * GDK_XTERM
482  * GDK_LAST_CURSOR
483  * last cursor type
484  * GDK_BLANK_CURSOR
485  * Blank cursor. Since 2.16
486  * GDK_CURSOR_IS_PIXMAP
487  * type of cursors constructed with
488  *  gdk_cursor_new_from_pixbuf()
489  */
490 public enum GdkCursorType
491 {
492 	X_CURSOR = 0,
493 	ARROW = 2,
494 	BASED_ARROW_DOWN = 4,
495 	BASED_ARROW_UP = 6,
496 	BOAT = 8,
497 	BOGOSITY = 10,
498 	BOTTOM_LEFT_CORNER = 12,
499 	BOTTOM_RIGHT_CORNER = 14,
500 	BOTTOM_SIDE = 16,
501 	BOTTOM_TEE = 18,
502 	BOX_SPIRAL = 20,
503 	CENTER_PTR = 22,
504 	CIRCLE = 24,
505 	CLOCK = 26,
506 	COFFEE_MUG = 28,
507 	CROSS = 30,
508 	CROSS_REVERSE = 32,
509 	CROSSHAIR = 34,
510 	DIAMOND_CROSS = 36,
511 	DOT = 38,
512 	DOTBOX = 40,
513 	DOUBLE_ARROW = 42,
514 	DRAFT_LARGE = 44,
515 	DRAFT_SMALL = 46,
516 	DRAPED_BOX = 48,
517 	EXCHANGE = 50,
518 	FLEUR = 52,
519 	GOBBLER = 54,
520 	GUMBY = 56,
521 	HAND1 = 58,
522 	HAND2 = 60,
523 	HEART = 62,
524 	ICON = 64,
525 	IRON_CROSS = 66,
526 	LEFT_PTR = 68,
527 	LEFT_SIDE = 70,
528 	LEFT_TEE = 72,
529 	LEFTBUTTON = 74,
530 	LL_ANGLE = 76,
531 	LR_ANGLE = 78,
532 	MAN = 80,
533 	MIDDLEBUTTON = 82,
534 	MOUSE = 84,
535 	PENCIL = 86,
536 	PIRATE = 88,
537 	PLUS = 90,
538 	QUESTION_ARROW = 92,
539 	RIGHT_PTR = 94,
540 	RIGHT_SIDE = 96,
541 	RIGHT_TEE = 98,
542 	RIGHTBUTTON = 100,
543 	RTL_LOGO = 102,
544 	SAILBOAT = 104,
545 	SB_DOWN_ARROW = 106,
546 	SB_H_DOUBLE_ARROW = 108,
547 	SB_LEFT_ARROW = 110,
548 	SB_RIGHT_ARROW = 112,
549 	SB_UP_ARROW = 114,
550 	SB_V_DOUBLE_ARROW = 116,
551 	SHUTTLE = 118,
552 	SIZING = 120,
553 	SPIDER = 122,
554 	SPRAYCAN = 124,
555 	STAR = 126,
556 	TARGET = 128,
557 	TCROSS = 130,
558 	TOP_LEFT_ARROW = 132,
559 	TOP_LEFT_CORNER = 134,
560 	TOP_RIGHT_CORNER = 136,
561 	TOP_SIDE = 138,
562 	TOP_TEE = 140,
563 	TREK = 142,
564 	UL_ANGLE = 144,
565 	UMBRELLA = 146,
566 	UR_ANGLE = 148,
567 	WATCH = 150,
568 	XTERM = 152,
569 	LAST_CURSOR,
570 	BLANK_CURSOR = -2,
571 	CURSOR_IS_PIXMAP = -1
572 }
573 alias GdkCursorType CursorType;
574 
575 /**
576  * Describes the kind of window.
577  * GDK_WINDOW_ROOT
578  * root window; this window has no parent, covers the entire
579  *  screen, and is created by the window system
580  * GDK_WINDOW_TOPLEVEL
581  * toplevel window (used to implement GtkWindow)
582  * GDK_WINDOW_CHILD
583  * child window (used to implement e.g. GtkEntry)
584  * GDK_WINDOW_TEMP
585  * override redirect temporary window (used to implement
586  *  GtkMenu)
587  * GDK_WINDOW_FOREIGN
588  * foreign window (see gdk_window_foreign_new())
589  * GDK_WINDOW_OFFSCREEN
590  * offscreen window (see
591  *  the section called “Offscreen Windows”). Since 2.18
592  */
593 public enum GdkWindowType
594 {
595 	ROOT,
596 	TOPLEVEL,
597 	CHILD,
598 	TEMP,
599 	FOREIGN,
600 	OFFSCREEN
601 }
602 alias GdkWindowType WindowType;
603 
604 /**
605  * GDK_INPUT_OUTPUT windows are the standard kind of window you might expect.
606  * Such windows receive events and are also displayed on screen.
607  * GDK_INPUT_ONLY windows are invisible; they are usually placed above other
608  * windows in order to trap or filter the events. You can't draw on
609  * GDK_INPUT_ONLY windows.
610  * GDK_INPUT_OUTPUT
611  * window for graphics and events
612  * GDK_INPUT_ONLY
613  * window for events only
614  */
615 public enum GdkWindowWindowClass
616 {
617 	INPUT_OUTPUT, /+*< nick= input-output >+/
618 	INPUT_ONLY /+*< nick= input-only >+/
619 }
620 alias GdkWindowWindowClass WindowWindowClass;
621 
622 /**
623  * Used to indicate which fields of a GdkGeometry struct should be paid
624  * attention to. Also, the presence/absence of GDK_HINT_POS,
625  * GDK_HINT_USER_POS, and GDK_HINT_USER_SIZE is significant, though they don't
626  * directly refer to GdkGeometry fields. GDK_HINT_USER_POS will be set
627  * automatically by GtkWindow if you call gtk_window_move().
628  * GDK_HINT_USER_POS and GDK_HINT_USER_SIZE should be set if the user
629  * specified a size/position using a --geometry command-line argument;
630  * gtk_window_parse_geometry() automatically sets these flags.
631  * GDK_HINT_POS
632  * indicates that the program has positioned the window
633  * GDK_HINT_MIN_SIZE
634  * min size fields are set
635  * GDK_HINT_MAX_SIZE
636  * max size fields are set
637  * GDK_HINT_BASE_SIZE
638  * base size fields are set
639  * GDK_HINT_ASPECT
640  * aspect ratio fields are set
641  * GDK_HINT_RESIZE_INC
642  * resize increment fields are set
643  * GDK_HINT_WIN_GRAVITY
644  * window gravity field is set
645  * GDK_HINT_USER_POS
646  * indicates that the window's position was explicitly set
647  *  by the user
648  * GDK_HINT_USER_SIZE
649  * indicates that the window's size was explicitly set by
650  *  the user
651  */
652 public enum GdkWindowHints
653 {
654 	HINT_POS = 1 << 0,
655 	HINT_MIN_SIZE = 1 << 1,
656 	HINT_MAX_SIZE = 1 << 2,
657 	HINT_BASE_SIZE = 1 << 3,
658 	HINT_ASPECT = 1 << 4,
659 	HINT_RESIZE_INC = 1 << 5,
660 	HINT_WIN_GRAVITY = 1 << 6,
661 	HINT_USER_POS = 1 << 7,
662 	HINT_USER_SIZE = 1 << 8
663 }
664 alias GdkWindowHints WindowHints;
665 
666 /**
667  * Defines the reference point of a window and the meaning of coordinates
668  * passed to gtk_window_move(). See gtk_window_move() and the "implementation
669  * notes" section of the
670  * Extended
671  * Window Manager Hints specification for more details.
672  * GDK_GRAVITY_NORTH_WEST
673  * the reference point is at the top left corner.
674  * GDK_GRAVITY_NORTH
675  * the reference point is in the middle of the top edge.
676  * GDK_GRAVITY_NORTH_EAST
677  * the reference point is at the top right corner.
678  * GDK_GRAVITY_WEST
679  * the reference point is at the middle of the left edge.
680  * GDK_GRAVITY_CENTER
681  * the reference point is at the center of the window.
682  * GDK_GRAVITY_EAST
683  * the reference point is at the middle of the right edge.
684  * GDK_GRAVITY_SOUTH_WEST
685  * the reference point is at the lower left corner.
686  * GDK_GRAVITY_SOUTH
687  * the reference point is at the middle of the lower edge.
688  * GDK_GRAVITY_SOUTH_EAST
689  * the reference point is at the lower right corner.
690  * GDK_GRAVITY_STATIC
691  * the reference point is at the top left corner of the
692  *  window itself, ignoring window manager decorations.
693  */
694 public enum GdkGravity
695 {
696 	NORTH_WEST = 1,
697 	NORTH,
698 	NORTH_EAST,
699 	WEST,
700 	CENTER,
701 	EAST,
702 	SOUTH_WEST,
703 	SOUTH,
704 	SOUTH_EAST,
705 	STATIC
706 }
707 alias GdkGravity Gravity;
708 
709 /**
710  * Determines a window edge or corner.
711  * GDK_WINDOW_EDGE_NORTH_WEST
712  * the top left corner.
713  * GDK_WINDOW_EDGE_NORTH
714  * the top edge.
715  * GDK_WINDOW_EDGE_NORTH_EAST
716  * the top right corner.
717  * GDK_WINDOW_EDGE_WEST
718  * the left edge.
719  * GDK_WINDOW_EDGE_EAST
720  * the right edge.
721  * GDK_WINDOW_EDGE_SOUTH_WEST
722  * the lower left corner.
723  * GDK_WINDOW_EDGE_SOUTH
724  * the lower edge.
725  * GDK_WINDOW_EDGE_SOUTH_EAST
726  * the lower right corner.
727  */
728 public enum GdkWindowEdge
729 {
730 	NORTH_WEST,
731 	NORTH,
732 	NORTH_EAST,
733 	WEST,
734 	EAST,
735 	SOUTH_WEST,
736 	SOUTH,
737 	SOUTH_EAST
738 }
739 alias GdkWindowEdge WindowEdge;
740 
741 /**
742  * These are hints for the window manager that indicate what type of function
743  * the window has. The window manager can use this when determining decoration
744  * and behaviour of the window. The hint must be set before mapping the window.
745  * See the
746  * Extended
747  * Window Manager Hints specification for more details about
748  * window types.
749  * GDK_WINDOW_TYPE_HINT_NORMAL
750  * Normal toplevel window.
751  * GDK_WINDOW_TYPE_HINT_DIALOG
752  * Dialog window.
753  * GDK_WINDOW_TYPE_HINT_MENU
754  * Window used to implement a menu; GTK+ uses
755  *  this hint only for torn-off menus, see GtkTearoffMenuItem.
756  * GDK_WINDOW_TYPE_HINT_TOOLBAR
757  * Window used to implement toolbars.
758  * GDK_WINDOW_TYPE_HINT_SPLASHSCREEN
759  * Window used to display a splash
760  *  screen during application startup.
761  * GDK_WINDOW_TYPE_HINT_UTILITY
762  * Utility windows which are not detached
763  *  toolbars or dialogs.
764  * GDK_WINDOW_TYPE_HINT_DOCK
765  * Used for creating dock or panel windows.
766  * GDK_WINDOW_TYPE_HINT_DESKTOP
767  * Used for creating the desktop background
768  *  window.
769  * GDK_WINDOW_TYPE_HINT_DROPDOWN_MENU
770  * A menu that belongs to a menubar.
771  * GDK_WINDOW_TYPE_HINT_POPUP_MENU
772  * A menu that does not belong to a menubar,
773  *  e.g. a context menu.
774  * GDK_WINDOW_TYPE_HINT_TOOLTIP
775  * A tooltip.
776  * GDK_WINDOW_TYPE_HINT_NOTIFICATION
777  * A notification - typically a "bubble"
778  *  that belongs to a status icon.
779  * GDK_WINDOW_TYPE_HINT_COMBO
780  * A popup from a combo box.
781  * GDK_WINDOW_TYPE_HINT_DND
782  * A window that is used to implement a DND cursor.
783  */
784 public enum GdkWindowTypeHint
785 {
786 	NORMAL,
787 	DIALOG,
788 	MENU, /+* Torn off menu +/
789 	TOOLBAR,
790 	SPLASHSCREEN,
791 	UTILITY,
792 	DOCK,
793 	DESKTOP,
794 	DROPDOWN_MENU, /+* A drop down menu (from a menubar) +/
795 	POPUP_MENU, /+* A popup menu (from right-click) +/
796 	TOOLTIP,
797 	NOTIFICATION,
798 	COMBO,
799 	DND
800 }
801 alias GdkWindowTypeHint WindowTypeHint;
802 
803 /**
804  * Used to indicate which fields in the GdkWindowAttr struct should be honored.
805  * For example, if you filled in the "cursor" and "x" fields of GdkWindowAttr,
806  * pass "GDK_WA_X | GDK_WA_CURSOR" to gdk_window_new(). Fields in
807  * GdkWindowAttr not covered by a bit in this enum are required; for example,
808  * the width/height, wclass, and window_type fields are required, they have
809  * no corresponding flag in GdkWindowAttributesType.
810  * GDK_WA_TITLE
811  * Honor the title field
812  * GDK_WA_X
813  * Honor the X coordinate field
814  * GDK_WA_Y
815  * Honor the Y coordinate field
816  * GDK_WA_CURSOR
817  * Honor the cursor field
818  * GDK_WA_VISUAL
819  * Honor the visual field
820  * GDK_WA_WMCLASS
821  * Honor the wmclass_class and wmclass_name fields
822  * GDK_WA_NOREDIR
823  * Honor the override_redirect field
824  * GDK_WA_TYPE_HINT
825  * Honor the type_hint field
826  */
827 public enum GdkWindowAttributesType
828 {
829 	WA_TITLE = 1 << 1,
830 	WA_X = 1 << 2,
831 	WA_Y = 1 << 3,
832 	WA_CURSOR = 1 << 4,
833 	WA_VISUAL = 1 << 5,
834 	WA_WMCLASS = 1 << 6,
835 	WA_NOREDIR = 1 << 7,
836 	WA_TYPE_HINT = 1 << 8
837 }
838 alias GdkWindowAttributesType WindowAttributesType;
839 
840 /**
841  * Indicates which monitor (in a multi-head setup) a window should span over
842  * when in fullscreen mode.
843  * GDK_FULLSCREEN_ON_CURRENT_MONITOR
844  * Fullscreen on current monitor only.
845  * GDK_FULLSCREEN_ON_ALL_MONITORS
846  * Span across all monitors when fullscreen.
847  * Since 3.8
848  */
849 public enum GdkFullscreenMode
850 {
851 	ON_CURRENT_MONITOR,
852 	ON_ALL_MONITORS
853 }
854 alias GdkFullscreenMode FullscreenMode;
855 
856 /**
857  * Specifies the result of applying a GdkFilterFunc to a native event.
858  * GDK_FILTER_CONTINUE
859  * event not handled, continue processing.
860  * GDK_FILTER_TRANSLATE
861  * native event translated into a GDK event and stored
862  *  in the event structure that was passed in.
863  * GDK_FILTER_REMOVE
864  * event handled, terminate processing.
865  */
866 public enum GdkFilterReturn
867 {
868 	CONTINUE, /+* Event not handled, continu processesing +/
869 	TRANSLATE, /+* Native event translated into a GDK event and
870 	stored inn the "event" structure that was
871 	passed inn +/
872 	REMOVE /+* Terminate processing, removing event +/
873 }
874 alias GdkFilterReturn FilterReturn;
875 
876 /**
877  * A set of bit-flags to indicate the state of modifier keys and mouse buttons
878  * in various event types. Typical modifier keys are Shift, Control, Meta,
879  * Super, Hyper, Alt, Compose, Apple, CapsLock or ShiftLock.
880  * Like the X Window System, GDK supports 8 modifier keys and 5 mouse buttons.
881  * Since 2.10, GDK recognizes which of the Meta, Super or Hyper keys are mapped
882  * to Mod2 - Mod5, and indicates this by setting GDK_SUPER_MASK,
883  * GDK_HYPER_MASK or GDK_META_MASK in the state field of key events.
884  * Note that GDK may add internal values to events which include
885  * reserved values such as GDK_MODIFIER_RESERVED_13_MASK. Your code
886  * should preserve and ignore them. You can use GDK_MODIFIER_MASK to
887  * remove all reserved values.
888  * GDK_SHIFT_MASK
889  * the Shift key.
890  * GDK_LOCK_MASK
891  * a Lock key (depending on the modifier mapping of the
892  *  X server this may either be CapsLock or ShiftLock).
893  * GDK_CONTROL_MASK
894  * the Control key.
895  * GDK_MOD1_MASK
896  * the fourth modifier key (it depends on the modifier
897  *  mapping of the X server which key is interpreted as this modifier, but
898  *  normally it is the Alt key).
899  * GDK_MOD2_MASK
900  * the fifth modifier key (it depends on the modifier
901  *  mapping of the X server which key is interpreted as this modifier).
902  * GDK_MOD3_MASK
903  * the sixth modifier key (it depends on the modifier
904  *  mapping of the X server which key is interpreted as this modifier).
905  * GDK_MOD4_MASK
906  * the seventh modifier key (it depends on the modifier
907  *  mapping of the X server which key is interpreted as this modifier).
908  * GDK_MOD5_MASK
909  * the eighth modifier key (it depends on the modifier
910  *  mapping of the X server which key is interpreted as this modifier).
911  * GDK_BUTTON1_MASK
912  * the first mouse button.
913  * GDK_BUTTON2_MASK
914  * the second mouse button.
915  * GDK_BUTTON3_MASK
916  * the third mouse button.
917  * GDK_BUTTON4_MASK
918  * the fourth mouse button.
919  * GDK_BUTTON5_MASK
920  * the fifth mouse button.
921  * GDK_MODIFIER_RESERVED_13_MASK
922  * A reserved bit flag; do not use in your own code
923  * GDK_MODIFIER_RESERVED_14_MASK
924  * GDK_MODIFIER_RESERVED_15_MASK
925  * GDK_MODIFIER_RESERVED_16_MASK
926  * GDK_MODIFIER_RESERVED_17_MASK
927  * GDK_MODIFIER_RESERVED_18_MASK
928  * GDK_MODIFIER_RESERVED_19_MASK
929  * GDK_MODIFIER_RESERVED_20_MASK
930  * GDK_MODIFIER_RESERVED_21_MASK
931  * GDK_MODIFIER_RESERVED_22_MASK
932  * GDK_MODIFIER_RESERVED_23_MASK
933  * GDK_MODIFIER_RESERVED_24_MASK
934  * GDK_MODIFIER_RESERVED_25_MASK
935  * GDK_SUPER_MASK
936  * the Super modifier. Since 2.10
937  * GDK_HYPER_MASK
938  * the Hyper modifier. Since 2.10
939  * GDK_META_MASK
940  * the Meta modifier. Since 2.10
941  * GDK_MODIFIER_RESERVED_29_MASK
942  * GDK_RELEASE_MASK
943  * not used in GDK itself. GTK+ uses it to differentiate
944  *  between (keyval, modifiers) pairs from key press and release events.
945  * GDK_MODIFIER_MASK
946  * a mask covering all modifier types.
947  */
948 public enum GdkModifierType
949 {
950 	SHIFT_MASK = 1 << 0,
951 	LOCK_MASK = 1 << 1,
952 	CONTROL_MASK = 1 << 2,
953 	MOD1_MASK = 1 << 3,
954 	MOD2_MASK = 1 << 4,
955 	MOD3_MASK = 1 << 5,
956 	MOD4_MASK = 1 << 6,
957 	MOD5_MASK = 1 << 7,
958 	BUTTON1_MASK = 1 << 8,
959 	BUTTON2_MASK = 1 << 9,
960 	BUTTON3_MASK = 1 << 10,
961 	BUTTON4_MASK = 1 << 11,
962 	BUTTON5_MASK = 1 << 12,
963 	MODIFIER_RESERVED_13_MASK = 1 << 13,
964 	MODIFIER_RESERVED_14_MASK = 1 << 14,
965 	MODIFIER_RESERVED_15_MASK = 1 << 15,
966 	MODIFIER_RESERVED_16_MASK = 1 << 16,
967 	MODIFIER_RESERVED_17_MASK = 1 << 17,
968 	MODIFIER_RESERVED_18_MASK = 1 << 18,
969 	MODIFIER_RESERVED_19_MASK = 1 << 19,
970 	MODIFIER_RESERVED_20_MASK = 1 << 20,
971 	MODIFIER_RESERVED_21_MASK = 1 << 21,
972 	MODIFIER_RESERVED_22_MASK = 1 << 22,
973 	MODIFIER_RESERVED_23_MASK = 1 << 23,
974 	MODIFIER_RESERVED_24_MASK = 1 << 24,
975 	MODIFIER_RESERVED_25_MASK = 1 << 25,
976 	/+* The next few modifiers are used by XKB, so we skip to the end.
977 	 * Bits 15 - 25 are currently unused. Bit 29 is used internally.
978 	+/
979 	SUPER_MASK = 1 << 26,
980 	HYPER_MASK = 1 << 27,
981 	META_MASK = 1 << 28,
982 	MODIFIER_RESERVED_29_MASK = 1 << 29,
983 	RELEASE_MASK = 1 << 30,
984 	/+* Combination of SHIFT_MASK..BUTTON5_MASK + SUPER_MASK
985 	+ HYPER_MASK + META_MASK + RELEASE_MASK +/
986 	MODIFIER_MASK = 0x5c001fff
987 }
988 alias GdkModifierType ModifierType;
989 
990 /**
991  * These are hints originally defined by the Motif toolkit.
992  * The window manager can use them when determining how to decorate
993  * the window. The hint must be set before mapping the window.
994  * GDK_DECOR_ALL
995  * all decorations should be applied.
996  * GDK_DECOR_BORDER
997  * a frame should be drawn around the window.
998  * GDK_DECOR_RESIZEH
999  * the frame should have resize handles.
1000  * GDK_DECOR_TITLE
1001  * a titlebar should be placed above the window.
1002  * GDK_DECOR_MENU
1003  * a button for opening a menu should be included.
1004  * GDK_DECOR_MINIMIZE
1005  * a minimize button should be included.
1006  * GDK_DECOR_MAXIMIZE
1007  * a maximize button should be included.
1008  */
1009 public enum GdkWMDecoration
1010 {
1011 	DECOR_ALL = 1 << 0,
1012 	DECOR_BORDER = 1 << 1,
1013 	DECOR_RESIZEH = 1 << 2,
1014 	DECOR_TITLE = 1 << 3,
1015 	DECOR_MENU = 1 << 4,
1016 	DECOR_MINIMIZE = 1 << 5,
1017 	DECOR_MAXIMIZE = 1 << 6
1018 }
1019 alias GdkWMDecoration WMDecoration;
1020 
1021 /**
1022  * These are hints originally defined by the Motif toolkit. The window manager
1023  * can use them when determining the functions to offer for the window. The
1024  * hint must be set before mapping the window.
1025  * GDK_FUNC_ALL
1026  * all functions should be offered.
1027  * GDK_FUNC_RESIZE
1028  * the window should be resizable.
1029  * GDK_FUNC_MOVE
1030  * the window should be movable.
1031  * GDK_FUNC_MINIMIZE
1032  * the window should be minimizable.
1033  * GDK_FUNC_MAXIMIZE
1034  * the window should be maximizable.
1035  * GDK_FUNC_CLOSE
1036  * the window should be closable.
1037  */
1038 public enum GdkWMFunction
1039 {
1040 	FUNC_ALL = 1 << 0,
1041 	FUNC_RESIZE = 1 << 1,
1042 	FUNC_MOVE = 1 << 2,
1043 	FUNC_MINIMIZE = 1 << 3,
1044 	FUNC_MAXIMIZE = 1 << 4,
1045 	FUNC_CLOSE = 1 << 5
1046 }
1047 alias GdkWMFunction WMFunction;
1048 
1049 /**
1050  * GdkFrameClockPhase is used to represent the different paint clock
1051  * phases that can be requested. The elements of the enumeration
1052  * correspond to the signals of GdkPaintClock.
1053  * GDK_FRAME_CLOCK_PHASE_NONE
1054  * no phase
1055  * GDK_FRAME_CLOCK_PHASE_FLUSH_EVENTS
1056  * corresponds to GdkFrameClock::flush-events. Should not be handled by applications.
1057  * GDK_FRAME_CLOCK_PHASE_BEFORE_PAINT
1058  * corresponds to GdkFrameClock::before-paint. Should not be handled by applications.
1059  * GDK_FRAME_CLOCK_PHASE_UPDATE
1060  * corresponds to GdkFrameClock::update.
1061  * GDK_FRAME_CLOCK_PHASE_LAYOUT
1062  * corresponds to GdkFrameClock::layout.
1063  * GDK_FRAME_CLOCK_PHASE_PAINT
1064  * corresponds to GdkFrameClock::paint.
1065  * GDK_FRAME_CLOCK_PHASE_RESUME_EVENTS
1066  * corresponds to GdkFrameClock::resume-events. Should not be handled by applications.
1067  * GDK_FRAME_CLOCK_PHASE_AFTER_PAINT
1068  * corresponds to GdkFrameClock::after-paint. Should not be handled by applications.
1069  * Since 3.8
1070  */
1071 public enum GdkFrameClockPhase
1072 {
1073 	NONE = 0,
1074 	FLUSH_EVENTS = 1 << 0,
1075 	BEFORE_PAINT = 1 << 1,
1076 	UPDATE = 1 << 2,
1077 	LAYOUT = 1 << 3,
1078 	PAINT = 1 << 4,
1079 	RESUME_EVENTS = 1 << 5,
1080 	AFTER_PAINT = 1 << 6
1081 }
1082 alias GdkFrameClockPhase FrameClockPhase;
1083 
1084 /**
1085  * Specifies the type of the event.
1086  * Do not confuse these events with the signals that GTK+ widgets emit.
1087  * Although many of these events result in corresponding signals being emitted,
1088  * the events are often transformed or filtered along the way.
1089  * In some language bindings, the values GDK_2BUTTON_PRESS and
1090  * GDK_3BUTTON_PRESS would translate into something syntactically
1091  * invalid (eg Gdk.EventType.2ButtonPress, where a
1092  * symbol is not allowed to start with a number). In that case, the
1093  * aliases GDK_DOUBLE_BUTTON_PRESS and GDK_TRIPLE_BUTTON_PRESS can
1094  * be used instead.
1095  * GDK_NOTHING
1096  * a special code to indicate a null event.
1097  * GDK_DELETE
1098  * the window manager has requested that the toplevel window be
1099  *  hidden or destroyed, usually when the user clicks on a special icon in the
1100  *  title bar.
1101  * GDK_DESTROY
1102  * the window has been destroyed.
1103  * GDK_EXPOSE
1104  * all or part of the window has become visible and needs to be
1105  *  redrawn.
1106  * GDK_MOTION_NOTIFY
1107  * the pointer (usually a mouse) has moved.
1108  * GDK_BUTTON_PRESS
1109  * a mouse button has been pressed.
1110  * GDK_2BUTTON_PRESS
1111  * a mouse button has been double-clicked (clicked twice
1112  *  within a short period of time). Note that each click also generates a
1113  *  GDK_BUTTON_PRESS event.
1114  * GDK_DOUBLE_BUTTON_PRESS
1115  * alias for GDK_2BUTTON_PRESS, added in 3.6.
1116  * GDK_3BUTTON_PRESS
1117  * a mouse button has been clicked 3 times in a short period
1118  *  of time. Note that each click also generates a GDK_BUTTON_PRESS event.
1119  * GDK_TRIPLE_BUTTON_PRESS
1120  * alias for GDK_3BUTTON_PRESS, added in 3.6.
1121  * GDK_BUTTON_RELEASE
1122  * a mouse button has been released.
1123  * GDK_KEY_PRESS
1124  * a key has been pressed.
1125  * GDK_KEY_RELEASE
1126  * a key has been released.
1127  * GDK_ENTER_NOTIFY
1128  * the pointer has entered the window.
1129  * GDK_LEAVE_NOTIFY
1130  * the pointer has left the window.
1131  * GDK_FOCUS_CHANGE
1132  * the keyboard focus has entered or left the window.
1133  * GDK_CONFIGURE
1134  * the size, position or stacking order of the window has changed.
1135  *  Note that GTK+ discards these events for GDK_WINDOW_CHILD windows.
1136  * GDK_MAP
1137  * the window has been mapped.
1138  * GDK_UNMAP
1139  * the window has been unmapped.
1140  * GDK_PROPERTY_NOTIFY
1141  * a property on the window has been changed or deleted.
1142  * GDK_SELECTION_CLEAR
1143  * the application has lost ownership of a selection.
1144  * GDK_SELECTION_REQUEST
1145  * another application has requested a selection.
1146  * GDK_SELECTION_NOTIFY
1147  * a selection has been received.
1148  * GDK_PROXIMITY_IN
1149  * an input device has moved into contact with a sensing
1150  *  surface (e.g. a touchscreen or graphics tablet).
1151  * GDK_PROXIMITY_OUT
1152  * an input device has moved out of contact with a sensing
1153  *  surface.
1154  * GDK_DRAG_ENTER
1155  * the mouse has entered the window while a drag is in progress.
1156  * GDK_DRAG_LEAVE
1157  * the mouse has left the window while a drag is in progress.
1158  * GDK_DRAG_MOTION
1159  * the mouse has moved in the window while a drag is in
1160  *  progress.
1161  * GDK_DRAG_STATUS
1162  * the status of the drag operation initiated by the window
1163  *  has changed.
1164  * GDK_DROP_START
1165  * a drop operation onto the window has started.
1166  * GDK_DROP_FINISHED
1167  * the drop operation initiated by the window has completed.
1168  * GDK_CLIENT_EVENT
1169  * a message has been received from another application.
1170  * GDK_VISIBILITY_NOTIFY
1171  * the window visibility status has changed.
1172  * GDK_SCROLL
1173  * the scroll wheel was turned
1174  * GDK_WINDOW_STATE
1175  * the state of a window has changed. See GdkWindowState
1176  *  for the possible window states
1177  * GDK_SETTING
1178  * a setting has been modified.
1179  * GDK_OWNER_CHANGE
1180  * the owner of a selection has changed. This event type
1181  *  was added in 2.6
1182  * GDK_GRAB_BROKEN
1183  * a pointer or keyboard grab was broken. This event type
1184  *  was added in 2.8.
1185  * GDK_DAMAGE
1186  * the content of the window has been changed. This event type
1187  *  was added in 2.14.
1188  * GDK_TOUCH_BEGIN
1189  * A new touch event sequence has just started. This event
1190  *  type was added in 3.4.
1191  * GDK_TOUCH_UPDATE
1192  * A touch event sequence has been updated. This event type
1193  *  was added in 3.4.
1194  * GDK_TOUCH_END
1195  * A touch event sequence has finished. This event type
1196  *  was added in 3.4.
1197  * GDK_TOUCH_CANCEL
1198  * A touch event sequence has been canceled. This event type
1199  *  was added in 3.4.
1200  * GDK_EVENT_LAST
1201  * marks the end of the GdkEventType enumeration. Added in 2.18
1202  */
1203 public enum GdkEventType
1204 {
1205 	NOTHING = -1,
1206 	DELETE = 0,
1207 	DESTROY = 1,
1208 	EXPOSE = 2,
1209 	MOTION_NOTIFY = 3,
1210 	BUTTON_PRESS = 4,
1211 	
1212 	DOUBLE_BUTTON_PRESS = 5,
1213 	
1214 	TRIPLE_BUTTON_PRESS = 6,
1215 	BUTTON_RELEASE = 7,
1216 	KEY_PRESS = 8,
1217 	KEY_RELEASE = 9,
1218 	ENTER_NOTIFY = 10,
1219 	LEAVE_NOTIFY = 11,
1220 	FOCUS_CHANGE = 12,
1221 	CONFIGURE = 13,
1222 	MAP = 14,
1223 	UNMAP = 15,
1224 	PROPERTY_NOTIFY = 16,
1225 	SELECTION_CLEAR = 17,
1226 	SELECTION_REQUEST = 18,
1227 	SELECTION_NOTIFY = 19,
1228 	PROXIMITY_IN = 20,
1229 	PROXIMITY_OUT = 21,
1230 	DRAG_ENTER = 22,
1231 	DRAG_LEAVE = 23,
1232 	DRAG_MOTION = 24,
1233 	DRAG_STATUS = 25,
1234 	DROP_START = 26,
1235 	DROP_FINISHED = 27,
1236 	CLIENT_EVENT = 28,
1237 	VISIBILITY_NOTIFY = 29,
1238 	SCROLL = 31,
1239 	WINDOW_STATE = 32,
1240 	SETTING = 33,
1241 	OWNER_CHANGE = 34,
1242 	GRAB_BROKEN = 35,
1243 	DAMAGE = 36,
1244 	TOUCH_BEGIN = 37,
1245 	TOUCH_UPDATE = 38,
1246 	TOUCH_END = 39,
1247 	TOUCH_CANCEL = 40,
1248 	EVENT_LAST /+* helper variable for decls +/
1249 }
1250 alias GdkEventType EventType;
1251 
1252 /**
1253  * A set of bit-flags to indicate which events a window is to receive.
1254  * Most of these masks map onto one or more of the GdkEventType event types
1255  * above.
1256  * GDK_POINTER_MOTION_HINT_MASK is a special mask which is used to reduce the
1257  * number of GDK_MOTION_NOTIFY events received. Normally a GDK_MOTION_NOTIFY
1258  * event is received each time the mouse moves. However, if the application
1259  * spends a lot of time processing the event (updating the display, for example),
1260  * it can lag behind the position of the mouse. When using
1261  * GDK_POINTER_MOTION_HINT_MASK, fewer GDK_MOTION_NOTIFY events will be sent,
1262  * some of which are marked as a hint (the is_hint member is TRUE).
1263  * To receive more motion events after a motion hint event, the application
1264  * needs to asks for more, by calling gdk_event_request_motions().
1265  * If GDK_TOUCH_MASK is enabled, the window will receive touch events
1266  * from touch-enabled devices. Those will come as sequences of GdkEventTouch
1267  * with type GDK_TOUCH_UPDATE, enclosed by two events with
1268  * type GDK_TOUCH_BEGIN and GDK_TOUCH_END (or GDK_TOUCH_CANCEL).
1269  * gdk_event_get_event_sequence() returns the event sequence for these
1270  * events, so different sequences may be distinguished.
1271  * GDK_EXPOSURE_MASK
1272  * receive expose events
1273  * GDK_POINTER_MOTION_MASK
1274  * receive all pointer motion events
1275  * GDK_POINTER_MOTION_HINT_MASK
1276  * see the explanation above
1277  * GDK_BUTTON_MOTION_MASK
1278  * receive pointer motion events while any button is pressed
1279  * GDK_BUTTON1_MOTION_MASK
1280  * receive pointer motion events while 1 button is pressed
1281  * GDK_BUTTON2_MOTION_MASK
1282  * receive pointer motion events while 2 button is pressed
1283  * GDK_BUTTON3_MOTION_MASK
1284  * receive pointer motion events while 3 button is pressed
1285  * GDK_BUTTON_PRESS_MASK
1286  * receive button press events
1287  * GDK_BUTTON_RELEASE_MASK
1288  * receive button release events
1289  * GDK_KEY_PRESS_MASK
1290  * receive key press events
1291  * GDK_KEY_RELEASE_MASK
1292  * receive key release events
1293  * GDK_ENTER_NOTIFY_MASK
1294  * receive window enter events
1295  * GDK_LEAVE_NOTIFY_MASK
1296  * receive window leave events
1297  * GDK_FOCUS_CHANGE_MASK
1298  * receive focus change events
1299  * GDK_STRUCTURE_MASK
1300  * receive events about window configuration change
1301  * GDK_PROPERTY_CHANGE_MASK
1302  * receive property change events
1303  * GDK_VISIBILITY_NOTIFY_MASK
1304  * receive visibility change events
1305  * GDK_PROXIMITY_IN_MASK
1306  * receive proximity in events
1307  * GDK_PROXIMITY_OUT_MASK
1308  * receive proximity out events
1309  * GDK_SUBSTRUCTURE_MASK
1310  * receive events about window configuration changes of
1311  *  child windows
1312  * GDK_SCROLL_MASK
1313  * receive scroll events
1314  * GDK_TOUCH_MASK
1315  * receive touch events. Since 3.4
1316  * GDK_SMOOTH_SCROLL_MASK
1317  * receive smooth scrolling events. Since 3.4
1318  * GDK_ALL_EVENTS_MASK
1319  * the combination of all the above event masks.
1320  */
1321 public enum GdkEventMask
1322 {
1323 	EXPOSURE_MASK = 1 << 1,
1324 	POINTER_MOTION_MASK = 1 << 2,
1325 	POINTER_MOTION_HINT_MASK = 1 << 3,
1326 	BUTTON_MOTION_MASK = 1 << 4,
1327 	BUTTON1_MOTION_MASK = 1 << 5,
1328 	BUTTON2_MOTION_MASK = 1 << 6,
1329 	BUTTON3_MOTION_MASK = 1 << 7,
1330 	BUTTON_PRESS_MASK = 1 << 8,
1331 	BUTTON_RELEASE_MASK = 1 << 9,
1332 	KEY_PRESS_MASK = 1 << 10,
1333 	KEY_RELEASE_MASK = 1 << 11,
1334 	ENTER_NOTIFY_MASK = 1 << 12,
1335 	LEAVE_NOTIFY_MASK = 1 << 13,
1336 	FOCUS_CHANGE_MASK = 1 << 14,
1337 	STRUCTURE_MASK = 1 << 15,
1338 	PROPERTY_CHANGE_MASK = 1 << 16,
1339 	VISIBILITY_NOTIFY_MASK = 1 << 17,
1340 	PROXIMITY_IN_MASK = 1 << 18,
1341 	PROXIMITY_OUT_MASK = 1 << 19,
1342 	SUBSTRUCTURE_MASK = 1 << 20,
1343 	SCROLL_MASK = 1 << 21,
1344 	TOUCH_MASK = 1 << 22,
1345 	SMOOTH_SCROLL_MASK = 1 << 23,
1346 	ALL_EVENTS_MASK = 0xFFFFFE
1347 }
1348 alias GdkEventMask EventMask;
1349 
1350 /**
1351  * Specifies the direction for GdkEventScroll.
1352  * GDK_SCROLL_UP
1353  * the window is scrolled up.
1354  * GDK_SCROLL_DOWN
1355  * the window is scrolled down.
1356  * GDK_SCROLL_LEFT
1357  * the window is scrolled to the left.
1358  * GDK_SCROLL_RIGHT
1359  * the window is scrolled to the right.
1360  * GDK_SCROLL_SMOOTH
1361  * the scrolling is determined by the delta values
1362  *  in GdkEventScroll. See gdk_event_get_scroll_deltas(). Since: 3.4
1363  */
1364 public enum GdkScrollDirection
1365 {
1366 	UP,
1367 	DOWN,
1368 	LEFT,
1369 	RIGHT,
1370 	SMOOTH
1371 }
1372 alias GdkScrollDirection ScrollDirection;
1373 
1374 /**
1375  * Specifies the visiblity status of a window for a GdkEventVisibility.
1376  * GDK_VISIBILITY_UNOBSCURED
1377  * the window is completely visible.
1378  * GDK_VISIBILITY_PARTIAL
1379  * the window is partially visible.
1380  * GDK_VISIBILITY_FULLY_OBSCURED
1381  * the window is not visible at all.
1382  */
1383 public enum GdkVisibilityState
1384 {
1385 	UNOBSCURED,
1386 	PARTIAL,
1387 	FULLY_OBSCURED
1388 }
1389 alias GdkVisibilityState VisibilityState;
1390 
1391 /**
1392  * Specifies the crossing mode for GdkEventCrossing.
1393  * GDK_CROSSING_NORMAL
1394  * crossing because of pointer motion.
1395  * GDK_CROSSING_GRAB
1396  * crossing because a grab is activated.
1397  * GDK_CROSSING_UNGRAB
1398  * crossing because a grab is deactivated.
1399  * GDK_CROSSING_GTK_GRAB
1400  * crossing because a GTK+ grab is activated.
1401  * GDK_CROSSING_GTK_UNGRAB
1402  * crossing because a GTK+ grab is deactivated.
1403  * GDK_CROSSING_STATE_CHANGED
1404  * crossing because a GTK+ widget changed
1405  *  state (e.g. sensitivity).
1406  * GDK_CROSSING_TOUCH_BEGIN
1407  * crossing because a touch sequence has begun,
1408  *  this event is synthetic as the pointer might have not left the window.
1409  * GDK_CROSSING_TOUCH_END
1410  * crossing because a touch sequence has ended,
1411  *  this event is synthetic as the pointer might have not left the window.
1412  * GDK_CROSSING_DEVICE_SWITCH
1413  * crossing because of a device switch (i.e.
1414  *  a mouse taking control of the pointer after a touch device), this event
1415  *  is synthetic as the pointer didn't leave the window.
1416  */
1417 public enum GdkCrossingMode
1418 {
1419 	NORMAL,
1420 	GRAB,
1421 	UNGRAB,
1422 	GTK_GRAB,
1423 	GTK_UNGRAB,
1424 	STATE_CHANGED,
1425 	TOUCH_BEGIN,
1426 	TOUCH_END,
1427 	DEVICE_SWITCH
1428 }
1429 alias GdkCrossingMode CrossingMode;
1430 
1431 /**
1432  * Specifies the kind of crossing for GdkEventCrossing.
1433  * See the X11 protocol specification of LeaveNotify for
1434  * full details of crossing event generation.
1435  * GDK_NOTIFY_ANCESTOR
1436  * the window is entered from an ancestor or
1437  *  left towards an ancestor.
1438  * GDK_NOTIFY_VIRTUAL
1439  * the pointer moves between an ancestor and an
1440  *  inferior of the window.
1441  * GDK_NOTIFY_INFERIOR
1442  * the window is entered from an inferior or
1443  *  left towards an inferior.
1444  * GDK_NOTIFY_NONLINEAR
1445  * the window is entered from or left towards
1446  *  a window which is neither an ancestor nor an inferior.
1447  * GDK_NOTIFY_NONLINEAR_VIRTUAL
1448  * the pointer moves between two windows
1449  *  which are not ancestors of each other and the window is part of
1450  *  the ancestor chain between one of these windows and their least
1451  *  common ancestor.
1452  * GDK_NOTIFY_UNKNOWN
1453  * an unknown type of enter/leave event occurred.
1454  */
1455 public enum GdkNotifyType
1456 {
1457 	ANCESTOR = 0,
1458 	VIRTUAL = 1,
1459 	INFERIOR = 2,
1460 	NONLINEAR = 3,
1461 	NONLINEAR_VIRTUAL = 4,
1462 	UNKNOWN = 5
1463 }
1464 alias GdkNotifyType NotifyType;
1465 
1466 /**
1467  * Specifies the type of a property change for a GdkEventProperty.
1468  * GDK_PROPERTY_NEW_VALUE
1469  * the property value was changed.
1470  * GDK_PROPERTY_DELETE
1471  * the property was deleted.
1472  */
1473 public enum GdkPropertyState
1474 {
1475 	NEW_VALUE,
1476 	DELETE
1477 }
1478 alias GdkPropertyState PropertyState;
1479 
1480 /**
1481  * Specifies the state of a toplevel window.
1482  * GDK_WINDOW_STATE_WITHDRAWN
1483  * the window is not shown.
1484  * GDK_WINDOW_STATE_ICONIFIED
1485  * the window is minimized.
1486  * GDK_WINDOW_STATE_MAXIMIZED
1487  * the window is maximized.
1488  * GDK_WINDOW_STATE_STICKY
1489  * the window is sticky.
1490  * GDK_WINDOW_STATE_FULLSCREEN
1491  * the window is maximized without
1492  *  decorations.
1493  * GDK_WINDOW_STATE_ABOVE
1494  * the window is kept above other windows.
1495  * GDK_WINDOW_STATE_BELOW
1496  * the window is kept below other windows.
1497  * GDK_WINDOW_STATE_FOCUSED
1498  * the window is presented as focused (with active decorations).
1499  * GDK_WINDOW_STATE_TILED
1500  */
1501 public enum GdkWindowState
1502 {
1503 	WITHDRAWN = 1 << 0,
1504 	ICONIFIED = 1 << 1,
1505 	MAXIMIZED = 1 << 2,
1506 	STICKY = 1 << 3,
1507 	FULLSCREEN = 1 << 4,
1508 	ABOVE = 1 << 5,
1509 	BELOW = 1 << 6,
1510 	FOCUSED = 1 << 7,
1511 	TILED = 1 << 8
1512 }
1513 alias GdkWindowState WindowState;
1514 
1515 /**
1516  * Specifies the kind of modification applied to a setting in a
1517  * GdkEventSetting.
1518  * GDK_SETTING_ACTION_NEW
1519  * a setting was added.
1520  * GDK_SETTING_ACTION_CHANGED
1521  * a setting was changed.
1522  * GDK_SETTING_ACTION_DELETED
1523  * a setting was deleted.
1524  */
1525 public enum GdkSettingAction
1526 {
1527 	NEW,
1528 	CHANGED,
1529 	DELETED
1530 }
1531 alias GdkSettingAction SettingAction;
1532 
1533 /**
1534  * Specifies why a selection ownership was changed.
1535  * GDK_OWNER_CHANGE_NEW_OWNER
1536  * some other app claimed the ownership
1537  * GDK_OWNER_CHANGE_DESTROY
1538  * the window was destroyed
1539  * GDK_OWNER_CHANGE_CLOSE
1540  * the client was closed
1541  */
1542 public enum GdkOwnerChange
1543 {
1544 	NEW_OWNER,
1545 	DESTROY,
1546 	CLOSE
1547 }
1548 alias GdkOwnerChange OwnerChange;
1549 
1550 /**
1551  * Used in GdkDragContext to indicate the protocol according to
1552  * which DND is done.
1553  * GDK_DRAG_PROTO_NONE
1554  * no protocol.
1555  * GDK_DRAG_PROTO_MOTIF
1556  * The Motif DND protocol. No longer supported
1557  * GDK_DRAG_PROTO_XDND
1558  * The Xdnd protocol.
1559  * GDK_DRAG_PROTO_ROOTWIN
1560  * An extension to the Xdnd protocol for
1561  *  unclaimed root window drops.
1562  * GDK_DRAG_PROTO_WIN32_DROPFILES
1563  * The simple WM_DROPFILES protocol.
1564  * GDK_DRAG_PROTO_OLE2
1565  * The complex OLE2 DND protocol (not implemented).
1566  * GDK_DRAG_PROTO_LOCAL
1567  * Intra-application DND.
1568  */
1569 public enum GdkDragProtocol
1570 {
1571 	NONE = 0,
1572 	MOTIF,
1573 	XDND,
1574 	ROOTWIN,
1575 	WIN32_DROPFILES,
1576 	OLE2,
1577 	LOCAL
1578 }
1579 alias GdkDragProtocol DragProtocol;
1580 
1581 /**
1582  * Used in GdkDragContext to indicate what the destination
1583  * should do with the dropped data.
1584  * GDK_ACTION_DEFAULT
1585  * Means nothing, and should not be used.
1586  * GDK_ACTION_COPY
1587  * Copy the data.
1588  * GDK_ACTION_MOVE
1589  * Move the data, i.e. first copy it, then delete
1590  *  it from the source using the DELETE target of the X selection protocol.
1591  * GDK_ACTION_LINK
1592  * Add a link to the data. Note that this is only
1593  *  useful if source and destination agree on what it means.
1594  * GDK_ACTION_PRIVATE
1595  * Special action which tells the source that the
1596  *  destination will do something that the source doesn't understand.
1597  * GDK_ACTION_ASK
1598  * Ask the user what to do with the data.
1599  */
1600 public enum GdkDragAction
1601 {
1602 	ACTION_DEFAULT = 1 << 0,
1603 	ACTION_COPY = 1 << 1,
1604 	ACTION_MOVE = 1 << 2,
1605 	ACTION_LINK = 1 << 3,
1606 	ACTION_PRIVATE = 1 << 4,
1607 	ACTION_ASK = 1 << 5
1608 }
1609 alias GdkDragAction DragAction;
1610 
1611 /**
1612  * Describes how existing data is combined with new data when
1613  * using gdk_property_change().
1614  * GDK_PROP_MODE_REPLACE
1615  * the new data replaces the existing data.
1616  * GDK_PROP_MODE_PREPEND
1617  * the new data is prepended to the existing data.
1618  * GDK_PROP_MODE_APPEND
1619  * the new data is appended to the existing data.
1620  */
1621 public enum GdkPropMode
1622 {
1623 	MODE_REPLACE,
1624 	MODE_PREPEND,
1625 	MODE_APPEND
1626 }
1627 alias GdkPropMode PropMode;
1628 
1629 
1630 /**
1631  * Main Gtk struct.
1632  */
1633 public struct GdkDisplayManager{}
1634 
1635 
1636 /**
1637  * Main Gtk struct.
1638  */
1639 public struct GdkDisplay{}
1640 
1641 
1642 /**
1643  * Main Gtk struct.
1644  */
1645 public struct GdkScreen{}
1646 
1647 
1648 /**
1649  * Main Gtk struct.
1650  */
1651 public struct GdkDeviceManager{}
1652 
1653 
1654 /**
1655  * Main Gtk struct.
1656  */
1657 public struct GdkDevice{}
1658 
1659 
1660 /**
1661  * The GdkTimeCoord structure stores a single event in a motion history.
1662  * guint32 time;
1663  * The timestamp for this event.
1664  * gdouble axes[GDK_MAX_TIMECOORD_AXES];
1665  * the values of the device's axes.
1666  */
1667 public struct GdkTimeCoord
1668 {
1669 	uint time;
1670 	double axes[GDK_MAX_TIMECOORD_AXES];
1671 }
1672 
1673 
1674 /**
1675  * Defines the x and y coordinates of a point.
1676  * gint x;
1677  * the x coordinate of the point.
1678  * gint y;
1679  * the y coordinate of the point.
1680  */
1681 public struct GdkPoint
1682 {
1683 	int x;
1684 	int y;
1685 }
1686 
1687 
1688 /**
1689  * Main Gtk struct.
1690  * This is the main structure in the gdk-pixbuf; library. It is
1691  * used to represent images. It contains information about the
1692  * image's pixel data, its color space, bits per sample, width and
1693  * height, and the rowstride (the number of bytes between the start of
1694  * one row and the start of the next).
1695  */
1696 public struct GdkPixbuf{}
1697 
1698 
1699 /**
1700  * Main Gtk struct.
1701  * The GdkColor structure is used to describe a color,
1702  * similar to the XColor struct used in the X11 drawing API.
1703  * guint32 pixel;
1704  * For allocated colors, the pixel value used to
1705  * draw this color on the screen. Not used anymore.
1706  * guint16 red;
1707  * The red component of the color. This is
1708  * a value between 0 and 65535, with 65535 indicating
1709  * full intensity
1710  * guint16 green;
1711  * The green component of the color
1712  * guint16 blue;
1713  * The blue component of the color
1714  */
1715 public struct GdkColor
1716 {
1717 	uint pixel;
1718 	ushort red;
1719 	ushort green;
1720 	ushort blue;
1721 }
1722 
1723 
1724 /**
1725  * Main Gtk struct.
1726  * The GdkRGBA structure is used to represent a (possibly translucent)
1727  * color, in a way that is compatible with cairos notion of color.
1728  * gdouble red;
1729  * The intensity of the red channel from 0.0 to 1.0 inclusive
1730  * gdouble green;
1731  * The intensity of the green channel from 0.0 to 1.0 inclusive
1732  * gdouble blue;
1733  * The intensity of the blue channel from 0.0 to 1.0 inclusive
1734  * gdouble alpha;
1735  * The opacity of the color from 0.0 for completely translucent to
1736  * 1.0 for opaque
1737  */
1738 public struct GdkRGBA
1739 {
1740 	double red;
1741 	double green;
1742 	double blue;
1743 	double alpha;
1744 }
1745 
1746 
1747 /**
1748  * Main Gtk struct.
1749  * The GdkVisual structure contains information about
1750  * a particular visual.
1751  */
1752 public struct GdkVisual{}
1753 
1754 
1755 /**
1756  * Main Gtk struct.
1757  * The GdkCursor structure represents a cursor. Its contents are private.
1758  */
1759 public struct GdkCursor{}
1760 
1761 
1762 /**
1763  * Main Gtk struct.
1764  */
1765 public struct GdkWindow{}
1766 
1767 
1768 /**
1769  * The GdkGeometry struct gives the window manager information about
1770  * a window's geometry constraints. Normally you would set these on
1771  * the GTK+ level using gtk_window_set_geometry_hints(). GtkWindow
1772  * then sets the hints on the GdkWindow it creates.
1773  * gdk_window_set_geometry_hints() expects the hints to be fully valid already
1774  * and simply passes them to the window manager; in contrast,
1775  * gtk_window_set_geometry_hints() performs some interpretation. For example,
1776  * GtkWindow will apply the hints to the geometry widget instead of the
1777  * toplevel window, if you set a geometry widget. Also, the
1778  * min_width/min_height/max_width/max_height fields may be set to -1, and
1779  * GtkWindow will substitute the size request of the window or geometry widget.
1780  * If the minimum size hint is not provided, GtkWindow will use its requisition
1781  * as the minimum size. If the minimum size is provided and a geometry widget is
1782  * set, GtkWindow will take the minimum size as the minimum size of the
1783  * geometry widget rather than the entire window. The base size is treated
1784  * similarly.
1785  * The canonical use-case for gtk_window_set_geometry_hints() is to get a
1786  * terminal widget to resize properly. Here, the terminal text area should be
1787  * the geometry widget; GtkWindow will then automatically set the base size to
1788  * the size of other widgets in the terminal window, such as the menubar and
1789  * scrollbar. Then, the width_inc and height_inc fields should be set to the
1790  * size of one character in the terminal. Finally, the base size should be set
1791  * to the size of one character. The net effect is that the minimum size of the
1792  * terminal will have a 1x1 character terminal area, and only terminal sizes on
1793  * the "character grid" will be allowed.
1794  * Here's an example of how the terminal example would be implemented, assuming
1795  * a terminal area widget called "terminal" and a toplevel window "toplevel":
1796  * $(DDOC_COMMENT example)
1797  * The other useful fields are the min_aspect and max_aspect fields; these
1798  * contain a width/height ratio as a floating point number. If a geometry widget
1799  * is set, the aspect applies to the geometry widget rather than the entire
1800  * window. The most common use of these hints is probably to set min_aspect and
1801  * max_aspect to the same value, thus forcing the window to keep a constant
1802  * aspect ratio.
1803  * gint min_width;
1804  * minimum width of window (or -1 to use requisition, with
1805  * GtkWindow only)
1806  * gint min_height;
1807  * minimum height of window (or -1 to use requisition, with
1808  * GtkWindow only)
1809  * gint max_width;
1810  * maximum width of window (or -1 to use requisition, with
1811  * GtkWindow only)
1812  * gint max_height;
1813  * maximum height of window (or -1 to use requisition, with
1814  * GtkWindow only)
1815  * gint base_width;
1816  * allowed window widths are base_width + width_inc * N where N
1817  * is any integer (-1 allowed with GtkWindow)
1818  * gint base_height;
1819  * allowed window widths are base_height + height_inc * N where
1820  * N is any integer (-1 allowed with GtkWindow)
1821  * gint width_inc;
1822  * width resize increment
1823  * gint height_inc;
1824  * height resize increment
1825  * gdouble min_aspect;
1826  * minimum width/height ratio
1827  * gdouble max_aspect;
1828  * maximum width/height ratio
1829  * GdkGravity win_gravity;
1830  * window gravity, see gtk_window_set_gravity()
1831  */
1832 public struct GdkGeometry
1833 {
1834 	int minWidth;
1835 	int minHeight;
1836 	int maxWidth;
1837 	int maxHeight;
1838 	int baseWidth;
1839 	int baseHeight;
1840 	int widthInc;
1841 	int heightInc;
1842 	double minAspect;
1843 	double maxAspect;
1844 	GdkGravity winGravity;
1845 }
1846 
1847 
1848 /**
1849  * Attributes to use for a newly-created window.
1850  * gchar *title;
1851  * title of the window (for toplevel windows)
1852  * gint event_mask;
1853  * event mask (see gdk_window_set_events())
1854  * gint x;
1855  * X coordinate relative to parent window (see gdk_window_move())
1856  * gint y;
1857  * Y coordinate relative to parent window (see gdk_window_move())
1858  * gint width;
1859  * width of window
1860  * gint height;
1861  * height of window
1862  * GdkWindowWindowClass wclass;
1863  * GDK_INPUT_OUTPUT (normal window) or GDK_INPUT_ONLY (invisible
1864  * window that receives events)
1865  * GdkVisual *visual;
1866  * GdkVisual for window
1867  * GdkWindowType window_type;
1868  * type of window
1869  * GdkCursor *cursor;
1870  * cursor for the window (see gdk_window_set_cursor())
1871  * gchar *wmclass_name;
1872  * don't use (see gtk_window_set_wmclass())
1873  * gchar *wmclass_class;
1874  * don't use (see gtk_window_set_wmclass())
1875  * gboolean override_redirect;
1876  * TRUE to bypass the window manager
1877  * GdkWindowTypeHint type_hint;
1878  * a hint of the function of the window
1879  */
1880 public struct GdkWindowAttr
1881 {
1882 	char *title;
1883 	int eventMask;
1884 	int x, y;
1885 	int width;
1886 	int height;
1887 	GdkWindowWindowClass wclass;
1888 	GdkVisual *visual;
1889 	GdkWindowType windowType;
1890 	GdkCursor *cursor;
1891 	char *wmclassName;
1892 	char *wmclassClass;
1893 	int overrideRedirect;
1894 	GdkWindowTypeHint typeHint;
1895 }
1896 
1897 
1898 /**
1899  * Main Gtk struct.
1900  */
1901 public struct GdkFrameClock
1902 {
1903 	GObject parentInstance;
1904 }
1905 
1906 
1907 /**
1908  * Main Gtk struct.
1909  */
1910 public struct GdkFrameTimings
1911 {
1912 	uint refCount;
1913 	long frameCounter;
1914 	ulong cookie;
1915 	long frameTime;
1916 	long drawnTime;
1917 	long presentationTime;
1918 	long refreshInterval;
1919 	long predictedPresentationTime;
1920 	debug
1921 	{
1922 		long layoutStartTime;
1923 		long paintStartTime;
1924 		long frameEndTime;
1925 	}
1926 	uint bitfield0;
1927 	//uint complete : 1;
1928 	//uint sleptBefore : 1;
1929 }
1930 
1931 
1932 public struct GdkEventSequence{}
1933 
1934 
1935 /**
1936  * Contains the fields which are common to all event structs.
1937  * Any event pointer can safely be cast to a pointer to a GdkEventAny to
1938  * access these fields.
1939  * GdkEventType type;
1940  * the type of the event.
1941  * GdkWindow *window;
1942  * the window which received the event.
1943  * gint8 send_event;
1944  * TRUE if the event was sent explicitly (e.g. using
1945  * XSendEvent).
1946  */
1947 public struct GdkEventAny
1948 {
1949 	GdkEventType type;
1950 	GdkWindow *window;
1951 	byte sendEvent;
1952 }
1953 
1954 
1955 /**
1956  * Describes a key press or key release event.
1957  * GdkEventType type;
1958  * the type of the event (GDK_KEY_PRESS or GDK_KEY_RELEASE).
1959  * GdkWindow *window;
1960  * the window which received the event.
1961  * gint8 send_event;
1962  * TRUE if the event was sent explicitly (e.g. using
1963  * XSendEvent).
1964  * guint32 time;
1965  * the time of the event in milliseconds.
1966  * guint state;
1967  * a bit-mask representing the state of
1968  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
1969  * buttons. See GdkModifierType. [type GdkModifierType]
1970  * guint keyval;
1971  * the key that was pressed or released. See the
1972  * <gdk/gdkkeysyms.h> header file for a
1973  * complete list of GDK key codes.
1974  * gint length;
1975  * the length of string.
1976  * gchar *string;
1977  * a string containing an approximation of the text that
1978  * would result from this keypress. The only correct way to handle text
1979  * input of text is using input methods (see GtkIMContext), so this
1980  * field is deprecated and should never be used.
1981  * (gdk_unicode_to_keyval() provides a non-deprecated way of getting
1982  * an approximate translation for a key.) The string is encoded in the
1983  * encoding of the current locale (Note: this for backwards compatibility:
1984  * strings in GTK+ and GDK are typically in UTF-8.) and NUL-terminated.
1985  * In some cases, the translation of the key code will be a single
1986  * NUL byte, in which case looking at length is necessary to distinguish
1987  * it from the an empty translation.
1988  * guint16 hardware_keycode;
1989  * the raw code of the key that was pressed or released.
1990  * guint8 group;
1991  * the keyboard group.
1992  * guint is_modifier : 1;
1993  * a flag that indicates if hardware_keycode is mapped to a
1994  * modifier. Since 2.10
1995  */
1996 public struct GdkEventKey
1997 {
1998 	GdkEventType type;
1999 	GdkWindow *window;
2000 	byte sendEvent;
2001 	uint time;
2002 	uint state;
2003 	uint keyval;
2004 	int length;
2005 	char *string;
2006 	ushort hardwareKeycode;
2007 	ubyte group;
2008 	uint bitfield0;
2009 	//uint isModifier : 1;
2010 }
2011 
2012 
2013 /**
2014  * Used for button press and button release events. The
2015  * type field will be one of GDK_BUTTON_PRESS,
2016  * GDK_2BUTTON_PRESS, GDK_3BUTTON_PRESS or GDK_BUTTON_RELEASE,
2017  * Double and triple-clicks result in a sequence of events being received.
2018  * For double-clicks the order of events will be:
2019  * GDK_BUTTON_PRESS
2020  * GDK_BUTTON_RELEASE
2021  * GDK_BUTTON_PRESS
2022  * GDK_2BUTTON_PRESS
2023  * GDK_BUTTON_RELEASE
2024  * Note that the first click is received just like a normal
2025  * button press, while the second click results in a GDK_2BUTTON_PRESS
2026  * being received just after the GDK_BUTTON_PRESS.
2027  * Triple-clicks are very similar to double-clicks, except that
2028  * GDK_3BUTTON_PRESS is inserted after the third click. The order of the
2029  * events is:
2030  * GDK_BUTTON_PRESS
2031  * GDK_BUTTON_RELEASE
2032  * GDK_BUTTON_PRESS
2033  * GDK_2BUTTON_PRESS
2034  * GDK_BUTTON_RELEASE
2035  * GDK_BUTTON_PRESS
2036  * GDK_3BUTTON_PRESS
2037  * GDK_BUTTON_RELEASE
2038  * For a double click to occur, the second button press must occur within
2039  * 1/4 of a second of the first. For a triple click to occur, the third
2040  * button press must also occur within 1/2 second of the first button press.
2041  * GdkEventType type;
2042  * the type of the event (GDK_BUTTON_PRESS, GDK_2BUTTON_PRESS,
2043  * GDK_3BUTTON_PRESS or GDK_BUTTON_RELEASE).
2044  * GdkWindow *window;
2045  * the window which received the event.
2046  * gint8 send_event;
2047  * TRUE if the event was sent explicitly (e.g. using
2048  * XSendEvent).
2049  * guint32 time;
2050  * the time of the event in milliseconds.
2051  * gdouble x;
2052  * the x coordinate of the pointer relative to the window.
2053  * gdouble y;
2054  * the y coordinate of the pointer relative to the window.
2055  * gdouble *axes;
2056  * x, y translated to the axes of device, or NULL if device is
2057  * the mouse.
2058  * guint state;
2059  * a bit-mask representing the state of
2060  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
2061  * buttons. See GdkModifierType. [type GdkModifierType]
2062  * guint button;
2063  * the button which was pressed or released, numbered from 1 to 5.
2064  * Normally button 1 is the left mouse button, 2 is the middle button,
2065  * and 3 is the right button. On 2-button mice, the middle button can
2066  * often be simulated by pressing both mouse buttons together.
2067  * GdkDevice *device;
2068  * the device where the event originated.
2069  * gdouble x_root;
2070  * the x coordinate of the pointer relative to the root of the
2071  * screen.
2072  * gdouble y_root;
2073  * the y coordinate of the pointer relative to the root of the
2074  * screen.
2075  */
2076 public struct GdkEventButton
2077 {
2078 	GdkEventType type;
2079 	GdkWindow *window;
2080 	byte sendEvent;
2081 	uint time;
2082 	double x;
2083 	double y;
2084 	double *axes;
2085 	uint state;
2086 	uint button;
2087 	GdkDevice *device;
2088 	double xRoot, yRoot;
2089 }
2090 
2091 
2092 /**
2093  * Used for touch events.
2094  * type field will be one of GDK_TOUCH_BEGIN, GDK_TOUCH_UPDATE,
2095  * GDK_TOUCH_END or GDK_TOUCH_CANCEL.
2096  * Touch events are grouped into sequences by means of the sequence
2097  * field, which can also be obtained with gdk_event_get_event_sequence().
2098  * Each sequence begins with a GDK_TOUCH_BEGIN event, followed by
2099  * any number of GDK_TOUCH_UPDATE events, and ends with a GDK_TOUCH_END
2100  * (or GDK_TOUCH_CANCEL) event. With multitouch devices, there may be
2101  * several active sequences at the same time.
2102  * GdkEventType type;
2103  * the type of the event (GDK_TOUCH_BEGIN, GDK_TOUCH_UPDATE,
2104  * GDK_TOUCH_END, GDK_TOUCH_CANCEL)
2105  * GdkWindow *window;
2106  * the window which received the event
2107  * gint8 send_event;
2108  * TRUE if the event was sent explicitly (e.g. using
2109  * XSendEvent)
2110  * guint32 time;
2111  * the time of the event in milliseconds.
2112  * gdouble x;
2113  * the x coordinate of the pointer relative to the window
2114  * gdouble y;
2115  * the y coordinate of the pointer relative to the window
2116  * gdouble *axes;
2117  * x, y translated to the axes of device, or NULL if device is
2118  * the mouse
2119  * guint state;
2120  * a bit-mask representing the state of
2121  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
2122  * buttons. See GdkModifierType. [type GdkModifierType]
2123  * GdkEventSequence *sequence;
2124  * the event sequence that the event belongs to
2125  * gboolean emulating_pointer;
2126  * whether the event should be used for emulating
2127  * pointer event
2128  * GdkDevice *device;
2129  * the device where the event originated
2130  * gdouble x_root;
2131  * the x coordinate of the pointer relative to the root of the
2132  * screen
2133  * gdouble y_root;
2134  * the y coordinate of the pointer relative to the root of the
2135  * screen
2136  */
2137 public struct GdkEventTouch
2138 {
2139 	GdkEventType type;
2140 	GdkWindow *window;
2141 	byte sendEvent;
2142 	uint time;
2143 	double x;
2144 	double y;
2145 	double *axes;
2146 	uint state;
2147 	GdkEventSequence *sequence;
2148 	int emulatingPointer;
2149 	GdkDevice *device;
2150 	double xRoot, yRoot;
2151 }
2152 
2153 
2154 /**
2155  * Generated from button presses for the buttons 4 to 7. Wheel mice are
2156  * usually configured to generate button press events for buttons 4 and 5
2157  * when the wheel is turned.
2158  * Some GDK backends can also generate 'smooth' scroll events, which
2159  * can be recognized by the GDK_SCROLL_SMOOTH scroll direction. For
2160  * these, the scroll deltas can be obtained with
2161  * gdk_event_get_scroll_deltas().
2162  * GdkEventType type;
2163  * the type of the event (GDK_SCROLL).
2164  * GdkWindow *window;
2165  * the window which received the event.
2166  * gint8 send_event;
2167  * TRUE if the event was sent explicitly (e.g. using
2168  * XSendEvent).
2169  * guint32 time;
2170  * the time of the event in milliseconds.
2171  * gdouble x;
2172  * the x coordinate of the pointer relative to the window.
2173  * gdouble y;
2174  * the y coordinate of the pointer relative to the window.
2175  * guint state;
2176  * a bit-mask representing the state of
2177  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
2178  * buttons. See GdkModifierType. [type GdkModifierType]
2179  * GdkScrollDirection direction;
2180  * the direction to scroll to (one of GDK_SCROLL_UP,
2181  * GDK_SCROLL_DOWN, GDK_SCROLL_LEFT, GDK_SCROLL_RIGHT or
2182  * GDK_SCROLL_SMOOTH).
2183  * GdkDevice *device;
2184  * the device where the event originated.
2185  * gdouble x_root;
2186  * the x coordinate of the pointer relative to the root of the
2187  * screen.
2188  * gdouble y_root;
2189  * the y coordinate of the pointer relative to the root of the
2190  * screen.
2191  * gdouble delta_x;
2192  * gdouble delta_y;
2193  */
2194 public struct GdkEventScroll
2195 {
2196 	GdkEventType type;
2197 	GdkWindow *window;
2198 	byte sendEvent;
2199 	uint time;
2200 	double x;
2201 	double y;
2202 	uint state;
2203 	GdkScrollDirection direction;
2204 	GdkDevice *device;
2205 	double xRoot, yRoot;
2206 	double deltaX;
2207 	double deltaY;
2208 }
2209 
2210 
2211 /**
2212  * Generated when the pointer moves.
2213  * GdkEventType type;
2214  * the type of the event.
2215  * GdkWindow *window;
2216  * the window which received the event.
2217  * gint8 send_event;
2218  * TRUE if the event was sent explicitly (e.g. using
2219  * XSendEvent).
2220  * guint32 time;
2221  * the time of the event in milliseconds.
2222  * gdouble x;
2223  * the x coordinate of the pointer relative to the window.
2224  * gdouble y;
2225  * the y coordinate of the pointer relative to the window.
2226  * gdouble *axes;
2227  * x, y translated to the axes of device, or NULL if device is
2228  * the mouse.
2229  * guint state;
2230  * a bit-mask representing the state of
2231  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
2232  * buttons. See GdkModifierType. [type GdkModifierType]
2233  * gint16 is_hint;
2234  * set to 1 if this event is just a hint, see the
2235  * GDK_POINTER_MOTION_HINT_MASK value of GdkEventMask.
2236  * GdkDevice *device;
2237  * the device where the event originated.
2238  * gdouble x_root;
2239  * the x coordinate of the pointer relative to the root of the
2240  * screen.
2241  * gdouble y_root;
2242  * the y coordinate of the pointer relative to the root of the
2243  * screen.
2244  */
2245 public struct GdkEventMotion
2246 {
2247 	GdkEventType type;
2248 	GdkWindow *window;
2249 	byte sendEvent;
2250 	uint time;
2251 	double x;
2252 	double y;
2253 	double *axes;
2254 	uint state;
2255 	short isHint;
2256 	GdkDevice *device;
2257 	double xRoot, yRoot;
2258 }
2259 
2260 
2261 /**
2262  * Generated when all or part of a window becomes visible and needs to be
2263  * redrawn.
2264  * GdkEventType type;
2265  * the type of the event (GDK_EXPOSE or GDK_DAMAGE).
2266  * GdkWindow *window;
2267  * the window which received the event.
2268  * gint8 send_event;
2269  * TRUE if the event was sent explicitly (e.g. using
2270  * XSendEvent).
2271  * GdkRectangle area;
2272  * bounding box of region.
2273  * cairo_region_t *region;
2274  * the region that needs to be redrawn.
2275  * gint count;
2276  * the number of contiguous GDK_EXPOSE events following this one.
2277  * The only use for this is "exposure compression", i.e. handling all
2278  * contiguous GDK_EXPOSE events in one go, though GDK performs some
2279  * exposure compression so this is not normally needed.
2280  */
2281 public struct GdkEventExpose
2282 {
2283 	GdkEventType type;
2284 	GdkWindow *window;
2285 	byte sendEvent;
2286 	Rectangle area;
2287 	cairo_region_t *region;
2288 	int count; /+* If non-zero, how many more events follow. +/
2289 }
2290 
2291 
2292 /**
2293  * Generated when the window visibility status has changed.
2294  * GdkEventType type;
2295  * the type of the event (GDK_VISIBILITY_NOTIFY).
2296  * GdkWindow *window;
2297  * the window which received the event.
2298  * gint8 send_event;
2299  * TRUE if the event was sent explicitly (e.g. using
2300  * XSendEvent).
2301  * GdkVisibilityState state;
2302  * the new visibility state (GDK_VISIBILITY_FULLY_OBSCURED,
2303  * GDK_VISIBILITY_PARTIAL or GDK_VISIBILITY_UNOBSCURED).
2304  */
2305 public struct GdkEventVisibility
2306 {
2307 	GdkEventType type;
2308 	GdkWindow *window;
2309 	byte sendEvent;
2310 	GdkVisibilityState state;
2311 }
2312 
2313 
2314 /**
2315  * Generated when the pointer enters or leaves a window.
2316  * GdkEventType type;
2317  * the type of the event (GDK_ENTER_NOTIFY or GDK_LEAVE_NOTIFY).
2318  * GdkWindow *window;
2319  * the window which received the event.
2320  * gint8 send_event;
2321  * TRUE if the event was sent explicitly (e.g. using
2322  * XSendEvent).
2323  * GdkWindow *subwindow;
2324  * the window that was entered or left.
2325  * guint32 time;
2326  * the time of the event in milliseconds.
2327  * gdouble x;
2328  * the x coordinate of the pointer relative to the window.
2329  * gdouble y;
2330  * the y coordinate of the pointer relative to the window.
2331  * gdouble x_root;
2332  * the x coordinate of the pointer relative to the root of the screen.
2333  * gdouble y_root;
2334  * the y coordinate of the pointer relative to the root of the screen.
2335  * GdkCrossingMode mode;
2336  * the crossing mode (GDK_CROSSING_NORMAL, GDK_CROSSING_GRAB,
2337  * GDK_CROSSING_UNGRAB, GDK_CROSSING_GTK_GRAB, GDK_CROSSING_GTK_UNGRAB or
2338  * GDK_CROSSING_STATE_CHANGED). GDK_CROSSING_GTK_GRAB, GDK_CROSSING_GTK_UNGRAB,
2339  * and GDK_CROSSING_STATE_CHANGED were added in 2.14 and are always synthesized,
2340  * never native.
2341  * GdkNotifyType detail;
2342  * the kind of crossing that happened (GDK_NOTIFY_INFERIOR,
2343  * GDK_NOTIFY_ANCESTOR, GDK_NOTIFY_VIRTUAL, GDK_NOTIFY_NONLINEAR or
2344  * GDK_NOTIFY_NONLINEAR_VIRTUAL).
2345  * gboolean focus;
2346  * TRUE if window is the focus window or an inferior.
2347  * guint state;
2348  * a bit-mask representing the state of
2349  * the modifier keys (e.g. Control, Shift and Alt) and the pointer
2350  * buttons. See GdkModifierType. [type GdkModifierType]
2351  */
2352 public struct GdkEventCrossing
2353 {
2354 	GdkEventType type;
2355 	GdkWindow *window;
2356 	byte sendEvent;
2357 	GdkWindow *subwindow;
2358 	uint time;
2359 	double x;
2360 	double y;
2361 	double xRoot;
2362 	double yRoot;
2363 	GdkCrossingMode mode;
2364 	GdkNotifyType detail;
2365 	int focus;
2366 	uint state;
2367 }
2368 
2369 
2370 /**
2371  * Describes a change of keyboard focus.
2372  * GdkEventType type;
2373  * the type of the event (GDK_FOCUS_CHANGE).
2374  * GdkWindow *window;
2375  * the window which received the event.
2376  * gint8 send_event;
2377  * TRUE if the event was sent explicitly (e.g. using
2378  * XSendEvent).
2379  * gint16 in;
2380  * TRUE if the window has gained the keyboard focus, FALSE if
2381  * it has lost the focus.
2382  */
2383 public struct GdkEventFocus
2384 {
2385 	GdkEventType type;
2386 	GdkWindow *window;
2387 	byte sendEvent;
2388 	short inn;
2389 }
2390 
2391 
2392 /**
2393  * Generated when a window size or position has changed.
2394  * GdkEventType type;
2395  * the type of the event (GDK_CONFIGURE).
2396  * GdkWindow *window;
2397  * the window which received the event.
2398  * gint8 send_event;
2399  * TRUE if the event was sent explicitly (e.g. using
2400  * XSendEvent).
2401  * gint x;
2402  * the new x coordinate of the window, relative to its parent.
2403  * gint y;
2404  * the new y coordinate of the window, relative to its parent.
2405  * gint width;
2406  * the new width of the window.
2407  * gint height;
2408  * the new height of the window.
2409  */
2410 public struct GdkEventConfigure
2411 {
2412 	GdkEventType type;
2413 	GdkWindow *window;
2414 	byte sendEvent;
2415 	int x, y;
2416 	int width;
2417 	int height;
2418 }
2419 
2420 
2421 /**
2422  * Describes a property change on a window.
2423  * GdkEventType type;
2424  * the type of the event (GDK_PROPERTY_NOTIFY).
2425  * GdkWindow *window;
2426  * the window which received the event.
2427  * gint8 send_event;
2428  * TRUE if the event was sent explicitly (e.g. using
2429  * XSendEvent).
2430  * GdkAtom atom;
2431  * the property that was changed.
2432  * guint32 time;
2433  * the time of the event in milliseconds.
2434  * guint state;
2435  * whether the property was changed
2436  * (GDK_PROPERTY_NEW_VALUE) or deleted (GDK_PROPERTY_DELETE). [type GdkPropertyState]
2437  */
2438 public struct GdkEventProperty
2439 {
2440 	GdkEventType type;
2441 	GdkWindow *window;
2442 	byte sendEvent;
2443 	GdkAtom atom;
2444 	uint time;
2445 	uint state;
2446 }
2447 
2448 
2449 /**
2450  * Generated when a selection is requested or ownership of a selection
2451  * is taken over by another client application.
2452  * GdkEventType type;
2453  * the type of the event (GDK_SELECTION_CLEAR,
2454  * GDK_SELECTION_NOTIFY or GDK_SELECTION_REQUEST).
2455  * GdkWindow *window;
2456  * the window which received the event.
2457  * gint8 send_event;
2458  * TRUE if the event was sent explicitly (e.g. using
2459  * XSendEvent).
2460  * GdkAtom selection;
2461  * the selection.
2462  * GdkAtom target;
2463  * the target to which the selection should be converted.
2464  * GdkAtom property;
2465  * the property in which to place the result of the conversion.
2466  * guint32 time;
2467  * the time of the event in milliseconds.
2468  * GdkWindow *requestor;
2469  * the window on which to place property or NULL if none.
2470  */
2471 public struct GdkEventSelection
2472 {
2473 	GdkEventType type;
2474 	GdkWindow *window;
2475 	byte sendEvent;
2476 	GdkAtom selection;
2477 	GdkAtom target;
2478 	GdkAtom property;
2479 	uint time;
2480 	GdkWindow *requestor;
2481 }
2482 
2483 
2484 /**
2485  * Generated during DND operations.
2486  * GdkEventType type;
2487  * the type of the event (GDK_DRAG_ENTER, GDK_DRAG_LEAVE,
2488  * GDK_DRAG_MOTION, GDK_DRAG_STATUS, GDK_DROP_START or
2489  * GDK_DROP_FINISHED).
2490  * GdkWindow *window;
2491  * the window which received the event.
2492  * gint8 send_event;
2493  * TRUE if the event was sent explicitly (e.g. using
2494  * XSendEvent).
2495  * GdkDragContext *context;
2496  * the GdkDragContext for the current DND operation.
2497  * guint32 time;
2498  * the time of the event in milliseconds.
2499  * gshort x_root;
2500  * the x coordinate of the pointer relative to the root of the
2501  * screen, only set for GDK_DRAG_MOTION and GDK_DROP_START.
2502  * gshort y_root;
2503  * the y coordinate of the pointer relative to the root of the
2504  * screen, only set for GDK_DRAG_MOTION and GDK_DROP_START.
2505  */
2506 public struct GdkEventDND
2507 {
2508 	GdkEventType type;
2509 	GdkWindow *window;
2510 	byte sendEvent;
2511 	GdkDragContext *context;
2512 	uint time;
2513 	short xRoot, yRoot;
2514 }
2515 
2516 
2517 /**
2518  * Proximity events are generated when using GDK's wrapper for the
2519  * XInput extension. The XInput extension is an add-on for standard X
2520  * that allows you to use nonstandard devices such as graphics tablets.
2521  * A proximity event indicates that the stylus has moved in or out of
2522  * contact with the tablet, or perhaps that the user's finger has moved
2523  * in or out of contact with a touch screen.
2524  * This event type will be used pretty rarely. It only is important for
2525  * XInput aware programs that are drawing their own cursor.
2526  * GdkEventType type;
2527  * the type of the event (GDK_PROXIMITY_IN or GDK_PROXIMITY_OUT).
2528  * GdkWindow *window;
2529  * the window which received the event.
2530  * gint8 send_event;
2531  * TRUE if the event was sent explicitly (e.g. using XSendEvent).
2532  * guint32 time;
2533  * the time of the event in milliseconds.
2534  * GdkDevice *device;
2535  * the device where the event originated.
2536  */
2537 public struct GdkEventProximity
2538 {
2539 	GdkEventType type;
2540 	GdkWindow *window;
2541 	byte sendEvent;
2542 	uint time;
2543 	GdkDevice *device;
2544 }
2545 
2546 
2547 /**
2548  * Generated when the state of a toplevel window changes.
2549  * GdkEventType type;
2550  * the type of the event (GDK_WINDOW_STATE).
2551  * GdkWindow *window;
2552  * the window which received the event.
2553  * gint8 send_event;
2554  * TRUE if the event was sent explicitly (e.g. using
2555  * XSendEvent).
2556  * GdkWindowState changed_mask;
2557  * mask specifying what flags have changed.
2558  * GdkWindowState new_window_state;
2559  * the new window state, a combination of
2560  * GdkWindowState bits.
2561  */
2562 public struct GdkEventWindowState
2563 {
2564 	GdkEventType type;
2565 	GdkWindow *window;
2566 	byte sendEvent;
2567 	GdkWindowState changedMask;
2568 	GdkWindowState newWindowState;
2569 }
2570 
2571 
2572 /**
2573  * Generated when a setting is modified.
2574  * GdkEventType type;
2575  * the type of the event (GDK_SETTING).
2576  * GdkWindow *window;
2577  * the window which received the event.
2578  * gint8 send_event;
2579  * TRUE if the event was sent explicitly (e.g. using
2580  * XSendEvent).
2581  * GdkSettingAction action;
2582  * what happened to the setting (GDK_SETTING_ACTION_NEW,
2583  * GDK_SETTING_ACTION_CHANGED or GDK_SETTING_ACTION_DELETED).
2584  * char *name;
2585  * the name of the setting.
2586  */
2587 public struct GdkEventSetting
2588 {
2589 	GdkEventType type;
2590 	GdkWindow *window;
2591 	byte sendEvent;
2592 	GdkSettingAction action;
2593 	char *name;
2594 }
2595 
2596 
2597 /**
2598  * Generated when the owner of a selection changes. On X11, this
2599  * information is only available if the X server supports the XFIXES
2600  * extension.
2601  * GdkEventType type;
2602  * the type of the event (GDK_OWNER_CHANGE).
2603  * GdkWindow *window;
2604  * the window which received the event
2605  * gint8 send_event;
2606  * TRUE if the event was sent explicitly (e.g. using
2607  * XSendEvent)
2608  * GdkWindow *owner;
2609  * the new owner of the selection, or NULL if there is none
2610  * GdkOwnerChange reason;
2611  * the reason for the ownership change as a GdkOwnerChange value
2612  * GdkAtom selection;
2613  * the atom identifying the selection
2614  * guint32 time;
2615  * the timestamp of the event
2616  * guint32 selection_time;
2617  * the time at which the selection ownership was taken
2618  * over
2619  * Since 2.6
2620  */
2621 public struct GdkEventOwnerChange
2622 {
2623 	GdkEventType type;
2624 	GdkWindow *window;
2625 	byte sendEvent;
2626 	GdkWindow *owner;
2627 	GdkOwnerChange reason;
2628 	GdkAtom selection;
2629 	uint time;
2630 	uint selectionTime;
2631 }
2632 
2633 
2634 /**
2635  * Generated when a pointer or keyboard grab is broken. On X11, this happens
2636  * when the grab window becomes unviewable (i.e. it or one of its ancestors
2637  * is unmapped), or if the same application grabs the pointer or keyboard
2638  * again. Note that implicit grabs (which are initiated by button presses)
2639  * can also cause GdkEventGrabBroken events.
2640  * GdkEventType type;
2641  * the type of the event (GDK_GRAB_BROKEN)
2642  * GdkWindow *window;
2643  * the window which received the event, i.e. the window
2644  * that previously owned the grab
2645  * gint8 send_event;
2646  * TRUE if the event was sent explicitly (e.g. using
2647  * XSendEvent).
2648  * gboolean keyboard;
2649  * TRUE if a keyboard grab was broken, FALSE if a pointer
2650  * grab was broken
2651  * gboolean implicit;
2652  * TRUE if the broken grab was implicit
2653  * GdkWindow *grab_window;
2654  * If this event is caused by another grab in the same
2655  * application, grab_window contains the new grab window. Otherwise
2656  * grab_window is NULL.
2657  * Since 2.8
2658  */
2659 public struct GdkEventGrabBroken
2660 {
2661 	GdkEventType type;
2662 	GdkWindow *window;
2663 	byte sendEvent;
2664 	int keyboard;
2665 	int implicit;
2666 	GdkWindow *grabWindow;
2667 }
2668 
2669 
2670 /**
2671  * Main Gtk struct.
2672  * A GdkKeymap defines the translation from keyboard state
2673  * (including a hardware key, a modifier mask, and active keyboard group)
2674  * to a keyval. This translation has two phases. The first phase is
2675  * to determine the effective keyboard group and level for the keyboard
2676  * state; the second phase is to look up the keycode/group/level triplet
2677  * in the keymap and see what keyval it corresponds to.
2678  */
2679 public struct GdkKeymap{}
2680 
2681 
2682 /**
2683  * A GdkKeymapKey is a hardware key that can be mapped to a keyval.
2684  * guint keycode;
2685  * the hardware keycode. This is an identifying number for a
2686  * physical key.
2687  * gint group;
2688  * indicates movement in a horizontal direction. Usually groups are used
2689  * for two different languages. In group 0, a key might have two English
2690  * characters, and in group 1 it might have two Hebrew characters. The Hebrew
2691  * characters will be printed on the key next to the English characters.
2692  * gint level;
2693  * indicates which symbol on the key will be used, in a vertical direction.
2694  * So on a standard US keyboard, the key with the number "1" on it also has the
2695  * exclamation point ("!") character on it. The level indicates whether to use
2696  * the "1" or the "!" symbol. The letter keys are considered to have a lowercase
2697  * letter at level 0, and an uppercase letter at level 1, though only the
2698  * uppercase letter is printed.
2699  */
2700 public struct GdkKeymapKey
2701 {
2702 	uint keycode;
2703 	int group;
2704 	int level;
2705 }
2706 
2707 
2708 /**
2709  * Main Gtk struct.
2710  */
2711 public struct GdkDragContext{}
2712 
2713 
2714 /**
2715  * An opaque type representing a string as an index into a table
2716  * of strings on the X server.
2717  */
2718 public struct GdkAtom{}
2719 
2720 
2721 /**
2722  * Main Gtk struct.
2723  */
2724 public struct GdkAppLaunchContext{}
2725 
2726 
2727 /*
2728  * Converts a GdkAtom into a pointer type.
2729  * atom :
2730  * a GdkAtom.
2731  */
2732 // TODO
2733 // #define GDK_ATOM_TO_POINTER(atom) (atom)
2734 
2735 /*
2736  * Extracts a GdkAtom from a pointer. The GdkAtom must have been
2737  * stored in the pointer with GDK_ATOM_TO_POINTER().
2738  * ptr :
2739  * a pointer containing a GdkAtom.
2740  */
2741 // TODO
2742 // #define GDK_POINTER_TO_ATOM(ptr) ((GdkAtom)(ptr))
2743 
2744 /*
2745  * Returns the X window belonging to a GdkWindow.
2746  * win :
2747  * a GdkWindow.
2748  * Returns :
2749  * the Xlib Window of win.
2750  */
2751 // TODO
2752 // #define GDK_WINDOW_XID(win)
2753 
2754 /*
2755  */
2756 // TODO
2757 // #define GDK_DISPLAY_XDISPLAY(display)
2758 
2759 /*
2760  * Returns the display of a X11 GdkScreen.
2761  * screen :
2762  * a GdkScreen
2763  * Returns :
2764  * an Xlib Display*
2765  */
2766 // TODO
2767 // #define GDK_SCREEN_XDISPLAY(screen)
2768 
2769 /*
2770  * Returns the index of a X11 GdkScreen.
2771  * screen :
2772  * a GdkScreen
2773  * Returns :
2774  * the position of screen among the screens of its display
2775  */
2776 // TODO
2777 // #define GDK_SCREEN_XNUMBER(screen) (gdk_x11_screen_get_screen_number (screen))
2778 
2779 /*
2780  * Returns the screen of a X11 GdkScreen.
2781  * screen :
2782  * a GdkScreen
2783  * Returns :
2784  * an Xlib Screen*
2785  */
2786 // TODO
2787 // #define GDK_SCREEN_XSCREEN(screen) (gdk_x11_screen_get_xscreen (screen))
2788 
2789 /*
2790  * Returns the X cursor belonging to a GdkCursor.
2791  * cursor :
2792  * a GdkCursor.
2793  * Returns :
2794  * an Xlib Cursor.
2795  */
2796 // TODO
2797 // #define GDK_CURSOR_XCURSOR(cursor) (gdk_x11_cursor_get_xcursor (cursor))
2798 
2799 /*
2800  * Returns the display of a GdkCursor.
2801  * cursor :
2802  * a GdkCursor.
2803  * Returns :
2804  * an Xlib Display*.
2805  */
2806 // TODO
2807 // #define GDK_CURSOR_XDISPLAY(cursor) (gdk_x11_cursor_get_xdisplay (cursor))
2808 
2809 /*
2810  * Converts a gpointer back to an XID that was previously converted
2811  * using GDK_XID_TO_POINTER().
2812  */
2813 // TODO
2814 // #define GDK_POINTER_TO_XID(pointer) GPOINTER_TO_UINT(pointer)
2815 
2816 /*
2817  * Converts an XID into a gpointer. This is useful with data structures
2818  * that use pointer arguments such as GHashTable. Use GDK_POINTER_TO_XID()
2819  * to convert the argument back to an XID.
2820  */
2821 // TODO
2822 // #define GDK_XID_TO_POINTER(pointer) GUINT_TO_POINTER(pointer)
2823 
2824 /*
2825  * A function of this type is responsible for freeing the pixel array
2826  * of a pixbuf. The gdk_pixbuf_new_from_data() function lets you
2827  * pass in a pre-allocated pixel array so that a pixbuf can be
2828  * created from it; in this case you will need to pass in a function
2829  * of GdkPixbufDestroyNotify so that the pixel data can be freed
2830  * when the pixbuf is finalized.
2831  * pixels :
2832  * The pixel array of the pixbuf
2833  * that is being finalized. [array][element-type guint8]
2834  * data :
2835  * User closure data. [closure]
2836  * See Also
2837  * GdkPixbuf, gdk_pixbuf_new_from_data().
2838  */
2839 // void (*GdkPixbufDestroyNotify) (guchar *pixels,  gpointer data);
2840 public alias extern(C) void function(guchar* pixels, void* data) GdkPixbufDestroyNotify;
2841 
2842 /*
2843  * Specifies the type of the function passed to
2844  * gdk_pixbuf_save_to_callback(). It is called once for each block of
2845  * bytes that is "written" by gdk_pixbuf_save_to_callback(). If
2846  * successful it should return TRUE. If an error occurs it should set
2847  * error and return FALSE, in which case gdk_pixbuf_save_to_callback()
2848  * will fail with the same error.
2849  * buf :
2850  * bytes to be written. [array length=count][element-type guint8]
2851  * count :
2852  * number of bytes in buf.
2853  * error :
2854  * A location to return an error. [out]
2855  * data :
2856  * user data passed to gdk_pixbuf_save_to_callback(). [closure]
2857  * Returns :
2858  * TRUE if successful, FALSE (with error set) if failed.
2859  * Since 2.4
2860  */
2861 // gboolean (*GdkPixbufSaveFunc) (const gchar *buf,  gsize count,  GError **error,  gpointer data);
2862 public alias extern(C) int function(char* buf, gsize count, GError** error, void* data) GdkPixbufSaveFunc;
2863 
2864 /*
2865  * Whenever some area of the window is invalidated (directly in the
2866  * window or in a child window) this gets called with region in
2867  * the coordinate space of window. You can use region to just
2868  * keep track of the dirty region, or you can actually change
2869  * region in case you are doing display tricks like showing
2870  * a child in multiple places.
2871  * window :
2872  * a GdkWindow
2873  * region :
2874  * a cairo_region_t
2875  * Since 3.10
2876  */
2877 // void (*GdkWindowInvalidateHandlerFunc) (GdkWindow *window,  cairo_region_t *region);
2878 public alias extern(C) void function(GdkWindow* window, cairo_region_t* region) GdkWindowInvalidateHandlerFunc;
2879 
2880 /*
2881  * A function of this type is passed to gdk_window_invalidate_maybe_recurse().
2882  * It gets called for each child of the window to determine whether to
2883  * recursively invalidate it or now.
2884  * window :
2885  * a GdkWindow
2886  * user_data :
2887  * user data
2888  * Returns :
2889  * TRUE to invalidate window recursively
2890  */
2891 // gboolean (*GdkWindowChildFunc) (GdkWindow *window,  gpointer user_data);
2892 public alias extern(C) int function(GdkWindow* window, void* userData) GdkWindowChildFunc;
2893 
2894 /*
2895  * Specifies the type of function used to filter native events before they are
2896  * converted to GDK events.
2897  * When a filter is called, event is unpopulated, except for
2898  * event->window. The filter may translate the native
2899  * event to a GDK event and store the result in event, or handle it without
2900  * translation. If the filter translates the event and processing should
2901  * continue, it should return GDK_FILTER_TRANSLATE.
2902  * xevent :
2903  * the native event to filter.
2904  * event :
2905  * the GDK event to which the X event will be translated.
2906  * data :
2907  * user data set when the filter was installed.
2908  * Returns :
2909  * a GdkFilterReturn value.
2910  */
2911 // GdkFilterReturn (*GdkFilterFunc) (GdkXEvent *xevent,  GdkEvent *event,  gpointer data);
2912 public alias extern(C) GdkFilterReturn function(GdkXEvent* xevent, GdkEvent* event, void* data) GdkFilterFunc;
2913 
2914 /*
2915  * Specifies the type of function passed to gdk_event_handler_set() to
2916  * handle all GDK events.
2917  * event :
2918  * the GdkEvent to process.
2919  * data :
2920  * user data set when the event handler was installed with
2921  * gdk_event_handler_set(). [closure]
2922  */
2923 // void (*GdkEventFunc) (GdkEvent *event,  gpointer data);
2924 public alias extern(C) void function(GdkEvent* event, void* data) GdkEventFunc;
2925 /**
2926  * The GdkEvent struct contains a union of all of the event structs,
2927  * and allows access to the data fields in a number of ways.
2928  * The event type is always the first field in all of the event structs, and
2929  * can always be accessed with the following code, no matter what type of event
2930  * it is:
2931  */
2932 public struct GdkEvent
2933 {
2934 	union
2935 	{
2936 		GdkEventType type;
2937 		GdkEventAny any;
2938 		GdkEventExpose expose;
2939 		GdkEventVisibility visibility;
2940 		GdkEventMotion motion;
2941 		GdkEventButton button;
2942 		GdkEventScroll scroll;
2943 		GdkEventKey key;
2944 		GdkEventCrossing crossing;
2945 		GdkEventFocus focusChange;
2946 		GdkEventConfigure configure;
2947 		GdkEventProperty property;
2948 		GdkEventSelection selection;
2949 		GdkEventOwnerChange ownerChange;
2950 		GdkEventProximity proximity;
2951 		GdkEventDND dnd;
2952 		GdkEventWindowState windowState;
2953 		GdkEventSetting setting;
2954 		GdkEventGrabBroken grabBroken;
2955 	}
2956 }