<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Dear vtk developers,<br>
<br>
I have a number of modules that I would like to (and have been asked
to) contribute in the near
to mid-term future but I do not wish to reformat my code to fit the vtk
coding style. If (for example) vtkNetCDFReader is contributed to
vtk/paraview, I will most likely be doing the majority of maintenance
and fixing work on the class(es). I do not like the vtk coding style as
I find it hard to quickly mentally parse (bracket indentation in
particular) and I would like to reserve the right to use my own coding
style on the contributed class(es). I can digest and debug my own code
considerably faster because I am familiar with the way it is structured
and laid out.<br>
<br>
I would like therefore to propose that the vtk coding style (as
described here <a class="moz-txt-link-freetext"
href="http://www.vtk.org/Wiki/VTK_Coding_Standards">http://www.vtk.org/Wiki/VTK_Coding_Standards</a>
) be
modified to include the following (additional text in red - apologies
for non html capable email readers)<br>
<ul>
<li> The indentation style can be characterized as the "indented
brace" style. Indentations are two spaces, and the curly brace (scope
delimiter) is placed on the following line and indented along with the
code (i.e., the curly brace lines up with the code). Example: </li>
</ul>
<pre> [example deleted]</pre>
<ul>
<li><font color="#ff0000">Cod</font><font color="#ff0000">e </font><font
color="#ff0000">contributions/modifications should use the accepted
vtk coding style as outlined in this document, with the exception that
contributions which consist of new modules in their entirety are
permitted
to use their
own style - provided the style is consistent throughout the whole
contributed module.<br>
</font></li>
<li><font color="#ff0000">Modifications to existing code must follow
the coding style of the module being changed. If the code being changed
is a contributed module which deviates from the accepted vtk style then
the changes should attempt to follow the contributed style.<br>
</font></li>
</ul>
To summarize my changes in a nutshell :<br>
Any fixes/modifications/additions to existing code must follow the
coding style of the module being modified : In the vast majority of
cases
this means that the standard vtk coding style must be used. All
existing classes must continue to use the vtk coding style. But I (for
one) would
like to be able to contribute new code in my own style and anyone
modifying
the code I have contributed should follow the style I have used in the
module as best they can.<br>
<br>
If this proposal is accepted, then I will be happy and will (hopefully)
never
need to raise the issue of coding style again. I have asked in the past
to change the style, but met with opposition, I believe the wording of
my proposition above is flexible enough to satisfy myself and others
without opening the doors to complete corruption of the existing
code-base. Please feel free to propose further changes to my text, but
do not dismiss out of hand my proposition as I believe that the
majority of vtk developers are capable of coping with different styles
providing they are consistent. In general very few vtk users (or indeed
developers) study the source
code in great depth for modules other that those that they are making
use of heavily, (and have problems with). I find it acutely
painful to reformat code that may be thousands of lines long into a
style that I don't like, for nobody's benefit.<br>
<br>
NB : One possible addition to my proposal might be that modules
deviating from the standard vtk style should contain a disclaimer<br>
"This class uses a different coding style to the vtk standard, please
pay careful attention to code layout when debugging"<br>
<br>
yours<br>
<br>
JB<br>
<pre class="moz-signature" cols="72">--
John Biddiscombe, <a
class="moz-txt-link-freetext" href="email:biddisco">email:biddisco</a> @ cscs.ch
<a class="moz-txt-link-freetext"
href="http://www.cscs.ch/about/BJohn.php">http://www.cscs.ch/about/BJohn.php</a>
CSCS, Swiss National Supercomputing Centre | Tel: +41 (91) 610.82.07
Via Cantonale, 6928 Manno, Switzerland | Fax: +41 (91) 610.82.82
</pre>
</body>
</html>