editors.rst 1.11 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49


.. _editors:

==============
Editor support
==============

The AADL modes for Emacs and vim provide syntax coloration and
automatic indentation features when editing AADL files.

Emacs
=====

To load the AADL mode for Emacs, you need to add the following line to
your emacs configuration file (usually located in :file:`~/.emacs`) ::

      (load "/path/to/this/file.el")

For more details on this mode, please refer to the emacs contextual help.

.. figure:: aadl-mode.png
   :align: center

   AADL mode for Emacs

vim
===

The AADL mode for vim is made of two files aadl.vim: one for syntactic
coloration, and the other for indentation. The file for indentation
must be placed into ~/.vim/indent/ while the one for syntactic
coloration must be placed into :file:`~/.vim/syntax/`

To load the AADL mode whenever you edit AADL files, create a file
named :file:`~/.vim/filetype.vim`, in which you write::

     augroup filetypedetect
             au BufNewFile,BufRead *.aadl    setf aadl
     augroup END

For more details, please read the documentation of vim.


.. figure:: aadl-mode_vim.png
   :align: center

   AADL mode for vim