440
+ − 1 #ifndef INCLUDED_xlwmenuP_h_
+ − 2 #define INCLUDED_xlwmenuP_h_
428
+ − 3
+ − 4 #include "xlwmenu.h"
+ − 5 #include <X11/CoreP.h>
+ − 6
3094
+ − 7 #ifdef USE_XFT_MENUBARS
+ − 8 #include <X11/Xft/Xft.h>
+ − 9 #endif
+ − 10
+ − 11
428
+ − 12 /* Elements in the stack arrays. */
+ − 13 typedef struct _window_state
+ − 14 {
+ − 15 Window window;
+ − 16 Position x;
+ − 17 Position y;
+ − 18 Dimension width;
+ − 19 Dimension height;
+ − 20 Dimension label_width;
+ − 21 Dimension toggle_width;
+ − 22 } window_state;
+ − 23
+ − 24
+ − 25 /* New fields for the XlwMenu widget instance record */
+ − 26 typedef struct _XlwMenu_part
+ − 27 {
+ − 28 /* slots set by the resources */
+ − 29
3094
+ − 30 #if defined(NEED_MOTIF) && !defined(USE_XFT_MENUBARS)
428
+ − 31 XmFontList font_list;
+ − 32 XmFontList font_list_2;
+ − 33 XmFontList fallback_font_list;
+ − 34 #else
+ − 35 XFontStruct * font;
3094
+ − 36 #ifdef USE_XFT_MENUBARS
+ − 37 /* #### Fix naming convention here */
+ − 38 String renderFontSpec;
+ − 39 XftFont *renderFont;
+ − 40 #endif
428
+ − 41 # ifdef USE_XFONTSET
+ − 42 XFontSet font_set;
+ − 43 # endif
+ − 44 #endif
+ − 45 Dimension font_ascent, font_descent; /* extracted from font/fontlist */
+ − 46
+ − 47 Pixel foreground;
+ − 48 Pixel button_foreground;
+ − 49 Pixel highlight_foreground;
+ − 50 Pixel title_foreground;
+ − 51 Dimension margin;
+ − 52 Dimension horizontal_margin;
+ − 53 Dimension vertical_margin;
+ − 54 Dimension column_spacing;
+ − 55 Dimension shadow_thickness;
+ − 56 Dimension indicator_size;
+ − 57 Pixel top_shadow_color;
+ − 58 Pixel bottom_shadow_color;
+ − 59 Pixel select_color;
3094
+ − 60 #ifdef USE_XFT_MENUBARS
+ − 61 #endif
428
+ − 62 Pixmap top_shadow_pixmap;
+ − 63 Pixmap bottom_shadow_pixmap;
+ − 64 Cursor cursor_shape;
+ − 65 XtCallbackList open;
+ − 66 XtCallbackList select;
+ − 67 widget_value* contents;
+ − 68 int horizontal;
+ − 69 Boolean use_backing_store;
+ − 70 Boolean bounce_down;
+ − 71 Boolean lookup_labels;
+ − 72
+ − 73 /* State of the XlwMenu */
+ − 74 int old_depth;
+ − 75 widget_value** old_stack;
+ − 76 int old_stack_length;
+ − 77
+ − 78 /* New state after the user moved */
+ − 79 int new_depth;
+ − 80 widget_value** new_stack;
+ − 81 int new_stack_length;
+ − 82
+ − 83 /* Window resources */
+ − 84 window_state* windows;
+ − 85 int windows_length;
+ − 86
+ − 87 /* Internal part, set by the XlwMenu */
+ − 88 GC foreground_gc;
+ − 89 GC button_gc;
+ − 90 GC background_gc;
+ − 91 GC inactive_gc;
+ − 92 GC inactive_button_gc;
+ − 93 GC shadow_top_gc;
+ − 94 GC shadow_bottom_gc;
+ − 95 GC select_gc;
+ − 96 GC highlight_gc;
+ − 97 GC title_gc;
+ − 98 Cursor cursor;
+ − 99 Boolean popped_up;
+ − 100 Pixmap gray_pixmap;
+ − 101
+ − 102 /* Stay-up stuff */
+ − 103 Boolean pointer_grabbed;
+ − 104 Boolean next_release_must_exit;
+ − 105 Time menu_post_time, menu_bounce_time;
+ − 106 widget_value * last_selected_val;
+ − 107 } XlwMenuPart;
+ − 108
+ − 109 /* Full instance record declaration */
+ − 110 typedef struct _XlwMenuRec
+ − 111 {
+ − 112 CorePart core;
+ − 113 XlwMenuPart menu;
+ − 114 } XlwMenuRec;
+ − 115
+ − 116 /* New fields for the XlwMenu widget class record */
+ − 117 typedef struct
+ − 118 {
+ − 119 int dummy;
+ − 120 } XlwMenuClassPart;
+ − 121
+ − 122 /* Full class record declaration. */
+ − 123 typedef struct _XlwMenuClassRec
+ − 124 {
+ − 125 CoreClassPart core_class;
+ − 126 XlwMenuClassPart menu_class;
+ − 127 } XlwMenuClassRec;
+ − 128
+ − 129 /* Class pointer. */
+ − 130 extern XlwMenuClassRec xlwMenuClassRec;
+ − 131
440
+ − 132 #endif /* INCLUDED_xlwmenuP_h_ */