help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Need Help: insert tab(8 characters) for every tabstroke


From: amit mehta
Subject: Re: Need Help: insert tab(8 characters) for every tabstroke
Date: Tue, 9 Aug 2011 10:26:08 +0530

On Tue, Aug 9, 2011 at 3:11 AM, Jai Dayal <dayalsoap@gmail.com> wrote:
> Try fiddling with c-set-style
>
> http://www.phys.ufl.edu/docs/emacs/emacs_254.html
>
> Here's a list of built in c-styles
>
> http://www.delorie.com/gnu/docs/emacs/cc-mode_24.html
>
> On Mon, Aug 8, 2011 at 8:05 AM, amit mehta <gmate.amit@gmail.com> wrote:
>>
>> I'm a complete n00b and hence please don't shower your wrath upon me.
>> I'm finding it little difficult to use TABS in my 'C' programs. I've been
>> a vim
>> user till last week and have slowly started to migrate towards mighty
>> emacs.
>> In vim, I usually indent my code with tabs, where each tab stroke replaces
>> the
>> cursor by 8 columns, but in an emacs buffer, a tab stroke doesn't work
>> this
>> way by default. I did some text search and based on that, have added the
>> following line under $HOME/.emacs:
>>
>> (setq indent-tabs-mode t)
>>
>> but this doesn't work(i mean, hitting the TAB key on my keyboard doesn't
>> move forward the cursor to 8 columns to the right), so every time i need a
>> TAB,
>> I've to use C-q <tab>. this is overkill.
>>
>> Then I tried putting just this entry in $HOME/.emacs, but this too doesn't
>> work
>> (setq default-tab-width 8);
>>
>>
>> Please help.
>>
>> -amit
>>
>
>
Thank you very much. This one very much solved my issue:
http://www.delorie.com/gnu/docs/emacs/cc-mode_39.html

-amit



reply via email to

[Prev in Thread] Current Thread [Next in Thread]