home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c221 / 6.ddi / MWHC.006 / J < prev    next >
Encoding:
Text File  |  1992-12-09  |  1.4 KB  |  41 lines

  1. /*
  2.  *   lineterm.cf -- extra-ANSI 
  3.  *
  4.  *   Facilities for manipulating the line terminator definitions.
  5.  *
  6.  *           Copyright (c) 1990, MetaWare Incorporated
  7.  */
  8.  
  9. #ifndef _LINETERM_CF
  10. #define _LINETERM_CF
  11.  
  12. #if 0
  13. This defines line termination conventions on a particular system.
  14. Both the input line terminator and the output line terminator are
  15. specified.  This allows one to write a program to convert text from one
  16. format to another by simply reading and writing lines.
  17. The values are exported from the assembly language init routine.
  18. These values can also be changed dynamically by the programmer at
  19. execution time.
  20.  
  21. There may be at most 2 chars in the input line terminator.
  22. The output line terminator may be of any length.
  23. For systems terminating a line with a single character (e.g UNIX), merely
  24. set both strings to a string of length 1 containing just that character.
  25. MS-DOS also supports multiple input terminations. by setting the length
  26. to zero, the first character to cr and the second to lf, then any of the
  27. three combinations cr, cr lf, lf, will act as a valid line terminator.
  28. #endif
  29.  
  30. #include <implemen.cf>
  31.  
  32. #pragma data(common,_Private_prefix "LTCONV");
  33.  
  34. /* Pascal strings contain two bytes of length followed by the characters. */
  35. static struct {short Length; char S[2];} LTConv_in, LTConv_out;
  36. /* For Unix: LTConv = LF; MS-DOS: LTConv = CR || LF; Daisy Logician: LTConv = CR. */
  37.  
  38. #pragma data;
  39.  
  40. #endif /* _LINETERM_CF */
  41.