Line breaks not working for Doc class

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
Greg Gillet

Line breaks not working for Doc class

Post by Greg Gillet »

Hi

I'm trying something which should be really simple, but it's not working.

I want to limit lines of text to a maximum of 60 characters (because the text will be sent in an email and I want to cater for the simplest email clients).

I've set up a new document class. I've checked "Word wrap long lines" and selected "Save with hard breaks". I've also checked "Word break at column number:" and entered "60" in this field.

This appears to work OK for MOST lines - i.e TextPad inserts a hard line break when I save the file with the appropriate extension - but NOT all! I've got lines of anything up to 68 characters. What's more, some of the lines DON'T end in a line break.

Any ideas gratefully received

Greg
Glg11
Posts: 5
Joined: Mon Jan 05, 2004 1:01 pm

Re: Line breaks not working

Post by Glg11 »

Greg Gillet wrote:This appears to work OK for MOST lines - i.e TextPad inserts a hard line break when I save the file with the appropriate extension - but NOT all! I've got lines of anything up to 68 characters. What's more, some of the lines DON'T end in a line break.
This line wrapping is a problem for me too! :-(

In the current version it works only for non-space characters. If you enter some spaces near at the last column (see "Word break at column number"), all following spaces will be in the same line (and sometimes the cursor is scrolling out of the visible window). Only the next entered non-space character will jump into the next line.

I prefer a "word wrapping" for spaces too. Could be an additional configuration option in textpad. :idea:

Regards
Heiko J.
pepper
Posts: 1
Joined: Fri Dec 10, 2004 8:29 pm

This must be a bug

Post by pepper »

At the very least, it's a feature that's not implemented in a way that's useful to me and my colleagues.

Here is the behavior I want when I hit Ctrl-Shift-J to wrap individual lines at a certain column number: when I set Word Break at Column Number to 66, I want NO CHARACTERS past column 66.

That's how my previously installed version worked, but now I am getting lines of 67, 68, and occasionally more. What happened, and how can I fix this? It's kinda driving me crazy having to go back through and manually fix these line breaks. :?

Thanks in advance for any assistance. I'm willing to do crazy workarounds to a point.
charles
Posts: 20
Joined: Mon Dec 27, 2004 5:11 pm
Contact:

Wrap hard

Post by charles »

The easiest would be to write a script hat does it.
It would be easier to do it in TextPad, but the behavior seems random.
Divide the text in substrings, and find the closest backwards match whitespace (unless you're ok with words cut in the middle)
Post Reply