Hi All,

2017-1-24(Tue) 2:03:05 UTC+9 Zhen-Huan (Kenny) Hu:
> else if (ins_compl_active())
> 
> 
> 
> buf[1] = pum_visible() ? 'C' : 'c';
> 
> 
> 
> 
> 
> Does this 'C' vs. 'c' mean whether a completion was successful? I don't think 
> pum_visible() alone is able to determine this accurately since it depends on 
> whether the user have completeopt=menuone to have a menu if there is only one 
> match. I'd rather not distinguish it in mode() and let it return 'ic' if 
> ins_compl_active() no matther whether pum_visible().


I was also thinking somewhat similar.

It's a idea level proposal.
Adding completion info built-in function ...

completion_info()
    Returns a Dictionary with information about insert mode completion:
    "active"                When completion is active, set to 1.
    "matches"               Numner of matches.
    "Searching_match_done"  Searching match done.
    "popupmenued"           Popup menu displayed.
    "inserted"              Insert a match from the menu.
    "selected"              Select a match in the menu.
    "ctrl_x_selecting"      Waiting for the ctrl-x mode selection.
    ...

--
Best regards,
Hirohito Higashi (a.k.a. h_east)

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui