On Feb 3, 2010, at 9:34 PM, ext Charles N Burns wrote:

>> 
>> 
>> On Wed, Feb 3, 2010 at 2:23 AM, Eike Ziller <eike.zil...@nokia.com> wrote:
>> 
>> On Feb 2, 2010, at 8:58 PM, ext Charles N Burns wrote:
>> 
>> > Thank you for the reply. I will file a report on the few issues which
>> > were not a misunderstanding of my own.
>> >
>> > Regarding #4, whitespace:
>> >
>> >>> 4) The option [Text Editor --> Behavior --> Clean Whitespace] is very
>> >>> useful, but it should not clean the whitespace of the currently active
>> >>> line of text. I often save with CTRL+S, and when I do this, the
>> >>> indentation of my current line (If otherwise blank) is lost. This can
>> >>> be annoying when saving a lot right before adding a new line.
>> >>
>> >> How could it be possible to know if you intend to continue typing or not?
>> >> If you are annoyed by that, perhaps doing it explicitly "Clean 
>> >> Whitespace" instead of the automatic cleaning on save works out for you.
>> >> Either invoke it from the Menu (Edit->Advanced->Clean Whitespace),
>> >> or assign a keyboard shortcut of your liking to it 
>> >> (Tools->Options->Environment->Keyboard, type "Clean Whitespace" as a 
>> >> filter for the list, assign a shortcut), and use that.
>> >
>> > What I had in mind was "Clean whitespace unless it is to the left of
>> > the keyboard cursor."
>> > This way, unnecessary whitespace would be removed, but it would not
>> > require manual re-indentation of the current line of code every time
>> > it's saved.
>> 
>> Yes, but in case you pressed return to create a new line, but don't intend 
>> to continue writing there, not cleaning the whitespace on the line of the 
>> cursor is wrong:
>> Press return (getting indented new line), save, go to a different file. 
>> Later you find out that "Clean Whitespace" didn't do it's job, without any 
>> hint why.
>> (Ever added a new line to make code visually a bit more separated?)
>> 
>> 

> True, though that could be solved by making any action other than typing code 
> into that line (saving, moving the cursor to a different line, even viewing a 
> different file) remove the space.

Unfortunately not:
Add line. Save. Move to a different file - if at this point the whitespace is 
removed, that change is not saved! I don't think "delayed second saving" is 
what we want either. And if the change is not saved, moving away from a file 
would mark it as modified, which would be very weird.

By the way, vim "solves" this issue by having the user explicitly state that 
they stop editing a file, before they can even save it. I don't want to go that 
way either :)

> I think it would be a nice option as a check box under "Clean Whitespace", 
> maybe "Exclude current line" or something. I don't want to encourage 
> featuritis,

But you do ;)

> but I suspect many people save frequently and would find this a nice minor 
> time saver.

I do save frequently, too. I fear that we have to live with the minor 
annoyance, since there seems to be no better solution, really. And for people 
who are too annoyed, there's still the option not to clean whitespace 
automatically, but to do that manually, completely "under your control".

> If you disagree, that's okay too. You and your team obviously know what you 
> are doing in making an IDE, and I'll certainly still use Qt Creator.

Thank you a lot!

Regards,
Eike

-- 
Eike Ziller
Software Engineer
Nokia, Qt Development Frameworks

Nokia gate5 GmbH
Firmensitz: Invalidenstr. 117, 10115 Berlin, Germany
Registergericht: Amtsgericht Charlottenburg, Berlin: HRB 106443 B
Umsatzsteueridentifikationsnummer: DE 812 845 193
Geschäftsführer: Dr. Michael Halbherr, Karim Tähtivuori




_______________________________________________
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator

Reply via email to