in reply to Truncating Last Sentence

Are you sure you want to do this?

It seems like you should really handle sentances that end with other punctuation, or quoted sentances, etc. But the problem becomes rapidly more complicated when you try.

A simpler option is just to append ... to the truncated string, or at most to always cut off the last word in case its partial. People know whats going on when they see a truncated sentance and ..., whereas if you silently cut off something you may change the meaning without giving any clue that you've done so.

qq

Replies are listed 'Best First'.
Re: Re: Truncating Last Sentence
by dimar (Curate) on May 17, 2004 at 18:52 UTC

    The use of 'dot dot dot' (aka elipsis?) is also a common convention used in many contexts, so this is a good suggestion. You should consider to use this whenever you truncate text in order to fit it in a confined area.