CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   XEmacs autoindentation (http://www.cfd-online.com/Forums/openfoam/61008-xemacs-autoindentation.html)

gschaider December 29, 2005 13:01

Hi! I use XEmacs to edit my
 
Hi!

I use XEmacs to edit my source-codes. My "problem" is that the indentation-convention (Nr of spaces to indent for a new block etc) of the C++-mode is not the same as that used in the OpenFoam-sources. Therefor editing a OF-Source-file means either not using the Emacs-indentation or "messing" it up.

Of course (it is Emacs we're talking about) these conventions can be customized by setting a bunch of variables.

My question is the following: has anyone already done this and could she pass me these settings.

thanks for listening

PS: Hope I don't start a religious discussion ("Vi versus Emacs" or "XEmacs is not Emacs) here

hjasak December 29, 2005 13:39

Sure. Please send me an E-mai
 
Sure. Please send me an E-mail and I'll pass you the relevant sections of the .xemacs file. It is not perfect, but it's pretty good.

Hrv

gschaider December 29, 2005 15:25

For those interested: The cust
 
For those interested: The customizations provided by Hrv can now be found at

http://openfoamwiki.net/index.php/HowTo_xemacsInd entation

(the code is Hrv's, the errors are mine)

francois January 27, 2006 10:25

Cool ! I will try it ... I
 
Cool !
I will try it ...

Is there any vim or jedit gurus that can do the same for vim and/or Jedit
I've found this link on the web:
Ident Finder http://phil.freehackers.org/indent-finder/

Description
------------
Indent Finder is a python script that reads a file and tells you what indentation is used inside the file. The indentation analysis works on any language. It was tested successfully with C, C++, python and Java code.
The current version provides helps for the integration with vim.

Maybe I will be helpfull

mattijs February 1, 2006 05:27

For the nedit users among us:
 
For the nedit users among us: set up all files ending in *Dict to be c++ syntax. (in addition to *.C and *.H ofcourse)


All times are GMT -4. The time now is 12:11.