119974Sdist /* 219974Sdist * Copyright (c) 1980 Regents of the University of California. 319974Sdist * All rights reserved. The Berkeley software License Agreement 419974Sdist * specifies the terms and conditions for redistribution. 519974Sdist */ 619974Sdist 715494Sralph #ifndef lint 8*46636Sbostic static char sccsid[] = "@(#)open.c 5.2 (Berkeley) 02/24/91"; 919974Sdist #endif not lint 1015494Sralph 1115494Sralph /* 1215494Sralph * Displays plot files on a gigi "graphics" terminal. 1315494Sralph */ 1415494Sralph 1515494Sralph #include <signal.h> 1615494Sralph #include "gigi.h" 1715494Sralph 1815494Sralph int currentx = 0; 1915494Sralph int currenty = 0; 2015494Sralph double lowx = 0.0; 2115494Sralph double lowy = 0.0; 2215494Sralph double scalex = 1.0; 2315494Sralph double scaley = 1.0; 2415494Sralph 2515494Sralph openpl() 2615494Sralph { 27*46636Sbostic void closepl(); 2815494Sralph 2915494Sralph /* catch interupts */ 3015494Sralph signal(SIGINT, closepl); 3115494Sralph currentx = 0; 3215494Sralph currenty = 0; 3315494Sralph /* enter grapics mode */ 3415494Sralph putchar(ESC); putchar('P'); putchar('p'); 3515494Sralph 3615494Sralph /* set some parameters */ 3715494Sralph printf("S(I0 T0 [0,0])"); 3815494Sralph 3915494Sralph space(0, 0, XMAX, YMAX); 4015494Sralph } 41