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

Re: justifying text

Expand Messages
  • Adam 'Vonlia' Seyfarth
    ... Well, have you seen $VIMRUNTIME/macros/justify.vim ? You could go to ... Which would give you this: a b ce a b c d e ab a b c f Which means you had the
    Message 1 of 2 , Aug 10, 2001
      On Fri, 10 Aug 2001, Denis Perelyubskiy wrote:

      > hello,
      >
      > is it possible to justify text in vim. is that
      > possible to do, or would something like an external program
      > need to be used? perhaps a function would have to be
      > written?
      >
      > so, what i am looking for is something that took something
      > that looks like this:
      >
      > a b ce
      > a b c d e
      > ab a b c f
      >
      > and turn it into (much like 'm$word does' :
      >
      > a b ce
      > a b c d e
      > ab a b c f

      Well, have you seen $VIMRUNTIME/macros/justify.vim ? You could go to
      the first 'a' and do:

      :.,.+3Justify
      :set textwidth=8

      Which would give you this:

      a b ce
      a b c d e
      ab a b c f

      Which means you had the spaces right :-) It will keep the current
      indent, and justifies the right at &textwidth .

      HTH


      --
      Hunter with gun: ``I love animals. That's why I love to kill
      them.''
      -- Monty Python::sketch

      /|| Adam Seyfarth <http://members.home.net/adam.seyfarth/> ||\
      /«|| <mailto:cloud@...> <http://www.majik3d.org> ||»\
      \«|| <http://tuxaqfh.sf.net> <http://tuxkart.sf.net> ||»/
      \|| <http://vim.sf.net> <http://www.majik3d.org> ||/
    Your message has been successfully submitted and would be delivered to recipients shortly.