[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: auto-indent in emacs
From: |
Lennart Borgman |
Subject: |
Re: auto-indent in emacs |
Date: |
Mon, 30 Nov 2009 16:58:35 +0100 |
On Mon, Nov 30, 2009 at 4:26 PM, harven <address@hidden> wrote:
> Kenneth Brun Nielsen <address@hidden> writes:
>
>> I want to auto-indent a section (actually a whole file) in Emacs.
>>
>> I googled, that the shortcut C-M-\ ("CTRL+ALT+backspace") does the
>> job, but since I have a danish keyboard, where "backspace" requires me
>> to push the META-button "Alt Gr", it seems I'm not able to push this
>> combination.
>>
>> Any suggestions for another way to auto-indent?
>>
>> Best regards,
>> Kenneth
>
> C-M-\ runs the command indent-region (check it by typing C-h k C-M-\).
> So bind that command to another shortcut. For example, to bind it to C-c i
> put the following line in your .emacs
>
> (global-set-key (kbd "C-c i") 'indent-region)
Please see also the page http://www.emacswiki.org/emacs/AltGrKey for
how to type C-M-\.
Emacs Devel: Could we please get this information into the manual? I
think it fits under (info "(emacs) Windows Keyboard") where AltGr is
mentioned.
- Re: auto-indent in emacs,
Lennart Borgman <=