Patch 8.1.1596

18 views
Skip to first unread message

Bram Moolenaar

unread,
Jun 25, 2019, 7:06:26 PM6/25/19
to vim...@googlegroups.com

Patch 8.1.1596
Problem: When resizing the screen may draw popup in wrong position. (Masato
Nishihata)
Solution: Check the popup is not outside of the screen. (fixes #4592)
Files: src/popupwin.c


*** ../vim-8.1.1595/src/popupwin.c 2019-06-25 05:15:15.188891898 +0200
--- src/popupwin.c 2019-06-26 00:54:52.027896829 +0200
***************
*** 2154,2161 ****
wp->w_winrow += top_off;
wp->w_wincol += left_off;

! // Draw the popup text.
! win_update(wp);

wp->w_winrow -= top_off;
wp->w_wincol -= left_off;
--- 2154,2162 ----
wp->w_winrow += top_off;
wp->w_wincol += left_off;

! // Draw the popup text, unless it's off screen.
! if (wp->w_winrow < screen_Rows && wp->w_wincol < screen_Columns)
! win_update(wp);

wp->w_winrow -= top_off;
wp->w_wincol -= left_off;
*** ../vim-8.1.1595/src/version.c 2019-06-26 00:34:10.456712240 +0200
--- src/version.c 2019-06-26 00:57:46.971238922 +0200
***************
*** 779,780 ****
--- 779,782 ----
{ /* Add new patch number below this line */
+ /**/
+ 1596,
/**/

--
"Time flies like an arrow". So I put an arrow on my desk, now
awaiting one of these time flies showing up.

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

Tony Mechelynck

unread,
Jun 25, 2019, 9:03:09 PM6/25/19
to Bram Moolenaar, vim_dev
On Wed, Jun 26, 2019 at 1:06 AM Bram Moolenaar <Br...@moolenaar.net> wrote:
>
>
> Patch 8.1.1596
> Problem: When resizing the screen may draw popup in wrong position. (Masato
> Nishihata)
> Solution: Check the popup is not outside of the screen. (fixes #4592)
> Files: src/popupwin.c

Warning in Normal, Big and Huge (not in Small or Tiny):

gcc -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_GTK -pthread
-I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include
-I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo
-I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libpng16
-I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0
-I/usr/include/harfbuzz -I/usr/include/pango-1.0
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include
-I/usr/include/freetype2 -O2 -fno-strength-reduce -Wall -D_REENTRANT
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -o objects/popupwin.o
popupwin.c
popupwin.c: In function ‘update_popups’:
popupwin.c:2274:35: warning: ‘sb_thumb_height’ may be used
uninitialized in this function [-Wmaybe-uninitialized]
&& line < sb_thumb_top + sb_thumb_height
~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~

Best regards,
Tony.

Bram Moolenaar

unread,
Jun 25, 2019, 10:06:06 PM6/25/19
to vim...@googlegroups.com, Tony Mechelynck
Hmm, the compiler isn't clever enough to see the condition.
Anyway, will fix that.

--
Ten bugs in the hand is better than one as yet undetected.
Reply all
Reply to author
Forward
0 new messages