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

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

Re: how to set c-set-style at startup?


From: Andreas Röhler
Subject: Re: how to set c-set-style at startup?
Date: Wed, 20 Jul 2011 07:30:54 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; de; rv:1.9.2.18) Gecko/20110616 SUSE/3.1.11 Thunderbird/3.1.11

Am 20.07.2011 04:34, schrieb Jai Dayal:
I tried this, but it doesn't seem to be working.  For example, I change the
style to the style I have in the code below, and the indentation will be
different.  I can also put in garbage instead of "linux" and no errors
occur.

Maybe I'm missing something?

On Mon, Jul 18, 2011 at 11:03 PM, Peter Münster<pmlists@free.fr>  wrote:

On Tue, Jul 19 2011, Jai Dayal wrote:

   It seems right now, I have to do c-set-style for each file/buffer I
open.
Is there a way I can set this in my .emacs file so that all files will
have
the same c style indentation?

Without customize:

--8<---------------cut here---------------start------------->8---
(add-hook 'c-mode-hook
          '(lambda ()
             (c-set-style "linux")
             ... ; other settings
             ))
--8<---------------cut here---------------end--------------->8---

--
            Peter





Emacs' c-modes have it's own lists.

Please consider a post onto bug-cc-mode@gnu.org

cheers,

Andreas



reply via email to

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