Please help!! Indentation vs. Tabs problem! [message #161485] |
Fri, 06 January 2006 20:02  |
Eclipse User |
|
|
|
Originally posted by: jutes.rogers.com
Hi Eclipse Community,
Eclipse is my favourite IDE on Windows and I am now using Linux at work
and decided to continue using Eclipse.
I am having a terribly hard time trying to set up tabs and indentation in
Eclipse...
Here's what I am *trying* to do:
Each indentation level is 4 spaces. I.e. two indentations equals a single
tab.
In VI this would be accomplished with: ":set tabstop=8 hardtabs=8
shiftwidth=4"
I am trying to get this working in Eclipse and I can't for the life of me
get it to work. I need to display tabs as 8 spaces, but I need some sort
of keyboard shortcut (eg Ctrl-T) to "indent" i.e. add 4 spaces.
Can someone PLEASE help! Thanks so much.
Mike Jutan
|
|
|
|
|
|
Re: Please help!! Indentation vs. Tabs problem! [message #165119 is a reply to message #165059] |
Fri, 03 March 2006 09:57  |
Eclipse User |
|
|
|
Originally posted by: arne.anka.ginguppin.de
i understand. but a) i'm afraid we have to wait until somebody implements
the jdt-auto-formatting for the cdt and b) i don't think your case will
ever be solved -- having two different tab-sizes (and indent imo uses tab
as measure) is not a very common problem, i think.
On Fri, 03 Mar 2006 10:10:57 +0100, James Milne <jamesm@filmlight.ltd.uk>
wrote:
> arne anka wrote:
>> what's wrong with preferences->general->text editors: displayed tab
>> width [] and ctrl+i?
>
> The C++ editor automatically indents when you hit return after a brace,
> ie:
>
> void myFunction(void)
> {
> <autoIndent>int blah;
> }
>
> The problem is that the indent size is not separate from the tab size. I
> want to indent 4 spaces, but for historical purposes in my source code,
> I want it to treat the tab character as 8 spaces.
>
> When I hit the Tab key, I also want the editor to perform an indent and
> insert 4 spaces, rather than insert a tab character which ends up being
> 8 spaces.
>
> --
> Kind regards,
> James Milne
> FilmLight Ltd.
|
|
|
Powered by
FUDForum. Page generated in 0.03120 seconds