/*
 * $Copyright:	$
 * Copyright (c) 1984, 1985, 1986, 1987, 1988, 1989, 1990 
 * Sequent Computer Systems, Inc.   All rights reserved.
 *  
 * This software is furnished under a license and may be used
 * only in accordance with the terms of that license and with the
 * inclusion of the above copyright notice.   This software may not
 * be provided or otherwise made available to, or used by, any
 * other person.  No title to or ownership of the software is
 * hereby transferred.
 *
 */

/*	Copyright (c) 1984 AT&T	*/
/*	  All Rights Reserved  	*/

/*	THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T	*/
/*	The copyright notice above does not evidence any   	*/
/*	actual or intended publication of such source code.	*/

#ident	"$Header: devinit.c 1.3 89/10/10 $@(#)graf:src/dev.d/hp7220.d/hpd.d/devinit.c	1.2"
#include <stdio.h>
#include "hpd.h"
#include "dev.h"
extern struct device dv;
extern struct options {
	int eopt;  /*  erase  */
	int slant;  /* character slant  */
	int achset ;  /* select alternate char set  */
	int pen;  /*  select pen  */
	int win;  /*  flag for window options ( 'u' or 'r')  */
}op;

devinit()
{	PLOTON;
	if(op.pen){PENSEL; sbn(op.pen);}
	SETGLIM;
	mbp(dv.v.lx,dv.v.ly); mbp(dv.v.hx,dv.v.hy); 
	TERMINATOR;
	dv.v.hx -= dv.v.lx; dv.v.hy -= dv.v.ly;
	dv.v.lx = 0; dv.v.ly = 0;
	SETGRIDSZ;
	mbp(dv.v.hx,dv.v.hy);
	TERMINATOR;
	ROTATE;   /*  init ang for text rotation to 0  */
	if(op.slant) { LABSLANT; mba(op.slant+90.);}
	if(op.achset) { LABCHSET; mbp(op.achset,0);}
}
