Saluton Tony :) >> On Sun 12 Apr 2009 19:33 +0200, Tony Mechelynck<[email protected]> dixit: >>>>> Looks like $ does mean "maximum possible" but . doesn't mean "current >>>>> window" — maybe it still means "current line". >>>>> >>>>> Bram, do you think this use with $ is worth documenting? And y'all >>>>> people, what do you think? >>>> >>>> I think it is worth documenting. If I ever use '$' in that context, >>>> probably I would be using things like '.' and '-4' (to cite your >>>> examples) soon, and I would spend some time trying to understand why >>>> they don't work if '$' does. If, according to the documentation, '$' is >>>> an exception, a shortcut, in that context (wincmd, I mean), then it >>>> seems natural that other "special" count values don't work. >>> >>> On closer examination, $ in this context still means "the number of >>> lines in the current window" -- but if it exceeds the total number of >>> windows, ":$wincmd w" falls back to the last window. >> >> Then I think that it's better not to document this unintended behaviour. >> The fact that it works is that usually it is bigger than the number of >> current windows, but not always: if you are on a window with no lines >> and you use '$', you won't get the last window with ":$wincmd w". [...] > Well, I guess I "should" be using 99^Ww then... There goes one more > bright idea. However it _could_ be documented that counts in excess of > the number of windows go to the bottom-right window, what do you think? > That would be something which "will always work".
Dunno. If you know exactly the number of windows you have (which looks improbable), then you can use that number. If you don't know the exact number, but you know the order of magnitude, you may be able to use maybe 9 or even 99 as the count, which for me are easier to type that $ in the context of a count. Of course, is a personal opinion, or a matter of taste. Probably documenting that counts in the excess of the number of windows go to the bottom-right window won't do any harm, since it doesn't invite to use '$' as a synonim for "last window". -- Raúl "DervishD" Núñez de Arenas Coronado Linux Registered User 88736 | http://www.dervishd.net It's my PC and I'll cry if I want to... RAmen! --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
