Fanuc C-Executer Operating Manual
B-62443EN-3/03E
- 1001 -
[Example]
The following program makes the characters and attributes that are
displayed on the specified area to move to right by 3 digit.
#include <crt.h>
#include <stdio.h>
#include <stdlib.h>
void example( unsigned int y1, unsigned int x1,
unsigned int y2, unsigned int x2 )
{
unsigned long *buf ;
unsigned int i ;
buf = (unsigned long *)malloc( (y2-y1+1)*(x2-x1+1)*4) ;
crt_gettextimg( y1, x1, y2, x2, buf ) ;
crt_puttextimg( y1, x1+3, y2, x2+3, buf, 0 ) ;
free( buf ) ;
/* erase disused characters */
for ( i = y1 ; i <= y2 ; i++ )
printf ( "\033[%u;%uH ", i, x1 ) ;
}