Mercurial > hg > xemacs-beta
diff src/objects.c @ 563:183866b06e0b
[xemacs-hg @ 2001-05-24 07:50:48 by ben]
Makefile.in.in, abbrev.c, alloc.c, buffer.c, bytecode.c, callint.c, callproc.c, casetab.c, chartab.c, cmdloop.c, cmds.c, console-msw.c, console-msw.h, console-stream.c, console-tty.c, console-x.c, console.c, data.c, database.c, debug.c, device-gtk.c, device-msw.c, device-tty.c, device-x.c, device.c, dialog-gtk.c, dialog-msw.c, dialog-x.c, dialog.c, dired-msw.c, dired.c, doc.c, doprnt.c, dragdrop.c, editfns.c, eldap.c, eldap.h, elhash.c, emacs-widget-accessors.c, emacs.c, emodules.c, esd.c, eval.c, event-Xt.c, event-gtk.c, event-msw.c, event-stream.c, events.c, extents.c, faces.c, file-coding.c, fileio.c, filelock.c, floatfns.c, fns.c, font-lock.c, frame-gtk.c, frame-x.c, frame.c, general-slots.h, glade.c, glyphs-gtk.c, glyphs-msw.c, glyphs-widget.c, glyphs-x.c, glyphs.c, glyphs.h, gpmevent.c, gui-gtk.c, gui-x.c, gui.c, gutter.c, hpplay.c, indent.c, input-method-xlib.c, insdel.c, intl.c, keymap.c, libsst.c, libsst.h, linuxplay.c, lisp.h, lread.c, lstream.c, lstream.h, macros.c, marker.c, md5.c, menubar-gtk.c, menubar-msw.c, menubar-x.c, menubar.c, minibuf.c, miscplay.c, miscplay.h, mule-ccl.c, mule-charset.c, mule-wnnfns.c, mule.c, nas.c, ntplay.c, ntproc.c, objects-gtk.c, objects-msw.c, objects-x.c, objects.c, postgresql.c, print.c, process-nt.c, process-unix.c, process.c, ralloc.c, rangetab.c, redisplay.c, scrollbar.c, search.c, select-gtk.c, select-x.c, select.c, sgiplay.c, sheap.c, sound.c, specifier.c, sunplay.c, symbols.c, symeval.h, symsinit.h, syntax.c, sysdep.c, toolbar-msw.c, toolbar.c, tooltalk.c, ui-byhand.c, ui-gtk.c, undo.c, unexaix.c, unexapollo.c, unexconvex.c, unexec.c, widget.c, win32.c, window.c:
-- defsymbol -> DEFSYMBOL.
-- add an error type to all errors.
-- eliminate the error functions in eval.c that let you just
use Qerror as the type.
-- redo the error API to be more consistent, sensibly named,
and easier to use.
-- redo the error hierarchy somewhat. create new errors:
structure-formation-error, gui-error, invalid-constant,
stack-overflow, out-of-memory, process-error, network-error,
sound-error, printing-unreadable-object, base64-conversion-
error; coding-system-error renamed to text-conversion error;
some others.
-- fix Mule problems in error strings in emodules.c, tooltalk.c.
-- fix error handling in mswin open-network-stream.
-- Mule-ize all sound files and clean up the headers.
-- nativesound.h -> sound.h and used for all sound files.
-- move some shared stuff into glyphs-shared.c: first attempt
at eliminating some of the massive GTK code duplication.
xemacs.mak: add glyphs-shared.c.
xemacs-faq.texi: document how to debug X errors
subr.el: fix doc string to reflect reality
author | ben |
---|---|
date | Thu, 24 May 2001 07:51:33 +0000 |
parents | 3078fd1074e8 |
children | 190b164ddcac |
line wrap: on
line diff
--- a/src/objects.c Thu May 24 06:30:21 2001 +0000 +++ b/src/objects.c Thu May 24 07:51:33 2001 +0000 @@ -45,7 +45,7 @@ Lisp_Object obj; XSETOBJ (obj, ptr); - signal_simple_error + invalid_operation ("Can't dump an emacs containing window system objects", obj); } @@ -74,7 +74,7 @@ char buf[100]; Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj); if (print_readably) - error ("printing unreadable object #<color-instance 0x%x>", + printing_unreadable_object ("#<color-instance 0x%x>", c->header.uid); write_c_string ("#<color-instance ", printcharfun); print_internal (c->name, printcharfun, 0); @@ -254,7 +254,7 @@ char buf[200]; Lisp_Font_Instance *f = XFONT_INSTANCE (obj); if (print_readably) - error ("printing unreadable object #<font-instance 0x%x>", f->header.uid); + printing_unreadable_object ("#<font-instance 0x%x>", f->header.uid); write_c_string ("#<font-instance ", printcharfun); print_internal (f->name, printcharfun, 1); write_c_string (" on ", printcharfun); @@ -421,8 +421,8 @@ if (NILP (f->device)) { - maybe_signal_simple_error ("Couldn't determine font truename", - font_instance, Qfont, errb); + maybe_signal_error (Qgui_error, "Couldn't determine font truename", + font_instance, Qfont, errb); return Qnil; } @@ -545,12 +545,12 @@ if (DEVICE_TTY_P (d)) return Vthe_null_color_instance; else - signal_simple_error ("Color instantiator [] only valid on TTY's", + gui_error ("Color instantiator [] only valid on TTY's", device); case 1: if (NILP (COLOR_SPECIFIER_FACE (XCOLOR_SPECIFIER (specifier)))) - signal_simple_error ("Color specifier not attached to a face", + gui_error ("Color specifier not attached to a face", instantiator); return (FACE_PROPERTY_INSTANCE_1 (Fget_face (XVECTOR_DATA (instantiator)[0]), @@ -571,7 +571,7 @@ if (DEVICE_TTY_P (d)) return Vthe_null_color_instance; else - signal_simple_error ("Color instantiator [] only valid on TTY's", + gui_error ("Color instantiator [] only valid on TTY's", device); } else @@ -588,7 +588,7 @@ if (VECTORP (instantiator)) { if (XVECTOR_LENGTH (instantiator) > 2) - signal_simple_error ("Inheritance vector must be of size 0 - 2", + sferror ("Inheritance vector must be of size 0 - 2", instantiator); else if (XVECTOR_LENGTH (instantiator) > 0) { @@ -599,14 +599,14 @@ { Lisp_Object field = XVECTOR_DATA (instantiator)[1]; if (!EQ (field, Qforeground) && !EQ (field, Qbackground)) - signal_simple_error + invalid_constant ("Inheritance field must be `foreground' or `background'", field); } } } else - signal_simple_error ("Invalid color instantiator", instantiator); + invalid_argument ("Invalid color instantiator", instantiator); } static void @@ -801,13 +801,13 @@ { if (XVECTOR_LENGTH (instantiator) != 1) { - signal_simple_error + sferror ("Vector length must be one for font inheritance", instantiator); } Fget_face (XVECTOR_DATA (instantiator)[0]); } else - signal_simple_error ("Must be string, vector, or font-instance", + invalid_argument ("Must be string, vector, or font-instance", instantiator); } @@ -894,7 +894,7 @@ { if (NILP (FACE_BOOLEAN_SPECIFIER_FACE (XFACE_BOOLEAN_SPECIFIER (specifier)))) - signal_simple_error + gui_error ("Face-boolean specifier not attached to a face", instantiator); prop = FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (XFACE_BOOLEAN_SPECIFIER (specifier)); @@ -937,15 +937,15 @@ && !EQ (field, Qdim) && !EQ (field, Qblinking) && !EQ (field, Qreverse)) - signal_simple_error ("Invalid face-boolean inheritance field", + invalid_constant ("Invalid face-boolean inheritance field", field); } } else if (VECTORP (instantiator)) - signal_simple_error ("Wrong length for face-boolean inheritance spec", + sferror ("Wrong length for face-boolean inheritance spec", instantiator); else - signal_simple_error ("Face-boolean instantiator must be nil, t, or vector", + invalid_argument ("Face-boolean instantiator must be nil, t, or vector", instantiator); } @@ -1000,14 +1000,14 @@ DEFSUBR (Ffont_specifier_p); DEFSUBR (Fface_boolean_specifier_p); - defsymbol (&Qcolor_instancep, "color-instance-p"); + DEFSYMBOL_MULTIWORD_PREDICATE (Qcolor_instancep); DEFSUBR (Fmake_color_instance); DEFSUBR (Fcolor_instance_p); DEFSUBR (Fcolor_instance_name); DEFSUBR (Fcolor_instance_rgb_components); DEFSUBR (Fvalid_color_name_p); - defsymbol (&Qfont_instancep, "font-instance-p"); + DEFSYMBOL_MULTIWORD_PREDICATE (Qfont_instancep); DEFSUBR (Fmake_font_instance); DEFSUBR (Ffont_instance_p); DEFSUBR (Ffont_instance_name); @@ -1020,7 +1020,7 @@ DEFSUBR (Flist_fonts); /* Qcolor, Qfont defined in general.c */ - defsymbol (&Qface_boolean, "face-boolean"); + DEFSYMBOL (Qface_boolean); } static const struct lrecord_description color_specifier_description[] = {