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

Re: vim voldmarker with a space

Expand Messages
  • 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 1 of 8 , Mar 8, 2013
    View Source
    • 0 Attachment
      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 2 of 8 , Mar 8, 2013
      View Source
      • 0 Attachment
        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 3 of 8 , Mar 8, 2013
        View Source
        • 0 Attachment
          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 4 of 8 , Mar 9, 2013
          View Source
          • 0 Attachment
            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 5 of 8 , Mar 11, 2013
            View Source
            • 0 Attachment
              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 6 of 8 , Mar 14, 2013
              View Source
              • 0 Attachment
                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 7 of 8 , Mar 14, 2013
                View Source
                • 0 Attachment
                  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.