#include <config.h>
#include <stdio.h>
-#include <stdlib.h>
#include <setjmp.h>
#include <lisp.h>
XtTranslations button_override;
#endif
- if (! pop_up_p) abort (); /* not implemented */
- if (text_input_slot) abort (); /* not implemented */
- if (radio_box) abort (); /* not implemented */
- if (list) abort (); /* not implemented */
+ if (! pop_up_p) emacs_abort (); /* not implemented */
+ if (text_input_slot) emacs_abort (); /* not implemented */
+ if (radio_box) emacs_abort (); /* not implemented */
+ if (list) emacs_abort (); /* not implemented */
if (! actions_initted)
{
break;
val = val->next;
}
- if (! val) abort ();
+ if (! val) emacs_abort ();
user_data = val->call_data;
}
shell = w;
if (! XtIsSubclass (shell, shellWidgetClass))
- abort ();
+ emacs_abort ();
XtVaGetValues (shell, XtNnumChildren, &nkids, NULL);
XtVaGetValues (shell, XtNchildren, &kids, NULL);
if (!kids || !*kids)
- abort ();
+ emacs_abort ();
for (i = 0; i < nkids; i++)
{
widget = kids[i];
if (! widget) return;
id = lw_get_widget_id (widget);
- if (! id) abort ();
+ if (! id) emacs_abort ();
{
widget_info *info = lw_get_widget_info (id);
- if (! info) abort ();
+ if (! info) emacs_abort ();
if (info->selection_cb)
info->selection_cb (widget, id, (XtPointer) -1);
}
#include <unistd.h>
#include <stdio.h>
-#include <stdlib.h>
#include <setjmp.h>
#include <X11/StringDefs.h>
/* WIDGET should be a RowColumn. */
if (!XmIsRowColumn (widget))
- abort ();
+ emacs_abort ();
/* Determine whether WIDGET is a menu bar. */
type = -1;
XtSetArg (al[0], XmNrowColumnType, &type);
XtGetValues (widget, al, 1);
if (type != XmMENU_BAR && type != XmMENU_PULLDOWN && type != XmMENU_POPUP)
- abort ();
+ emacs_abort ();
menubar_p = type == XmMENU_BAR;
/* Add a callback to popups and pulldowns that is called when
/* Check that those are all we have
(the caller should have deleted the rest). */
if (old_num_children != keep_first_children)
- abort ();
+ emacs_abort ();
/* Create the rest. */
for (child_index = keep_first_children; cur; child_index++, cur = cur->next)
if (strcmp (XtName (widget_list[i]), XtName (widget)) == 0)
break;
if (i == old_num_children)
- abort ();
+ emacs_abort ();
if (XmIsCascadeButton (widget_list[i]))
{
menu = XmCreatePulldownMenu (parent, XtName(widget), NULL, 0);
break;
default:
- abort ();
+ emacs_abort ();
}
}
#include <sys/types.h>
#include <stdio.h>
-#include <stdlib.h>
#include "lwlib-int.h"
#include "lwlib-utils.h"
#include <X11/StringDefs.h>
{
printf ("No creation function for widget type %s\n",
instance->info->type);
- abort ();
+ emacs_abort ();
}
instance->widget = (*function) (instance);
if (!instance->widget)
- abort ();
+ emacs_abort ();
/* XtRealizeWidget (instance->widget);*/
}
initialize_widget_instance (instance);
}
if (!instance->widget)
- abort ();
+ emacs_abort ();
return instance->widget;
}
if (XtIsShell (XtParent (w)))
XtRemoveGrab (w);
ungrab_all (w, CurrentTime);
- abort ();
+ emacs_abort ();
}
static void
break;
default:
- abort ();
+ emacs_abort ();
}
}
return 5;
default:
- abort ();
+ emacs_abort ();
}
}
if (!mw->menu.font)
{
fprintf (stderr, "Menu font fixed not found, can't continue.\n");
- abort ();
+ emacs_abort ();
}
}
}
#define offset(field) offsetof (EmacsFrameRec, emacs_frame.field)
static XtResource resources[] = {
- {XtNgeometry, XtCGeometry, XtRString, sizeof (String),
+ {(char *) XtNgeometry, (char *) XtCGeometry, XtRString, sizeof (String),
offset (geometry), XtRString, (XtPointer) 0},
{XtNiconic, XtCIconic, XtRBoolean, sizeof (Boolean),
offset (iconic), XtRImmediate, (XtPointer) False},
- {XtNemacsFrame, XtCEmacsFrame, XtRPointer, sizeof (XtPointer),
+ {(char *) XtNemacsFrame, (char *) XtCEmacsFrame,
+ XtRPointer, sizeof (XtPointer),
offset (frame), XtRImmediate, 0},
- {XtNminibuffer, XtCMinibuffer, XtRInt, sizeof (int),
+ {(char *) XtNminibuffer, (char *) XtCMinibuffer, XtRInt, sizeof (int),
offset (minibuffer), XtRImmediate, (XtPointer)0},
- {XtNunsplittable, XtCUnsplittable, XtRBoolean, sizeof (Boolean),
+ {(char *) XtNunsplittable, (char *) XtCUnsplittable,
+ XtRBoolean, sizeof (Boolean),
offset (unsplittable), XtRImmediate, (XtPointer)0},
- {XtNinternalBorderWidth, XtCInternalBorderWidth, XtRInt, sizeof (int),
+ {(char *) XtNinternalBorderWidth, (char *) XtCInternalBorderWidth,
+ XtRInt, sizeof (int),
offset (internal_border_width), XtRImmediate, (XtPointer)4},
- {XtNinterline, XtCInterline, XtRInt, sizeof (int),
+ {(char *) XtNinterline, (char *) XtCInterline, XtRInt, sizeof (int),
offset (interline), XtRImmediate, (XtPointer)0},
- {XtNforeground, XtCForeground, XtRPixel, sizeof (Pixel),
- offset (foreground_pixel), XtRString, "XtDefaultForeground"},
- {XtNcursorColor, XtCForeground, XtRPixel, sizeof (Pixel),
- offset (cursor_color), XtRString, "XtDefaultForeground"},
- {XtNbarCursor, XtCBarCursor, XtRBoolean, sizeof (Boolean),
+ {(char *) XtNforeground, (char *) XtCForeground, XtRPixel, sizeof (Pixel),
+ offset (foreground_pixel), XtRString, (char *) "XtDefaultForeground"},
+ {(char *) XtNcursorColor, (char *) XtCForeground, XtRPixel, sizeof (Pixel),
+ offset (cursor_color), XtRString, (char *) "XtDefaultForeground"},
+ {(char *) XtNbarCursor, (char *) XtCBarCursor, XtRBoolean, sizeof (Boolean),
offset (bar_cursor), XtRImmediate, (XtPointer)0},
- {XtNvisualBell, XtCVisualBell, XtRBoolean, sizeof (Boolean),
+ {(char *) XtNvisualBell, (char *) XtCVisualBell, XtRBoolean, sizeof (Boolean),
offset (visual_bell), XtRImmediate, (XtPointer)0},
- {XtNbellVolume, XtCBellVolume, XtRInt, sizeof (int),
+ {(char *) XtNbellVolume, (char *) XtCBellVolume, XtRInt, sizeof (int),
offset (bell_volume), XtRImmediate, (XtPointer)0},
};
static EmacsFrameClassRec emacsFrameClassRec = {
{ /* core fields */
/* superclass */ &widgetClassRec,
- /* class_name */ "EmacsFrame",
+ /* class_name */ (char *) "EmacsFrame",
/* widget_size */ sizeof (EmacsFrameRec),
/* class_initialize */ 0,
/* class_part_initialize */ 0,
ac = 0;
XtSetArg (al[ac], XtNmappedWhenManaged, 0); ac++;
- XtSetArg (al[ac], XtNshowGrip, 0); ac++;
- XtSetArg (al[ac], XtNallowResize, 1); ac++;
- XtSetArg (al[ac], XtNresizeToPreferred, 1); ac++;
- XtSetArg (al[ac], XtNemacsFrame, f); ac++;
+ XtSetArg (al[ac], (char *) XtNshowGrip, 0); ac++;
+ XtSetArg (al[ac], (char *) XtNallowResize, 1); ac++;
+ XtSetArg (al[ac], (char *) XtNresizeToPreferred, 1); ac++;
+ XtSetArg (al[ac], (char *) XtNemacsFrame, f); ac++;
XtSetArg (al[ac], XtNvisual, FRAME_X_VISUAL (f)); ac++;
XtSetArg (al[ac], XtNdepth, FRAME_DISPLAY_INFO (f)->n_planes); ac++;
XtSetArg (al[ac], XtNcolormap, FRAME_X_COLORMAP (f)); ac++;
event->button = i;
/* Don't allow any geometry request from the user. */
- XtSetArg (av[ac], XtNgeometry, 0); ac++;
+ XtSetArg (av[ac], (char *) XtNgeometry, 0); ac++;
XtSetValues (menu, av, ac);
/* Display the menu. */
#ifdef USE_X_TOOLKIT
static XrmOptionDescRec emacs_options[] = {
- {"-geometry", ".geometry", XrmoptionSepArg, NULL},
- {"-iconic", ".iconic", XrmoptionNoArg, (XtPointer) "yes"},
-
- {"-internal-border-width", "*EmacsScreen.internalBorderWidth",
- XrmoptionSepArg, NULL},
- {"-ib", "*EmacsScreen.internalBorderWidth", XrmoptionSepArg, NULL},
-
- {"-T", "*EmacsShell.title", XrmoptionSepArg, (XtPointer) NULL},
- {"-wn", "*EmacsShell.title", XrmoptionSepArg, (XtPointer) NULL},
- {"-title", "*EmacsShell.title", XrmoptionSepArg, (XtPointer) NULL},
- {"-iconname", "*EmacsShell.iconName", XrmoptionSepArg, (XtPointer) NULL},
- {"-in", "*EmacsShell.iconName", XrmoptionSepArg, (XtPointer) NULL},
- {"-mc", "*pointerColor", XrmoptionSepArg, (XtPointer) NULL},
- {"-cr", "*cursorColor", XrmoptionSepArg, (XtPointer) NULL}
+ {(char *) "-geometry", (char *) ".geometry", XrmoptionSepArg, NULL},
+ {(char *) "-iconic", (char *) ".iconic", XrmoptionNoArg, (XtPointer) "yes"},
+
+ {(char *) "-internal-border-width",
+ (char *) "*EmacsScreen.internalBorderWidth", XrmoptionSepArg, NULL},
+ {(char *) "-ib", (char *) "*EmacsScreen.internalBorderWidth",
+ XrmoptionSepArg, NULL},
+ {(char *) "-T", (char *) "*EmacsShell.title", XrmoptionSepArg, NULL},
+ {(char *) "-wn", (char *) "*EmacsShell.title", XrmoptionSepArg, NULL},
+ {(char *) "-title", (char *) "*EmacsShell.title", XrmoptionSepArg, NULL},
+ {(char *) "-iconname", (char *) "*EmacsShell.iconName",
+ XrmoptionSepArg, NULL},
+ {(char *) "-in", (char *) "*EmacsShell.iconName", XrmoptionSepArg, NULL},
+ {(char *) "-mc", (char *) "*pointerColor", XrmoptionSepArg, NULL},
+ {(char *) "-cr", (char *) "*cursorColor", XrmoptionSepArg, NULL}
};
/* Whether atimer for Xt timeouts is activated or not. */
int argc = 0;
char *argv[3];
- argv[0] = "";
+ argv[0] = (char *) "";
argc = 1;
if (xrm_option)
{
- argv[argc++] = "-xrm";
+ argv[argc++] = (char *) "-xrm";
argv[argc++] = xrm_option;
}
turn_on_atimers (false);
dpy = dpyinfo->display;
d.addr = (XPointer)&dpy;
d.size = sizeof (Display *);
- fr.addr = XtDefaultFont;
+ fr.addr = (char *) XtDefaultFont;
fr.size = sizeof (XtDefaultFont);
to.size = sizeof (Font *);
to.addr = (XPointer)&font;