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

Setting cursor position upon opening netrw

Expand Messages
  • François Ingelrest
    Hi all, I m using the thin listing (g:netrw_liststyle=0) and each time I open netrw, the cursor seems to end up on a random line inside the listing. What I d
    Message 1 of 4 , Jan 24, 2013
    • 0 Attachment
      Hi all,

      I'm using the thin listing (g:netrw_liststyle=0) and each time I open
      netrw, the cursor seems to end up on a random line inside the listing.

      What I'd like is to have it always be placed on the first listing
      entry, just below the banner (thus line 9), each time I open netrw.
      I've tried various autocommands, but although seemingly easy I
      couldn't get it to work.

      Any idea on how I could achieve that?

      --
      --
      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
    • Charles Campbell
      ... Please try the attached version. It doesn t put the cursor below the banner, but does consistently leave the cursor at line 1, column 1. What I d like to
      Message 2 of 4 , Jan 24, 2013
      • 0 Attachment
        François Ingelrest wrote:
        > Hi all,
        >
        > I'm using the thin listing (g:netrw_liststyle=0) and each time I open
        > netrw, the cursor seems to end up on a random line inside the listing.
        >
        > What I'd like is to have it always be placed on the first listing
        > entry, just below the banner (thus line 9), each time I open netrw.
        > I've tried various autocommands, but although seemingly easy I
        > couldn't get it to work.
        >
        > Any idea on how I could achieve that?
        >
        Please try the attached version. It doesn't put the cursor below the
        banner, but does consistently leave the cursor at line 1, column 1.
        What I'd like to have happen that's not happening: browse a directory,
        change into a directory, return -- and have the cursor reappear at where
        it was earlier.

        Regards,
        Chip Campbell

        --
        --
        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
      • Charles Campbell
        ... Darn. I keep unintentionally sending the attached file to the entire list. Sorry about that! Regards, Chip Campbell -- -- You received this message from
        Message 3 of 4 , Jan 24, 2013
        • 0 Attachment
          Charles Campbell wrote:
          > François Ingelrest wrote:
          >> Hi all,
          >>
          >> I'm using the thin listing (g:netrw_liststyle=0) and each time I open
          >> netrw, the cursor seems to end up on a random line inside the listing.
          >>
          >> What I'd like is to have it always be placed on the first listing
          >> entry, just below the banner (thus line 9), each time I open netrw.
          >> I've tried various autocommands, but although seemingly easy I
          >> couldn't get it to work.
          >>
          >> Any idea on how I could achieve that?
          >>
          > Please try the attached version. It doesn't put the cursor below the
          > banner, but does consistently leave the cursor at line 1, column 1.
          > What I'd like to have happen that's not happening: browse a directory,
          > change into a directory, return -- and have the cursor reappear at where
          > it was earlier.
          >
          Darn. I keep unintentionally sending the attached file to the entire
          list. Sorry about that!

          Regards,
          Chip Campbell


          --
          --
          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
        • François Ingelrest
          Hi, ... This doesn t seem to work when using :Explore. It looks like the cursor stays on the same line as it was inside the file before using ... -- -- You
          Message 4 of 4 , Jan 24, 2013
          • 0 Attachment
            Hi,

            On Thu, Jan 24, 2013 at 5:34 PM, Charles Campbell wrote:
            > Please try the attached version. It doesn't put the cursor below the
            > banner, but does consistently leave the cursor at line 1, column 1.
            > What I'd like to have happen that's not happening: browse a directory,
            > change into a directory, return -- and have the cursor reappear at where it
            > was earlier.

            This doesn't seem to work when using :Explore. It looks like the
            cursor stays on the same line as it was inside the file before using
            :Explore. This does however work when using :Texplore.

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