Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ NLescstr(3) — AIX PS/2 1.2.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ctype

getc, fgetc, getchar, getw, getwc, fgetwc, getwchar

NCctype

NCstring

NLchar

NLstring

display

symbols



NLESCSTR(3,L)               AIX Technical Reference               NLESCSTR(3,L)



-------------------------------------------------------------------------------
NLescstr, NLunescstr, NLflatstr



PURPOSE

Translates strings of characters.

LIBRARY

Standard C Library (libc.a)

SYNTAX

#include <NLctype.h>




      int NLescstr (src, dest, dlen)      int NLunescstr (src, dest, dlen)
      unsigned char *src, *dest;          unsigned char *src, *dest;
      int dlen;                           int dlen;

      int NLflatstr (src, dest, dlen)
      unsigned char *src, *dest;
      int dlen



DESCRIPTION

Note:  In the multibyte environment, these routines are provided for backward
       compatibility and they support only code page pc850.

These subroutines use the subroutines described under "conv" to convert an
entire string of type char, perhaps containing extended characters, into a
string of pure ASCII bytes.  Each of these subroutines require three
parameters:  the src address of the source string, the dest address of the
destination string, and the dlen value, giving the total number of bytes
available in the destination string.  Each writes a result string terminated by
a null character and returns its length in bytes.  The dlen value should
include space for the null character.  If dest is too short to contain the
entire output string, not all of src is translated.

The NLescstr uses the NCesc subroutine to translate each ASCII or extended
character in src to pure ASCII.  Each extended character encountered is
translated to a printable ASCII escape sequence that uniquely identifies the
extended character.  See "display symbols" for a list of these escape
sequences.





Processed November 7, 1990       NLESCSTR(3,L)                                1





NLESCSTR(3,L)               AIX Technical Reference               NLESCSTR(3,L)



The NLunescstr subroutine performs the inverse translation using the NCunesc
subroutine to translate each ASCII byte of src into dest, and translate each
ASCII escape sequence back into the extended character it represents.

The NLflatstr subroutine uses the NCflatchr subroutine to translate each
character, ASCII or extended, in src to a single ASCII byte in dest.  The dest
string may have fewer bytes than the src string, but the number of logical
characters, or the display length, is the same.  See "NLstring."

RELATED INFORMATION

In this book:  "ctype,"  "getc, fgetc, getchar, getw, getwc, fgetwc,
getwchar,"  "NCctype," "NCstring,"  "NLchar,"  "NLstring," and "display
symbols."

AIX Guide to Multibyte Character Set (MBCS) Support.







































Processed November 7, 1990       NLESCSTR(3,L)                                2



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026