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

'g' and 'G' in more-prompt

Expand Messages
  • cptstubing
    I was going to ask if you would consider adding g/G to the |more- prompt| in message.c:msg_moremsg() like so: 2922c2922
    Message 1 of 4 , Mar 11, 2013
    • 0 Attachment
      I was going to ask if you would consider adding g/G to the |more-
      prompt| in message.c:msg_moremsg() like so:

      2922c2922
      < _(" SPACE/d/j: screen/page/line down, b/u/k: up, first/
      last: g/G, q: quit "),
      ---
      > _(" SPACE/d/j: screen/page/line down, b/u/k: up, q: quit "),

      ....which I am still asking. ;-) My reasoning is that the
      enumeration of all these other inputs in this more message implies
      that it is an exhaustive list, and (ignoring backspace which is
      already redundant) this would make it so. This is a particularly
      useful tidbit of knowledge to have when you've set verbose very high
      and have tons of autocmds firing off.

      Then, while playing with g and G, I noticed an issue:

      vim -u NONE --cmd 'set nocompatible | echo "hi\nthere"'

      Now if I hit gGgGgGgGgG..., a blank line is added below the last line
      each time I hit G, so the paged output "walks" upwards. This is a
      minimal test case, but you'll see this happening everywhere there is
      paged output in vim that is shorter than the height of your window.
      For example, :let, :!date, :cscope, etc.

      Ahoy,
      CS

      --
      --
      You received this message from the "vim_dev" 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_dev" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Bram Moolenaar
      ... The problem is that this message must fit in one line, and adding more text makes it wrap. ... I only see the problem for when there are just a couple of
      Message 2 of 4 , Mar 12, 2013
      • 0 Attachment
        cptstubing wrote:

        > I was going to ask if you would consider adding g/G to the |more-
        > prompt| in message.c:msg_moremsg() like so:
        >
        > 2922c2922
        > < _(" SPACE/d/j: screen/page/line down, b/u/k: up, first/
        > last: g/G, q: quit "),
        > ---
        > > _(" SPACE/d/j: screen/page/line down, b/u/k: up, q: quit "),
        >
        > ....which I am still asking. ;-) My reasoning is that the
        > enumeration of all these other inputs in this more message implies
        > that it is an exhaustive list, and (ignoring backspace which is
        > already redundant) this would make it so. This is a particularly
        > useful tidbit of knowledge to have when you've set verbose very high
        > and have tons of autocmds firing off.

        The problem is that this message must fit in one line, and adding more
        text makes it wrap.

        > Then, while playing with g and G, I noticed an issue:
        >
        > vim -u NONE --cmd 'set nocompatible | echo "hi\nthere"'
        >
        > Now if I hit gGgGgGgGgG..., a blank line is added below the last line
        > each time I hit G, so the paged output "walks" upwards. This is a
        > minimal test case, but you'll see this happening everywhere there is
        > paged output in vim that is shorter than the height of your window.
        > For example, :let, :!date, :cscope, etc.

        I only see the problem for when there are just a couple of lines.
        Not when it's more than a screen.

        --
        Bumper sticker: Honk if you love peace and quiet.

        /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
        /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
        \\\ an exciting new programming language -- http://www.Zimbu.org ///
        \\\ help me help AIDS victims -- http://ICCF-Holland.org ///

        --
        --
        You received this message from the "vim_dev" 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_dev" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
        For more options, visit https://groups.google.com/groups/opt_out.
      • cptstubing
        ... I can appreciate that. What if you moved the usage message to the first column instead of appending it to the -- More -- that s already there and
        Message 3 of 4 , Mar 15, 2013
        • 0 Attachment
          The Moolmeister wrote:
          > The problem is that this message must fit in one line, and adding more
          > text makes it wrap.

          I can appreciate that. What if you moved the usage message to the first column instead of appending it to the "-- More --" that's already there and abbreviate "page/line" to "pg/ln"? Now it's only a net addition of one column:

          2919d2918
          < screen_puts(s, (int)Rows - 1, 0, attr);
          2920a2920
          > {
          2922,2923c2922,2928
          < _(" SPACE/d/j: screen/page/line down, b/u/k: up, q: quit "),
          < (int)Rows - 1, vim_strsize(s), attr);
          ---
          > _("SPACE/d/j: screen/pg/ln down, b/u/k: up, first/last: g/G, q: quit "),
          > (int)Rows - 1, 0, attr);
          > }
          > else
          > {
          > screen_puts(s, (int)Rows - 1, 0, attr);
          > }


          >
          > I only see the problem for when there are just a couple of lines.
          > Not when it's more than a screen.

          Right, it appears to be something about the use of MSG_PUTS_ATTR to display the "Press ENTER..." message. I'll take a closer look and see if I can find a resolution for this case when I have some more time.

          Ahoy,
          CS

          --
          --
          You received this message from the "vim_dev" 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_dev" group.
          To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
          For more options, visit https://groups.google.com/groups/opt_out.
        • cptstubing
          Please see details of several issues here: https://code.google.com/r/cptstubing06-vimmoremsg/ Update to message.c:
          Message 4 of 4 , Mar 16, 2013
          • 0 Attachment
            Please see details of several issues here:
            https://code.google.com/r/cptstubing06-vimmoremsg/

            Update to message.c:
            https://code.google.com/r/cptstubing06-vimmoremsg/source/detail?r=37b0480ae9ff3811cdd6bee7e0007365f1c7e21b#

            Update to docs/message.txt:
            https://code.google.com/r/cptstubing06-vimmoremsg/source/detail?r=555f98f7c62d4b3e6679e33fbfc9a19557fe48c8#

            I understand if you don't want to abandon the same old usage message, but I still think a huge majority of users don't know about g and G in there.

            Please consider the other fixes.

            - CS

            --
            --
            You received this message from the "vim_dev" 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_dev" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+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.