diff options
| author | Hye-Shik Chang <hyeshik@gmail.com> | 2004-06-04 03:18:12 +0000 |
|---|---|---|
| committer | Hye-Shik Chang <hyeshik@gmail.com> | 2004-06-04 03:18:12 +0000 |
| commit | 8356bca85c468351dbad862e6dafbccafb01967e (patch) | |
| tree | 32a4b1e1c9c0e5761777e7f4a87e232d0b810a26 /Lib/UserString.py | |
| parent | 14e6ff512915b52af02ce7bc0836cb2d4e2ddc9f (diff) | |
| download | cpython-8356bca85c468351dbad862e6dafbccafb01967e.tar.gz | |
Add iswide() and width() method for UserString according as the
addition to unicode objects.
Diffstat (limited to 'Lib/UserString.py')
| -rwxr-xr-x | Lib/UserString.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/UserString.py b/Lib/UserString.py index e8e0fedd87..914f3ce14a 100755 --- a/Lib/UserString.py +++ b/Lib/UserString.py @@ -126,6 +126,10 @@ class UserString: def upper(self): return self.__class__(self.data.upper()) def zfill(self, width): return self.__class__(self.data.zfill(width)) + # the following methods are defined for unicode objects only: + def iswide(self): return self.data.iswide() + def width(self): return self.data.width() + class MutableString(UserString): """mutable string objects |
