Bug 298496 - undesired wrapping in comments with static word wrap and search/replace
Summary: undesired wrapping in comments with static word wrap and search/replace
Alias: None
Product: kate
Classification: Applications
Component: part (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: KWrite Developers
Depends on:
Reported: 2012-04-20 16:25 UTC by Jonas
Modified: 2012-11-01 14:23 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Note You need to log in before you can comment on or make changes to this bug.
Description Jonas 2012-04-20 16:25:50 UTC
I'm using kile with static word wrap.

If I make a search/replace over a file it is possible that lines in a commented paragraph suddenly get wrapped, 
- either because the paragraph was not wrapped properly before (possible since commenting results in two extra characters in each line, and commenting doesn't wrap)
- or because I replace a shorter string with a longer one.

Since the wrapping of commented lines does not automatically comment the overflowing parts, it is possible that I end up with isolated uncommented words in a commented paragraph.

This is especially problematic since one normally doesn't even notice that anything went wrong before re-reading the document and finding random words occuring.

One possibility to resolve that might be to fix the word wrapping code in connection with comments, but there doesn't see to be a consensus on the right way to do it (see bug 105373).

Therefore I propose to deactivate all static wrapping during search/replace.

Reproducible: Always
Comment 1 Christoph Cullmann 2012-11-01 14:23:45 UTC
Sorry, but that makes this even more confusing then.
The whole "static word wrap" system is a horrible bad idea.
Now at least it is consistent, that all editing actions will trigger it.
Actually sometime this whole static word wrap should be deleted and moved to a script which allows you to fast wrap the last paragraph or so.