File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -452,24 +452,22 @@ apply_move_options(win_T *wp, dict_T *d)
452452 wp -> w_popup_prop_type = 0 ;
453453 if (* str != NUL )
454454 {
455- nr = find_prop_type_id (str , wp -> w_buffer );
455+ wp -> w_popup_prop_win = curwin ;
456+ di = dict_find (d , (char_u * )"textpropwin" , -1 );
457+ if (di != NULL )
458+ {
459+ wp -> w_popup_prop_win = find_win_by_nr_or_id (& di -> di_tv );
460+ if (!win_valid (wp -> w_popup_prop_win ))
461+ wp -> w_popup_prop_win = curwin ;
462+ }
463+
464+ nr = find_prop_type_id (str , wp -> w_popup_prop_win -> w_buffer );
456465 if (nr <= 0 )
457466 nr = find_prop_type_id (str , NULL );
458467 if (nr <= 0 )
459468 semsg (_ (e_invarg2 ), str );
460469 else
461- {
462470 wp -> w_popup_prop_type = nr ;
463- wp -> w_popup_prop_win = curwin ;
464-
465- di = dict_find (d , (char_u * )"textpropwin" , -1 );
466- if (di != NULL )
467- {
468- wp -> w_popup_prop_win = find_win_by_nr_or_id (& di -> di_tv );
469- if (win_valid (wp -> w_popup_prop_win ))
470- wp -> w_popup_prop_win = curwin ;
471- }
472- }
473471 }
474472 }
475473
Original file line number Diff line number Diff line change @@ -13,10 +13,11 @@ func Test_textprop_popup()
1313 50
1414 normal zz
1515 set scrolloff = 0
16- call prop_type_add (' popupMarker' , #{highlight : ' DiffAdd' })
16+ call prop_type_add (' popupMarker' , #{highlight : ' DiffAdd' , bufnr : bufnr ( ' % ' ) })
1717 call prop_add (50 , 11 , #{
1818 \ length: 7 ,
1919 \ type : ' popupMarker' ,
20+ \ bufnr : bufnr (' %' ),
2021 \ })
2122 let winid = popup_create (' the text' , #{
2223 \ pos: ' botleft' ,
@@ -68,6 +69,7 @@ func Test_textprop_popup_corners()
6869 let winid = popup_create (' bottom left' , #{
6970 \ pos: ' botleft' ,
7071 \ textprop: ' popupMarker' ,
72+ \ textpropwin: win_getid (),
7173 \ padding: [0 ,1 ,0 ,1 ],
7274 \ })
7375 let winid = popup_create (' bottom right' , #{
Original file line number Diff line number Diff line change @@ -741,6 +741,8 @@ static char *(features[]) =
741741
742742static int included_patches [] =
743743{ /* Add new patch number below this line */
744+ /**/
745+ 2307 ,
744746/**/
745747 2306 ,
746748/**/
You can’t perform that action at this time.
0 commit comments