[Insight-developers] Anyone got Emacs config for ITK-standard
indentation?
Miller, James V (Research)
millerjv@crd.ge.com
Wed, 30 Apr 2003 12:19:12 -0400
Attached is what I use. I haven't updated it for all the ITK indentation
styles (namespaces etc.) but it does the "if" and "for" blocks correctly
> -----Original Message-----
> From: Kent Williams [mailto:kent@mail.psychiatry.uiowa.edu]
> Sent: Wednesday, April 30, 2003 10:10 AM
> To: Insight Developers List
> Subject: [Insight-developers] Anyone got Emacs config for ITK-standard
> indentation?
>
>
> So my latest checkins were criticized for indentation style;
> sorry! My
> problem is that I either have to turn off auto-indent in
> Emacs, or trick it
> into enforcing the ITK coding standards -- in particular,
> Emacs wants to do
> this:
>
> if ( this )
> {
> Do That;
> }
>
> And ITK wants:
>
> if ( this )
> {
> Do That;
> }
>
> I also gather from Bill's reformatting that there's no indent
> inside a
> namespace. Emacs doesn't want to do that either.
>
> I know that C++-mode in Emacs is configurable, and I'm
> willing to slog into it
> and figure it out, but if someone else has already done this,
> please share!
> Thanks!
>
> _______________________________________________
> Insight-developers mailing list
> Insight-developers@public.kitware.com
> http://public.kitware.com/mailman/listinfo/insight-developers
>
begin 600 init.el
M.SL*.SL@37D@<&%T:`H[.R`**'-E='$@;&]A9"UP871H("AC;VYS("AE>'!A
M;F0M9FEL92UN86UE(")^+V5M86-S(BD@"@D)("`@("`@*&-O;G,@*&5X<&%N
M9"UF:6QE+6YA;64@(GXO96UA8W,O:6QI<W`B*0H)"2`@("`@("AC;VYS("AE
M>'!A;F0M9FEL92UN86UE(")^+V5M86-S+VUO9&5S(BD*("`@("`@("`@("`@
M("`@("`@("`@(&QO860M<&%T:"DI*2D*"BAD969M86-R;R!P=7-H+6YE=R`H
M;V)J96-T('9A<BD*("`B4'5S:&5S($]"2D5#5"!O;G1O(%9!4B!I9B!I="!I
M<R!N;W0@=&AE<F4@86QR96%D>2X@(%5S97,@97$@=&\@=&5S="X*4F5T=7)N
M<R!N97<@=F%L=65S(&]F(%9!4BXB"B`@.SL@5&AE(&)A8V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"`B>R(@,2D@
M*&-U<G)E;G0M8V]L=6UN*2D@,"D*("`@("`@("!C+6)A<VEC+6]F9G-E=`H@
M("`@("`[.R!O=&AE<G=I<V4@9&]N="!I;F1E;G0*("`@("`@,"DI*0H*"BAA
M9&0M:&]O:R`G8RUM;V1E+6-O;6UO;BUH;V]K(`H@("`@("`@("`@)RAL86UB
M9&$@*"D@"B`@("`@("`@("`@("`@(#L[(&UY('=A>0H@("`@("`@("`@("`@
M("`[.RAP=7-H+6YE=R`G*'-U8G-T871E;65N="UO<&5N("X@,"D@8RUO9F9S
M971S+6%L:7-T*0H@("`@("`@("`@("`@("`[.RAP=7-H+6YE=R`G*&1E9G5N
M+6)L;V-K+6EN=')O("X@*RLI(&,M;V9F<V5T<RUA;&ES="D*("`@("`@("`@
M("`@("`@.SL@2V5N)W,@=V%Y"B`@("`@("`@("`@("`@("AC+7-E="UO9F9S
M970@)W-T871E;65N="UB;&]C:RUI;G1R;R`G:V5N<RUC+7-T871E;65N="UB
M;&]C:RUI;G1R;RD*("`@("`@("`@("`@("`@*'-E='$@9G5M92UD:7-P;&%Y
M+6EN+6UO9&5L:6YE+7`@;FEL*0H)("`@("`@(#L[(&9I>"!T86)S('1O('-P
M86-E<PH@("`@("`@("`@("`@("`H<V5T+61E9F%U;'0@)VEN9&5N="UT86)S
M+6UO9&4@;FEL*0H*("`@("`@("`@("`@("`@.SL@<WEN=&%X(&-O;&]R:6YG
M"B`@("`@("`@("`@("`@("AT=7)N+6]N+69O;G0M;&]C:RD*("`@("`@("`@
M("`I*0HH861D+6AO;VL@)V,K*RUM;V1E+6AO;VL@"B`@("`@("`@("`G*&QA
M;6)D82`H*2`*("`@("`@("`@("`@("`@*'!U<V@M;F5W("<H86-C97-S+6QA
M8F5L("X@+RD@8RUO9F9S971S+6%L:7-T*0H@("`@("`@("`@("`@("`H<V5T
M<2!C*RLM8V]M<&QE=&4M8VQA<W,M<')O=&]T>7!E('0I"B`@("`@("`@("`@
M("`@("`@("`@("`*("`@("`@("`@("`@("`@.SL@;F]W(&9I>"!I="!S;R!<
M0RUM(&EN9&5N=',*("`@("`@("`@("`@("`@*&1E9FEN92UK97D@8RLK+6UO
M9&4M;6%P(")<0RUM(B`*("`@("`@("`@("`@("`@("`G<F5I;F1E;G0M=&AE
M;BUN97=L:6YE+6%N9"UI;F1E;G0I"@D@("`@("`@.SL@9FEX('1A8G,@=&\@
M<W!A8V5S"B`@("`@("`@("`@("`@("AS970M9&5F875L="`G:6YD96YT+71A
M8G,M;6]D92!N:6PI"B`@("`@("`@("`@*2D**&%D9"UH;V]K("=J879A+6UO
M9&4M:&]O:R`*("`@("`@("`@("<H;&%M8F1A("@I(`H@("`@("`@("`@("`@
M("`H<'5S:"UN97<@)RAA8V-E<W,M;&%B96P@+B`O*2!C+6]F9G-E=',M86QI
M<W0I"B`@("`@("`@("`@("`@("AS971Q(&,K*RUC;VUP;&5T92UC;&%S<RUP
M<F]T;W1Y<&4@;FEL*0H@("`@("`@("`@("`@("`@("`@("`@"B`@("`@("`@
M("`@("`@(#L[(&YO=R!F:7@@:70@<V\@7$,M;2!I;F1E;G1S"B`@("`@("`@
M("`@("`@("AD969I;F4M:V5Y(&,K*RUM;V1E+6UA<"`B7$,M;2(@"B`@("`@
M("`@("`@("`@("`@)W)E:6YD96YT+71H96XM;F5W;&EN92UA;F0M:6YD96YT
M*0H)("`@("`@(#L[(&9I>"!T86)S('1O('-P86-E<PH@("`@("`@("`@("`@
M("`H<V5T+61E9F%U;'0@)VEN9&5N="UT86)S+6UO9&4@;FEL*0H@("`@("`@
M("`@("DI"@HH861D+6AO;VL@)W1C;"UM;V1E+6AO;VL@"B`@("`@("`@("`G
M*&QA;6)D82`H*2`*"2`@("`@("`[.R!F:7@@=&%B<R!T;R!S<&%C97,*("`@
M("`@("`@("`@("`@*'-E="UD969A=6QT("=I;F1E;G0M=&%B<RUM;V1E(&YI
M;"D*"B`@("`@("`@("`@("`@(#L[('-Y;G1A>"!C;VQO<FEN9PH@("`@("`@
M("`@("`@("`H='5R;BUO;BUF;VYT+6QO8VLI"B`@("`@("`@("`@*2D*"BAA
M9&0M:&]O:R`G<'ET:&]N+6UO9&4M:&]O:R`*("`@("`@("`@("<H;&%M8F1A
M("@I(`H)("`@("`@(#L[(&9I>"!T86)S('1O('-P86-E<PH@("`@("`@("`@
M("`@("`H<V5T+61E9F%U;'0@)VEN9&5N="UT86)S+6UO9&4@;FEL*0H*("`@
M("`@("`@("`@("`@.SL@<WEN=&%X(&-O;&]R:6YG"B`@("`@("`@("`@("`@
M("AT=7)N+6]N+69O;G0M;&]C:RD*("`@("`@("`@("`I*0H["CL@<V5T('5P
M('-O;64@=F%R:6%B;&5S('-O(&5D:69F('=I;&P@=V]R:R!P<F]P97)L>0HH
M8V]N9"`H<G5N;FEN9RUX96UA8W,*("`@("`@("AS971Q(&5D:69F+71E;7`M
M9FEL92UP<F5F:7@@(B(I"B`@("`@("`H<V5T<2!E9&EF9BUD:69F+7!R;V=R
M86T@(F,Z+V-Y9W=I;B]B:6XO9&EF9BYE>&4B*0H@("`@("`@*'-E='$@961I
M9F8M9&EF9C,M<')O9W)A;2`B8SHO8WEG=VEN+V)I;B]D:69F,RYE>&4B*0H@
M("`@("`@*'-E='$@961I9F8M<&%T8V@M<')O9W)A;2`B8SHO8WEG=VEN+V)I
M;B]P871C:"YE>&4B*0HI*0H*"CL*.R!#:&%N9V4@<V]M92!I;G1E<FYA;"!F
M;&%G<R!F;W(@<W!E961B87(*.RAS<&5E9&)A<BD*.RAD969I;F4M:V5Y('-P
M965D8F%R+6ME>2UM87`@)V)U='1O;C$@)V1F<F%M92UC;&EC:RD*"CL*.R!3
M970@=&AE(&EN:71I86P@8V]M;6%N9"!F;W(@8V]M<&EL:6YG"CL**'-E='$@
M8V]M<&EL92UC;VUM86YD("<H(D,Z+U!23T=207XQ+TU)0U)/4WXQ+DY%5"]#
M;VUM;VXW+TE$12]D979E;G8N8V]M($E42RYS;&X@+V)U:6QD(%)E;%=I=&A$
M96));F9O("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