[GRASSGUI] Using Python -t ?
Jachym Cepicky
jachym.cepicky at gmail.com
Tue Mar 20 11:12:42 EDT 2007
I do not have clear opinion to this. Till now, I was using 4 letters.
Grass default should be 8. It is truth, that 4 letters sound
reasonable, because you lost only half of the space in the line, which
you wold loose, if the indentation would be set to 8
class MyClass:
def MyFunction():
if 1:
#my condition
while 1:
#my loop
class MyClass:
def MyFunction():
if 1:
#my condition
while 1:
#my loop
We should IMHO set one-line definiton for vim and emacs to each
python file, which would tell them, how the indentation is set.
for vim, this would be
## vim:ts=4:et:sts=4:sw=4:ai:
jachym
2007/3/20, Daniel Calvelo <dca.gis at gmail.com>:
> My vote for 4-space indentation, as this is emacs python-mode default.
>
> Daniel.
>
> On 3/19/07, Glynn Clements <glynn at gclements.plus.com> wrote:
> >
> > As some people seem to have trouble with indentation, I'd like to
> > suggest that the wxgrass script should be changed to use -t, or even
> > -t -t:
> >
> > -t Issue a warning when a source file mixes tabs and spaces for
> > indentation in a way that makes it depend on the worth of a tab
> > expressed in spaces. Issue an error when the option is given
> > twice.
> >
> > Beyond that, we should agree upon a common indentation setting (number
> > of columns, and whether to use tabs or spaces). As Python determines
> > nesting based upon indentation, this isn't just a stylistic issue.
> >
> > --
> > Glynn Clements <glynn at gclements.plus.com>
> >
> > _______________________________________________
> > grassgui mailing list
> > grassgui at grass.itc.it
> > http://grass.itc.it/mailman/listinfo/grassgui
> >
>
>
> --
> -- Daniel Calvelo Aros
>
> _______________________________________________
> grassgui mailing list
> grassgui at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grassgui
>
--
Jachym Cepicky
e-mail: jachym.cepicky gmail com
URL: http://les-ejk.cz
GPG: http://www.les-ejk.cz/pgp/jachym_cepicky-gpg.pub
More information about the grass-gui
mailing list