1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771
|
/* $Id: osdepend.c,v 1.2 2000/05/25 22:28:56 jholder Exp $
* --------------------------------------------------------------------
* see doc/License.txt for License Information
* --------------------------------------------------------------------
*
* File name: $Id: osdepend.c,v 1.2 2000/05/25 22:28:56 jholder Exp $
*
* Description:
*
* Modification history:
* $Log: osdepend.c,v $
* Revision 1.2 2000/05/25 22:28:56 jholder
* changes routine names to reflect zmachine opcode names per spec 1.0
*
* Revision 1.1.1.1 2000/05/10 14:21:34 jholder
*
* imported
*
*
* --------------------------------------------------------------------
*/
/*
* osdepend.c
*
* All non screen specific operating system dependent routines.
*
* Olaf Barthel 28-Jul-1992
* Modified John Holder(j-holder@home.com) 25-July-1995
* Support for standalone storyfiles by Magnu Olsson (mol@df.lth.se) Nov.1995
*
*/
#ifdef HAVE_GETOPT
#include <getopt.h>
#endif
#include "ztypes.h"
#include "jzexe.h"
/* File names will be O/S dependent */
#if defined(AMIGA)
#define SAVE_NAME "Story.Save" /* Default save name */
#define SCRIPT_NAME "PRT:" /* Default script name */
#define RECORD_NAME "Story.Record" /* Default record name */
#define AUXILARY_NAME "Story.Aux" /* Default auxilary name */
#else /* defined(AMIGA) */
#define SAVE_NAME "story.sav" /* Default save name */
#define SCRIPT_NAME "story.scr" /* Default script name */
#define RECORD_NAME "story.rec" /* Default record name */
#define AUXILARY_NAME "story.aux" /* Default auxilary name */
#endif /* defined(AMIGA) */
#ifdef STRICTZ
/* Define stuff for stricter Z-code error checking, for the generic
* Unix/DOS/etc terminal-window interface. Feel free to change the way
* player prefs are specified, or replace report_zstrict_error()
* completely if you want to change the way errors are reported.
*/
/* There are four error reporting modes: never report errors;
* report only the first time a given error type occurs; report
* every time an error occurs; or treat all errors as fatal
* errors, killing the interpreter. I strongly recommend
* "report once" as the default. But you can compile in a
* different default by changing the definition of
* STRICTZ_DEFAULT_REPORT_MODE. In any case, the player can
* specify a report mode on the command line by typing "-s 0"
* through "-s 3".
*/
#define STRICTZ_REPORT_NEVER (0)
#define STRICTZ_REPORT_ONCE (1)
#define STRICTZ_REPORT_ALWAYS (2)
#define STRICTZ_REPORT_FATAL (3)
#define STRICTZ_DEFAULT_REPORT_MODE STRICTZ_REPORT_NEVER
static int strictz_report_mode;
static int strictz_error_count[STRICTZ_NUM_ERRORS];
#endif /* STRICTZ */
#if !defined(AMIGA)
/* getopt linkages */
#if !defined(POSIX)
extern int optind;
extern const char *optarg;
#endif /* !defined(POSIX) */
extern ZINT16 default_fg, default_bg;
#endif /* !defined(AMIGA) */
#if defined OS2 || defined __MSDOS__
int iPalette;
#endif
#if !defined(AMIGA)
/*
* process_arguments
*
* Do any argument preprocessing necessary before the game is
* started. This may include selecting a specific game file or
* setting interface-specific options.
*
*/
void process_arguments( int argc, char *argv[] )
{
int c, errflg = 0;
int infoflag = 0;
int size;
int expected_args;
int num;
#ifdef STRICTZ
/* Initialize the STRICTZ variables. */
strictz_report_mode = STRICTZ_DEFAULT_REPORT_MODE;
for ( num = 0; num < STRICTZ_NUM_ERRORS; num++ )
{
strictz_error_count[num] = 0;
}
#endif /* STRICTZ */
/* Parse the options */
monochrome = 0;
hist_buf_size = 1024;
bigscreen = 0;
#ifdef STRICTZ
#if defined OS2 || defined __MSDOS__
#define GETOPT_SET "gbomvzhy?l:c:k:r:t:s:"
#elif defined TURBOC
#define GETOPT_SET "bmvzhy?l:c:k:r:t:s:"
#elif defined HARD_COLORS
#define GETOPT_SET "mvzhy?l:c:k:r:t:s:f:b:"
#else
#define GETOPT_SET "mvzhy?l:c:k:r:t:s:"
#endif
#else
#if defined OS2 || defined __MSDOS__
#define GETOPT_SET "gbomvzhy?l:c:k:r:t:"
#elif defined TURBOC
#define GETOPT_SET "bmvzhy?l:c:k:r:t:"
#elif defined HARD_COLORS
#define GETOPT_SET "mvzhy?l:c:k:r:t:f:b:"
#else
#define GETOPT_SET "mvzhy?l:c:k:r:t:"
#endif
#endif
while ( ( c = getopt( argc, argv, GETOPT_SET ) ) != EOF )
{
switch ( c )
{
case 'l': /* lines */
screen_rows = atoi( optarg );
break;
case 'c': /* columns */
screen_cols = atoi( optarg );
break;
case 'r': /* right margin */
right_margin = atoi( optarg );
break;
case 't': /* top margin */
top_margin = atoi( optarg );
break;
case 'k': /* number of K for hist_buf_size */
size = atoi( optarg );
hist_buf_size = ( hist_buf_size > size ) ? hist_buf_size : size;
if ( hist_buf_size > 16384 )
hist_buf_size = 16384;
break;
case 'y': /* Tandy */
fTandy = 1;
break;
#if defined OS2 || defined __MSDOS__
case 'g': /* Beyond Zork or other games using IBM graphics */
fIBMGraphics = 1;
break;
#endif
case 'v': /* version information */
fprintf( stdout, "\nJZIP - An Infocom Z-code Interpreter Program \n" );
fprintf( stdout, " %s %s\n", JZIPVER, JZIPRELDATE );
if ( STANDALONE_FLAG )
{
fprintf( stdout, " Standalone game: %s\n", argv[0] );
}
fprintf( stdout, "---------------------------------------------------------\n" );
fprintf( stdout, "Author : %s\n", JZIPAUTHOR );
fprintf( stdout, "Official Webpage: %s\n", JZIPURL );
fprintf( stdout, "IF Archive : ftp://ifarchive.org/infocom/interpreters/zip/\n" );
fprintf( stdout, " Based on ZIP 2.0 source code by Mark Howell\n\n" );
fprintf( stdout,
"Bugs: Please report bugs and portability bugs to the maintainer." );
fprintf( stdout, "\n\nInterpreter:\n\n" );
fprintf( stdout, "\tThis interpreter will run all Infocom V1 to V5 and V8 games.\n" );
fprintf( stdout,
"\tThis is a Z-machine standard 1.0 interpreter, including support for\n" );
fprintf( stdout, "\tthe Quetzal portable save file format, ISO 8859-1 (Latin-1)\n" );
fprintf( stdout,
"\tinternational character support, and the extended save and load opcodes.\n" );
fprintf( stdout, "\t\n" );
infoflag++;
break;
#if defined (HARD_COLORS)
case 'f':
default_fg = atoi( optarg );
break;
case 'b':
default_bg = atoi( optarg );
break;
#endif
#if defined OS2 || defined __MSDOS__
case 'm': /* monochrome */
iPalette = 2;
break;
case 'b': /* black-and-white */
iPalette = 1;
break;
case 'o': /* color */
iPalette = 0;
break;
#else
case 'm':
monochrome = 1;
break;
#endif
#if defined TURBOC
case 'b':
bigscreen = 1;
break;
#endif
#ifdef STRICTZ
case 's': /* strictz reporting mode */
strictz_report_mode = atoi( optarg );
if ( strictz_report_mode < STRICTZ_REPORT_NEVER ||
strictz_report_mode > STRICTZ_REPORT_FATAL )
{
errflg++;
}
break;
#endif /* STRICTZ */
case 'z':
print_license( );
infoflag++;
break;
case 'h':
case '?':
default:
errflg++;
}
}
if ( infoflag )
exit( EXIT_SUCCESS );
if ( STANDALONE_FLAG )
expected_args = 0;
else
expected_args = 1;
/* Display usage */
if ( errflg || optind + expected_args != argc )
{
if ( STANDALONE_FLAG )
fprintf( stdout, "usage: %s [options...]\n", argv[0] );
else
fprintf( stdout, "usage: %s [options...] story-file\n", argv[0] );
fprintf( stdout, "JZIP - an Infocom story file interpreter.\n" );
fprintf( stdout, " Version %s by %s.\n", JZIPVER, JZIPAUTHOR );
fprintf( stdout, " Release %s.\n", JZIPRELDATE );
fprintf( stdout, " Based on ZIP V2.0 source by Mark Howell\n" );
fprintf( stdout, " Plays types 1-5 and 8 Infocom and Inform games.\n\n" );
fprintf( stdout, "\t-l n lines in display\n" );
fprintf( stdout, "\t-c n columns in display\n" );
fprintf( stdout, "\t-r n text right margin (default = %d)\n", DEFAULT_RIGHT_MARGIN );
fprintf( stdout, "\t-t n text top margin (default = %d)\n", DEFAULT_TOP_MARGIN );
fprintf( stdout, "\t-k n set the size of the command history buffer to n bytes\n" );
fprintf( stdout, "\t (Default is 1024 bytes. Maximum is 16384 bytes.)\n" );
fprintf( stdout, "\t-y turn on the legendary \"Tandy\" bit\n" );
fprintf( stdout, "\t-v display version information\n" );
fprintf( stdout, "\t-h display this usage information\n" );
#if defined (HARD_COLORS)
fprintf( stdout, "\t-f n foreground color\n" );
fprintf( stdout, "\t-b n background color (-1 to ignore bg color (try it on an Eterm))\n" );
fprintf( stdout, "\t Black=0 Red=1 Green=2 Yellow=3 Blue=4 Magenta=5 Cyan=6 White=7\n" );
#endif
fprintf( stdout, "\t-m force monochrome mode\n" );
#if defined __MSDOS__ || defined OS2
fprintf( stdout, "\t-b force black-and-white mode\n" );
fprintf( stdout, "\t-o force color mode\n" );
fprintf( stdout, "\t-g use \"Beyond Zork\" graphics, rather than standard international\n" );
#elif defined TURBOC
fprintf( stdout, "\t-b run in 43/50 line EGA/VGA mode\n" );
#endif
#ifdef STRICTZ
fprintf( stdout, "\t-s n stricter error checking (default = %d) (0: none; 1: report 1st\n",
STRICTZ_DEFAULT_REPORT_MODE );
fprintf( stdout, "\t error; 2: report all errors; 3: exit after any error)\n" );
#endif /* STRICTZ */
fprintf( stdout, "\t-z display license information.\n" );
exit( EXIT_FAILURE );
}
/* Open the story file */
if ( !STANDALONE_FLAG ) /* mol 951115 */
open_story( argv[optind] );
else
{
/* standalone, ie. the .exe file _is_ the story file. */
if ( argv[0][0] == 0 )
{
/* some OS's (ie DOS prior to v.3.0) don't supply the path to */
/* the .exe file in argv[0]; in that case, we give up. (mol) */
fatal( "process_arguments(): Sorry, this program will not run on this platform." );
}
open_story( argv[0] );
}
} /* process_arguments */
#endif /* !defined(AMIGA) */
#if !defined(AMIGA)
/*
* file_cleanup
*
* Perform actions when a file is successfully closed. Flag can be one of:
* GAME_SAVE, GAME_RESTORE, GAME_SCRIPT.
*
*/
void file_cleanup( const char *file_name, int flag )
{
UNUSEDVAR( file_name );
UNUSEDVAR( flag );
} /* file_cleanup */
#endif /* !defined(AMIGA) */
#if !defined(AMIGA)
/*
* sound
*
* Play a sound file or a note.
*
* argc = 1: argv[0] = note# (range 1 - 3)
*
* Play note.
*
* argc = 2: argv[0] = 0
* argv[1] = 3
*
* Stop playing current sound.
*
* argc = 2: argv[0] = 0
* argv[1] = 4
*
* Free allocated resources.
*
* argc = 3: argv[0] = ID# of sound file to replay.
* argv[1] = 2
* argv[2] = Volume to replay sound with, this value
* can range between 1 and 8.
*
* argc = 4: argv[0] = ID# of sound file to replay.
* argv[1] = 2
* argv[2] = Control information
* argv[3] = Volume information
*
* Volume information:
*
* 0x34FB -> Fade sound in
* 0x3507 -> Fade sound out
* other -> Replay sound at maximum volume
*
* Control information:
*
* This word is divided into two bytes,
* the upper byte determines the number of
* cycles to play the sound (e.g. how many
* times a clock chimes or a dog barks).
* The meaning of the lower byte is yet to
* be discovered :)
*
*/
void sound( int argc, zword_t * argv )
{
/* Supply default parameters */
if ( argc < 4 )
argv[3] = 0;
if ( argc < 3 )
argv[2] = 0xff;
if ( argc < 2 )
argv[1] = 2;
/* Generic bell sounder */
if ( argc == 1 || argv[1] == 2 )
display_char( '\007' );
} /* sound */
#endif /* !defined(AMIGA) */
/*
* get_file_name
*
* Return the name of a file. Flag can be one of:
* GAME_SAVE - Save file (write only)
* GAME_RESTORE - Save file (read only)
* GAME_SCRIPT - Script file (write only)
* GAME_RECORD - Keystroke record file (write only)
* GAME_PLABACK - Keystroke record file (read only)
* GAME_SAVE_AUX - Auxilary (preferred settings) file (write only)
* GAME_LOAD_AUX - Auxilary (preferred settings) file (read only)
*/
int get_file_name( char *file_name, char *default_name, int flag )
{
char buffer[127 + 2]; /* 127 is the biggest positive char */
int status = 0;
/* If no default file name then supply the standard name */
if ( default_name[0] == '\0' )
{
if ( flag == GAME_SCRIPT )
strcpy( default_name, SCRIPT_NAME );
else if ( flag == GAME_RECORD || flag == GAME_PLAYBACK )
strcpy( default_name, RECORD_NAME );
else if ( flag == GAME_SAVE_AUX || GAME_LOAD_AUX )
strcpy( default_name, AUXILARY_NAME );
else /* (flag == GAME_SAVE || flag == GAME_RESTORE) */
strcpy( default_name, SAVE_NAME );
}
/* Prompt for the file name */
output_line( "Enter a file name." );
output_string( "(Default is \"" );
output_string( default_name );
output_string( "\"): " );
buffer[0] = 127;
buffer[1] = 0;
( void ) get_line( buffer, 0, 0 );
/* Copy file name from the input buffer */
if ( h_type > V4 )
{
unsigned char len = buffer[1];
memcpy( file_name, &buffer[2], len );
file_name[len] = '\0';
}
else
strcpy( file_name, &buffer[1] );
/* If nothing typed then use the default name */
if ( file_name[0] == '\0' )
strcpy( file_name, default_name );
#if !defined(VMS) /* VMS has file version numbers, so cannot overwrite */
/* Check if we are going to overwrite the file */
if ( flag == GAME_SAVE || flag == GAME_SCRIPT || flag == GAME_RECORD || flag == GAME_SAVE_AUX )
{
FILE *tfp;
#if defined BUFFER_FILES
char tfpbuffer[BUFSIZ];
#endif
char c;
/* Try to access the file */
tfp = fopen( file_name, "r" );
if ( tfp != NULL )
{
/* If it succeeded then prompt to overwrite */
#if defined BUFFER_FILES
setbuf( tfp, tfpbuffer );
#endif
output_line( "You are about to write over an existing file." );
output_string( "Proceed? (Y/N) " );
do
{
c = ( char ) input_character( 0 );
c = ( char ) toupper( c );
}
while ( c != 'Y' && c != 'N' );
output_char( c );
output_new_line( );
/* If no overwrite then fail the routine */
if ( c == 'N' )
status = 1;
fclose( tfp );
}
}
#endif /* !defined(VMS) */
/* Record the file name if it was OK */
if ( status == 0 )
record_line( file_name );
return ( status );
} /* get_file_name */
#if !defined(AMIGA)
/*
* fatal
*
* Display message and stop interpreter.
*
*/
void fatal( const char *s )
{
reset_screen( );
fprintf( stderr, "\nFatal error: %s (PC = 0x%08lX)\n", s, pc );
#ifdef DEBUG_TERPRE
fprintf( stdout, "\nFatal error: %s (PC = 0x%08lX)\n", s, pc );
#endif
exit( 1 );
} /* fatal */
#endif /* !defined(AMIGA) */
/*
* report_strictz_error
*
* This handles Z-code error conditions which ought to be fatal errors,
* but which players might want to ignore for the sake of finishing the
* game.
*
* The error is provided as both a numeric code and a string. This allows
* us to print a warning the first time a particular error occurs, and
* ignore it thereafter.
*
* errnum : Numeric code for error (0 to STRICTZ_NUM_ERRORS-1)
* errstr : Text description of error
*
*/
#ifdef STRICTZ
void report_strictz_error( int errnum, const char *errstr )
{
int wasfirst;
char buf[256] = { 0 };
if ( errnum <= 0 || errnum >= STRICTZ_NUM_ERRORS )
return;
if ( strictz_report_mode == STRICTZ_REPORT_FATAL )
{
sprintf( buf, "STRICTZ: %s (PC = %lx)", errstr, pc );
fatal( buf );
return;
}
wasfirst = ( strictz_error_count[errnum] == 0 );
strictz_error_count[errnum]++;
if ( ( strictz_report_mode == STRICTZ_REPORT_ALWAYS ) ||
( strictz_report_mode == STRICTZ_REPORT_ONCE && wasfirst ) )
{
sprintf( buf, "STRICTZ Warning: %s (PC = %lx)", errstr, pc );
write_string( buf );
if ( strictz_report_mode == STRICTZ_REPORT_ONCE )
{
write_string( " (will ignore further occurrences)" );
}
else
{
sprintf( buf, " (occurrence %d)", strictz_error_count[errnum] );
write_string( buf );
}
z_new_line( );
}
} /* report_strictz_error */
#endif /* STRICTZ */
#if !defined(AMIGA)
/*
* fit_line
*
* This routine determines whether a line of text will still fit
* on the screen.
*
* line : Line of text to test.
* pos : Length of text line (in characters).
* max : Maximum number of characters to fit on the screen.
*
*/
int fit_line( const char *line_buffer, int pos, int max )
{
UNUSEDVAR( line_buffer );
return ( pos < max );
} /* fit_line */
#endif /* !defined(AMIGA) */
#if !defined(AMIGA)
/*
* print_status
*
* Print the status line (type 3 games only).
*
* argv[0] : Location name
* argv[1] : Moves/Time
* argv[2] : Score
*
* Depending on how many arguments are passed to this routine
* it is to print the status line. The rendering attributes
* and the status line window will be have been activated
* when this routine is called. It is to return FALSE if it
* cannot render the status line in which case the interpreter
* will use display_char() to render it on its own.
*
* This routine has been provided in order to support
* proportional-spaced fonts.
*
*/
int print_status( int argc, char *argv[] )
{
UNUSEDVAR( argc );
UNUSEDVAR( argv );
return ( FALSE );
} /* print_status */
#endif /* !defined(AMIGA) */
#if !defined(AMIGA)
/*
* set_font
*
* Set a new character font. Font can be either be:
*
* TEXT_FONT (1) = normal text character font
* GRAPHICS_FONT (3) = graphical character font
*
*/
void set_font( int font_type )
{
UNUSEDVAR( font_type );
} /* set_font */
#endif /* !defined(AMIGA) */
#if !defined MSDOS && !defined OS2 && !defined AMIGA && !defined HARD_COLORS && !defined ATARIST
/*
* set_colours
*
* Sets screen foreground and background colours.
*
*/
void set_colours( zword_t foreground, zword_t background )
{
} /* set_colours */
#endif /* !defined MSDOS && !defined OS2 && !defined AMIGA !defined HARD_COLORS && !defined ATARIST */
#if !defined VMS && !defined MSDOS && !defined OS2 && !defined POSIX
/*
* codes_to_text
*
* Translate Z-code characters to machine specific characters. These characters
* include line drawing characters and international characters.
*
* The routine takes one of the Z-code characters from the following table and
* writes the machine specific text replacement. The target replacement buffer
* is defined by MAX_TEXT_SIZE in ztypes.h. The replacement text should be in a
* normal C, zero terminated, string.
*
* Return 0 if a translation was available, otherwise 1.
*
* Arrow characters (0x18 - 0x1b):
*
* 0x18 Up arrow
* 0x19 Down arrow
* 0x1a Right arrow
* 0x1b Left arrow
*
* International characters (0x9b - 0xa3):
*
* 0x9b a umlaut (ae)
* 0x9c o umlaut (oe)
* 0x9d u umlaut (ue)
* 0x9e A umlaut (Ae)
* 0x9f O umlaut (Oe)
* 0xa0 U umlaut (Ue)
* 0xa1 sz (ss)
* 0xa2 open quote (>>)
* 0xa3 close quota (<<)
*
* Line drawing characters (0xb3 - 0xda):
*
* 0xb3 vertical line (|)
* 0xba double vertical line (#)
* 0xc4 horizontal line (-)
* 0xcd double horizontal line (=)
* all other are corner pieces (+)
*
*/
int codes_to_text( int c, char *s )
{
return 1;
} /* codes_to_text */
#endif /* !defined VMS && !defined MSDOS && !defined OS2 && !defined POSIX */
|