comparison src/frame.c @ 109179:8cfee7d2955f

Convert DEFUNs to standard C. * src/alloc.c: Convert DEFUNs to standard C. * src/buffer.c: * src/bytecode.c: * src/callint.c: * src/callproc.c: * src/casefiddle.c: * src/casetab.c: * src/category.c: * src/character.c: * src/charset.c: * src/chartab.c: * src/cmds.c: * src/coding.c: * src/composite.c: * src/data.c: * src/dbusbind.c: * src/dired.c: * src/dispnew.c: * src/doc.c: * src/dosfns.c: * src/editfns.c: * src/emacs.c: * src/eval.c: * src/fileio.c: * src/filelock.c: * src/floatfns.c: * src/fns.c: * src/font.c: * src/fontset.c: * src/frame.c: * src/fringe.c: * src/image.c: * src/indent.c: * src/insdel.c: * src/keyboard.c: * src/keymap.c: * src/lread.c: * src/macros.c: * src/marker.c: * src/menu.c: * src/minibuf.c: * src/msdos.c: * src/nsfns.m: * src/nsmenu.m: * src/nsselect.m: * src/print.c: * src/process.c: * src/search.c: * src/sound.c: * src/syntax.c: * src/term.c: * src/terminal.c: * src/textprop.c: * src/undo.c: * src/w16select.c: * src/w32console.c: * src/w32fns.c: * src/w32font.c: * src/w32menu.c: * src/w32proc.c: * src/w32select.c: * src/window.c: * src/xdisp.c: * src/xfaces.c: * src/xfns.c: * src/xmenu.c: * src/xselect.c: * src/xsettings.c: * src/xsmfns.c: Likewise.
author Dan Nicolaescu <dann@ics.uci.edu>
date Thu, 08 Jul 2010 14:25:08 -0700
parents c25c24812fb1
children 379a5ad9f30b 60516122d066
comparison
equal deleted inserted replaced
109178:53f8ebcd9a97 109179:8cfee7d2955f
211 `x' for an Emacs frame that is really an X window, 211 `x' for an Emacs frame that is really an X window,
212 `w32' for an Emacs frame that is a window on MS-Windows display, 212 `w32' for an Emacs frame that is a window on MS-Windows display,
213 `ns' for an Emacs frame on a GNUstep or Macintosh Cocoa display, 213 `ns' for an Emacs frame on a GNUstep or Macintosh Cocoa display,
214 `pc' for a direct-write MS-DOS frame. 214 `pc' for a direct-write MS-DOS frame.
215 See also `frame-live-p'. */) 215 See also `frame-live-p'. */)
216 (object) 216 (Lisp_Object object)
217 Lisp_Object object;
218 { 217 {
219 if (!FRAMEP (object)) 218 if (!FRAMEP (object))
220 return Qnil; 219 return Qnil;
221 switch (XFRAME (object)->output_method) 220 switch (XFRAME (object)->output_method)
222 { 221 {
242 doc: /* Return non-nil if OBJECT is a frame which has not been deleted. 241 doc: /* Return non-nil if OBJECT is a frame which has not been deleted.
243 Value is nil if OBJECT is not a live frame. If object is a live 242 Value is nil if OBJECT is not a live frame. If object is a live
244 frame, the return value indicates what sort of terminal device it is 243 frame, the return value indicates what sort of terminal device it is
245 displayed on. See the documentation of `framep' for possible 244 displayed on. See the documentation of `framep' for possible
246 return values. */) 245 return values. */)
247 (object) 246 (Lisp_Object object)
248 Lisp_Object object;
249 { 247 {
250 return ((FRAMEP (object) 248 return ((FRAMEP (object)
251 && FRAME_LIVE_P (XFRAME (object))) 249 && FRAME_LIVE_P (XFRAME (object)))
252 ? Fframep (object) 250 ? Fframep (object)
253 : Qnil); 251 : Qnil);
257 doc: /* The name of the window system that FRAME is displaying through. 255 doc: /* The name of the window system that FRAME is displaying through.
258 The value is a symbol---for instance, 'x' for X windows. 256 The value is a symbol---for instance, 'x' for X windows.
259 The value is nil if Emacs is using a text-only terminal. 257 The value is nil if Emacs is using a text-only terminal.
260 258
261 FRAME defaults to the currently selected frame. */) 259 FRAME defaults to the currently selected frame. */)
262 (frame) 260 (Lisp_Object frame)
263 Lisp_Object frame;
264 { 261 {
265 Lisp_Object type; 262 Lisp_Object type;
266 if (NILP (frame)) 263 if (NILP (frame))
267 frame = selected_frame; 264 frame = selected_frame;
268 265
656 653
657 (make-terminal-frame '((tty . "/dev/pts/5") (tty-type . "xterm"))) 654 (make-terminal-frame '((tty . "/dev/pts/5") (tty-type . "xterm")))
658 655
659 Note that changing the size of one terminal frame automatically 656 Note that changing the size of one terminal frame automatically
660 affects all frames on the same terminal device. */) 657 affects all frames on the same terminal device. */)
661 (parms) 658 (Lisp_Object parms)
662 Lisp_Object parms;
663 { 659 {
664 struct frame *f; 660 struct frame *f;
665 struct terminal *t = NULL; 661 struct terminal *t = NULL;
666 Lisp_Object frame, tem; 662 Lisp_Object frame, tem;
667 struct frame *sf = SELECTED_FRAME (); 663 struct frame *sf = SELECTED_FRAME ();
884 when returning to the command loop, because it still may have 880 when returning to the command loop, because it still may have
885 the window system's input focus. On a text-only terminal, the 881 the window system's input focus. On a text-only terminal, the
886 next redisplay will display FRAME. 882 next redisplay will display FRAME.
887 883
888 This function returns FRAME, or nil if FRAME has been deleted. */) 884 This function returns FRAME, or nil if FRAME has been deleted. */)
889 (frame, norecord) 885 (Lisp_Object frame, Lisp_Object norecord)
890 Lisp_Object frame, norecord;
891 { 886 {
892 return do_switch_frame (frame, 1, 0, norecord); 887 return do_switch_frame (frame, 1, 0, norecord);
893 } 888 }
894 889
895 890
900 that the user's events be directed to the frame mentioned in the event. 895 that the user's events be directed to the frame mentioned in the event.
901 This function selects the selected window of the frame of EVENT. 896 This function selects the selected window of the frame of EVENT.
902 897
903 If EVENT is frame object, handle it as if it were a switch-frame event 898 If EVENT is frame object, handle it as if it were a switch-frame event
904 to that frame. */) 899 to that frame. */)
905 (event) 900 (Lisp_Object event)
906 Lisp_Object event;
907 { 901 {
908 /* Preserve prefix arg that the command loop just cleared. */ 902 /* Preserve prefix arg that the command loop just cleared. */
909 current_kboard->Vprefix_arg = Vcurrent_prefix_arg; 903 current_kboard->Vprefix_arg = Vcurrent_prefix_arg;
910 call1 (Vrun_hooks, Qmouse_leave_buffer_hook); 904 call1 (Vrun_hooks, Qmouse_leave_buffer_hook);
911 return do_switch_frame (event, 0, 0, Qnil); 905 return do_switch_frame (event, 0, 0, Qnil);
912 } 906 }
913 907
914 DEFUN ("selected-frame", Fselected_frame, Sselected_frame, 0, 0, 0, 908 DEFUN ("selected-frame", Fselected_frame, Sselected_frame, 0, 0, 0,
915 doc: /* Return the frame that is now selected. */) 909 doc: /* Return the frame that is now selected. */)
916 () 910 (void)
917 { 911 {
918 return selected_frame; 912 return selected_frame;
919 } 913 }
920 914
921 DEFUN ("window-frame", Fwindow_frame, Swindow_frame, 1, 1, 0, 915 DEFUN ("window-frame", Fwindow_frame, Swindow_frame, 1, 1, 0,
922 doc: /* Return the frame object that window WINDOW is on. */) 916 doc: /* Return the frame object that window WINDOW is on. */)
923 (window) 917 (Lisp_Object window)
924 Lisp_Object window;
925 { 918 {
926 CHECK_LIVE_WINDOW (window); 919 CHECK_LIVE_WINDOW (window);
927 return XWINDOW (window)->frame; 920 return XWINDOW (window)->frame;
928 } 921 }
929 922
930 DEFUN ("frame-first-window", Fframe_first_window, Sframe_first_window, 0, 1, 0, 923 DEFUN ("frame-first-window", Fframe_first_window, Sframe_first_window, 0, 1, 0,
931 doc: /* Returns the topmost, leftmost window of FRAME. 924 doc: /* Returns the topmost, leftmost window of FRAME.
932 If omitted, FRAME defaults to the currently selected frame. */) 925 If omitted, FRAME defaults to the currently selected frame. */)
933 (frame) 926 (Lisp_Object frame)
934 Lisp_Object frame;
935 { 927 {
936 Lisp_Object w; 928 Lisp_Object w;
937 929
938 if (NILP (frame)) 930 if (NILP (frame))
939 w = SELECTED_FRAME ()->root_window; 931 w = SELECTED_FRAME ()->root_window;
955 } 947 }
956 948
957 DEFUN ("active-minibuffer-window", Factive_minibuffer_window, 949 DEFUN ("active-minibuffer-window", Factive_minibuffer_window,
958 Sactive_minibuffer_window, 0, 0, 0, 950 Sactive_minibuffer_window, 0, 0, 0,
959 doc: /* Return the currently active minibuffer window, or nil if none. */) 951 doc: /* Return the currently active minibuffer window, or nil if none. */)
960 () 952 (void)
961 { 953 {
962 return minibuf_level ? minibuf_window : Qnil; 954 return minibuf_level ? minibuf_window : Qnil;
963 } 955 }
964 956
965 DEFUN ("frame-root-window", Fframe_root_window, Sframe_root_window, 0, 1, 0, 957 DEFUN ("frame-root-window", Fframe_root_window, Sframe_root_window, 0, 1, 0,
966 doc: /* Returns the root-window of FRAME. 958 doc: /* Returns the root-window of FRAME.
967 If omitted, FRAME defaults to the currently selected frame. */) 959 If omitted, FRAME defaults to the currently selected frame. */)
968 (frame) 960 (Lisp_Object frame)
969 Lisp_Object frame;
970 { 961 {
971 Lisp_Object window; 962 Lisp_Object window;
972 963
973 if (NILP (frame)) 964 if (NILP (frame))
974 window = SELECTED_FRAME ()->root_window; 965 window = SELECTED_FRAME ()->root_window;
983 974
984 DEFUN ("frame-selected-window", Fframe_selected_window, 975 DEFUN ("frame-selected-window", Fframe_selected_window,
985 Sframe_selected_window, 0, 1, 0, 976 Sframe_selected_window, 0, 1, 0,
986 doc: /* Return the selected window of FRAME. 977 doc: /* Return the selected window of FRAME.
987 FRAME defaults to the currently selected frame. */) 978 FRAME defaults to the currently selected frame. */)
988 (frame) 979 (Lisp_Object frame)
989 Lisp_Object frame;
990 { 980 {
991 Lisp_Object window; 981 Lisp_Object window;
992 982
993 if (NILP (frame)) 983 if (NILP (frame))
994 window = SELECTED_FRAME ()->selected_window; 984 window = SELECTED_FRAME ()->selected_window;
1007 If FRAME is nil, use the selected frame. If FRAME is the 997 If FRAME is nil, use the selected frame. If FRAME is the
1008 selected frame, this makes WINDOW the selected window. 998 selected frame, this makes WINDOW the selected window.
1009 Optional argument NORECORD non-nil means to neither change the 999 Optional argument NORECORD non-nil means to neither change the
1010 order of recently selected windows nor the buffer list. 1000 order of recently selected windows nor the buffer list.
1011 Return WINDOW. */) 1001 Return WINDOW. */)
1012 (frame, window, norecord) 1002 (Lisp_Object frame, Lisp_Object window, Lisp_Object norecord)
1013 Lisp_Object frame, window, norecord;
1014 { 1003 {
1015 if (NILP (frame)) 1004 if (NILP (frame))
1016 frame = selected_frame; 1005 frame = selected_frame;
1017 1006
1018 CHECK_LIVE_FRAME (frame); 1007 CHECK_LIVE_FRAME (frame);
1029 1018
1030 1019
1031 DEFUN ("frame-list", Fframe_list, Sframe_list, 1020 DEFUN ("frame-list", Fframe_list, Sframe_list,
1032 0, 0, 0, 1021 0, 0, 0,
1033 doc: /* Return a list of all live frames. */) 1022 doc: /* Return a list of all live frames. */)
1034 () 1023 (void)
1035 { 1024 {
1036 Lisp_Object frames; 1025 Lisp_Object frames;
1037 frames = Fcopy_sequence (Vframe_list); 1026 frames = Fcopy_sequence (Vframe_list);
1038 #ifdef HAVE_WINDOW_SYSTEM 1027 #ifdef HAVE_WINDOW_SYSTEM
1039 if (FRAMEP (tip_frame)) 1028 if (FRAMEP (tip_frame))
1210 If MINIFRAME is a window, include only its own frame 1199 If MINIFRAME is a window, include only its own frame
1211 and any frame now using that window as the minibuffer. 1200 and any frame now using that window as the minibuffer.
1212 If MINIFRAME is `visible', include all visible frames. 1201 If MINIFRAME is `visible', include all visible frames.
1213 If MINIFRAME is 0, include all visible and iconified frames. 1202 If MINIFRAME is 0, include all visible and iconified frames.
1214 Otherwise, include all frames. */) 1203 Otherwise, include all frames. */)
1215 (frame, miniframe) 1204 (Lisp_Object frame, Lisp_Object miniframe)
1216 Lisp_Object frame, miniframe;
1217 { 1205 {
1218 if (NILP (frame)) 1206 if (NILP (frame))
1219 frame = selected_frame; 1207 frame = selected_frame;
1220 1208
1221 CHECK_LIVE_FRAME (frame); 1209 CHECK_LIVE_FRAME (frame);
1231 If MINIFRAME is a window, include only its own frame 1219 If MINIFRAME is a window, include only its own frame
1232 and any frame now using that window as the minibuffer. 1220 and any frame now using that window as the minibuffer.
1233 If MINIFRAME is `visible', include all visible frames. 1221 If MINIFRAME is `visible', include all visible frames.
1234 If MINIFRAME is 0, include all visible and iconified frames. 1222 If MINIFRAME is 0, include all visible and iconified frames.
1235 Otherwise, include all frames. */) 1223 Otherwise, include all frames. */)
1236 (frame, miniframe) 1224 (Lisp_Object frame, Lisp_Object miniframe)
1237 Lisp_Object frame, miniframe;
1238 { 1225 {
1239 if (NILP (frame)) 1226 if (NILP (frame))
1240 frame = selected_frame; 1227 frame = selected_frame;
1241 CHECK_LIVE_FRAME (frame); 1228 CHECK_LIVE_FRAME (frame);
1242 return prev_frame (frame, miniframe); 1229 return prev_frame (frame, miniframe);
1629 but if the second optional argument FORCE is non-nil, you may do so. 1616 but if the second optional argument FORCE is non-nil, you may do so.
1630 1617
1631 This function runs `delete-frame-functions' before actually 1618 This function runs `delete-frame-functions' before actually
1632 deleting the frame, unless the frame is a tooltip. 1619 deleting the frame, unless the frame is a tooltip.
1633 The functions are run with one argument, the frame to be deleted. */) 1620 The functions are run with one argument, the frame to be deleted. */)
1634 (frame, force) 1621 (Lisp_Object frame, Lisp_Object force)
1635 Lisp_Object frame, force;
1636 { 1622 {
1637 return delete_frame (frame, !NILP (force) ? Qt : Qnil); 1623 return delete_frame (frame, !NILP (force) ? Qt : Qnil);
1638 } 1624 }
1639 1625
1640 1626
1649 to read the mouse position, it returns the selected frame for FRAME 1635 to read the mouse position, it returns the selected frame for FRAME
1650 and nil for X and Y. 1636 and nil for X and Y.
1651 If `mouse-position-function' is non-nil, `mouse-position' calls it, 1637 If `mouse-position-function' is non-nil, `mouse-position' calls it,
1652 passing the normal return value to that function as an argument, 1638 passing the normal return value to that function as an argument,
1653 and returns whatever that function returns. */) 1639 and returns whatever that function returns. */)
1654 () 1640 (void)
1655 { 1641 {
1656 FRAME_PTR f; 1642 FRAME_PTR f;
1657 Lisp_Object lispy_dummy; 1643 Lisp_Object lispy_dummy;
1658 enum scroll_bar_part party_dummy; 1644 enum scroll_bar_part party_dummy;
1659 Lisp_Object x, y, retval; 1645 Lisp_Object x, y, retval;
1695 upper-left corner of the frame, X is the horizontal offset, and Y is 1681 upper-left corner of the frame, X is the horizontal offset, and Y is
1696 the vertical offset. 1682 the vertical offset.
1697 If Emacs is running on a mouseless terminal or hasn't been programmed 1683 If Emacs is running on a mouseless terminal or hasn't been programmed
1698 to read the mouse position, it returns the selected frame for FRAME 1684 to read the mouse position, it returns the selected frame for FRAME
1699 and nil for X and Y. */) 1685 and nil for X and Y. */)
1700 () 1686 (void)
1701 { 1687 {
1702 FRAME_PTR f; 1688 FRAME_PTR f;
1703 Lisp_Object lispy_dummy; 1689 Lisp_Object lispy_dummy;
1704 enum scroll_bar_part party_dummy; 1690 enum scroll_bar_part party_dummy;
1705 Lisp_Object x, y; 1691 Lisp_Object x, y;
1732 1718
1733 This function is a no-op for an X frame that is not visible. 1719 This function is a no-op for an X frame that is not visible.
1734 If you have just created a frame, you must wait for it to become visible 1720 If you have just created a frame, you must wait for it to become visible
1735 before calling this function on it, like this. 1721 before calling this function on it, like this.
1736 (while (not (frame-visible-p frame)) (sleep-for .5)) */) 1722 (while (not (frame-visible-p frame)) (sleep-for .5)) */)
1737 (frame, x, y) 1723 (Lisp_Object frame, Lisp_Object x, Lisp_Object y)
1738 Lisp_Object frame, x, y;
1739 { 1724 {
1740 CHECK_LIVE_FRAME (frame); 1725 CHECK_LIVE_FRAME (frame);
1741 CHECK_NUMBER (x); 1726 CHECK_NUMBER (x);
1742 CHECK_NUMBER (y); 1727 CHECK_NUMBER (y);
1743 1728
1774 1759
1775 Note, this is a no-op for an X frame that is not visible. 1760 Note, this is a no-op for an X frame that is not visible.
1776 If you have just created a frame, you must wait for it to become visible 1761 If you have just created a frame, you must wait for it to become visible
1777 before calling this function on it, like this. 1762 before calling this function on it, like this.
1778 (while (not (frame-visible-p frame)) (sleep-for .5)) */) 1763 (while (not (frame-visible-p frame)) (sleep-for .5)) */)
1779 (frame, x, y) 1764 (Lisp_Object frame, Lisp_Object x, Lisp_Object y)
1780 Lisp_Object frame, x, y;
1781 { 1765 {
1782 CHECK_LIVE_FRAME (frame); 1766 CHECK_LIVE_FRAME (frame);
1783 CHECK_NUMBER (x); 1767 CHECK_NUMBER (x);
1784 CHECK_NUMBER (y); 1768 CHECK_NUMBER (y);
1785 1769
1812 1796
1813 DEFUN ("make-frame-visible", Fmake_frame_visible, Smake_frame_visible, 1797 DEFUN ("make-frame-visible", Fmake_frame_visible, Smake_frame_visible,
1814 0, 1, "", 1798 0, 1, "",
1815 doc: /* Make the frame FRAME visible (assuming it is an X window). 1799 doc: /* Make the frame FRAME visible (assuming it is an X window).
1816 If omitted, FRAME defaults to the currently selected frame. */) 1800 If omitted, FRAME defaults to the currently selected frame. */)
1817 (frame) 1801 (Lisp_Object frame)
1818 Lisp_Object frame;
1819 { 1802 {
1820 if (NILP (frame)) 1803 if (NILP (frame))
1821 frame = selected_frame; 1804 frame = selected_frame;
1822 1805
1823 CHECK_LIVE_FRAME (frame); 1806 CHECK_LIVE_FRAME (frame);
1872 but if the second optional argument FORCE is non-nil, you may do so. 1855 but if the second optional argument FORCE is non-nil, you may do so.
1873 1856
1874 This function has no effect on text-only terminal frames. Such frames 1857 This function has no effect on text-only terminal frames. Such frames
1875 are always considered visible, whether or not they are currently being 1858 are always considered visible, whether or not they are currently being
1876 displayed in the terminal. */) 1859 displayed in the terminal. */)
1877 (frame, force) 1860 (Lisp_Object frame, Lisp_Object force)
1878 Lisp_Object frame, force;
1879 { 1861 {
1880 if (NILP (frame)) 1862 if (NILP (frame))
1881 frame = selected_frame; 1863 frame = selected_frame;
1882 1864
1883 CHECK_LIVE_FRAME (frame); 1865 CHECK_LIVE_FRAME (frame);
1914 1896
1915 DEFUN ("iconify-frame", Ficonify_frame, Siconify_frame, 1897 DEFUN ("iconify-frame", Ficonify_frame, Siconify_frame,
1916 0, 1, "", 1898 0, 1, "",
1917 doc: /* Make the frame FRAME into an icon. 1899 doc: /* Make the frame FRAME into an icon.
1918 If omitted, FRAME defaults to the currently selected frame. */) 1900 If omitted, FRAME defaults to the currently selected frame. */)
1919 (frame) 1901 (Lisp_Object frame)
1920 Lisp_Object frame;
1921 { 1902 {
1922 if (NILP (frame)) 1903 if (NILP (frame))
1923 frame = selected_frame; 1904 frame = selected_frame;
1924 1905
1925 CHECK_LIVE_FRAME (frame); 1906 CHECK_LIVE_FRAME (frame);
1960 usually not displayed at all, even in a window system's \"taskbar\". 1941 usually not displayed at all, even in a window system's \"taskbar\".
1961 1942
1962 If FRAME is a text-only terminal frame, this always returns t. 1943 If FRAME is a text-only terminal frame, this always returns t.
1963 Such frames are always considered visible, whether or not they are 1944 Such frames are always considered visible, whether or not they are
1964 currently being displayed on the terminal. */) 1945 currently being displayed on the terminal. */)
1965 (frame) 1946 (Lisp_Object frame)
1966 Lisp_Object frame;
1967 { 1947 {
1968 CHECK_LIVE_FRAME (frame); 1948 CHECK_LIVE_FRAME (frame);
1969 1949
1970 FRAME_SAMPLE_VISIBILITY (XFRAME (frame)); 1950 FRAME_SAMPLE_VISIBILITY (XFRAME (frame));
1971 1951
1977 } 1957 }
1978 1958
1979 DEFUN ("visible-frame-list", Fvisible_frame_list, Svisible_frame_list, 1959 DEFUN ("visible-frame-list", Fvisible_frame_list, Svisible_frame_list,
1980 0, 0, 0, 1960 0, 0, 0,
1981 doc: /* Return a list of all frames now \"visible\" (being updated). */) 1961 doc: /* Return a list of all frames now \"visible\" (being updated). */)
1982 () 1962 (void)
1983 { 1963 {
1984 Lisp_Object tail, frame; 1964 Lisp_Object tail, frame;
1985 struct frame *f; 1965 struct frame *f;
1986 Lisp_Object value; 1966 Lisp_Object value;
1987 1967
2003 doc: /* Bring FRAME to the front, so it occludes any frames it overlaps. 1983 doc: /* Bring FRAME to the front, so it occludes any frames it overlaps.
2004 If FRAME is invisible or iconified, make it visible. 1984 If FRAME is invisible or iconified, make it visible.
2005 If you don't specify a frame, the selected frame is used. 1985 If you don't specify a frame, the selected frame is used.
2006 If Emacs is displaying on an ordinary terminal or some other device which 1986 If Emacs is displaying on an ordinary terminal or some other device which
2007 doesn't support multiple overlapping frames, this function selects FRAME. */) 1987 doesn't support multiple overlapping frames, this function selects FRAME. */)
2008 (frame) 1988 (Lisp_Object frame)
2009 Lisp_Object frame;
2010 { 1989 {
2011 struct frame *f; 1990 struct frame *f;
2012 if (NILP (frame)) 1991 if (NILP (frame))
2013 frame = selected_frame; 1992 frame = selected_frame;
2014 1993
2033 DEFUN ("lower-frame", Flower_frame, Slower_frame, 0, 1, "", 2012 DEFUN ("lower-frame", Flower_frame, Slower_frame, 0, 1, "",
2034 doc: /* Send FRAME to the back, so it is occluded by any frames that overlap it. 2013 doc: /* Send FRAME to the back, so it is occluded by any frames that overlap it.
2035 If you don't specify a frame, the selected frame is used. 2014 If you don't specify a frame, the selected frame is used.
2036 If Emacs is displaying on an ordinary terminal or some other device which 2015 If Emacs is displaying on an ordinary terminal or some other device which
2037 doesn't support multiple overlapping frames, this function does nothing. */) 2016 doesn't support multiple overlapping frames, this function does nothing. */)
2038 (frame) 2017 (Lisp_Object frame)
2039 Lisp_Object frame;
2040 { 2018 {
2041 struct frame *f; 2019 struct frame *f;
2042 2020
2043 if (NILP (frame)) 2021 if (NILP (frame))
2044 frame = selected_frame; 2022 frame = selected_frame;
2077 This means that a frame whose focus is redirected to itself is treated 2055 This means that a frame whose focus is redirected to itself is treated
2078 differently from a frame whose focus is redirected to nil; the former 2056 differently from a frame whose focus is redirected to nil; the former
2079 is affected by `select-frame', while the latter is not. 2057 is affected by `select-frame', while the latter is not.
2080 2058
2081 The redirection lasts until `redirect-frame-focus' is called to change it. */) 2059 The redirection lasts until `redirect-frame-focus' is called to change it. */)
2082 (frame, focus_frame) 2060 (Lisp_Object frame, Lisp_Object focus_frame)
2083 Lisp_Object frame, focus_frame;
2084 { 2061 {
2085 struct frame *f; 2062 struct frame *f;
2086 2063
2087 /* Note that we don't check for a live frame here. It's reasonable 2064 /* Note that we don't check for a live frame here. It's reasonable
2088 to redirect the focus of a frame you're about to delete, if you 2065 to redirect the focus of a frame you're about to delete, if you
2105 2082
2106 DEFUN ("frame-focus", Fframe_focus, Sframe_focus, 1, 1, 0, 2083 DEFUN ("frame-focus", Fframe_focus, Sframe_focus, 1, 1, 0,
2107 doc: /* Return the frame to which FRAME's keystrokes are currently being sent. 2084 doc: /* Return the frame to which FRAME's keystrokes are currently being sent.
2108 This returns nil if FRAME's focus is not redirected. 2085 This returns nil if FRAME's focus is not redirected.
2109 See `redirect-frame-focus'. */) 2086 See `redirect-frame-focus'. */)
2110 (frame) 2087 (Lisp_Object frame)
2111 Lisp_Object frame;
2112 { 2088 {
2113 CHECK_LIVE_FRAME (frame); 2089 CHECK_LIVE_FRAME (frame);
2114 2090
2115 return FRAME_FOCUS_FRAME (XFRAME (frame)); 2091 return FRAME_FOCUS_FRAME (XFRAME (frame));
2116 } 2092 }
2327 DEFUN ("frame-parameters", Fframe_parameters, Sframe_parameters, 0, 1, 0, 2303 DEFUN ("frame-parameters", Fframe_parameters, Sframe_parameters, 0, 1, 0,
2328 doc: /* Return the parameters-alist of frame FRAME. 2304 doc: /* Return the parameters-alist of frame FRAME.
2329 It is a list of elements of the form (PARM . VALUE), where PARM is a symbol. 2305 It is a list of elements of the form (PARM . VALUE), where PARM is a symbol.
2330 The meaningful PARMs depend on the kind of frame. 2306 The meaningful PARMs depend on the kind of frame.
2331 If FRAME is omitted, return information on the currently selected frame. */) 2307 If FRAME is omitted, return information on the currently selected frame. */)
2332 (frame) 2308 (Lisp_Object frame)
2333 Lisp_Object frame;
2334 { 2309 {
2335 Lisp_Object alist; 2310 Lisp_Object alist;
2336 FRAME_PTR f; 2311 FRAME_PTR f;
2337 int height, width; 2312 int height, width;
2338 struct gcpro gcpro1; 2313 struct gcpro gcpro1;
2425 2400
2426 2401
2427 DEFUN ("frame-parameter", Fframe_parameter, Sframe_parameter, 2, 2, 0, 2402 DEFUN ("frame-parameter", Fframe_parameter, Sframe_parameter, 2, 2, 0,
2428 doc: /* Return FRAME's value for parameter PARAMETER. 2403 doc: /* Return FRAME's value for parameter PARAMETER.
2429 If FRAME is nil, describe the currently selected frame. */) 2404 If FRAME is nil, describe the currently selected frame. */)
2430 (frame, parameter) 2405 (Lisp_Object frame, Lisp_Object parameter)
2431 Lisp_Object frame, parameter;
2432 { 2406 {
2433 struct frame *f; 2407 struct frame *f;
2434 Lisp_Object value; 2408 Lisp_Object value;
2435 2409
2436 if (NILP (frame)) 2410 if (NILP (frame))
2516 The value of frame parameter FOO can also be accessed 2490 The value of frame parameter FOO can also be accessed
2517 as a frame-local binding for the variable FOO, if you have 2491 as a frame-local binding for the variable FOO, if you have
2518 enabled such bindings for that variable with `make-variable-frame-local'. 2492 enabled such bindings for that variable with `make-variable-frame-local'.
2519 Note that this functionality is obsolete as of Emacs 22.2, and its 2493 Note that this functionality is obsolete as of Emacs 22.2, and its
2520 use is not recommended. Explicitly check for a frame-parameter instead. */) 2494 use is not recommended. Explicitly check for a frame-parameter instead. */)
2521 (frame, alist) 2495 (Lisp_Object frame, Lisp_Object alist)
2522 Lisp_Object frame, alist;
2523 { 2496 {
2524 FRAME_PTR f; 2497 FRAME_PTR f;
2525 register Lisp_Object tail, prop, val; 2498 register Lisp_Object tail, prop, val;
2526 2499
2527 if (EQ (frame, Qnil)) 2500 if (EQ (frame, Qnil))
2582 DEFUN ("frame-char-height", Fframe_char_height, Sframe_char_height, 2555 DEFUN ("frame-char-height", Fframe_char_height, Sframe_char_height,
2583 0, 1, 0, 2556 0, 1, 0,
2584 doc: /* Height in pixels of a line in the font in frame FRAME. 2557 doc: /* Height in pixels of a line in the font in frame FRAME.
2585 If FRAME is omitted, the selected frame is used. 2558 If FRAME is omitted, the selected frame is used.
2586 For a terminal frame, the value is always 1. */) 2559 For a terminal frame, the value is always 1. */)
2587 (frame) 2560 (Lisp_Object frame)
2588 Lisp_Object frame;
2589 { 2561 {
2590 struct frame *f; 2562 struct frame *f;
2591 2563
2592 if (NILP (frame)) 2564 if (NILP (frame))
2593 frame = selected_frame; 2565 frame = selected_frame;
2607 0, 1, 0, 2579 0, 1, 0,
2608 doc: /* Width in pixels of characters in the font in frame FRAME. 2580 doc: /* Width in pixels of characters in the font in frame FRAME.
2609 If FRAME is omitted, the selected frame is used. 2581 If FRAME is omitted, the selected frame is used.
2610 On a graphical screen, the width is the standard width of the default font. 2582 On a graphical screen, the width is the standard width of the default font.
2611 For a terminal screen, the value is always 1. */) 2583 For a terminal screen, the value is always 1. */)
2612 (frame) 2584 (Lisp_Object frame)
2613 Lisp_Object frame;
2614 { 2585 {
2615 struct frame *f; 2586 struct frame *f;
2616 2587
2617 if (NILP (frame)) 2588 if (NILP (frame))
2618 frame = selected_frame; 2589 frame = selected_frame;
2644 and menu bar. 2615 and menu bar.
2645 2616
2646 For a text-only terminal, it includes the menu bar. In this case, the 2617 For a text-only terminal, it includes the menu bar. In this case, the
2647 result is really in characters rather than pixels (i.e., is identical 2618 result is really in characters rather than pixels (i.e., is identical
2648 to `frame-height'). */) 2619 to `frame-height'). */)
2649 (frame) 2620 (Lisp_Object frame)
2650 Lisp_Object frame;
2651 { 2621 {
2652 struct frame *f; 2622 struct frame *f;
2653 2623
2654 if (NILP (frame)) 2624 if (NILP (frame))
2655 frame = selected_frame; 2625 frame = selected_frame;
2667 DEFUN ("frame-pixel-width", Fframe_pixel_width, 2637 DEFUN ("frame-pixel-width", Fframe_pixel_width,
2668 Sframe_pixel_width, 0, 1, 0, 2638 Sframe_pixel_width, 0, 1, 0,
2669 doc: /* Return FRAME's width in pixels. 2639 doc: /* Return FRAME's width in pixels.
2670 For a terminal frame, the result really gives the width in characters. 2640 For a terminal frame, the result really gives the width in characters.
2671 If FRAME is omitted, the selected frame is used. */) 2641 If FRAME is omitted, the selected frame is used. */)
2672 (frame) 2642 (Lisp_Object frame)
2673 Lisp_Object frame;
2674 { 2643 {
2675 struct frame *f; 2644 struct frame *f;
2676 2645
2677 if (NILP (frame)) 2646 if (NILP (frame))
2678 frame = selected_frame; 2647 frame = selected_frame;
2689 2658
2690 DEFUN ("set-frame-height", Fset_frame_height, Sset_frame_height, 2, 3, 0, 2659 DEFUN ("set-frame-height", Fset_frame_height, Sset_frame_height, 2, 3, 0,
2691 doc: /* Specify that the frame FRAME has LINES lines. 2660 doc: /* Specify that the frame FRAME has LINES lines.
2692 Optional third arg non-nil means that redisplay should use LINES lines 2661 Optional third arg non-nil means that redisplay should use LINES lines
2693 but that the idea of the actual height of the frame should not be changed. */) 2662 but that the idea of the actual height of the frame should not be changed. */)
2694 (frame, lines, pretend) 2663 (Lisp_Object frame, Lisp_Object lines, Lisp_Object pretend)
2695 Lisp_Object frame, lines, pretend;
2696 { 2664 {
2697 register struct frame *f; 2665 register struct frame *f;
2698 2666
2699 CHECK_NUMBER (lines); 2667 CHECK_NUMBER (lines);
2700 if (NILP (frame)) 2668 if (NILP (frame))
2718 2686
2719 DEFUN ("set-frame-width", Fset_frame_width, Sset_frame_width, 2, 3, 0, 2687 DEFUN ("set-frame-width", Fset_frame_width, Sset_frame_width, 2, 3, 0,
2720 doc: /* Specify that the frame FRAME has COLS columns. 2688 doc: /* Specify that the frame FRAME has COLS columns.
2721 Optional third arg non-nil means that redisplay should use COLS columns 2689 Optional third arg non-nil means that redisplay should use COLS columns
2722 but that the idea of the actual width of the frame should not be changed. */) 2690 but that the idea of the actual width of the frame should not be changed. */)
2723 (frame, cols, pretend) 2691 (Lisp_Object frame, Lisp_Object cols, Lisp_Object pretend)
2724 Lisp_Object frame, cols, pretend;
2725 { 2692 {
2726 register struct frame *f; 2693 register struct frame *f;
2727 CHECK_NUMBER (cols); 2694 CHECK_NUMBER (cols);
2728 if (NILP (frame)) 2695 if (NILP (frame))
2729 frame = selected_frame; 2696 frame = selected_frame;
2744 return Qnil; 2711 return Qnil;
2745 } 2712 }
2746 2713
2747 DEFUN ("set-frame-size", Fset_frame_size, Sset_frame_size, 3, 3, 0, 2714 DEFUN ("set-frame-size", Fset_frame_size, Sset_frame_size, 3, 3, 0,
2748 doc: /* Sets size of FRAME to COLS by ROWS, measured in characters. */) 2715 doc: /* Sets size of FRAME to COLS by ROWS, measured in characters. */)
2749 (frame, cols, rows) 2716 (Lisp_Object frame, Lisp_Object cols, Lisp_Object rows)
2750 Lisp_Object frame, cols, rows;
2751 { 2717 {
2752 register struct frame *f; 2718 register struct frame *f;
2753 2719
2754 CHECK_LIVE_FRAME (frame); 2720 CHECK_LIVE_FRAME (frame);
2755 CHECK_NUMBER (cols); 2721 CHECK_NUMBER (cols);
2777 Sset_frame_position, 3, 3, 0, 2743 Sset_frame_position, 3, 3, 0,
2778 doc: /* Sets position of FRAME in pixels to XOFFSET by YOFFSET. 2744 doc: /* Sets position of FRAME in pixels to XOFFSET by YOFFSET.
2779 This is actually the position of the upper left corner of the frame. 2745 This is actually the position of the upper left corner of the frame.
2780 Negative values for XOFFSET or YOFFSET are interpreted relative to 2746 Negative values for XOFFSET or YOFFSET are interpreted relative to
2781 the rightmost or bottommost possible position (that stays within the screen). */) 2747 the rightmost or bottommost possible position (that stays within the screen). */)
2782 (frame, xoffset, yoffset) 2748 (Lisp_Object frame, Lisp_Object xoffset, Lisp_Object yoffset)
2783 Lisp_Object frame, xoffset, yoffset;
2784 { 2749 {
2785 register struct frame *f; 2750 register struct frame *f;
2786 2751
2787 CHECK_LIVE_FRAME (frame); 2752 CHECK_LIVE_FRAME (frame);
2788 CHECK_NUMBER (xoffset); 2753 CHECK_NUMBER (xoffset);
3831 3796
3832 The optional arguments COMPONENT and SUBCLASS add to the key and the 3797 The optional arguments COMPONENT and SUBCLASS add to the key and the
3833 class, respectively. You must specify both of them or neither. 3798 class, respectively. You must specify both of them or neither.
3834 If you specify them, the key is `INSTANCE.COMPONENT.ATTRIBUTE' 3799 If you specify them, the key is `INSTANCE.COMPONENT.ATTRIBUTE'
3835 and the class is `Emacs.CLASS.SUBCLASS'. */) 3800 and the class is `Emacs.CLASS.SUBCLASS'. */)
3836 (attribute, class, component, subclass) 3801 (Lisp_Object attribute, Lisp_Object class, Lisp_Object component, Lisp_Object subclass)
3837 Lisp_Object attribute, class, component, subclass;
3838 { 3802 {
3839 #ifdef HAVE_X_WINDOWS 3803 #ifdef HAVE_X_WINDOWS
3840 check_x (); 3804 check_x ();
3841 #endif 3805 #endif
3842 3806
4045 The properties returned may include `top', `left', `height', and `width'. 4009 The properties returned may include `top', `left', `height', and `width'.
4046 For X, the value of `left' or `top' may be an integer, 4010 For X, the value of `left' or `top' may be an integer,
4047 or a list (+ N) meaning N pixels relative to top/left corner, 4011 or a list (+ N) meaning N pixels relative to top/left corner,
4048 or a list (- N) meaning -N pixels relative to bottom/right corner. 4012 or a list (- N) meaning -N pixels relative to bottom/right corner.
4049 On Nextstep, this just calls `ns-parse-geometry'. */) 4013 On Nextstep, this just calls `ns-parse-geometry'. */)
4050 (string) 4014 (Lisp_Object string)
4051 Lisp_Object string;
4052 { 4015 {
4053 #ifdef HAVE_NS 4016 #ifdef HAVE_NS
4054 call1 (Qns_parse_geometry, string); 4017 call1 (Qns_parse_geometry, string);
4055 #else 4018 #else
4056 int geometry, x, y; 4019 int geometry, x, y;