aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1996-06-10 21:08:24 +0000
committerRichard M. Stallman1996-06-10 21:08:24 +0000
commitbb221971650ae2a91e860b5d165c7cab167874ab (patch)
tree08449986aaa887838b9a8a9288d2febac6a82a04 /src
parent6f1817130257d24c9d4b5cca30ccf8f105c12d5f (diff)
downloademacs-bb221971650ae2a91e860b5d165c7cab167874ab.tar.gz
emacs-bb221971650ae2a91e860b5d165c7cab167874ab.zip
(Fset_mouse_position): Remove the DOS-specific
definition (it's defined on `frame.c'). (syms_of_dosfns): Remove defsubr of `Fset_mouse_position'.
Diffstat (limited to 'src')
-rw-r--r--src/frame.c54
1 files changed, 53 insertions, 1 deletions
diff --git a/src/frame.c b/src/frame.c
index 6291147ae73..bfa8046a0ea 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -78,6 +78,7 @@ Lisp_Object Qmenu_bar_lines;
78Lisp_Object Qwidth; 78Lisp_Object Qwidth;
79Lisp_Object Qx; 79Lisp_Object Qx;
80Lisp_Object Qwin32; 80Lisp_Object Qwin32;
81Lisp_Object Qpc;
81Lisp_Object Qvisible; 82Lisp_Object Qvisible;
82Lisp_Object Qbuffer_predicate; 83Lisp_Object Qbuffer_predicate;
83Lisp_Object Qtitle; 84Lisp_Object Qtitle;
@@ -117,6 +118,8 @@ syms_of_frame_1 ()
117 staticpro (&Qx); 118 staticpro (&Qx);
118 Qwin32 = intern ("win32"); 119 Qwin32 = intern ("win32");
119 staticpro (&Qwin32); 120 staticpro (&Qwin32);
121 Qpc = intern ("pc");
122 staticpro (&Qpc);
120 Qvisible = intern ("visible"); 123 Qvisible = intern ("visible");
121 staticpro (&Qvisible); 124 staticpro (&Qvisible);
122 Qbuffer_predicate = intern ("buffer-predicate"); 125 Qbuffer_predicate = intern ("buffer-predicate");
@@ -229,7 +232,8 @@ See also `frame-live-p'.")
229 return Qx; 232 return Qx;
230 case output_win32: 233 case output_win32:
231 return Qwin32; 234 return Qwin32;
232 /* The `pc' case is in the Fframep below. */ 235 case output_msdos_raw:
236 return Qpc;
233 default: 237 default:
234 abort (); 238 abort ();
235 } 239 }
@@ -498,7 +502,13 @@ make_terminal_frame ()
498 502
499 f->visible = 1; /* FRAME_SET_VISIBLE wd set frame_garbaged. */ 503 f->visible = 1; /* FRAME_SET_VISIBLE wd set frame_garbaged. */
500 f->async_visible = 1; /* Don't let visible be cleared later. */ 504 f->async_visible = 1; /* Don't let visible be cleared later. */
505#ifdef MSDOS
506 f->output_data.x = &the_only_x_display;
507 f->output_method = output_msdos_raw;
508 init_frame_faces (f);
509#else /* not MSDOS */
501 f->output_data.nothing = 1; /* Nonzero means frame isn't deleted. */ 510 f->output_data.nothing = 1; /* Nonzero means frame isn't deleted. */
511#endif
502 return f; 512 return f;
503} 513}
504 514
@@ -515,8 +525,13 @@ Note that changing the size of one terminal frame automatically affects all.")
515 struct frame *f; 525 struct frame *f;
516 Lisp_Object frame; 526 Lisp_Object frame;
517 527
528#ifdef __MSDOS__
529 if (selected_frame->output_method != output_msdos_raw)
530 abort ();
531#else
518 if (selected_frame->output_method != output_termcap) 532 if (selected_frame->output_method != output_termcap)
519 error ("Not using an ASCII terminal now; cannot make a new ASCII frame"); 533 error ("Not using an ASCII terminal now; cannot make a new ASCII frame");
534#endif
520 535
521 f = make_terminal_frame (); 536 f = make_terminal_frame ();
522 change_frame_size (f, FRAME_HEIGHT (selected_frame), 537 change_frame_size (f, FRAME_HEIGHT (selected_frame),
@@ -1326,6 +1341,14 @@ before calling this function on it, like this.\n\
1326 if (FRAME_WINDOW_P (XFRAME (frame))) 1341 if (FRAME_WINDOW_P (XFRAME (frame)))
1327 /* Warping the mouse will cause enternotify and focus events. */ 1342 /* Warping the mouse will cause enternotify and focus events. */
1328 x_set_mouse_position (XFRAME (frame), x, y); 1343 x_set_mouse_position (XFRAME (frame), x, y);
1344#else
1345#if defined(MSDOS) && defined(HAVE_MOUSE)
1346 if (FRAME_MSDOS_P (XFRAME (frame)))
1347 {
1348 Fselect_frame (frame, Qnil);
1349 mouse_moveto (XINT (x), XINT (y));
1350 }
1351#endif
1329#endif 1352#endif
1330 1353
1331 return Qnil; 1354 return Qnil;
@@ -1350,6 +1373,14 @@ before calling this function on it, like this.\n\
1350 if (FRAME_WINDOW_P (XFRAME (frame))) 1373 if (FRAME_WINDOW_P (XFRAME (frame)))
1351 /* Warping the mouse will cause enternotify and focus events. */ 1374 /* Warping the mouse will cause enternotify and focus events. */
1352 x_set_mouse_pixel_position (XFRAME (frame), x, y); 1375 x_set_mouse_pixel_position (XFRAME (frame), x, y);
1376#else
1377#if defined(MSDOS) && defined(HAVE_MOUSE)
1378 if (FRAME_MSDOS_P (XFRAME (frame)))
1379 {
1380 Fselect_frame (frame, Qnil);
1381 mouse_moveto (XINT (x), XINT (y));
1382 }
1383#endif
1353#endif 1384#endif
1354 1385
1355 return Qnil; 1386 return Qnil;
@@ -1713,6 +1744,22 @@ If FRAME is omitted, return information on the currently selected frame.")
1713 return Qnil; 1744 return Qnil;
1714 1745
1715 alist = Fcopy_alist (f->param_alist); 1746 alist = Fcopy_alist (f->param_alist);
1747#ifdef MSDOS
1748 if (FRAME_MSDOS_P (f))
1749 {
1750 static char *colornames[16] =
1751 {
1752 "black", "blue", "green", "cyan", "red", "magenta", "brown",
1753 "lightgray", "darkgray", "lightblue", "lightgreen", "lightcyan",
1754 "lightred", "lightmagenta", "yellow", "white"
1755 };
1756 store_in_alist (&alist, intern ("foreground-color"),
1757 build_string (colornames[FRAME_FOREGROUND_PIXEL (f)]));
1758 store_in_alist (&alist, intern ("background-color"),
1759 build_string (colornames[FRAME_BACKGROUND_PIXEL (f)]));
1760 }
1761 store_in_alist (&alist, intern ("font"), build_string ("default"));
1762#endif
1716 store_in_alist (&alist, Qname, f->name); 1763 store_in_alist (&alist, Qname, f->name);
1717 height = (FRAME_NEW_HEIGHT (f) ? FRAME_NEW_HEIGHT (f) : FRAME_HEIGHT (f)); 1764 height = (FRAME_NEW_HEIGHT (f) ? FRAME_NEW_HEIGHT (f) : FRAME_HEIGHT (f));
1718 store_in_alist (&alist, Qheight, make_number (height)); 1765 store_in_alist (&alist, Qheight, make_number (height));
@@ -1766,6 +1813,11 @@ The meaningful PARMs depend on the kind of frame; undefined PARMs are ignored.")
1766 x_set_frame_parameters (f, alist); 1813 x_set_frame_parameters (f, alist);
1767 else 1814 else
1768#endif 1815#endif
1816#ifdef MSDOS
1817 if (FRAME_MSDOS_P (f))
1818 IT_set_frame_parameters (f, alist);
1819 else
1820#endif
1769 for (tail = alist; !EQ (tail, Qnil); tail = Fcdr (tail)) 1821 for (tail = alist; !EQ (tail, Qnil); tail = Fcdr (tail))
1770 { 1822 {
1771 elt = Fcar (tail); 1823 elt = Fcar (tail);