On Sun, Oct 28, 2012 at 01:46:05PM +0100, Stephan Witt wrote: > >> Can you point me to the rules for coding style please? > > > > I only know of the old files in development/coding. > > The best match I found is: > > - Adapt the formatting of your code to the one used in the > other parts of LyX. In case there is different formatting for > the same construct, use the one used more often. > > So this implies one should care for *own* code, IMHO.
The vague formulation of "In case there is different formatting for the same construct, use the one used more often." was a result of LyX not having a lot of written, but quite a few unwritten rules, and the "majority vote" pretty much gives the same result as having all rules explicit. It was meant as a general permission, or even encouragement, to strive for a uniform code base, especially, but not restricted to cases where there are witten rules that are followed, and if the reformatting (as was e.g. done by Lars here) is separated from functional changes. It is really easier to apply mechanical refactoring on top of a uniform code base and to spot deviation from existing known -to-work-well patterns easier this way. Andre'