#14 Hyphenation problem with dots in names

closed-fixed
nobody
None
5
2009-02-10
2009-02-09
No

Just noticed the following problem in hyphenation of names with dots:

from wordaxe.DCWHyphenator import DCWHyphenator

def hyphenate(s): return DCWHyphenator().hyphenate(s).hyphenations

print hyphenate(u"Python-2-Verzeichnis") # ok
print hyphenate(u"Python.Verzeichnis") # ok
print hyphenate(u"Python-2.0-Verzeichnis") # no hyphenation at all?

Discussion

  • H. von Bargen
    H. von Bargen
    2009-02-10

    The code to detect numbers or dates was wrong. When seeing the "2.0", the code assumed the whole word to be a number or date and returned None.

     
  • H. von Bargen
    H. von Bargen
    2009-02-10

    • status: open --> closed-fixed
     
  • Thank you. The version in trunk is working now as expected.