[Kde-pim] Re: Kdepim coding style: indentation

John Layt johnlayt at googlemail.com
Tue Mar 1 14:40:47 GMT 2011


On Tuesday 01 March 2011 13:46:44 David Jarvie wrote:
> I'd like to propose that the kdepim coding standard
> http://community.kde.org/KDE_PIM/Development/CodingStyle/Korganizer should
> be amended to allow indentation with either 2 or 4 spaces. To avoid
> confusion when reading code, the two indentations should not, of course,
> be mixed together. The standard should stipulate that the same indentation
> should be used throughout each source file. Alternatives might be that
> each subdirectory, or each function, can have its own indentation.
> 
> For the benefit of those who were not there, this proposal is prompted by
> a show  of hands at the recent kdepim meeting when someone asked people
> which indentation they preferred. Most people preferred 4 spaces rather
> than the current 2.
> 
> Comments?

I'd like the policy to be "For all new files use the kdelibs/Qt coding 
standard" (i.e. 4 spaces), with existing files remaining with the current 
style unless the maintainer chooses to re-indent (all all that implies for 
merge and blame).  This will ensure we move towards consistency with 
kdelibs/kdebase over time.

http://techbase.kde.org/Policies/Kdelibs_Coding_Style

Judicious use of kate/vim/emacs settings/templates should ensure hitting a tab 
key equals the correct number of spaces in each file/directory.

John.
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list