Article View: gnu.emacs.help
Article #188812trouble with c-mode
From: Andy Davidson
Date: Thu, 11 Jul 1991 22:37
Date: Thu, 11 Jul 1991 22:37
73 lines
1987 bytes
1987 bytes
Hi
I was hoping some one could help me set up my C mode variables.
My boss requires this formate (personaly I do not care)
here is how they are currently set
;; c-mode settings
;; section 21.4.4 page 138 emacs manual
;; did this to hummor scott
(setq c-tab-always-indent nil)
(setq c-auto-newline 1)
(setq c-indent-level 4)
(setq c-continued-statement-offset 4)
(setq c-continued-brace-offset 0)
(setq c-brace-offset 0)
(setq c_brace-imaginary-offset 0)
(setq c-argdecl-indent 0)
(setq c-lablel-offset 0)
here is an exmple of the code it produces
IiDirBinCmp(ix)
int ix;
{
extern struct dirBase *dir;
long tt;
iodirFunc(dirFlag, ix, &testEntry);
if ( (fii) || (foo) )
return(ret);
else
return (ret);
if (ret)
{
this is wrong;
this is wrong;
}
}
The formate of the code I am required to produce is
IiDirBinCmp(ix)
int ix;
{
extern struct dirBase *dir;
long tt;
iodirFunc(dirFlag, ix, &testEntry);
if ( (fii) || (foo) )
return(ret);
else
return (ret);
if (ret)
{
this is correct;
this is correct;
}
}
It seems to me that you can not have c-indent-level equal to 4 sometimes and
zero other times.d
Any ideas would be greatly appricated
thanks in advance andy
--
-----------------------------------------------------------------
"bede-bede-bede Thats all Folks"
Porky Pig
Technical Details
Message-ID:
<1991Jul11.223721.8584@cats.com>Path:
arc1-ca.pugleaf.net!gmdzi!unido!unidui!math.fu-berlin.de!ira.uka.de!sol.ctr.columbia.edu!zaphod.mps.ohio-state.edu!mips!apple!portal!cats.com!andyShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103b8b,cd0de9d4a70fd5af,start X-Google-Attributes: gid103b8b,public X-Google-ArrivalTime: 1991-07-11 23:56:18 PST Path: arc1-ca.pugleaf.net!gmdzi!unido!unidui!math.fu-berlin.de!ira.uka.de!sol.ctr.columbia.edu!zaphod.mps.ohio-state.edu!mips!apple!portal!cats.com!andy From: andy@cats.com (Andy Davidson) Newsgroups: gnu.emacs.help Subject: trouble with c-mode Message-ID: <1991Jul11.223721.8584@cats.com> Date: 11 Jul 91 22:37:21 GMT Organization: CATS Software Inc Lines: 72