News for hackers. Stuff that matters.
Re:Seven habits of effective text editing (2000) by mercer on Monday October 23, 2017 @09:17AM (#15532933)
What's the cognitive overhead? I'm a huge vim weenie and a pretty fast typist, but I'd never argue that the mouse is obsolete when compared to vim.

For example, I've played FPS games where I had to target something the size of < 10 pixels, in less than a second, and the need to move my mouse from one end of the mouse pad to the other. Basically, the mouse and (in most cases) cursor are barely separate from my body when it comes to pointing at things on the screen.

So when I need to put the cursor somewhere, I still find that using the mouse can be much faster than any vim key combination.

While I do agree that the 'context switch' from keyboard to mouse matters, I still find using a mouse/trackpad worth the relative effort often enough that 'pure' keyboard vim is a degradation in experience.

Re:Seven habits of effective text editing (2000) by sevensor on Monday October 23, 2017 @09:38AM (#15533054)
I don't think the mouse is obsolete, just that it's an obstruction when it comes to editing text. Vim, emacs, and my current favorite, kakoune, all give you a rich language for talking to the computer about how you want your text to be arranged. The mouse doesn't speak that language. It requires you to switch from thinking about text as text to thinking about it as a pixel target. That may only feel natural if you play a lot of FPS games.
Re:Seven habits of effective text editing (2000) by mercer on Monday October 23, 2017 @09:54AM (#15533150)
While I do agree that when it comes to editing Vim/emacs/kaoune might be superior, I spend a nontrivial amount of my coding time in 'discovery' mode. scrolling, clicking around, and mouse stuff in general is very useful in that case, and in my experience definitely faster than keyboard-only.

I could try and make a nuanced argument of when and where a mouse is preferable to a keyboard, but I think even just scrolling is enough of an argument for me. CTRL-D or whatnot just doesn't do justice to scrolling with a mouse.

Anyways, mostly I'm a fan of Vim and using its approach as much as possible. I just get annoyed when Vim-fans try to argue that a mouse is never better, which honestly I feel is a the argument of a fanatic. I've never come across a remotely good argument as to why a mouse is never the answer, and it always feels like a needlessly 'partisan' type thing.

Keyboards are cool. Mice are cool. Can we all just get along?

EDIT: I got a bit carried away and I do agree more with you than this comment might suggest. I just think 'editing' is not the only thing I do when coding, and for some of that other stuff a mouse is a huge advantage, even in a coding context.

Re:Seven habits of effective text editing (2000) by jstimpfle on Monday October 23, 2017 @02:43PM (#15535771)
Re: scrolling, in vim you have CTRL-E and CTRL-Y and there must be a way to adjust the scroll step (usually 1) to the scroll step of your mouse wheel (usually like 3) is bound. Can a mouse do 30 scrollings per second (my keyboard input rate)?

Where the scroll wheel makes a difference is when you want to fine tune the scrolling speed, which you can't do with a keyboard. I don't think I have a usecase for that (but YMMV), and my impression is it often gets me out of text mode and into FPS mode.

What would be really nice for larger scroll steps (like CTRL-D) is smooth scrolling. I suppose there is no terminal support for this? Also gvim doesn't seem to have it.

Anyway I usually don't scroll by fixed amounts, but do * (identifier search), / (regex search), { and }, and maybe more.

EDIT: just added this to my vimrc. I don't think my mouse scrolling ever was this good

   " Triple scrolling "speed"
   nnoremap <C-e> 3<C-e>
   nnoremap <C-y> 3<C-y>
Re:Seven habits of effective text editing (2000) by fao_ on Monday October 30, 2017 @09:35AM (#15584865)
you also have ^f ^b (forward, back (by a page)), and ^u ^d (up, down (by half a page)). I honestly prefer scrolling by paragraph though ({ })
Re:Seven habits of effective text editing (2000) by gjjrfcbugxbhf on Monday October 23, 2017 @11:56AM (#15534116)
> Keyboards are cool. Mice are cool. Can we all just get along?

Agreed.

I'm a vim fanboy - and I use the mouse.

Re:Seven habits of effective text editing (2000) by sevensor on Monday October 23, 2017 @10:22AM (#15533334)
> I do agree more with you than this comment might suggest

Well spoken, that goes for me too. Something about internet discussions amplifies disagreement!

Re:Seven habits of effective text editing (2000) by kej on Monday October 23, 2017 @01:41PM (#15535138)
>Vim/emacs/kaoune might be superior

My google-fu is failing me; what is kaoune?

Re:Seven habits of effective text editing (2000) by Pete_D on Monday October 23, 2017 @02:05PM (#15535404)
Parent probably meant Kakoune: http://kakoune.org
Re:Seven habits of effective text editing (2000) by sevensor on Monday October 23, 2017 @02:12PM (#15535472)
Indeed I did. Kak is great, especially if you find yourself often using visual mode in vim.
Re:Seven habits of effective text editing (2000) by oblio on Monday October 23, 2017 @10:39AM (#15533474)
> That may only feel natural if you play a lot of FPS games.

Or almost any kind of PC games. There is learning curve to using a mouse, but it is quite short and once you're over the hump you can use the mouse without thinking about it. The cognitive overhead of the mouse is minimal. There are studies about this: http://www.asktog.com/TOI/toi22KeyboardVMouse2.html

Re:Seven habits of effective text editing (2000) by dredmorbius on Monday October 23, 2017 @09:36AM (#15533047)
Reaquiring the cursor is an issue for me on systems that "helpfully" make vim mouse (or touchscreen) sensitive.

The cursor's where I left it, damnit. Don't move it and force me to put it back.

There are times when directly pointing to screen elements is useful. Working with text I almost always find it gets in the way

Re:Seven habits of effective text editing (2000) by pmoriarty on Monday October 23, 2017 @12:57PM (#15534654)
"I've played FPS games where I had to target something the size of < 10 pixels, in less than a second, and the need to move my mouse from one end of the mouse pad to the other."

Do you type with just one hand? Because that's what you'd need to do to replicate that performance while coding.

If you type with both hands, now you have to add in the time it takes you to move one hand from the keyboard to the mouse, make the mouse motion (which could be far across the screen) and then back to the keyboard, repeating that cycle for every single operation which involves the mouse.

Meanwhile, someone who knows vim well and is not reliant on the mouse can type with both hands and only has to move their fingers.

Re:Seven habits of effective text editing (2000) by foldr on Monday October 23, 2017 @01:54PM (#15535301)
I have my mouse right next to my keyboard (don't most people?). I can grab it about as quickly a I can press a key.
Re:Seven habits of effective text editing (2000) by pmoriarty on Monday October 23, 2017 @02:06PM (#15535413)
Even if that's true (which is doubtful, as the motion to press a key is much shorter than to move one's arm all the way off a keyboard to the mouse), then you still have the additional time it takes to move the mouse to where it needs to go, and then the time it takes to move your arm back to the keyboard.

There's no way that's going to be as fast. It's also going to be a lot more tiring, if you do that a lot, than merely moving your fingers.

Re:Seven habits of effective text editing (2000) by foldr on Monday October 23, 2017 @02:51PM (#15535868)
Sure, but you usually have to press a bunch of keys in just the right sequence to do the equivalent with the keyboard.

Some things are quicker to do with the mouse and some things are quicker to do using keyboard shortcuts. I don't understand why people take such absolutist positions on this.

My arm doesn't get tired from moving a few inches to grab the mouse.

Re:Seven habits of effective text editing (2000) by pmoriarty on Monday October 23, 2017 @03:10PM (#15536040)
"you usually have to press a bunch of keys in just the right sequence to do the equivalent with the keyboard"

Compared to a veteran vim/emacs user, you'd to do a whole ton of mouse movements to get the same effect of a few keystrokes.

"Some things are quicker to do with the mouse and some things are quicker to do using keyboard shortcuts."

The only things I've found to be quicker to do with the mouse are doing things like drawing in Photoshop/GIMP/Inkscape, or interacting with GUI applications which don't have keyboard shortcuts for most of their functions. Text editing and coding, on the other hand, tends to be much faster, sometimes exponentially faster, than the mouse.

Re:Seven habits of effective text editing (2000) by foldr on Tuesday October 24, 2017 @11:18AM (#15542190)
>Compared to a veteran vim/emacs user, you'd to do a whole ton of mouse movements to get the same effect of a few keystrokes.

Depends on what you're doing. Again with the absolutism!

Re:Seven habits of effective text editing (2000) by jstimpfle on Monday October 23, 2017 @02:23PM (#15535567)
This can not be overstated. I haven't seen many GUI type programmers programming in my live, but none of them was faster than "slow". I die of impatience when I watch them edit.