Hi Jonathon, 2009/1/9 Jonathon Mah <[email protected]>: > > Have some patches. 1 and 2 are trivial fixes.
Thanks, I will merge this asap. Nice that you picked up on my "TODO comment" in patch 2. ;-) > With 4, I've tried to hack my way through getting scrollbind to work > when scrolling unfocussed windows (the one not containing the cursor). > This was annoying me, because when I had a vert split diff open, my > mouse wheel wouldn't scroll both windows in sync half the time (when > my mouse cursor was over the inactive pane). This patch contains > changes exclusively from the Vim tree. This being my first venture > into that code, someone more familiar with the codebase should > definitely review it before it gets accepted. I just did some > superficial testing, and it seemed to work, but I don't know the > nuances of scrollbind. > > Should this go into the Vim tree, or MacVim? It's a bigger issue on > Mac OS X than on other platforms, since on Windows, the scroll wheel > scrolls the focussed window, not the one under the cursor. (I didn't > try any Linux WMs.) This patch has to go to the vim_dev list for Bram to look at since the changes are to the Vim source code only. You should send it in the format preferred by Bram as well, I usually look at the following link on how to do this: http://vim.wikia.com/wiki/How_to_make_and_submit_a_patch I can't really offer any feedback as I know nothing about scrollbind. :( > Patch 3 is a one-liner that I'm not completely comfortable with. It > makes a call to read the viminfo when a preloaded Vim instance is > taken and run. I'll give some background for why I did it: I was doing > some stuff where I opened a few files in a Vim instance, made some > changes, then closed the instance. I was repeating this several times. > Quickstart was on, and I noticed that my registers were oscillating > between two sets. After working in one instance, changing some > registers, and closing it, those registers were written to my viminfo. > When I opened another instance, it was already preloaded with an old > viminfo, so the changes weren't there. But opening this instance > caused another to preload in the background, getting the new viminfo > with the changed registers again. Closing the second instance > overwrites the viminfo again, and so it continues. I understand what the problem is and I think the best way to deal with it is the same way I deal with [g]vimrc files. All you have to do is to add a couple of lines to -[MMAppController rcFilesModificationDate] (it should be completely straightforward so please send me a patch that you have tested yourself). (Hmmm...you really should test that this has no negative side-effects first...I'm not sure on how often and when the viminfo file changes. If it changes a lot then this "fix" may effectively render quickstart useless. Be careful.) > The reason I'm unhappy about this patch is because it raises two > issues. First, should this be folded into a more general hook that's > called when an instance is about to be used? And second, should we > attempt to unify the viminfo across instances? I could imagine that > when an instance is deactivated (i.e. when it's no longer the active > window), it writes its viminfo, and the next instance to be activated > reads it. (This could be tricky, because the newly-activated instance > would have to wait until the previous one had finished writing.) I think this will all be taken care of by the above suggestion. (?) > And finally, I'm working on some changes to drag and drop (getting my > beloved "replace dropped buffer" feature back). It's not done yet, and > the discussion from 2008-07 ("Open files in ...?") are scaring me. Great, just let me know if you have any questions and I'll try to help as best I can. Björn --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_mac" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
