8 #include <sys/farptr.h>
34 const char *pachText = (
const char *)
buffer;
36 unsigned char uchAttr = (
unsigned char) pInfo->
usAttr;
43 regs.h.al = *pachText++;
47 __dpmi_int(0x10, ®s);
62 const char *pachText = (
const char *)
buffer;
63 unsigned short usAttr = pInfo->
usAttr << 8;
64 int tmp_x = handle->
Coord.
X;
65 int tmp_y = handle->
Coord.
Y;
66 unsigned char *puchBuffer = alloca( length * 2 );
67 unsigned short *pusBuffer = (
unsigned short*) puchBuffer;
73 *--pusBuffer = usAttr + (
unsigned short) (
unsigned char) pachText[i];
76 _movedataw( _my_ds(), (
int) puchBuffer,
85 unsigned long physAddr;
86 unsigned char mode = _farpeekb( _dos_ds, 0x465 );
97 if( (cols == 0) || (rows == 0) )
100 int pageSize = cols * rows * (
sizeof( char ) * 2);
104 physAddr += pg * pageSize;
117 const char *pachText = (
const char *) buffer;
118 int win_left, win_top, win_cols, win_rows;
119 int view_top, view_bottom;
134 win_left = win_top = 0;
149 hooks.
Border.
Top = win_top + view_top - 1;
189 fwrite(buffer, len, 1, stdout);
195 static void (*fn)(
const void *
buffer,
size_t len,
int mask) =
NULL;
200 if( isatty( fileno( stdout ) ) )
206 fn( buffer, len, mask );