Split a string at a natural break
<p>While rendering a title (using reportlab), I would like to split it between two lines if it is longer than 45 characters.  So far I have this:</p>

<pre><code>if len(Title) &lt; 45:
    drawString(200, 695, Title)
else:
    drawString(200, 705, Title[:45])
    drawString(200, 685, Title[45:])
</code></pre>

<p>The problem with this is that I only want to split the title at a natural break, such as where a space occurs.  How do I go about accomplishing this?</p>
