Summary: | Wordwrap doesn't respect white space | ||
---|---|---|---|
Product: | [Applications] kate | Reporter: | alan |
Component: | part | Assignee: | KWrite Developers <kwrite-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Attachments: | patch to fix bug |
Description
alan
2003-03-03 21:26:54 UTC
Yes, whitespace is removed from the end of lines if you have the "remove trailing spaces" option. You might be able to get your intended behaviour by de-selecting this option. Unfortunately I don't know how the fixed-wrapping code works so I can't help here. Created attachment 1118 [details]
patch to fix bug
This is the first patch I have ever made - so I hope I have done it right.
Its for kdelibs/kate/part/katedocument.cpp
I had some problem deciding when to add white space in and when not. There
doesn't seem to be a definitive answer. In the end I decided it should only be
done when the line is capable of being broken into words and not otherwise.
could you try to test it with my last changes in CVS HEAD (in kdelibs/kate/part) without your patch ? I have changed the "remove trailing spaces" option to only remove the spaces on save (and only in the file, won't change the content of your document until you close and reopen it). Subject: Re: Wordwrap doesn't respect white space On Thursday 06 Mar 2003 10:26 pm, you wrote: > ------- You are receiving this mail because: ------- > You reported the bug, or are watching the reporter. > > http://bugs.kde.org/show_bug.cgi?id=55484 > > > > > ------- Additional Comments From crossfire@babylon2k.de 2003-03-06 23:26 > ------- could you try to test it with my last changes in CVS HEAD (in > kdelibs/kate/part) without your patch ? I have changed the "remove trailing > spaces" option to only remove the spaces on save (and only in the file, > won't change the content of your document until you close and reopen it). It works except of course if you save the file and then open it again. At that point, when you enter some text in the middle of a line and it wraps the white space is then lost. My patch gets over that problem. Just wanted to ask if anything is going to happen to this patch. I don't have access to cvs so if it is going to be put in then it has to be by someone else. I know the other approach (of leaving spaces on the end of lines until save) helps, but as my last message points out this doesn't solve the whole problem Subject: Re: Reminder to check on patch status This bug is still present in 3.1.1a as well as KDE 3.2 CVS (As of May 01) Just a reminder. Since this bug really should _not_ be in an editor. sorry, sorry ;) missed to apply the patch, fixed in CVS HEAD will be fixed for 3.2, together with many other bugs, sorry for delay, if somebody with a working 3_1 branch in kwrite-devel reads this, please backport Please reopen: the fix is improper since it creates another bug when the setting is not to strip whitespace. To reproduce: type several lines of words, don't press Enter, rely on wordwrap. A single extra space will be appended to the text you typed. The bug is still alive in KDE 3.1.3 right :/ perhaps fix in cvs head now, could you test it ? not sure if it does the intended stuff btw., if my fix works, if somebody has time to backport it, here are the commits: M +6 -15 katedocument.cpp 1.558 M +12 -5 katedocument.cpp 1.559 works here ;) The bug is still alive in KDE 3.1.4 |