Bug#450481: [Patch] Improved popup-menu alignment

James Vega jamessan at debian.org
Wed Jul 30 21:07:47 UTC 2008


On Wed, Jul 30, 2008 at 10:43:24PM +0200, Bram Moolenaar wrote:
> 
> James -
> 
> > When completing a word near the edge of the window, the completion list
> > gets truncated if there's not enough room to display the full width.  The
> > attached patch adds a condition to the display logic which, if there's
> > room, will anchor the right edge of the popup-menu to the cursor
> > position instead of the left edge.
> 
> Hmm, not sure if this will look right.  The idea is that the completed
> word is straight under the replaced word.  And I thought the window was
> already moved leftwards to avoid truncation.  Need to look into this,

I think the menu is moved to accomodate the default width of the pum,
but that still may truncate items in the list.  This still moves the
menu out from directly under the cursor.

With my patch, the pum is still anchored on the cursor but the anchor is
at the right edge instead of the left edge (or the slight adjustment
made to display the default width).  I think the positive aspect of
displaying the full completions is worth the negative aspect of moving
the pum (and in fact only came up with this patch in response to
<http://bugs.debian.org/450481>).

> I'll put it in the todo list.

Thanks for considering it.

-- 
James
GPG Key: 1024D/61326D40 2003-09-02 James Vega <jamessan at debian.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
Url : http://lists.alioth.debian.org/pipermail/pkg-vim-maintainers/attachments/20080730/0ae41364/attachment.pgp 


More information about the pkg-vim-maintainers mailing list