[TMP] enable load_prefer_newer
[bpt/emacs.git] / oldXMenu / XMenuInt.h
CommitLineData
e745ede7 1/* Copyright Massachusetts Institute of Technology 1985 */
e4187bb0
GM
2
3#include "copyright.h"
4
e745ede7
DL
5
6/*
7 * XMenu: MIT Project Athena, X Window system menu package
8 *
9 * XMenuInternal.h - Internal menu system include file for the
10 * MIT Project Athena XMenu X window system
11 * menu package.
177c0ea7 12 *
e745ede7
DL
13 * Author: Tony Della Fera, DEC
14 * October, 1985
15 */
16
17#ifndef _XMenuInternal_h_
18#define _XMenuInternal_h_
19
47a6e6df
PE
20#include <config.h>
21
e745ede7
DL
22/* Avoid warnings about redefining NULL by including <stdio.h> first;
23 the other file which wants to define it (<stddef.h> on Ultrix
24 systems) can deal if NULL is already defined, but <stdio.h> can't. */
25#include <stdio.h>
26#include <X11/Xlib.h>
27#include "X10.h"
28#include "XMenu.h"
29
30#define min(x, y) ((x) <= (y) ? (x) : (y))
31#define max(x, y) ((x) >= (y) ? (x) : (y))
32#define abs(a) ((a) < 0 ? -(a) : (a))
33
34#define _X_FAILURE -1
35
36#define _SUCCESS 1
37#define _FAILURE -1
38
39/*
40 * XMenu internal event handler variable.
41 */
b782e2d7 42extern int (*_XMEventHandler)(XEvent*);
e745ede7
DL
43
44#ifndef Pixel
45#define Pixel unsigned long
46#endif
47
48/*
49 * Internal routine declarations.
50 */
55660072
PE
51void _XMWinQueInit(void);
52int _XMWinQueAddPane(Display *display, XMenu *menu, XMPane *p_ptr);
53int _XMWinQueAddSelection(Display *display, XMenu *menu, XMSelect *s_ptr);
54int _XMWinQueFlush(Display *display, XMenu *menu, XMPane *pane, XMSelect *select);
55XMPane *_XMGetPanePtr(XMenu *menu, int p_num);
56XMSelect *_XMGetSelectionPtr(XMPane *p_ptr, int s_num);
57void _XMRecomputeGlobals(Display *display, XMenu *menu);
58int _XMRecomputePane(Display *display, XMenu *menu, XMPane *p_ptr, int p_num);
59int _XMRecomputeSelection(Display *display, XMenu *menu, XMSelect *s_ptr, int s_num);
60void _XMTransToOrigin(Display *display, XMenu *menu, XMPane *p_ptr, XMSelect *s_ptr, int x_pos, int y_pos, int *orig_x, int *orig_y);
61void _XMRefreshPane(Display *display, XMenu *menu, XMPane *pane);
62void _XMRefreshSelection(Display *display, XMenu *menu, XMSelect *select);
63void emacs_insque (void *elem, void *prev);
64void emacs_remque (void *elem);
65void XDeleteAssoc(Display *dpy, XAssocTable *table, XID x_id);
66void XDestroyAssocTable(XAssocTable *table);
67void XMakeAssoc(Display *dpy, XAssocTable *table, XID x_id, void *data);
68void XDeleteAssoc(Display *dpy, XAssocTable *table, XID x_id);
e745ede7
DL
69
70#endif
71/* Don't add stuff after this #endif */