Editing Fortran in Developer Studio

Editing Fortran in Developer Studio

I like using Emacs to edit Fortran code because it loads "Fortran-mode" in which

1. Tab puts the start of the current line indented appropriately for its position in nested IF and DO blocks

2. Tab only places spaces in the file, not tab characters, so the starting columns are the same regardless what editor I later use to view the file

3. Tab at an ENDIF or ENDDO statement places un-indents that statement in relation to the previous statement, so that it is in the same column as the corresponding IF or DO statement

4. Tab multiple times has no effect

5. Label numbers are automatically placed in columns 2-5

6. "$" + Tab places the $ in column 6 so it can be used as the continue line character

7. When pressing ")" the cursor is briefly moved to the matching "("

Is it possible to make the Developer Studio Editor work like this? The online help mentions emulation of BRIEF and Epsilon, but this did not give the result I want.

3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

I don't think you can make Developer Studio's editor behave the way you want, but check out VisEmacs, which claims to allow you to use Emacs from within Developer Studio.


Retired 12/31/2016

No more space, space, space ... to format my Fortran source and no more Tab characters! Thanks, Steve. VisEmacs is great!

I have some updated information in case anyone else is interested in this:

For VisEmacs installation go to http://atnetsend.ne.mediaone.net/computing/VisEmacs

I followed the FAQ link for additional info on getting VisEmacs working (on creating a .emacs) and obtaining a distribution of Emacs itself. Bye the way, the .emacs file can go in C: for Emacs to find it.

Also, the above website refers to gnuserv. One file from this distribution, gnuserv.el, had to be moved to my Emacs lispemacs-lisp folder.

Other than these last two items the website provided all the info necessary. The current maintainer of VisEmacs, Jeff Paquette, provided invaluable tips.

Leave a Comment

Please sign in to add a comment. Not a member? Join today