[Geany-devel] [Bug] When saving a modified file, a new empty line is added
enrico.troeger at xxxxx
Tue Dec 8 19:46:51 UTC 2009
On Tue, 01 Dec 2009 16:04:08 +0100, Maxime wrote:
>Thanks for your answers.
>I totally agree that a popup dialog for that would be ugly and
>annoying. However, I think that this issue is quite important, since
>enabling that feature by default can be strongly distrurbing for PHP
>After some thinking, I would suggest that :
> - the feature "*new line at end of file*" would be a drop-down list
>instead of a checkbox, with options "*according to file type*"
>(default), "*always*", "*never*"
> - when option "*according to file type*" is selected :
> - when (for example) a C/C++ file is saved, a new empty line is
>automatically added if necessary
>saved, no new empty line is added
> - details about file types requiring a "final empty line" or not,
>would be available in the manual.
>This way, Geany's default behavior would be convenient for all
>programming languages (but user can "force" the behavior to whatever
>he prefers), and the user wouldn't be annoyed by any warning message.
IMO this is too complicated.
Also having a hardcoded list of filetypes which use and don't use empty
new lines at end of file, isn't much better than the current status.I
still don't see what's the problem with simply deactiviting the feature
if it causes troubles for you.
A better implementation of your suggested solution would be to read the
setting from the filetype definition files so the user can really set
it for those filetypes he/she wants and is not limited to a hardcoded
list. If anyone finds this important enough, go ahead and write a patch.
Get my GPG key from http://www.uvena.de/pub.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 198 bytes
Desc: not available
More information about the Devel