don't want to type _

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

don't want to type _

sinbadd
i'm tired of typing underscore_ and -> in insert mode,
is there any way i can get around this. i thought of
using abbr, but it won't work if its in word_like_this.
any thoughts ?

cheers

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Andrei Kulakov
On 04/03/2012 01:23 AM, sinbad wrote:
> i'm tired of typing underscore_ and ->  in insert mode,
> is there any way i can get around this. i thought of
> using abbr, but it won't work if its in word_like_this.
> any thoughts ?
>
> cheers
>


Swap _ and - in code files via a mapping.  -ak

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Benjamin Fritz
In reply to this post by sinbadd
On Tuesday, April 3, 2012 12:23:22 AM UTC-5, sinbad wrote:
> i'm tired of typing underscore_ and -> in insert mode,
> is there any way i can get around this. i thought of
> using abbr, but it won't work if its in word_like_this.
> any thoughts ?
>
> cheers

Under what circumstances would Vim be able to determine you want these characters? Are they just too hard to reach for the frequency with which you type them? You could just imap infrequently used but easier to reach letter combinations, like qq or jj or hh to these characters.

I couldn't figure out what the problem was at first, because in Dvorak _ and - are very easy to access, on the home row even.

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Poly Yang

Best Regards.
Wuhan,China. 

i dose not feel that boring when typing underscore "_" in insert mode,maybe you could type it with another    
emotion

2012/4/3 Ben Fritz <[hidden email]>
On Tuesday, April 3, 2012 12:23:22 AM UTC-5, sinbad wrote:
> i'm tired of typing underscore_ and -> in insert mode,
> is there any way i can get around this. i thought of
> using abbr, but it won't work if its in word_like_this.
> any thoughts ?
>
> cheers

Under what circumstances would Vim be able to determine you want these characters? Are they just too hard to reach for the frequency with which you type them? You could just imap infrequently used but easier to reach letter combinations, like qq or jj or hh to these characters.

I couldn't figure out what the problem was at first, because in Dvorak _ and - are very easy to access, on the home row even.

--
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 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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Michael Ludwig-3
Poly Yang schrieb am 03.04.2012 um 23:15 (+0800):
> Best Regards.
> Wuhan,China.
>
> i dose not feel that boring when typing underscore "_" in insert
> mode,maybe you could type it with another emotion

I like this suggestion! :) The underscore ist SHIFT-MINUS on my
keyboard, not too bad. Especially considering that { is AltGr-7.

I might end up trying Dvorak (since I saw it mentioned on this
list a while ago) or maybe just hacking QWERTZ to add {[]} on
AltGr+ASDF. Anyone done that?

Michael

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

sinbadd
On Apr 3, 10:25 pm, Michael Ludwig <[hidden email]> wrote:

> Poly Yang schrieb am 03.04.2012 um 23:15 (+0800):
>
> > Best Regards.
> > Wuhan,China.
>
> > i dose not feel that boring when typing underscore "_" in insert
> > mode,maybe you could type it with another emotion
>
> I like this suggestion! :) The underscore ist SHIFT-MINUS on my
> keyboard, not too bad. Especially considering that { is AltGr-7.
>
> I might end up trying Dvorak (since I saw it mentioned on this
> list a while ago) or maybe just hacking QWERTZ to add {[]} on
> AltGr+ASDF. Anyone done that?
>
> Michael

imap does help,
it's not my emotion, it requires shift to enter _ or ->,
i tend to use my left little finger to press shift and lately
that finger is paining a lot, so i am finding ways to
avoid shift as much as possible. i'm so much used
to left finger, i'm not able to avoid even if i want to.
i am trying to use the right little finger, but it's not
happenin...:(

cheers


--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Nazri Ramliy
On Wed, Apr 4, 2012 at 9:49 AM, sinbad <[hidden email]> wrote:
> imap does help,
> it's not my emotion, it requires shift to enter _ or ->,
> i tend to use my left little finger to press shift and lately
> that finger is paining a lot, so i am finding ways to
> avoid shift as much as possible. i'm so much used
> to left finger, i'm not able to avoid even if i want to.
> i am trying to use the right little finger, but it's not
> happenin...:(

The AutoComplPop plugin might alleviate your pain:

  http://www.vim.org/scripts/script.php?script_id=1879

it actively pops up an omni-completion box to match whatever it is
you're currently typing with contents from the currently opened
buffers.

It's not perfect. I enable it in my vimrc all the time and sometimes
it does get in the way , like preventing you from inserting the enter
key the popup appears, but most of the time it's good at auto
completing stuff_like_this.

For -> you might find mapping "." to "->" in insert mode may help, or
even ".." to "->".

nazri

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

sinbadd
On Apr 4, 8:01 am, Nazri Ramliy <[hidden email]> wrote:

> On Wed, Apr 4, 2012 at 9:49 AM, sinbad <[hidden email]> wrote:
> > imap does help,
> > it's not my emotion, it requires shift to enter _ or ->,
> > i tend to use my left little finger to press shift and lately
> > that finger is paining a lot, so i am finding ways to
> > avoid shift as much as possible. i'm so much used
> > to left finger, i'm not able to avoid even if i want to.
> > i am trying to use the right little finger, but it's not
> > happenin...:(
>
> The AutoComplPop plugin might alleviate your pain:
>
>  http://www.vim.org/scripts/script.php?script_id=1879
>
> it actively pops up an omni-completion box to match whatever it is
> you're currently typing with contents from the currently opened
> buffers.
>
> It's not perfect. I enable it in my vimrc all the time and sometimes
> it does get in the way , like preventing you from inserting the enter
> key the popup appears, but most of the time it's good at auto
> completing stuff_like_this.
>
> For -> you might find mapping "." to "->" in insert mode may help, or
> even ".." to "->".
>
> nazri

i like the mapping .. to ->, i'll try out the plugin.

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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

Dan Wierenga-2
In reply to this post by sinbadd


On Tue, Apr 3, 2012 at 6:49 PM, sinbad <[hidden email]> wrote:
lately that finger is paining a lot, so i am finding ways to avoid shift as much as possible.
 i'm so much used to left finger, i'm not able to avoid even if i want to.
i am trying to use the right little finger, but it's not happenin...:(

I had the same problem.  On Windows I used an AutoHotKey script to disable the left-shift key, which forced me to use my right hand for shifting.  I'd bet there's a way to do it on linux with xmodmap or something similar but I've never done it myself.

The nice thing was it worked for all applications, not just Vim. 

--
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
Reply | Threaded
Open this post in threaded view
|

Re: don't want to type _

sinbadd
On Apr 4, 9:24 pm, Dan Wierenga <[hidden email]> wrote:

> On Tue, Apr 3, 2012 at 6:49 PM, sinbad <[hidden email]> wrote:
> > lately that finger is paining a lot, so i am finding ways to avoid shift
> > as much as possible.
> >  i'm so much used to left finger, i'm not able to avoid even if i want to.
> > i am trying to use the right little finger, but it's not happenin...:(
>
> I had the same problem.  On Windows I used an AutoHotKey script to disable
> the left-shift key, which forced me to use my right hand for shifting.  I'd
> bet there's a way to do it on linux with xmodmap or something similar but
> I've never done it myself.
>
> The nice thing was it worked for all applications, not just Vim.

Hi Dan,

i think it might work for me. i am on windows too, i will tryout the
script.
thanks for sharing.

cheers

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