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

Re: mapping a substitute for the Esc key?

Expand Messages
  • Benjamin Klein
    ... I use jk: inoremap jk This one shouldn’t require a finger from your left hand at all and is very fast indeed. -- b -- -- You received this message
    Message 1 of 16 , Feb 18, 2013
    • 0 Attachment
      On Feb 18, 2013, at 4:54 PM, Steve Litt <slitt@...> wrote:

      > Question for all of you: What's your favorite substitute for Esc,
      > whether a keystroke, key combination, or key sequence?

      I use jk:

      inoremap jk <Esc>

      This one shouldn’t require a finger from your left hand at all and is very fast indeed.

      --
      b

      --
      --
      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.
    • John Beckett
      ... Some ideas are at: http://vim.wikia.com/wiki/Avoid_the_escape_key I use the bizarre method on that page involving Enter (search for ToggleEnterMapping ).
      Message 2 of 16 , Feb 18, 2013
      • 0 Attachment
        Steve Litt wrote:
        > Question for all of you: What's your favorite substitute for
        > Esc, whether a keystroke, key combination, or key sequence?

        Some ideas are at:
        http://vim.wikia.com/wiki/Avoid_the_escape_key

        I use the bizarre method on that page involving Enter (search
        for "ToggleEnterMapping"). It's really weird and it took a while to
        get used to it, but pressing Enter is so easy and natural when
        one wants to terminate a command that it is now second nature.
        I press Ctrl-Enter in gvim to insert a manual end line, or
        switch off the mapping with its procedure for that.

        John

        --
        --
        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.
      • Steve Litt
        On Mon, 18 Feb 2013 16:58:45 -0600 ... VERY nice. Thank you Benjamin! I tried it on my laptop and it worked very well. It s a little awkward, and before my
        Message 3 of 16 , Feb 18, 2013
        • 0 Attachment
          On Mon, 18 Feb 2013 16:58:45 -0600
          Benjamin Klein <ben@...> wrote:

          > On Feb 18, 2013, at 4:54 PM, Steve Litt <slitt@...>
          > wrote:
          >
          > > Question for all of you: What's your favorite substitute for Esc,
          > > whether a keystroke, key combination, or key sequence?
          >
          > I use jk:
          >
          > inoremap jk <Esc>
          >
          > This one shouldn’t require a finger from your left hand at all and is
          > very fast indeed.

          VERY nice. Thank you Benjamin!

          I tried it on my laptop and it worked very well. It's a little awkward,
          and before my injury I would have preferred the Esc key, but given the
          situation, jk is an excellent choice. I might later change it to jj or
          kk or kl or something, to see if they're ergonomically better, but even
          though I'm not used to it, jk is very nice.

          Thank you!

          SteveT
          >
          > --
          > b
          >

          --
          --
          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.
        • Steve Litt
          On Tue, 19 Feb 2013 10:23:00 +1100 ... Thanks John, I wish I d read that article years ago. Right now I m trying jk, but I might try a lot of that web page s
          Message 4 of 16 , Feb 18, 2013
          • 0 Attachment
            On Tue, 19 Feb 2013 10:23:00 +1100
            "John Beckett" <johnb.beckett@...> wrote:

            > Steve Litt wrote:
            > > Question for all of you: What's your favorite substitute for
            > > Esc, whether a keystroke, key combination, or key sequence?
            >
            > Some ideas are at:
            > http://vim.wikia.com/wiki/Avoid_the_escape_key
            >
            > I use the bizarre method on that page involving Enter (search
            > for "ToggleEnterMapping"). It's really weird and it took a while to
            > get used to it, but pressing Enter is so easy and natural when
            > one wants to terminate a command that it is now second nature.
            > I press Ctrl-Enter in gvim to insert a manual end line, or
            > switch off the mapping with its procedure for that.
            >
            > John
            >

            Thanks John,

            I wish I'd read that article years ago. Right now I'm trying jk, but I
            might try a lot of that web page's other suggestions.

            Thanks

            SteveT

            --
            --
            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.
          • Daniel Zhang
            I map Caps_Lock as Esc 2013/2/19 Steve Litt ... -- -- You received this message from the vim_use maillist. Do not top-post! Type
            Message 5 of 16 , Feb 18, 2013
            • 0 Attachment
              I map Caps_Lock as Esc


              2013/2/19 Steve Litt <slitt@...>
              On Tue, 19 Feb 2013 10:23:00 +1100
              "John Beckett" <johnb.beckett@...> wrote:

              > Steve Litt wrote:
              > > Question for all of you: What's your favorite substitute for
              > > Esc, whether a keystroke, key combination, or key sequence?
              >
              > Some ideas are at:
              > http://vim.wikia.com/wiki/Avoid_the_escape_key
              >
              > I use the bizarre method on that page involving Enter (search
              > for "ToggleEnterMapping"). It's really weird and it took a while to
              > get used to it, but pressing Enter is so easy and natural when
              > one wants to terminate a command that it is now second nature.
              > I press Ctrl-Enter in gvim to insert a manual end line, or
              > switch off the mapping with its procedure for that.
              >
              > John
              >

              Thanks John,

              I wish I'd read that article years ago. Right now I'm trying jk, but I
              might try a lot of that web page's other suggestions.

              Thanks

              SteveT

              --
              --
              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.



              --
              --
              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.
               
               
            • Benjamin Klein
              ... You re welcome -- glad to be of help. :) I was going to say that I borrowed that one from Steve Losh s excellent (and lengthy) Coming Home To Vim
              Message 6 of 16 , Feb 18, 2013
              • 0 Attachment
                On Feb 18, 2013, at 7:52 PM, Steve Litt <slitt@...> wrote:

                Thank you!

                You're welcome -- glad to be of help. :) I was going to say that I borrowed that one from Steve Losh's excellent (and lengthy) "Coming Home To Vim" (http://stevelosh.com/blog/2010/09/coming-home-to-vim/), but I just looked and it seems that he uses jj instead, so I must have found that one elsewhere.

                I've read that jk is faster than jj -- I can't prove that, but certainly jk is very fast once you get to used to it. And for something as common as going back to normal mode from insert, it is definitely nice to be using keys right there on the home row instead of having to reach way out for the Esc key.

                --
                b

                --
                --
                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.
                 
                 
              • Erik Christiansen
                ... The tiny and distant Esc key on laptops quickly forced me to find something better, primarily for vim, but necessarily consistent for _all_ applications,
                Message 7 of 16 , Feb 18, 2013
                • 0 Attachment
                  On Feb 18, 2013, at 4:54 PM, Steve Litt <slitt@...> wrote:
                  > Question for all of you: What's your favorite substitute for Esc,
                  > whether a keystroke, key combination, or key sequence?

                  The tiny and distant Esc key on laptops quickly forced me to find
                  something better, primarily for vim, but necessarily consistent for
                  _all_ applications, so that muscle memory can be relied upon, whatever
                  you're doing. So I just changed the CapsLock key to Esc:

                  Added to ~/.Xmodmap:

                  keycode 0x42 = Escape
                  clear Lock # Disable Caps-Lock

                  I'm still using the cursor keys for motion, despite decades as a
                  programmer, and have been happy with that Esc on laptops and desktops
                  for years now.

                  Erik

                  --
                  Habit is habit, and not to be flung out of the window by any man, but
                  coaxed down-stairs a step at a time.
                  - Mark Twain, "Pudd'nhead Wilson's Calendar

                  --
                  --
                  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
                  ... I work primarily on laptops and found that wasn t the problem, but that it was too close to . So I mapped to behave like so I can
                  Message 8 of 16 , Feb 19, 2013
                  • 0 Attachment
                    On 2013-02-19 18:54, Erik Christiansen wrote:
                    > The tiny and distant Esc key on laptops quickly forced me to find
                    > something better, primarily for vim,

                    I work primarily on laptops and found that <esc> wasn't the problem,
                    but that it was too close to <f1>. So I mapped <f1> to behave like
                    <esc> so I can just shove my finger in the general direction of the
                    upper-left corner and get the behavior I want regardless of my
                    poor accuracy. :-)

                    -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.
                  • Steve Litt
                    ... Thanks Daniel, I can t do that because I use capslock all the time for its intended purpose. Of course, what maybe I COULD (see what I mean) do would be to
                    Message 9 of 16 , Feb 19, 2013
                    • 0 Attachment
                      :-)

                      Thanks Daniel,

                      I can't do that because I use capslock all the time for its intended
                      purpose.

                      Of course, what maybe I COULD (see what I mean) do would be to make
                      Capslock Esc, and then make Esc capslock. I use capslock much less than
                      Esc.

                      SteveT

                      On Tue, 19 Feb 2013 11:03:56 +0800
                      Daniel Zhang <wodesuck@...> wrote:

                      > I map Caps_Lock as Esc
                      >
                      >
                      > 2013/2/19 Steve Litt <slitt@...>
                      >
                      > > On Tue, 19 Feb 2013 10:23:00 +1100
                      > > "John Beckett" <johnb.beckett@...> wrote:
                      > >
                      > > > Steve Litt wrote:
                      > > > > Question for all of you: What's your favorite substitute for
                      > > > > Esc, whether a keystroke, key combination, or key sequence?
                      > > >
                      > > > Some ideas are at:
                      > > > http://vim.wikia.com/wiki/Avoid_the_escape_key
                      > > >
                      > > > I use the bizarre method on that page involving Enter (search
                      > > > for "ToggleEnterMapping"). It's really weird and it took a while
                      > > > to get used to it, but pressing Enter is so easy and natural when
                      > > > one wants to terminate a command that it is now second nature.
                      > > > I press Ctrl-Enter in gvim to insert a manual end line, or
                      > > > switch off the mapping with its procedure for that.
                      > > >
                      > > > John
                      > > >
                      > >
                      > > Thanks John,
                      > >
                      > > I wish I'd read that article years ago. Right now I'm trying jk,
                      > > but I might try a lot of that web page's other suggestions.
                      > >
                      > > Thanks
                      > >
                      > > SteveT
                      > >
                      > > --
                      > > --
                      > > 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.
                      > >
                      > >
                      > >
                      >

                      --
                      --
                      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.
                    • Steve Litt
                      On Mon, 18 Feb 2013 21:50:38 -0600 ... Thanks Benjamin, I m actually thinking of using jf. The jk sequence seems a little slow/tiring because I have to
                      Message 10 of 16 , Feb 19, 2013
                      • 0 Attachment
                        On Mon, 18 Feb 2013 21:50:38 -0600
                        Benjamin Klein <ben@...> wrote:

                        > On Feb 18, 2013, at 7:52 PM, Steve Litt <slitt@...>
                        > wrote:
                        >
                        > > Thank you!
                        >
                        > You're welcome -- glad to be of help. :) I was going to say that I
                        > borrowed that one from Steve Losh's excellent (and lengthy) "Coming
                        > Home To Vim" (http://stevelosh.com/blog/2010/09/coming-home-to-vim/),
                        > but I just looked and it seems that he uses jj instead, so I must
                        > have found that one elsewhere.
                        >
                        > I've read that jk is faster than jj -- I can't prove that, but
                        > certainly jk is very fast once you get to used to it.

                        Thanks Benjamin,

                        I'm actually thinking of using jf. The jk sequence seems a little
                        slow/tiring because I have to reposition the hand in a weird way. The
                        jj combo is similar. But with jf, the left index finger is readying
                        itself as the right index finger strikes, so it will be faster. The
                        cool thing about the j key is it's unlikely to be followed by a
                        consonant, so I have the choice of many, many key combos.

                        I'll get back to you all when I've fully evaluated key combos.

                        Thanks

                        SteveT

                        --
                        --
                        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.
                      • Grahame Blackwood
                        ... Hi Steve I find ;; feels quite natural and quick. Cheers Grahame -- -- You received this message from the vim_use maillist. Do not top-post! Type your
                        Message 11 of 16 , Feb 19, 2013
                        • 0 Attachment
                          On Mon, Feb 18, 2013 at 10:54 PM, Steve Litt <slitt@...> wrote:

                          > from: Steve Litt <slitt@...>
                          > date: Mon, Feb 18 05:54 PM -05:00 2013
                          > to: vim_use@...
                          > reply-to: vim_use@...
                          > subject: mapping a substitute for the Esc key?
                          >
                          > Hi all,
                          >
                          > I injured my left middle finger and can no longer extend it. Therefore,
                          > hitting the Esc key to get out of insert mode stops my work in its
                          > tracks.
                          >
                          > Question for all of you: What's your favorite substitute for Esc,
                          > whether a keystroke, key combination, or key sequence?
                          >
                          > Thanks
                          >
                          > SteveT
                          >
                          Hi Steve

                          I find ;; feels quite natural and quick.

                          Cheers

                          Grahame

                          --
                          --
                          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.
                        • Chris Lott
                          ... Most who type in classical position have jk under their index and middle finger, making it easy to rapidly type the two. kj would be the most natural for
                          Message 12 of 16 , Feb 19, 2013
                          • 0 Attachment
                            On Tue, Feb 19, 2013 at 9:04 AM, Steve Litt <slitt@...> wrote:
                            > I'm actually thinking of using jf. The jk sequence seems a little
                            > slow/tiring because I have to reposition the hand in a weird way.

                            Most who type in classical position have jk under their index and
                            middle finger, making it easy to rapidly type the two. kj would be the
                            most "natural" for me, but it occurs in just enough words to be
                            irritating...

                            c
                            --
                            Chris Lott <chris@...>

                            --
                            --
                            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.
                          • darkweasel
                            ... There might be other languages where that combination is more common. ;) -- -- You received this message from the vim_use maillist. Do not top-post! Type
                            Message 13 of 16 , Feb 19, 2013
                            • 0 Attachment
                              Am 2013-02-19 21:54, schrieb Tim Chase:
                              > On 2013-02-19 11:41, Chris Lott wrote:
                              >> On Tue, Feb 19, 2013 at 9:04 AM, Steve Litt
                              >> <slitt@...> wrote:
                              >>> I'm actually thinking of using jf. The jk sequence seems a little
                              >>> slow/tiring because I have to reposition the hand in a weird way.
                              >>
                              >> Most who type in classical position have jk under their index and
                              >> middle finger, making it easy to rapidly type the two. kj would be
                              >> the most "natural" for me, but it occurs in just enough words to be
                              >> irritating...
                              >
                              > You type "blackjack", "lockjaw" or "Reykjavik" that often? ;-)
                              >
                              > -tim

                              There might be other languages where that combination is more common. ;)

                              --
                              --
                              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
                              ... You type blackjack , lockjaw or Reykjavik that often? ;-) -tim -- -- You received this message from the vim_use maillist. Do not top-post! Type your
                              Message 14 of 16 , Feb 19, 2013
                              • 0 Attachment
                                On 2013-02-19 11:41, Chris Lott wrote:
                                > On Tue, Feb 19, 2013 at 9:04 AM, Steve Litt
                                > <slitt@...> wrote:
                                > > I'm actually thinking of using jf. The jk sequence seems a little
                                > > slow/tiring because I have to reposition the hand in a weird way.
                                >
                                > Most who type in classical position have jk under their index and
                                > middle finger, making it easy to rapidly type the two. kj would be
                                > the most "natural" for me, but it occurs in just enough words to be
                                > irritating...

                                You type "blackjack", "lockjaw" or "Reykjavik" that often? ;-)

                                -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.
                              • Grahame Blackwood
                                ... Hi Steve Probably Vimoutliner or Lyx. We have also corresponded about your Umenu system which I use every day, so thank you for developing it and also
                                Message 15 of 16 , Feb 21, 2013
                                • 0 Attachment
                                  On Thu, Feb 21, 2013 at 09:37 PM, Steve Litt <slitt@...> wrote:

                                  > from: Steve Litt <slitt@...>
                                  > date: Thu, Feb 21 04:37 PM -05:00 2013
                                  > to: Grahame Blackwood <grahameblackwood@...>
                                  > subject: Re: mapping a substitute for the Esc key?
                                  >
                                  > On Thu, 21 Feb 2013 16:41:14 +0000
                                  > Grahame Blackwood <grahameblackwood@...> wrote:
                                  >
                                  >> On Mon, Feb 18, 2013 at 10:54 PM, Steve Litt
                                  >> <slitt@...> wrote:
                                  >>
                                  >> > from: Steve Litt <slitt@...>
                                  >> > date: Mon, Feb 18 05:54 PM -05:00 2013
                                  >> > to: vim_use@...
                                  >> > reply-to: vim_use@...
                                  >> > subject: mapping a substitute for the Esc key?
                                  >> >
                                  >> > Hi all,
                                  >> >
                                  >> > I injured my left middle finger and can no longer extend it.
                                  >> > Therefore, hitting the Esc key to get out of insert mode stops my
                                  >> > work in its tracks.
                                  >> >
                                  >> > Question for all of you: What's your favorite substitute for Esc,
                                  >> > whether a keystroke, key combination, or key sequence?
                                  >> >
                                  >> > Thanks
                                  >> >
                                  >> > SteveT
                                  >> >
                                  >> Hi Steve
                                  >>
                                  >> Sorry to hear about your injury and hope your finger improves soon.
                                  >>
                                  >> I tried replying to the vim_use list but my email hasn't shown up.
                                  >>
                                  >> My preferred substitute for esc is ;; as on my keyboard it falls under
                                  >> my right little finger. I either hit it twice or sometimes just hold
                                  >> it down until vim exits insert mode.
                                  >>
                                  >> Cheers
                                  >>
                                  >> G
                                  >
                                  > Thanks Graham. I finally settled on jf, but ;; would have been pretty
                                  > good too.
                                  >
                                  > I think I know your name from a list other than the Vim list: LyX, Lua,
                                  > something like that?
                                  >
                                  > Thanks
                                  >
                                  > Steve

                                  Hi Steve

                                  Probably Vimoutliner or Lyx. We have also corresponded about your Umenu system
                                  which I use every day, so thank you for developing it and also
                                  Vimoutliner - both very useful tools.

                                  Cheers

                                  G



                                  --
                                  --
                                  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.