kdelibs coding style

David Faure faure at kde.org
Fri Jul 21 21:57:39 BST 2006


On Thursday 20 July 2006 21:46, Ingo Klöcker wrote:
> On Thursday 20 July 2006 21:23, Charles Samuels wrote:
> > Aaron J. Seigo wrote, on Thursday 2006 July 20 12:20 pm:
> > > please no adjustments. otherwise we'll discuss this till the cows
> > > come home as people try and adjust this or that citing past changes
> > > as precedent. =)
> >
> > I'm demanding that adjustment. And many others will agree with me.
> > Sorry.
> 
> Just for the record, I disagree with you, Charles. And if you look at 
> the KDE PIM coding style you'll see that most of the KDE PIM developers 
> (with the notable exception of David obviously) disagree with you as 
> well.

Actually I'm often using "braces on the same line" since then. Working on multiple
projects with Marc Mutz (in kdab) changed me for ever :)

Anyway I'm for "adopting the qt style without change, otherwise we'll never agree",
and for using .emacs-dirvars where a different coding style is expected
(kdepimlibs, phonon, whereever - I'd even be fine with kdeprint keeping its tabs,
I added a .emacs-dirvars for it). I just want to open files and edit code,
not to change my editor settings all the time, that's the main goal here.

Also, I'm against refusing patches that don't use the correct style. No need to be picky.
To me this isn't about making rules, it's merely about knowing what to use
as indentation when editing code. If some patches go in with spaces inside
parenthesis (that's a change I'll have to do to my own coding style, all my
kde code has spaces), we'll survive (interestingly the qt style doesn't say anything
about spaces inside parenthesis, so technically it's not forbidden, it's just not what
the examples use :). 
Let's be pragmatic, spaces inside lines don't really prevent editing this
code later on, unlike a completely messed up indentation (hello kssl).

Allen: green light from me for kdelibs/.emacs-dirvars.

-- 
David Faure, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).






More information about the kde-core-devel mailing list