aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1994-01-30 03:17:32 +0000
committerRichard M. Stallman1994-01-30 03:17:32 +0000
commit01492d1b7c916d117bce7d634243f2132437f270 (patch)
tree9ee380741008da3893978a0b7de6a13c9822a39d
parentcdee26965a38e6ae869655ee5dd76524586f4c24 (diff)
downloademacs-01492d1b7c916d117bce7d634243f2132437f270.tar.gz
emacs-01492d1b7c916d117bce7d634243f2132437f270.zip
*** empty log message ***
-rw-r--r--lwlib/lwlib-int.h7
-rw-r--r--lwlib/lwlib.c2
-rw-r--r--lwlib/lwlib.h47
-rw-r--r--src/widget.c31
4 files changed, 42 insertions, 45 deletions
diff --git a/lwlib/lwlib-int.h b/lwlib/lwlib-int.h
index 0f2c594e7de..3c8534f7ef2 100644
--- a/lwlib/lwlib-int.h
+++ b/lwlib/lwlib-int.h
@@ -32,7 +32,7 @@ typedef struct _widget_info
32} widget_info; 32} widget_info;
33 33
34typedef Widget 34typedef Widget
35(*widget_creation_function) (widget_instance* instance); 35(*widget_creation_function) ();
36 36
37typedef struct _widget_creation_entry 37typedef struct _widget_creation_entry
38{ 38{
@@ -43,12 +43,11 @@ typedef struct _widget_creation_entry
43/* update all other instances of a widget. Can be used in a callback when 43/* update all other instances of a widget. Can be used in a callback when
44 a wiget has been used by the user */ 44 a wiget has been used by the user */
45void 45void
46lw_internal_update_other_instances (Widget widget, XtPointer closure, 46lw_internal_update_other_instances ();
47 XtPointer call_data);
48 47
49/* get the widget_value for a widget in a given instance */ 48/* get the widget_value for a widget in a given instance */
50widget_value* 49widget_value*
51lw_get_widget_value_for_widget (widget_instance* instance, Widget w); 50lw_get_widget_value_for_widget ();
52 51
53#endif /* LWLIB_INTERNAL_H */ 52#endif /* LWLIB_INTERNAL_H */
54 53
diff --git a/lwlib/lwlib.c b/lwlib/lwlib.c
index f9727b991a5..21ca8987f7b 100644
--- a/lwlib/lwlib.c
+++ b/lwlib/lwlib.c
@@ -26,9 +26,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
26#include <sys/types.h> 26#include <sys/types.h>
27#include <string.h> 27#include <string.h>
28#include <stdio.h> 28#include <stdio.h>
29#include <X11/StringDefs.h>
30#include "lwlib-int.h" 29#include "lwlib-int.h"
31#include "lwlib-utils.h" 30#include "lwlib-utils.h"
31#include <X11/StringDefs.h>
32 32
33#if defined(__GNUC__) && !defined(alloca) 33#if defined(__GNUC__) && !defined(alloca)
34#define alloca __builtin_alloca 34#define alloca __builtin_alloca
diff --git a/lwlib/lwlib.h b/lwlib/lwlib.h
index 195bbb5df8b..f52e257bd7a 100644
--- a/lwlib/lwlib.h
+++ b/lwlib/lwlib.h
@@ -66,38 +66,31 @@ typedef struct _widget_value
66} widget_value; 66} widget_value;
67 67
68 68
69typedef void (*lw_callback) (Widget w, LWLIB_ID id, void* data); 69typedef void (*lw_callback) ();
70 70
71void lw_register_widget (char* type, char* name, LWLIB_ID id, 71void lw_register_widget ();
72 widget_value* val, lw_callback pre_activate_cb, 72Widget lw_get_widget ();
73 lw_callback selection_cb, 73Widget lw_make_widget ();
74 lw_callback post_activate_cb); 74Widget lw_create_widget ();
75Widget lw_get_widget (LWLIB_ID id, Widget parent, Boolean pop_up_p); 75LWLIB_ID lw_get_widget_id ();
76Widget lw_make_widget (LWLIB_ID id, Widget parent, Boolean pop_up_p); 76void lw_modify_all_widgets ();
77Widget lw_create_widget (char* type, char* name, LWLIB_ID id, 77void lw_destroy_widget ();
78 widget_value* val, Widget parent, Boolean pop_up_p, 78void lw_destroy_all_widgets ();
79 lw_callback pre_activate_cb, 79void lw_destroy_everything ();
80 lw_callback selection_cb, 80void lw_destroy_all_pop_ups ();
81 lw_callback post_activate_cb); 81Widget lw_raise_all_pop_up_widgets ();
82LWLIB_ID lw_get_widget_id (Widget w); 82widget_value* lw_get_all_values ();
83void lw_modify_all_widgets (LWLIB_ID id, widget_value* val, Boolean deep_p); 83Boolean lw_get_some_values ();
84void lw_destroy_widget (Widget w); 84void lw_pop_up_all_widgets ();
85void lw_destroy_all_widgets (LWLIB_ID id); 85void lw_pop_down_all_widgets ();
86void lw_destroy_everything (void);
87void lw_destroy_all_pop_ups (void);
88Widget lw_raise_all_pop_up_widgets (void);
89widget_value* lw_get_all_values (LWLIB_ID id);
90Boolean lw_get_some_values (LWLIB_ID id, widget_value* val);
91void lw_pop_up_all_widgets (LWLIB_ID id);
92void lw_pop_down_all_widgets (LWLIB_ID id);
93widget_value *malloc_widget_value (); 86widget_value *malloc_widget_value ();
94void free_widget_value (widget_value *); 87void free_widget_value ();
95void lw_popup_menu (Widget); 88void lw_popup_menu ();
96 89
97/* Toolkit independent way of focusing on a Widget at the Xt level. */ 90/* Toolkit independent way of focusing on a Widget at the Xt level. */
98void lw_set_keyboard_focus (Widget parent, Widget w); 91void lw_set_keyboard_focus ();
99 92
100/* Silly Energize hack to invert the "sheet" button */ 93/* Silly Energize hack to invert the "sheet" button */
101void lw_show_busy (Widget w, Boolean busy); 94void lw_show_busy ();
102 95
103#endif /* LWLIB_H */ 96#endif /* LWLIB_H */
diff --git a/src/widget.c b/src/widget.c
index e5092b1eb73..e93fbaf5c6b 100644
--- a/src/widget.c
+++ b/src/widget.c
@@ -58,14 +58,14 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
58#define DEFAULT_FACE_FONT "-*-courier-medium-r-*-*-*-120-*-*-*-*-iso8859-*" 58#define DEFAULT_FACE_FONT "-*-courier-medium-r-*-*-*-120-*-*-*-*-iso8859-*"
59 59
60 60
61static void EmacsFrameInitialize (Widget, Widget, ArgList, Cardinal *); 61static void EmacsFrameInitialize (/*Widget, Widget, ArgList, Cardinal * */);
62static void EmacsFrameDestroy (Widget); 62static void EmacsFrameDestroy (/* Widget */);
63static void EmacsFrameRealize (Widget, XtValueMask*, XSetWindowAttributes*); 63static void EmacsFrameRealize (/* Widget, XtValueMask*, XSetWindowAttributes* */);
64void EmacsFrameResize (Widget widget); 64void EmacsFrameResize (/* Widget widget */);
65static Boolean EmacsFrameSetValues (Widget, Widget, Widget, 65static Boolean EmacsFrameSetValues (/* Widget, Widget, Widget,
66 ArgList, Cardinal *); 66 ArgList, Cardinal * */);
67static XtGeometryResult EmacsFrameQueryGeometry (Widget, XtWidgetGeometry*, 67static XtGeometryResult EmacsFrameQueryGeometry (/* Widget, XtWidgetGeometry*,
68 XtWidgetGeometry*); 68 XtWidgetGeometry* */);
69 69
70 70
71#undef XtOffset 71#undef XtOffset
@@ -162,8 +162,10 @@ EmacsFrameClassRec emacsFrameClassRec = {
162WidgetClass emacsFrameClass = (WidgetClass) &emacsFrameClassRec; 162WidgetClass emacsFrameClass = (WidgetClass) &emacsFrameClassRec;
163 163
164static void 164static void
165get_default_char_pixel_size (EmacsFrame ew, int* pixel_width, 165get_default_char_pixel_size (ew, pixel_width, pixel_height)
166 int* pixel_height) 166 EmacsFrame ew;
167 int* pixel_width;
168 int* pixel_height;
167{ 169{
168/* 170/*
169 *pixel_width = XTextWidth (ew->emacs_frame.font, "n", 1); 171 *pixel_width = XTextWidth (ew->emacs_frame.font, "n", 1);
@@ -176,9 +178,12 @@ get_default_char_pixel_size (EmacsFrame ew, int* pixel_width,
176} 178}
177 179
178static void 180static void
179pixel_to_char_size (EmacsFrame ew, 181pixel_to_char_size (ew, pixel_width, pixel_height, char_width, char_height)
180 Dimension pixel_width, Dimension pixel_height, 182 EmacsFrame ew;
181 int* char_width, int* char_height) 183 Dimension pixel_width;
184 Dimension pixel_height;
185 int* char_width;
186 int* char_height;
182{ 187{
183 struct frame* f = ew->emacs_frame.frame; 188 struct frame* f = ew->emacs_frame.frame;
184 *char_width = PIXEL_TO_CHAR_WIDTH (f, pixel_width); 189 *char_width = PIXEL_TO_CHAR_WIDTH (f, pixel_width);