Loading ...
Sorry, an error occurred while loading the content.

136157Re: Using auto-format with LaTeX

Expand Messages
  • Christian Brabandt
    Feb 16, 2013
    • 0 Attachment
      Hi Marcin!

      On Do, 14 Feb 2013, Marcin Szamotulski wrote:

      > Thanks (once again) for the patch!
      >
      > Here are a few ideas:
      >
      > It would be nice to end paragraph line before the match for some
      > patterns. For example if you have
      >
      > lorem ipsum lorem ipsum
      > lorem ipsum lorem ipsum
      > lorem ipsum lorem ipsum
      > \section{New Aproach}
      >
      > adding ¶='/\\section' and using d} will delete one line to
      > much. But this should be only for some patters hence this will
      > require that ¶ is a list of patterns with some kind of
      > modifiers, or one would have to make support for multiline patterns.
      > Using something like ¶='/\n\s*\\section' is not working with the
      > patch.

      Oh yes, the motion is exclusive. The old patch did not allow multi-line
      patterns. I attach a new, slightly different one. Try this one.
      >
      >
      >
      > With the patch and ¶='/^\zs\s*$' and the following text:
      >
      > lorem ipsum lorem ipsum
      > lorem ipsum lorem ipsum
      >
      >
      > lorem ipsum lorem ipsum
      > lorem ipsum lorem ipsum
      >
      >
      > }, and { stop on the first met empty line, i.e. } will stop on the
      > top one, and { on the bottom one.

      Yes, paragraph motion is a little bit more clever than I initially
      thought. Try the updated patch, but note, that the pattern /^\s*$ does
      not work as expected (see the bug report earlier today:
      https://groups.google.com/forum/?fromgroups=#!topic/vim_dev/4Qzsf9CkMkE)

      The updated patch, works as expected, at least, if you go backwards with
      the pattern /^$ but not if you go forward.

      If the patch works for you and we don't find any issues I'll start
      creating test files. BTW: for documentation updates, what would you set
      the paragraphs/section options for latex? So I can document it as
      example in the help file.

      > Z wyrazami szacunku :)

      I had to look up this one. Are you Polish?

      regards,
      Christian
      --
      Ich verwünsche die, die aus dem Irrtum eine eigene Welt machen
      und doch unablässig fordern, dass der Mensch nützlich sein müsse.
      -- Goethe, Maximen und Reflektionen, Nr. 263

      --
      --
      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

      ---
      You received this message because you are subscribed to the Google Groups "vim_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Show all 6 messages in this topic