diff --git a/src/charset.c b/src/charset.c
index 7e2e2d1aeffa5acbacc2f67dd3ad1d7be91dee0e..34381adfcdc3f195a5d7ac6fa139d2c95b70af89 100644 (file)
--- a/src/charset.c
+++ b/src/charset.c
}
#endif
-#ifdef ENABLE_WIDE
+#ifdef HAVE_CURSES_ENHANCED
static inline unsigned
unicode_char_width(gunichar ch)
{
return 1;
}
-#endif /* ENABLE_WIDE */
+#endif /* HAVE_CURSES_ENHANCED */
unsigned
utf8_width(const char *str)
{
assert(str != NULL);
-#if defined(ENABLE_MULTIBYTE) && !defined(ENABLE_WIDE)
+#if defined(ENABLE_MULTIBYTE) && !defined(HAVE_CURSES_ENHANCED)
return g_utf8_strlen(str, -1);
#else
-#ifdef ENABLE_WIDE
+#ifdef HAVE_CURSES_ENHANCED
if (g_utf8_validate(str, -1, NULL)) {
size_t len = g_utf8_strlen(str, -1);
unsigned width = 0;
{
assert(p != NULL);
-#ifdef ENABLE_WIDE
+#ifdef HAVE_CURSES_ENHANCED
if (!g_utf8_validate(p, -1, NULL))
return ascii_cut_width(p, max_width);
return wide_cut_width(p, max_width);
-#elif defined(ENABLE_MULTIBYTE) && !defined(ENABLE_WIDE)
+#elif defined(ENABLE_MULTIBYTE) && !defined(HAVE_CURSES_ENHANCED)
return narrow_cut_width(p, max_width);
#else
return ascii_cut_width(p, max_width);