The KWin Coding Style Situation

Christoph Feck christoph at maxiom.de
Sun Nov 28 21:47:41 CET 2010


On Sunday 28 November 2010 20:20:33 Martin Gräßlin wrote:
> From various discussion on IRC and looking through review requests, it
> seems that we have a general problem with our coding style.

For kdelibs, we have a policy that only _new_ code needs to follow the style 
guidelines. Existing code is not reformatted. I would prefer switching to 
kdelibs style in kwin, but only for new code (i.e. new files or new 
functions).

While this inevitably leads to inconsistency, it has repository technical 
advantages (history, blame, bisect, licensing etc.) which we see as a 
requirement for kdelibs code. Small fixes _usually_ are done in the style of 
the surrounding code to keep at least some consistency.

Currently "external" contributions are mostly new effects, and don't usually 
touch kwin core code. Any new file you are currently working on (ES support 
etc.) should be new kdelibs style, because that is where future contributions 
and fixes will land.

Other than that, I agree that the current style is annoying and you should not 
force contributors to use it.

Christoph Feck (kdepepo)


More information about the Plasma-devel mailing list