~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/help_topics/__init__.py

  • Committer: Martin Pool
  • Date: 2009-06-10 02:22:58 UTC
  • mto: This revision was merged to the branch mainline in revision 4464.
  • Revision ID: mbp@sourcefrog.net-20090610022258-czra1150uv22976i
textwrap break_on_hyphens option is not available in python2.5

Show diffs side-by-side

added added

removed removed

Lines of Context:
208
208
 
209
209
    def add_string(proto, help, maxl, prefix_width=20):
210
210
       help_lines = textwrap.wrap(help, maxl - prefix_width,
211
 
            break_long_words=False,
212
 
            break_on_hyphens=False)
 
211
            break_long_words=False)
213
212
       line_with_indent = '\n' + ' ' * prefix_width
214
213
       help_text = line_with_indent.join(help_lines)
215
214
       return "%-20s%s\n" % (proto, help_text)