[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: syntax highlighting



roberto wrote:

hello, i have the following question:
in my MATLAB code i have a lot of "for...end" or "if....end" and most of them are nested one
inside the other, do you know how to recognise whose "for" or "if" an "end" belongs to?
i know some editors are able to do this (vim, kwite...).
I mean these for's or if's are very far from each other in the code...

for example:

for ...
  for
    if ...
    ....
    ....
    ....
    end
  end
end

thank you!

Roberto
Debian Sarge
kernel 2.6.8

Try the matchit plugin on vim. If can match words like if-else-then etc., I use it for Fortran90 programming, where you need to match do-end do, program-end program etc.,

matchit plugin is available as usr/share/vim/vim63/macros/matchit.vim and is part of vim-common package.

raju

--
Kamaraju S Kusumanchi
Graduate Student, MAE
Cornell University
http://www.people.cornell.edu/pages/kk288/



Reply to: