From a5e292e489abdeca2730f17c59302206ad564dba Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Fri, 18 Feb 2011 02:48:49 +0000 Subject: [PATCH] 4588: FAQ-gramplet looks very strange when translated to Swedish. svn: r16662 --- src/gui/widgets/grampletpane.py | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/src/gui/widgets/grampletpane.py b/src/gui/widgets/grampletpane.py index 639ca99a1..78f34c37e 100644 --- a/src/gui/widgets/grampletpane.py +++ b/src/gui/widgets/grampletpane.py @@ -400,24 +400,6 @@ class GuiGramplet(object): self.buffer.insert_at_cursor(text) self.text_length += len(text) - def len_text(self, text): - i = 0 - r = 0 - while i < len(text): - if ord(text[i]) > 126: - t = 0 - while i < len(text) and ord(text[i]) > 126: - i += 1 - t += 1 - r += t/2 - elif text[i] == "\\": - r += 1 - i += 2 - else: - r += 1 - i += 1 - return r - def render_text(self, text): markup_pos = {"B": [], "I": [], "U": [], "A": [], "TT": []} retval = "" @@ -451,11 +433,6 @@ class GuiGramplet(object): retval += text[i+1] r += 1 i += 2 - elif ord(text[i]) > 126: - while ord(text[i]) > 126: - retval += text[i] - i += 1 - r += 1 else: retval += text[i] r += 1