[Lazarus] clarification / Re: constant-highlight ? [Re: quick opinion poll / pascal highlighting "case"]
Mattias Gaertner
nc-gaertnma at netcologne.de
Fri May 28 10:09:20 CEST 2010
On Fri, 28 May 2010 09:15:19 +0200
Graeme Geldenhuys <graemeg.lists at gmail.com> wrote:
> On 27 May 2010 21:25, waldo kitty wrote:
> >> if x then begin
> >> code
> >> end else begin
> >> if y then begin
> >> code
> >> end else begin
> >> code
> >> end;
> >> end;
> >>
> >
> > the above format hurts my eyes... i cannot see else, for one thing, and
> > cannot separate out the individual code blocks...
>
>
> This is why I somethings think C (mostly unix projects) or Java have
> some reason behind there madness.
Beware Graeme. Seeing reason behind madness might lead to madness ;)
>[...]
> In the mean time, I have already considered switch all my pascal code
> to using Tab characters. That way each developer can specify what
> indentation width they want, but this is rather difficult to do in
> Lazarus. Why? Because tab width (editor preference) is a global
> option, not per project, so it will affect all other projects too,
> which is not ideal. And standard usage of Tab characters are not
> really as good as Elastic Tabstops.
Tabwidths is more like line endings and encodings. It should be per
file.
> nickgravgaard.com/elastictabstops/
> There is a Java applet you can play with and see how indentation
> works. But read the theory first to understand what it does. It's
> pretty clever!
I agree, it's better than fixed tabs.
> PS:
> I have tried once to implement Elastic Tabstops in Lazarus IDE, but
> SynEdit was just too confusing for me. And this was before Martin's
> major SynEdit refactoring and IFDEF code cleanup. Maybe SynEdit is
> easier to use now - I don't know.
It should be doable.
Mattias
More information about the Lazarus
mailing list