Re: vim7: completeopt=menu sort order
- View SourceOn 11/11/05, Martin Stubenschrott <stubenschrott@...> wrote:
>As Bram is on vacation, we may not see the next Vim7 alpha snapshot
> As a sidenote: does anybody know, when there will be a new vim alpha snapshot
> (7.00.157 is quite old now - 1 month withouth any checkins)?
for another two to three weeks.
- View SourceJohannes Zellner wrote:
> 1. is it possible to change the sort order for the completeopt menu?The order is what the completion function returns. When using CTRL-P
> Currently the first (automatically selected) menu entry is placed
> at the bottom of the menu, but I'd rather like it to be at the top.
(previous) the last match is selected, with CTRL-N the first match is
selected. Otherwise the ordering of matches would depend on whether you
use CTRL-N or CTRL-P
> 2. wouldn't a frame (e.g. by those thin ACS lines) nice?On what terminals would that work?
hundred-and-one symptoms of being an internet addict:
99. The hum of a cooling fan and the click of keys is comforting to you.
/// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
/// Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ Project leader for A-A-P -- http://www.A-A-P.org ///
\\\ Buy LOTR 3 and help AIDS victims -- http://ICCF.nl/lotr.html ///
- View SourceOn Sat, Nov 19, 2005 at 05:39:23PM +0100, Bram Moolenaar wrote:
>I'd really like to have an option here! When using CTRL-P (which I
> Johannes Zellner wrote:
> > 1. is it possible to change the sort order for the completeopt menu?
> > Currently the first (automatically selected) menu entry is placed
> > at the bottom of the menu, but I'd rather like it to be at the top.
> The order is what the completion function returns. When using CTRL-P
> (previous) the last match is selected, with CTRL-N the first match is
> selected. Otherwise the ordering of matches would depend on whether you
> use CTRL-N or CTRL-P
usually do, as it takes what I typed most recently) the completion menu
appears below the cursor but the first selected item of the completion
menu is at the bottom of the menu -- so it's far away from the current
line, which I find quite annoying. If you insist on this ordering, I'd
propose at least that in the case of typing CTRL-P, the menu should then
preferable (if there's enough space) appear ABOVE the current line, so
the closest match (for backward searching CTRL-P) which is displayed at
the bottom of the menu is again closest to the cursor.
What about stuff like
" place menu above current line if enough space
" always order the completion matches so that the first match is at
" the top, no matter if CTRL-P or CTRL-N was typed.
Well, the option names are a bit lengthy, but you get the point.