require '_h2ph_pre.ph';

no warnings 'redefine';

unless(defined(&VT100_EMUL_NARGS)) {
    sub VT100_EMUL_NARGS () {	10;}
}
if(defined(&DIAGNOSTIC)) {
}
unless(defined(&VTFL_LASTCHAR)) {
    sub VTFL_LASTCHAR () {	0x1;}
}
unless(defined(&VTFL_INSERTMODE)) {
    sub VTFL_INSERTMODE () {	0x2;}
}
unless(defined(&VTFL_APPLKEYPAD)) {
    sub VTFL_APPLKEYPAD () {	0x4;}
}
unless(defined(&VTFL_APPLCURSOR)) {
    sub VTFL_APPLCURSOR () {	0x8;}
}
unless(defined(&VTFL_DECOM)) {
    sub VTFL_DECOM () {	0x10;}
}
unless(defined(&VTFL_DECAWM)) {
    sub VTFL_DECAWM () {	0x20;}
}
unless(defined(&VTFL_CURSORON)) {
    sub VTFL_CURSORON () {	0x40;}
}
unless(defined(&VTFL_NATCHARSET)) {
    sub VTFL_NATCHARSET () {	0x80;}
}
unless(defined(&VTFL_SAVEDCURS)) {
    sub VTFL_SAVEDCURS () {	0x100;}
}
unless(defined(&DCS_MAXLEN)) {
    sub DCS_MAXLEN () {	256;}
}
unless(defined(&DCSTYPE_TABRESTORE)) {
    sub DCSTYPE_TABRESTORE () {	1;}
}
unless(defined(&ARG)) {
    sub ARG {
	my($n) = @_;
	eval q(( ($edp->{args[&(n)]})));
    }
}
unless(defined(&DEF1_ARG)) {
    sub DEF1_ARG {
	my($n) = @_;
	eval q(( &ARG($n) ?  &ARG($n) : 1));
    }
}
unless(defined(&DEFx_ARG)) {
    sub DEFx_ARG {
	my($n, $x) = @_;
	eval q(( &ARG($n) ?  &ARG($n) : ($x)));
    }
}
unless(defined(&ROWS_ABOVE)) {
    sub ROWS_ABOVE () {	( ($edp->{crow}) -  ($edp->{scrreg_startrow}));}
}
unless(defined(&ROWS_BELOW)) {
    sub ROWS_BELOW () {	(( ($edp->{scrreg_startrow}) +  ($edp->{scrreg_nrows})) -  ($edp->{crow}) - 1);}
}
unless(defined(&CHECK_DW)) {
    sub CHECK_DW () {	 &do {  &if ( ($edp->{dblwid})  &&  ($edp->{dblwid[&edp}->{crow]})) {  ($edp->{dw}) = 1;  &if ( ($edp->{ccol}) > ( ($edp->{ncols}) >> 1) - 1)  ($edp->{ccol}) = ( ($edp->{ncols}) >> 1) - 1; }  &else  ($edp->{dw}) = 0; }  &while (0);}
}
unless(defined(&NCOLS)) {
    sub NCOLS () {	( ($edp->{ncols}) >>  ($edp->{dw}));}
}
unless(defined(&COLS_LEFT)) {
    sub COLS_LEFT () {	( &NCOLS -  ($edp->{ccol}) - 1);}
}
unless(defined(&COPYCOLS)) {
    sub COPYCOLS {
	my($f, $t, $n) = @_;
	eval q((* ($edp->{emulops}->{copycols}))( ($edp->{emulcookie}),  ($edp->{crow}), ($f) <<  ($edp->{dw}), ($t) <<  ($edp->{dw}), ($n) <<  ($edp->{dw})));
    }
}
unless(defined(&ERASECOLS)) {
    sub ERASECOLS {
	my($f, $n, $a) = @_;
	eval q((* ($edp->{emulops}->{erasecols}))( ($edp->{emulcookie}),  ($edp->{crow}), ($f) <<  ($edp->{dw}), ($n) <<  ($edp->{dw}), $a));
    }
}
unless(defined(&WSEMUL_VT_ID1)) {
    sub WSEMUL_VT_ID1 () {	"\033[?62;6c";}
}
unless(defined(&WSEMUL_VT_ID2)) {
    sub WSEMUL_VT_ID2 () {	"\033[>24;20;0c";}
}
1;
