Liu Yubao wrote:

> Bram Moolenaar wrote:
> > Yegappan Lakshmanan wrote:
> > 
> >> On 11/22/06, Bram Moolenaar <[EMAIL PROTECTED]> wrote:
> >>> It does happen for me:
> >>>
> >>>         "gvim somefile"
> >>>         maximize gvim window
> >>>         minimize gvim window
> >>>         "gvim --remote-tab otherfile"
> >>>
> >>> Now I only see the tab label for "otherfile".  I can click on the gap
> >>> before it to go to "somefile", and then only that label is shown.
> >>>
> >> Which version of MS-Windows (Win98/WinME/Win2K/WinXP/Vista)
> >> are you using? I am not able to reproduce this problem using the
> >> above steps on WinXP and Win2K.
> >>
> >> I am using the following version of Vim:
> >>
> >> VIM - Vi IMproved 7.0 (2006 May 7, compiled May  7 2006 16:21:39)
> >> MS-Windows 32 bit GUI version
> >> Compiled by [EMAIL PROTECTED]
> >> Big version with GUI.  Features included (+) or not (-):
> >>
> >> Anybody else seeing this problem on MS-Windows?
> > 
> > It apparently only happens when 'encoding' is set to "utf-8".  Can you
> > reproduce it then?
> > 
> 
> I think I got it. In gui_w48.c:gui_mch_update_tabline(),
> SendMessage(...TCM_INSERTITEMW...) is called at line 2408
> but TabCtrl_SetItem(...) at line 2416. I'm a little confused
> why it sends an INSERT message but not a SET one too.
> 
> Index: gui_w48.c
> ===================================================================
> --- gui_w48.c (revision 184)
> +++ gui_w48.c (working copy)
> @@ -2405,7 +2405,7 @@
>               tiw.mask = TCIF_TEXT;
>               tiw.iImage = -1;
>               tiw.pszText = wstr;
> -             SendMessage(s_tabhwnd, TCM_INSERTITEMW, (WPARAM)nr,
> +             SendMessage(s_tabhwnd, TCM_SETITEMW, (WPARAM)nr,
>                                                               (LPARAM)&tiw);
>               vim_free(wstr);
>           }

That indeed appears to fix the problem.  Thanks!

-- 
Yah, well, we had to carve our electrons out of driftwood we'd
find.  In the winter.  Uphill.  Both ways.

 /// Bram Moolenaar -- [EMAIL PROTECTED] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

Reply via email to