📄 gdktypes.h
字号:
GDK_IC_FILTER_EVENTS = 1 << 3, GDK_IC_SPOT_LOCATION = 1 << 4, GDK_IC_LINE_SPACING = 1 << 5, GDK_IC_CURSOR = 1 << 6, GDK_IC_PREEDIT_FONTSET = 1 << 10, GDK_IC_PREEDIT_AREA = 1 << 11, GDK_IC_PREEDIT_AREA_NEEDED = 1 << 12, GDK_IC_PREEDIT_FOREGROUND = 1 << 13, GDK_IC_PREEDIT_BACKGROUND = 1 << 14, GDK_IC_PREEDIT_PIXMAP = 1 << 15, GDK_IC_PREEDIT_COLORMAP = 1 << 16, GDK_IC_STATUS_FONTSET = 1 << 21, GDK_IC_STATUS_AREA = 1 << 22, GDK_IC_STATUS_AREA_NEEDED = 1 << 23, GDK_IC_STATUS_FOREGROUND = 1 << 24, GDK_IC_STATUS_BACKGROUND = 1 << 25, GDK_IC_STATUS_PIXMAP = 1 << 26, GDK_IC_STATUS_COLORMAP = 1 << 27, GDK_IC_ALL_REQ = GDK_IC_STYLE | GDK_IC_CLIENT_WINDOW, GDK_IC_PREEDIT_AREA_REQ = GDK_IC_PREEDIT_AREA | GDK_IC_PREEDIT_FONTSET, GDK_IC_PREEDIT_POSITION_REQ = GDK_IC_PREEDIT_AREA | GDK_IC_SPOT_LOCATION | GDK_IC_PREEDIT_FONTSET, GDK_IC_STATUS_AREA_REQ = GDK_IC_STATUS_AREA | GDK_IC_STATUS_FONTSET} GdkICAttributesType;/* The next two enumeration values current match the * Motif constants. If this is changed, the implementation * of gdk_window_set_decorations/gdk_window_set_functions * will need to change as well. */typedef enum{ GDK_DECOR_ALL = 1 << 0, GDK_DECOR_BORDER = 1 << 1, GDK_DECOR_RESIZEH = 1 << 2, GDK_DECOR_TITLE = 1 << 3, GDK_DECOR_MENU = 1 << 4, GDK_DECOR_MINIMIZE = 1 << 5, GDK_DECOR_MAXIMIZE = 1 << 6} GdkWMDecoration;typedef enum{ GDK_FUNC_ALL = 1 << 0, GDK_FUNC_RESIZE = 1 << 1, GDK_FUNC_MOVE = 1 << 2, GDK_FUNC_MINIMIZE = 1 << 3, GDK_FUNC_MAXIMIZE = 1 << 4, GDK_FUNC_CLOSE = 1 << 5} GdkWMFunction;typedef void (*GdkInputFunction) (gpointer data, gint source, GdkInputCondition condition);typedef void (*GdkDestroyNotify) (gpointer data);/* Color Context modes. * * GDK_CC_MODE_UNDEFINED - unknown * GDK_CC_MODE_BW - default B/W * GDK_CC_MODE_STD_CMAP - has a standard colormap * GDK_CC_MODE_TRUE - is a TrueColor/DirectColor visual * GDK_CC_MODE_MY_GRAY - my grayramp * GDK_CC_MODE_PALETTE - has a pre-allocated palette */ typedef enum{ GDK_CC_MODE_UNDEFINED, GDK_CC_MODE_BW, GDK_CC_MODE_STD_CMAP, GDK_CC_MODE_TRUE, GDK_CC_MODE_MY_GRAY, GDK_CC_MODE_PALETTE} GdkColorContextMode;/* Types of overlapping between a rectangle and a region * GDK_OVERLAP_RECTANGLE_IN: rectangle is in region * GDK_OVERLAP_RECTANGLE_OUT: rectangle in not in region * GDK_OVERLAP_RECTANGLE_PART: rectangle in partially in region */typedef enum{ GDK_OVERLAP_RECTANGLE_IN, GDK_OVERLAP_RECTANGLE_OUT, GDK_OVERLAP_RECTANGLE_PART} GdkOverlapType;typedef enum { GDK_ACTION_DEFAULT = 1 << 0, GDK_ACTION_COPY = 1 << 1, GDK_ACTION_MOVE = 1 << 2, GDK_ACTION_LINK = 1 << 3, GDK_ACTION_PRIVATE = 1 << 4, GDK_ACTION_ASK = 1 << 5} GdkDragAction;typedef enum { GDK_DRAG_PROTO_MOTIF, GDK_DRAG_PROTO_XDND, GDK_DRAG_PROTO_ROOTWIN, /* A root window with nobody claiming * drags */ GDK_DRAG_PROTO_NONE /* Not a valid drag window */} GdkDragProtocol;/* The color type. * A color consists of red, green and blue values in the * range 0-65535 and a pixel value. The pixel value is highly * dependent on the depth and colormap which this color will * be used to draw into. Therefore, sharing colors between * colormaps is a bad idea. */struct _GdkColor{ gulong pixel; gushort red; gushort green; gushort blue;};/* The colormap type. * Colormaps consist of 256 colors. */struct _GdkColormap{ gint size; GdkColor *colors;};/* The visual type. * "type" is the type of visual this is (PseudoColor, TrueColor, etc). * "depth" is the bit depth of this visual. * "colormap_size" is the size of a colormap for this visual. * "bits_per_rgb" is the number of significant bits per red, green and blue. * The red, green and blue masks, shifts and precisions refer * to value needed to calculate pixel values in TrueColor and DirectColor * visuals. The "mask" is the significant bits within the pixel. The * "shift" is the number of bits left we must shift a primary for it * to be in position (according to the "mask"). "prec" refers to how * much precision the pixel value contains for a particular primary. */struct _GdkVisual{ GdkVisualType type; gint depth; GdkByteOrder byte_order; gint colormap_size; gint bits_per_rgb; guint32 red_mask; gint red_shift; gint red_prec; guint32 green_mask; gint green_shift; gint green_prec; guint32 blue_mask; gint blue_shift; gint blue_prec;};struct _GdkWindowAttr{ gchar *title; gint event_mask; gint16 x, y; gint16 width; gint16 height; GdkWindowClass wclass; GdkVisual *visual; GdkColormap *colormap; GdkWindowType window_type; GdkCursor *cursor; gchar *wmclass_name; gchar *wmclass_class; gboolean override_redirect;};struct _GdkWindow{ gpointer user_data;};struct _GdkGeometry { gint min_width; gint min_height; gint max_width; gint max_height; gint base_width; gint base_height; gint width_inc; gint height_inc; gdouble min_aspect; gdouble max_aspect; /* GdkGravity gravity; */};struct _GdkImage{ GdkImageType type; GdkVisual *visual; /* visual used to create the image */ GdkByteOrder byte_order; guint16 width; guint16 height; guint16 depth; guint16 bpp; /* bytes per pixel */ guint16 bpl; /* bytes per line */ gpointer mem;};struct _GdkGCValues{ GdkColor foreground; GdkColor background; GdkFont *font; GdkFunction function; GdkFill fill; GdkPixmap *tile; GdkPixmap *stipple; GdkPixmap *clip_mask; GdkSubwindowMode subwindow_mode; gint ts_x_origin; gint ts_y_origin; gint clip_x_origin; gint clip_y_origin; gint graphics_exposures; gint line_width; GdkLineStyle line_style; GdkCapStyle cap_style; GdkJoinStyle join_style;};struct _GdkGC{ gint dummy_var;};struct _GdkPoint{ gint16 x; gint16 y;};struct _GdkRectangle{ gint16 x; gint16 y; guint16 width; guint16 height;};struct _GdkSegment{ gint16 x1; gint16 y1; gint16 x2; gint16 y2;};struct _GdkFont{ GdkFontType type; gint ascent; gint descent;};struct _GdkCursor{ GdkCursorType type;};struct _GdkColorContextDither{ gint fast_rgb[32][32][32]; /* quick look-up table for faster rendering */ gint fast_err[32][32][32]; /* internal RGB error information */ gint fast_erg[32][32][32]; gint fast_erb[32][32][32];};struct _GdkColorContext{ GdkVisual *visual; GdkColormap *colormap; gint num_colors; /* available no. of colors in colormap */ gint max_colors; /* maximum no. of colors */ gint num_allocated; /* no. of allocated colors */ GdkColorContextMode mode; gint need_to_free_colormap; GdkAtom std_cmap_atom; gulong *clut; /* color look-up table */ GdkColor *cmap; /* colormap */ GHashTable *color_hash; /* hash table of allocated colors */ GdkColor *palette; /* preallocated palette */ gint num_palette; /* size of palette */ GdkColorContextDither *fast_dither; /* fast dither matrix */ struct { gint red; gint green; gint blue; } shifts; struct { gulong red; gulong green; gulong blue; } masks; struct { gint red; gint green; gint blue; } bits; gulong max_entry; gulong black_pixel; gulong white_pixel;};/* Types for XInput support */struct _GdkDeviceKey{ guint keyval; GdkModifierType modifiers;};struct _GdkDeviceInfo{ guint32 deviceid; gchar *name; GdkInputSource source; GdkInputMode mode; gint has_cursor; /* TRUE if the X pointer follows device motion */ gint num_axes; GdkAxisUse *axes; /* Specifies use for each axis */ gint num_keys; GdkDeviceKey *keys;};struct _GdkTimeCoord{ guint32 time; gdouble x; gdouble y; gdouble pressure; gdouble xtilt; gdouble ytilt;};/* Structure that holds information about a drag in progress. * this is used on both source and destination sides. */struct _GdkDragContext { GdkDragProtocol protocol; gboolean is_source; GdkWindow *source_window; GdkWindow *dest_window; GList *targets; GdkDragAction actions; GdkDragAction suggested_action; GdkDragAction action; guint32 start_time;};/* Event filtering */typedef void GdkXEvent; /* Can be cast to XEvent */typedef GdkFilterReturn (*GdkFilterFunc) (GdkXEvent *xevent, GdkEvent *event, gpointer data);struct _GdkEventAny{ GdkEventType type; GdkWindow *window; gint8 send_event;};struct _GdkEventExpose{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkRectangle area; gint count; /* If non-zero, how many more events follow. */};struct _GdkEventNoExpose{ GdkEventType type; GdkWindow *window; gint8 send_event; /* XXX: does anyone need the X major_code or minor_code fields? */};struct _GdkEventVisibility{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkVisibilityState state;};struct _GdkEventMotion{ GdkEventType type; GdkWindow *window; gint8 send_event; guint32 time; gdouble x; gdouble y; gdouble pressure; gdouble xtilt; gdouble ytilt; guint state; gint16 is_hint; GdkInputSource source; guint32 deviceid; gdouble x_root, y_root;};struct _GdkEventButton{ GdkEventType type; GdkWindow *window; gint8 send_event; guint32 time; gdouble x; gdouble y; gdouble pressure; gdouble xtilt; gdouble ytilt; guint state; guint button; GdkInputSource source; guint32 deviceid; gdouble x_root, y_root;};struct _GdkEventKey{ GdkEventType type; GdkWindow *window; gint8 send_event; guint32 time; guint state; guint keyval; gint length; gchar *string;};struct _GdkEventCrossing{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkWindow *subwindow; guint32 time; gdouble x; gdouble y; gdouble x_root; gdouble y_root; GdkCrossingMode mode; GdkNotifyType detail; gboolean focus; guint state;};struct _GdkEventFocus{ GdkEventType type; GdkWindow *window; gint8 send_event; gint16 in;};struct _GdkEventConfigure{ GdkEventType type; GdkWindow *window; gint8 send_event; gint16 x, y; gint16 width; gint16 height;};struct _GdkEventProperty{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkAtom atom; guint32 time; guint state;};struct _GdkEventSelection{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkAtom selection; GdkAtom target; GdkAtom property; guint32 requestor; guint32 time;};/* This event type will be used pretty rarely. It only is important for XInput aware programs that are drawing their own cursor */struct _GdkEventProximity{ GdkEventType type; GdkWindow *window; gint8 send_event; guint32 time; GdkInputSource source; guint32 deviceid;};struct _GdkEventClient{ GdkEventType type; GdkWindow *window; gint8 send_event; GdkAtom message_type; gushort data_format; union { char b[20]; short s[10]; long l[5]; } data;};/* Event types for DND */struct _GdkEventDND { GdkEventType type; GdkWindow *window; gint8 send_event; GdkDragContext *context; guint32 time; gshort x_root, y_root;};union _GdkEvent{ GdkEventType type; GdkEventAny any; GdkEventExpose expose; GdkEventNoExpose no_expose; GdkEventVisibility visibility; GdkEventMotion motion; GdkEventButton button; GdkEventKey key; GdkEventCrossing crossing; GdkEventFocus focus_change; GdkEventConfigure configure; GdkEventProperty property; GdkEventSelection selection; GdkEventProximity proximity; GdkEventClient client; GdkEventDND dnd;};struct _GdkRegion{ gpointer user_data;};struct _GdkICAttr{ GdkIMStyle style; GdkWindow *client_window; GdkWindow *focus_window; GdkEventMask filter_events; GdkPoint spot_location; gint line_spacing; GdkCursor *cursor; GdkFont *preedit_fontset; GdkRectangle preedit_area; GdkRectangle preedit_area_needed; GdkColor preedit_foreground; GdkColor preedit_background; GdkPixmap *preedit_pixmap; GdkColormap *preedit_colormap; GdkFont *status_fontset; GdkRectangle status_area; GdkRectangle status_area_needed; GdkColor status_foreground; GdkColor status_background; GdkPixmap *status_pixmap; GdkColormap *status_colormap;};#ifdef __cplusplus}#endif /* __cplusplus */#endif /* __GDK_TYPES_H__ */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -