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". In fact, it is a very bad usage, IMHO, and a bad habit ;) > So it is still useful (I like having an easy way to go to the last > window), but it might be "not by design", i.e., a bug which I choose to > treat as an undocumented feature. Which, moreover, won't always work... -- 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 -~----------~----~----~----~------~----~------~--~---
