Library /sys$common/syshlp/helplib.hlb  —  CRTL  wcswidth
    Determines the number of printing positions on a display device
    that are required for a wide-character string.

    Format

      #include  <wchar.h>

      int wcswidth  (const wchar_t *pwcs, size_t n);

1  –  Arguments

 pwcs

    A pointer to a wide-character string.

 n

    The maximum number of characters in the string.

2  –  Description

    The wcswidth function returns the number of printing positions
    required to display the first n characters of the string pointed
    to by pwcs. If there are less than n wide characters in the
    string, the function returns the number of positions required
    for the whole string.

3  –  Return Values

    x                  The number of printing positions required.
    0                  If pwcs is a null character.
    -1                 Indicates that one (or more) of the wide
                       characters in the string pointed to by pwcs
                       is not a printable character.
Close Help