diff src/frame-x.c @ 771:943eaba38521

[xemacs-hg @ 2002-03-13 08:51:24 by ben] The big ben-mule-21-5 check-in! Various files were added and deleted. See CHANGES-ben-mule. There are still some test suite failures. No crashes, though. Many of the failures have to do with problems in the test suite itself rather than in the actual code. I'll be addressing these in the next day or so -- none of the test suite failures are at all critical. Meanwhile I'll be trying to address the biggest issues -- i.e. build or run failures, which will almost certainly happen on various platforms. All comments should be sent to ben@xemacs.org -- use a Cc: if necessary when sending to mailing lists. There will be pre- and post- tags, something like pre-ben-mule-21-5-merge-in, and post-ben-mule-21-5-merge-in.
author ben
date Wed, 13 Mar 2002 08:54:06 +0000
parents fdefd0186b75
children e38acbeb1cae
line wrap: on
line diff
--- a/src/frame-x.c	Fri Mar 08 13:33:14 2002 +0000
+++ b/src/frame-x.c	Wed Mar 13 08:54:06 2002 +0000
@@ -1,6 +1,6 @@
 /* Functions for the X window system.
    Copyright (C) 1989, 1992-5, 1997 Free Software Foundation, Inc.
-   Copyright (C) 1995, 1996 Ben Wing.
+   Copyright (C) 1995, 1996, 2001 Ben Wing.
 
 This file is part of XEmacs.
 
@@ -492,13 +492,13 @@
 static Lisp_Object
 color_to_string (Widget w, unsigned long pixel)
 {
-  char buf[255];
+  Intbyte buf[255];
 
   XColor color;
   color.pixel = pixel;
   XQueryColor (XtDisplay (w), w->core.colormap, &color);
-  sprintf (buf, "#%04x%04x%04x", color.red, color.green, color.blue);
-  return build_string (buf);
+  qxesprintf (buf, "#%04x%04x%04x", color.red, color.green, color.blue);
+  return build_intstring (buf);
 }
 
 static void
@@ -578,7 +578,7 @@
   if (EQ (Qinter_line_space, property))
     return make_int (w->emacs_frame.interline);
   if (EQ (Qwindow_id, property))
-    return Fx_window_id (make_frame (f));
+    return Fx_window_id (wrap_frame (f));
 
   return Qunbound;
 }
@@ -611,7 +611,7 @@
   Widget gw = (Widget) w;
   Position x, y;
 
-  props = cons3 (Qwindow_id, Fx_window_id (make_frame (f)), props);
+  props = cons3 (Qwindow_id, Fx_window_id (wrap_frame (f)), props);
   props = cons3 (Qinter_line_space, make_int (w->emacs_frame.interline), props);
 
 #ifdef HAVE_TOOLBARS
@@ -1253,7 +1253,7 @@
 
   GCPRO3 (frame, l_type, l_data);
 
-  frame = make_frame ((struct frame *) clientData);
+  frame = wrap_frame ((struct frame *) clientData);
 
   if (transferInfo->dropData->protocol == DtDND_FILENAME_TRANSFER)
     {
@@ -1295,7 +1295,7 @@
 			   l_data );
  	}
       drag_not_done = 0;
-      unbind_to(speccount, Qnil);
+      unbind_to (speccount);
     }
   else /* the other cases: NOOP_TRANSFER */
     enqueue=0;
@@ -2155,7 +2155,8 @@
 /************************************************************************/
 
 static void
-x_init_frame_1 (struct frame *f, Lisp_Object props)
+x_init_frame_1 (struct frame *f, Lisp_Object props,
+		int frame_name_is_defaulted)
 {
   /* This function can GC */
   Lisp_Object device = FRAME_DEVICE (f);
@@ -2286,11 +2287,11 @@
 */
        (frame))
 {
-  char str[255];
+  Intbyte str[255];
   struct frame *f = decode_x_frame (frame);
 
-  sprintf (str, "%lu", XtWindow (FRAME_X_TEXT_WIDGET (f)));
-  return build_string (str);
+  qxesprintf (str, "%lu", XtWindow (FRAME_X_TEXT_WIDGET (f)));
+  return build_intstring (str);
 }