On 2011-05-15, Philipp Marek wrote:
> >> Just try by
> >>     :set indentexpr=5
> >> New lines are correctly indented, but "=" does the wrong thing.
> >
> > Could you elaborate on that just a wee bit.  "Does the wrong thing"
> > is not much to go on.
> Well, indentexpr is not used - the result is as if indentexpr is simply not 
> set, ie.
> what autoindent gives.
> 
> > I just opened a new Vim instance, typed some text, executed
> >
> >     :set indentexpr=5
> >
> > and executed "==" on one of the lines.  That line was indented by 5
> > spaces.  I also visually selected a few lines, typed "=" and they
> > were indented by 5 spaces.  That was using Vim 7.3.3 (old, but what
> > I had handy).  So I'm not seeing a problem.
> Hmmm, either it's the different vim version, or some other setting in the 
> buffer ...
> 
> I'll look again.

If you're still having trouble finding the problem, try coming up
with a minimal chunk of text that exhibits the problem.  Then post
that here as it appears before and after you perform the =
operation, along with an explanation of _exactly_ the steps you
executed and what you expected the results to be.

It might also help if you would include the results of ":version" in
your post.

If it only happens with some files, check the file type with

    :set ft?

and be sure to mention that, too.

As you're looking for the problem, it might help to start Vim as

    vim -N -u NONE

or as

    gvim -N -u NONE

That will prevent Vim from sourcing any of your configuration files.

Another thing that might help is to execute the ":options" command
and jump down to section "14 tabs and indenting".  That shows all
the indent-related settings and might suggest some settings that
could be affecting the behavior you're seeing.

> Thank you for your answer!

You're welcome.

Regards,
Gary

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to