Back to index

glibc  2.9
Functions
wcswidth.c File Reference
#include "wcwidth.h"

Go to the source code of this file.

Functions

int wcswidth (const wchar_t *s, size_t n)

Function Documentation

int wcswidth ( const wchar_t *  s,
size_t  n 
)

Definition at line 25 of file wcswidth.c.

{
  int result = 0;

  while (n-- > 0 && *s != L'\0')
    {
      int now = internal_wcwidth (*s);
      if (now == -1)
       return -1;
      result += now;
      ++s;
    }

  return result;
}

Here is the call graph for this function:

Here is the caller graph for this function: