diff options
author | Max Kellermann <max@duempel.org> | 2008-10-02 19:01:02 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-10-02 19:01:02 +0200 |
commit | ee9951222c4f0e3970466f6aba2e42dea21a6cdc (patch) | |
tree | e02b7d1ae6b5078df340485e1b81861a0aab9e12 /src/charset.h | |
parent | b693269fd9740a3074b84da5645f6bd9daa6486e (diff) | |
download | mpd-ee9951222c4f0e3970466f6aba2e42dea21a6cdc.tar.gz mpd-ee9951222c4f0e3970466f6aba2e42dea21a6cdc.tar.xz mpd-ee9951222c4f0e3970466f6aba2e42dea21a6cdc.zip |
charset: renamed my_strlen() to utf8_width()
my_strlen() is a bad name for the function, since the return value is
not a length, but a visible width on the screen. Rename it to
utf8_width() and change its return type to "unsigned".
Diffstat (limited to '')
-rw-r--r-- | src/charset.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/charset.h b/src/charset.h index 119937710..24f7ef632 100644 --- a/src/charset.h +++ b/src/charset.h @@ -28,7 +28,8 @@ void charset_init(bool disable); /** * Returns the number of terminal cells occupied by this string. */ -size_t my_strlen(const char *str); +unsigned +utf8_width(const char *str); char *utf8_to_locale(const char *str); char *locale_to_utf8(const char *str); |