Re: Tabs vs. Spaces
From: Karl Heinz Buchegger (kbuchegg_at_gascad.at)
Date: 05/25/04
- Next message: Chris \( Val \): "Re: How to use find on vector holding a <pair>"
- Previous message: James Dennett: "Re: std::vector pointer"
- In reply to: The Mike: "Re: Tabs vs. Spaces"
- Next in thread: Ben Measures: "Re: Tabs vs. Spaces"
- Reply: Ben Measures: "Re: Tabs vs. Spaces"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 25 May 2004 09:10:19 +0200
The Mike wrote:
>
[snip]
>
> Each <TAB> is just a character. I can't influence your editor on how
> many spaces it will display for each <TAB>. E.g.: if you're using the
> Vim texteditor then you could say something like ":set tabsize=4".
> Result:
Now do the same with something different:
void test( int j )
{
<tab>if( j == 5 ) {<tab><tab><tab><tab><tab><tab><tab><tab><tab>/* Check if the input is valid */
<tab><tab>printf( "Invlid input\n" );<tab> /* and barf out if not */
<tab><tab>return;
<tab>}
}
With a tabsize of 2 this comes out as
void test( int j )
{
if( j == 5 ) { /* Check if the input is valid */
printf( "Invlid input\n" ); /* and barf out if not */
return;
}
}
with a tabsize of 3 this comes out as:
void test( int j )
{
if( j == 5 ) { /* Check if the input is valid */
printf( "Invlid input\n" ); /* and barf out if not */
return;
}
}
-- Karl Heinz Buchegger kbuchegg@gascad.at
- Next message: Chris \( Val \): "Re: How to use find on vector holding a <pair>"
- Previous message: James Dennett: "Re: std::vector pointer"
- In reply to: The Mike: "Re: Tabs vs. Spaces"
- Next in thread: Ben Measures: "Re: Tabs vs. Spaces"
- Reply: Ben Measures: "Re: Tabs vs. Spaces"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|