summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorHye-Shik Chang <hyeshik@gmail.com>2004-08-04 07:38:35 (GMT)
committerHye-Shik Chang <hyeshik@gmail.com>2004-08-04 07:38:35 (GMT)
commite9ddfbb41207328d5c89061067f3431e00711fda (patch)
tree54093161fe6808de7d6fcc3304eb32241231f010 /Misc
parentb5047fd01948ab108edcc1b3c2c901d915814cfd (diff)
downloadcpython-e9ddfbb41207328d5c89061067f3431e00711fda.zip
cpython-e9ddfbb41207328d5c89061067f3431e00711fda.tar.gz
cpython-e9ddfbb41207328d5c89061067f3431e00711fda.tar.bz2
SF #989185: Drop unicode.iswide() and unicode.width() and add
unicodedata.east_asian_width(). You can still implement your own simple width() function using it like this: def width(u): w = 0 for c in unicodedata.normalize('NFC', u): cwidth = unicodedata.east_asian_width(c) if cwidth in ('W', 'F'): w += 2 else: w += 1 return w
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS3
1 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index 40c58b3..630c85e 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -67,6 +67,9 @@ Core and builtins
- Added a workaround for proper string operations in BSDs. str.split
and str.is* methods can now work correctly with UTF-8 locales.
+- unicode.iswide() and unicode.width() is dropped and the East Asian
+ Width support is moved to unicodedata extension module.
+
Extension modules
-----------------