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

vim voldmarker with a space

Expand Messages
  • ping
    foldmarker fmr string (default: {{{,}}} ) local to window {not in Vi} {not available when compiled without the |+folding| feature} The start and end
    Message 1 of 8 , Mar 8, 2013
      'foldmarker' 'fmr'    string (default: "{{{,}}}")
                  local to window
                  {not in Vi}
                  {not available when compiled without the |+folding|
                  feature}
          The start and end marker used when 'foldmethod' is "marker".  There
          must be one comma, which separates the start and end marker.  The
          marker is a literal string (a regular expression would be too slow).
          See |fold-marker|.


      but if I use this:

      :set foldmarker= {,}


      I got E536: comma required: foldmarker=


      why space not supported?


      then how do I fold with {,} but exclude the {6} ?

          policy COMMIT_TRAP {
              events ui_commit;
              attributes-match {
                  ui_commit.username matches "{6}";
              }
              then {
                  raise-trap;
              }
          }


      thanks!

      --
      --
      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.
       
       
    • Tim Chase
      ... which you can read about at ... -tim -- -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are
      Message 2 of 8 , Mar 8, 2013
        On 2013-03-08 17:13, ping wrote:
        > See |fold-marker|.
        > but if I use this:
        >
        > :set foldmarker= {,}
        >
        > I got E536: comma required: foldmarker=
        >
        > why space not supported?

        You just need to escape the space:

        :set foldmethod=marker foldmarker=\ {,}

        which you can read about at

        :help option-backslash

        Alternatively, you can use the "let" format:

        :let &fdm=' {,}'

        -tim


        --
        --
        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.
      • Tim Chase
        ... And of course I mean ... here, not &fdm (which is foldmethod ) -tim -- -- You received this message from the vim_use maillist. Do not top-post! Type
        Message 3 of 8 , Mar 8, 2013
          On 2013-03-08 17:01, Tim Chase wrote:
          > > :set foldmarker= {,}
          >
          > :let &fdm=' {,}'

          And of course I mean

          :let &foldmarker=' {,}'

          here, not &fdm (which is 'foldmethod')

          -tim



          --
          --
          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.
        • ping
          ... this really works! thanks! regards ping -- -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you
          Message 4 of 8 , Mar 8, 2013
            On 3/8/2013 6:01 PM, Tim Chase wrote:
            > On 2013-03-08 17:13, ping wrote:
            >> See |fold-marker|.
            >> but if I use this:
            >>
            >> :set foldmarker= {,}
            >>
            >> I got E536: comma required: foldmarker=
            >>
            >> why space not supported?
            > You just need to escape the space:
            >
            > :set foldmethod=marker foldmarker=\ {,}
            >
            > which you can read about at
            >
            > :help option-backslash
            >
            > Alternatively, you can use the "let" format:
            >
            > :let &fdm=' {,}'
            >
            > -tim
            >
            >
            this really works! thanks!

            regards
            ping

            --
            --
            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.
          • Ben Fritz
            ... Ping, I see from this final post that your mail reader is capable of using plaintext instead of some HUGE font size HTML formatted monospace font. Do you
            Message 5 of 8 , Mar 9, 2013
              On Friday, March 8, 2013 7:13:53 PM UTC-6, ping wrote:
              > On 3/8/2013 6:01 PM, Tim Chase wrote:
              >
              > > On 2013-03-08 17:13, ping wrote:
              >
              > >> See |fold-marker|.
              >
              > >> but if I use this:
              >
              > >>
              >
              > >> :set foldmarker= {,}
              >
              > >>
              >
              > >> I got E536: comma required: foldmarker=
              >
              > >>
              >
              > >> why space not supported?
              >
              > > You just need to escape the space:
              >
              > >
              >
              > > :set foldmethod=marker foldmarker=\ {,}
              >
              > >
              >
              > > which you can read about at
              >
              > >
              >
              > > :help option-backslash
              >
              > >
              >
              > > Alternatively, you can use the "let" format:
              >
              > >
              >
              > > :let &fdm=' {,}'
              >
              > >
              >
              > > -tim
              >
              > >
              >
              > >
              >
              > this really works! thanks!
              >
              >
              >
              > regards
              >
              > ping

              Ping, I see from this final post that your mail reader is capable of using plaintext instead of some HUGE font size HTML formatted monospace font. Do you think you could start doing that for your initial posts as well?

              --
              --
              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.
            • ping
              sure, sorry, and thanks! regards ping ... -- -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you are
              Message 6 of 8 , Mar 11, 2013
                sure, sorry, and thanks!

                regards
                ping

                On 03/09/2013 06:14 PM, Ben Fritz wrote:
                > On Friday, March 8, 2013 7:13:53 PM UTC-6, ping wrote:
                >> On 3/8/2013 6:01 PM, Tim Chase wrote:
                >>
                >>> On 2013-03-08 17:13, ping wrote:
                >>>> See |fold-marker|.
                >>>> but if I use this:
                >>>> :set foldmarker= {,}
                >>>> I got E536: comma required: foldmarker=
                >>>> why space not supported?
                >>> You just need to escape the space:
                >>> :set foldmethod=marker foldmarker=\ {,}
                >>> which you can read about at
                >>> :help option-backslash
                >>> Alternatively, you can use the "let" format:
                >>> :let &fdm=' {,}'
                >>> -tim
                >> this really works! thanks!
                >>
                >>
                >>
                >> regards
                >>
                >> ping
                > Ping, I see from this final post that your mail reader is capable of using plaintext instead of some HUGE font size HTML formatted monospace font. Do you think you could start doing that for your initial posts as well?
                >

                --
                --
                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.
              • ping
                ... to continue this topic, so I ran into following text event-options { policy COMMIT_TRAP { events ui_commit; attributes-match { ^([vz][0-9]{6}|abc)$ ; }
                Message 7 of 8 , Mar 14, 2013
                  On 03/08/2013 06:03 PM, Tim Chase wrote:
                  > On 2013-03-08 17:01, Tim Chase wrote:
                  >>> :set foldmarker= {,}
                  >>
                  >> :let &fdm=' {,}'
                  >
                  > And of course I mean
                  >
                  > :let &foldmarker=' {,}'
                  >
                  > here, not &fdm (which is 'foldmethod')
                  >
                  > -tim
                  >
                  >
                  >

                  to continue this topic, so I ran into following text

                  event-options {
                  policy COMMIT_TRAP {
                  events ui_commit;
                  attributes-match {
                  "^([vz][0-9]{6}|abc)$";
                  }
                  then {
                  raise-trap;
                  }
                  }
                  event-script {
                  file
                  }
                  }

                  after folding using the previous solution, I now can fold it as:

                  +-- 10 lines: event-options
                  +-- 3 lines: event-script
                  } <--one extra line here


                  so apparently that extra '}" in the line
                  "^([vz][0-9]{6}|abc)$";
                  is the culprit.

                  I hope I can simply do:

                  :set foldmarker=\ {,}$

                  so the intention is , using }, but only if it's the last char in the
                  line, as the marker....

                  but according to help foldmarker, it doesn't support regex.
                  so that doesn't work.

                  I guess there is no good way to achieve that goal?

                  thanks!

                  --
                  --
                  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.
                • Ben Fritz
                  ... I think the only way to achieve this is to use a different foldmethod. -- -- You received this message from the vim_use maillist. Do not top-post! Type
                  Message 8 of 8 , Mar 14, 2013
                    On Thursday, March 14, 2013 12:48:09 PM UTC-5, ping wrote:
                    >
                    > I hope I can simply do:
                    >
                    >
                    >
                    > :set foldmarker=\ {,}$
                    >
                    >
                    >
                    > so the intention is , using }, but only if it's the last char in the
                    >
                    > line, as the marker....
                    >
                    >
                    >
                    > but according to help foldmarker, it doesn't support regex.
                    >
                    > so that doesn't work.
                    >
                    >
                    >
                    > I guess there is no good way to achieve that goal?
                    >
                    >

                    I think the only way to achieve this is to use a different foldmethod.

                    --
                    --
                    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.
                  Your message has been successfully submitted and would be delivered to recipients shortly.