122672Sdist /* 234677Sbostic * Copyright (c) 1981 Regents of the University of California. 334677Sbostic * All rights reserved. 434677Sbostic * 5*42653Sbostic * %sccs.include.redist.c% 622672Sdist */ 722672Sdist 822672Sdist #ifndef lint 9*42653Sbostic static char sccsid[] = "@(#)move.c 5.5 (Berkeley) 06/01/90"; 1034677Sbostic #endif /* not lint */ 1122672Sdist 1211739Sarnold # include "curses.ext" 1311739Sarnold 1411739Sarnold /* 1511739Sarnold * This routine moves the cursor to the given point 1611739Sarnold * 1711739Sarnold */ 1811739Sarnold wmove(win, y, x) 1911739Sarnold reg WINDOW *win; 2011739Sarnold reg int y, x; { 2111739Sarnold 2211739Sarnold # ifdef DEBUG 2311739Sarnold fprintf(outf, "MOVE to (%d, %d)\n", y, x); 2411739Sarnold # endif 2525110Sbloom if (x < 0 || y < 0) 2625110Sbloom return ERR; 2711739Sarnold if (x >= win->_maxx || y >= win->_maxy) 2811739Sarnold return ERR; 2911739Sarnold win->_curx = x; 3011739Sarnold win->_cury = y; 3111739Sarnold return OK; 3211739Sarnold } 33