[Gllug] vi indenting

Paul Brazier pbrazier at cosmos-uk.co.uk
Wed Dec 19 17:14:22 UTC 2001


> With tables & 1-pixel clear .gifs, you specify exactly how a HTML page
> should look and anyone using Internet Explorer will see it as you
> intended!

OK, suppose I want to put this table in a text file:

a               1       3
longer          2

if I have tabs=8 I could do
a<tab><tab>1<tab>3
longer<tab><tab>2

which might come out like:

a               1       3
longer          2

but for someone with tabs=4 it might look like this:

a       1   3
longer      2

Which totally changes the meaning. Another thing is you can't get right
justified tabstops so numbers won't line up OK. So tabs as used in text
files are totally limited in terms of what a "proper" tab should be so
that they are only really useful for very basic left-hand line indents
which really is just a convenience to avoid pressing space loads of
times.

You could for example have a text editor designed so that if you pressed
space at the beginning of the line it actually did 8 spaces. Then if you
pressed backspace-delete and the only characters to the left were spaces
it would delete 8 spaces. This would have exactly the functionality of
the tab key (for this limited use only - i.e. enforcing strict
indentation amounts) and could be used for programming C etc. You could
turn off this mode for general text editing or set it to different
values for different parts of the same document. Tabs aren't really
useful for general alignment because of their limitations as above.

I think on balance we'd be better off without the tab though I do use it
really just to get round problems which could be solved other ways if
the incentive was there.

HTML has tables that get round the tab problem anyway so it is easy to
encode the intended meaning of the table above so I don't think with
text&tabs it is just a presentation (i.e. not content) problem.


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the originator.

This footnote also confirms that this email message has been checked
for the presence of computer viruses.

**********************************************************************


-- 
Gllug mailing list  -  Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug




More information about the GLLUG mailing list