On Oct 18, 12:57 pm, "Charles E. Campbell, Jr."
<[EMAIL PROTECTED]> wrote:
> Peng Yu wrote:
> > Hi,
>
> > Suppose I have the following line in a .tex file.
>
> > \input{one_another}
>
> > 'one_another' is a file name. Therefore, if I press 'b' when the
> > cursor is on the letter 'o' of 'one', I would like it move to the end
> > of another. However, the default setting would make it move to the end
> > of 'one'. I'm wondering how to change the default behavior?
>
> > Similarly, I also want '_' be treated differently in all the command
> > that has an filename as the argument. For example,
> > \includegraphics{one_another}
> > \usepackage{one_another}
>
> >  Can this be done as well?
>
> put
>
> setlocal isk+=_
>
> in .vim/after/syntax/tex.vim
>
> However, that will make _ act as a keyword character everywhere in the
> tex file, not just in restricted locations such as in commands that take
> filenames.
>
> Didn't you mean "w" in your example?  A "b" normally moves back, not
> forward.

Yes, I meant 'w' or 'e'.

'_' does mean something in math mode. Is there a way to make vim
interpret it based on the environment? Syntax highlight can be  made
context dependent, I think that it is also possible to make the
interpretation of '_' context dependent, right?

Thanks,
Peng
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to