wcwidth
Section: C Library Functions (3)
Updated: 2026-02-08
Index
JM Home Page
roff page
名前
wcwidth - ワイド文字が必要とするカラム数を調べる
ライブラリ
標準 C ライブラリ (libc,~-lc)
書式
#define _XOPEN_SOURCE
#include <wchar.h>
int wcwidth(wchar_t wc);
説明
The wcwidth() function returns the number of columns needed to represent
the wide character wc. If wc is a printable wide character, the value
is at least 0. If wc is null wide character (L'\0'), the
value is 0. Otherwise, -1 is returned.
返り値
The wcwidth() function returns the number of column positions for wc.
属性
この節で使用されている用語の説明については、 attributes(7) を参照。
| インターフェース | 属性 | 値
|
|
wcwidth()
| Thread safety | MT-Safe locale
|
標準規格
POSIX.1-2008.
歴史
POSIX.1-2001.
Note that before glibc 2.2.5, glibc used the prototype
int wcwidth(wint_t wc);
注意
wcwidth() の動作は、現在のロケールの LC_CTYPE カテゴリーに依存する。
関連項目
iswprint(3), wcswidth(3), feature_test_macros(7)
Index
- 名前
-
- ライブラリ
-
- 書式
-
- 説明
-
- 返り値
-
- 属性
-
- 標準規格
-
- 歴史
-
- 注意
-
- 関連項目
-
This document was created by
man2html,
using the manual pages.