111494Sralph /* 2*18786Sdist * Copyright (c) 1980 Regents of the University of California. 3*18786Sdist * All rights reserved. The Berkeley software License Agreement 4*18786Sdist * specifies the terms and conditions for redistribution. 5*18786Sdist */ 6*18786Sdist 7*18786Sdist #ifndef lint 8*18786Sdist static char sccsid[] = "@(#)sync.c 5.1 (Berkeley) 04/26/85"; 9*18786Sdist #endif not lint 10*18786Sdist 11*18786Sdist /* 1211494Sralph * Make the screen & screen mode look like what it's supposed to. 1311494Sralph * 1411494Sralph * There are two basic things to do here, put the _pen 1511494Sralph * in the right place, and make the line drawing mode be right. 1611494Sralph * We don't sync the cursor here, only when there's user input & it's on. 1711494Sralph */ 1811494Sralph 1911494Sralph #include "2648.h" 2011494Sralph sync()2111494Sralphsync() 2211494Sralph { 2311494Sralph if (_supx != _penx || _supy != _peny) { 2411494Sralph escseq(ESCP); 2511494Sralph outchar('a'); 2611494Sralph motion(_supx, _supy); 2711494Sralph } 2811494Sralph if (_supsmode != _actsmode) { 2911494Sralph escseq(ESCM); 3011494Sralph switch (_actsmode = _supsmode) { 3111494Sralph case MX: 3211494Sralph outchar('3'); 3311494Sralph break; 3411494Sralph case MC: 3511494Sralph outchar('1'); 3611494Sralph break; 3711494Sralph case MS: 3811494Sralph outchar('2'); 3911494Sralph break; 4011494Sralph } 4111494Sralph outchar('a'); 4211494Sralph } 4311494Sralph } 44