Bug 308613 - kile removes trailing space when it saves automatically for live preview
Summary: kile removes trailing space when it saves automatically for live preview
Status: RESOLVED FIXED
Alias: None
Product: kile
Classification: Applications
Component: editor (other bugs)
Version First Reported In: trunk-kde4
Platform: Chakra Linux
: NOR minor
Target Milestone: ---
Assignee: Michel Ludwig
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-18 17:18 UTC by Tim Ruffing
Modified: 2016-12-31 12:06 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Ruffing 2012-10-18 17:18:50 UTC
When live preview is enabled ("whenever there are changes"), kile automatically saves the opened file in order to compile it. If you have configured the editor component to remove trailing space when saving, the saving is very annoying: Suppose you are typing and stop shortly to think about which word to type next. At that moment, kile saves the document and the space you have just typed is removed again.

Reproducible: Always

Steps to Reproduce:
1. Enable live preview (based on changes) and configure editor to remove trailing space before saving.  
2. Type "word " and wait a moment.
Actual Results:  
The space is removed.

Expected Results:  
Actually, I don't know what a good behavior should look like... To only remove space when saving is triggered manually would turn the feature almost useless for users that have enabled live preview, because the automatic saving is usually faster than the user.
Comment 1 Michel Ludwig 2012-11-28 20:42:13 UTC
This is fixed in the latest KatePart (KDE 4.10 probably), see

http://quickgit.kde.org/?p=kate.git&a=commit&h=cebe2e4c47655d4fdef27ad4a306b89dfbdf3302

and Bug 310712:

https://bugs.kde.org/show_bug.cgi?id=310712
Comment 2 Frank Fischer 2016-12-31 12:06:13 UTC
Today I realized that this problem reappeared: Kile consistently removes the space I've just (half a second ago) typed left to the cursor when saving the document due to live-previews. This is really annoying (for me) and I had to disable the removal of trailing whitespaces.

I'm not sure if this is the right place for the bug-report, though. Certainly it's part of the behaviour of katepart, but it is also an unfortunate interaction of kate's whitespace-removal-feature and the automatic saving of kile due to live-preview. The comments in the bug report of katepart do not seem to discuss the case of automatic saving (only frequent pressing of Ctrl-S).