/* Functions for Sun Windows menus and selection buffer.
- Copyright (C) 1987 Free Software Foundation, Inc.
+ Copyright (C) 1987, 1999 Free Software Foundation, Inc.
This file is probably totally obsolete. In any case, the FSF is
unwilling to support it. We agreed to include it in our distribution
You should have received a copy of the GNU General Public License
along with GNU Emacs; see the file COPYING. If not, write to
-the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
+the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA. */
/* Author: Jeff Peck, Sun Microsystems, Inc. <peck@sun.com>
Original ideas by David Kastan and Eric Negaard, SRI International
if ((! already_initialized) || (!NILP(force))) {
cp = getenv("WINDOW_GFX");
- if (cp != 0) win_fd = open(cp, 2);
+ if (cp != 0) win_fd = emacs_open (cp, O_RDWR, 0);
if (win_fd > 0)
{
Sun_Font = pf_default();
Timeout.tv_usec = (XINT(n) - (Timeout.tv_sec * 1000)) * 1000;
if (detect_input_pending()) return(Qnil);
- redisplay_preserve_echo_area ();
+ redisplay_preserve_echo_area (16);
/*
* Check for queued keyboard input/mouse hits again
* (A bit screen update can take some time!)
"Perform redisplay.")
()
{
- redisplay_preserve_echo_area ();
+ redisplay_preserve_echo_area (17);
return(Qt);
}
CHECK_GFX (Qnil);
- xpos = CtoSX (XWINDOW(window)->left + XINT(X_Position));
+ xpos = CtoSX (WINDOW_LEFT_MARGIN (XWINDOW (window)) + XINT(X_Position));
ypos = CtoSY (XWINDOW(window)->top + XINT(Y_Position));
#ifdef Menu_Base_Kludge
{static Lisp_Object symbol[2];
symbol[0] = Fintern (sm_kludge_string, Qnil);
Pair = Ffuncall (1, symbol);
- xpos += XINT (XCONS (Pair)->cdr);
- ypos += XINT (XCONS (Pair)->car);
+ xpos += XINT (XCDR (Pair));
+ ypos += XINT (XCAR (Pair));
}
#endif
#ifdef Menu_Base_Kludge
/* i'm just too lazy to re-write this into C code */
/* so we will call this elisp function from C */
- sm_kludge_string = make_pure_string ("sm::menu-kludge", 15);
+ sm_kludge_string = make_pure_string ("sm::menu-kludge", 15, 15, 0);
#endif /* Menu_Base_Kludge */
defsubr(&Ssun_window_init);