1 |
/* Determine the number of screen columns needed for a string. |
/* Determine the number of screen columns needed for a string. |
2 |
Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc. |
Copyright (C) 2000-2002 Free Software Foundation, Inc. |
3 |
|
|
4 |
This program is free software; you can redistribute it and/or modify |
This program is free software; you can redistribute it and/or modify |
5 |
it under the terms of the GNU General Public License as published by |
it under the terms of the GNU General Public License as published by |
21 |
# include <config.h> |
# include <config.h> |
22 |
#endif |
#endif |
23 |
|
|
|
/* Get mbstate_t, mbrtowc(), mbsinit(), wcwidth(). This must be |
|
|
included before "mbswidth.h", because UnixWare 7.1.1 <wchar.h> |
|
|
declares its own mbswidth and we want mbswidth.h's "#define |
|
|
mbswidth gnu_mbswidth" to take effect after <wchar.h> is |
|
|
included. */ |
|
|
#if HAVE_WCHAR_H |
|
|
# include <wchar.h> |
|
|
#endif |
|
|
|
|
24 |
/* Specification. */ |
/* Specification. */ |
25 |
#include "mbswidth.h" |
#include "mbswidth.h" |
26 |
|
|
32 |
/* Get isprint(). */ |
/* Get isprint(). */ |
33 |
#include <ctype.h> |
#include <ctype.h> |
34 |
|
|
35 |
|
/* Get mbstate_t, mbrtowc(), mbsinit(), wcwidth(). */ |
36 |
|
#if HAVE_WCHAR_H |
37 |
|
# include <wchar.h> |
38 |
|
#endif |
39 |
|
|
40 |
/* Get iswprint(), iswcntrl(). */ |
/* Get iswprint(), iswcntrl(). */ |
41 |
#if HAVE_WCTYPE_H |
#if HAVE_WCTYPE_H |
42 |
# include <wctype.h> |
# include <wctype.h> |