Karsten Hopp 90c6e3
To: vim_dev@googlegroups.com
Karsten Hopp 90c6e3
Subject: Patch 7.3.608
Karsten Hopp 90c6e3
Fcc: outbox
Karsten Hopp 90c6e3
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 90c6e3
Mime-Version: 1.0
Karsten Hopp 90c6e3
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 90c6e3
Content-Transfer-Encoding: 8bit
Karsten Hopp 90c6e3
------------
Karsten Hopp 90c6e3
Karsten Hopp 90c6e3
Patch 7.3.608
Karsten Hopp 90c6e3
Problem:    winrestview() does not always restore the view correctly.
Karsten Hopp 90c6e3
Solution:   Call win_new_height() and win_new_width(). (Lech Lorens)
Karsten Hopp 90c6e3
Files:	    src/eval.c, src/proto/window.pro, src/window.c
Karsten Hopp 90c6e3
Karsten Hopp 90c6e3
Karsten Hopp 90c6e3
*** ../vim-7.3.607/src/eval.c	2012-07-16 19:27:25.000000000 +0200
Karsten Hopp 90c6e3
--- src/eval.c	2012-07-19 17:50:16.000000000 +0200
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 18601,18606 ****
Karsten Hopp 90c6e3
--- 18601,18610 ----
Karsten Hopp 90c6e3
  	curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol");
Karsten Hopp 90c6e3
  
Karsten Hopp 90c6e3
  	check_cursor();
Karsten Hopp 90c6e3
+ 	win_new_height(curwin, curwin->w_height);
Karsten Hopp 90c6e3
+ # ifdef FEAT_VERTSPLIT
Karsten Hopp 90c6e3
+ 	win_new_width(curwin, W_WIDTH(curwin));
Karsten Hopp 90c6e3
+ # endif
Karsten Hopp 90c6e3
  	changed_window_setting();
Karsten Hopp 90c6e3
  
Karsten Hopp 90c6e3
  	if (curwin->w_topline == 0)
Karsten Hopp 90c6e3
*** ../vim-7.3.607/src/proto/window.pro	2012-06-13 14:28:16.000000000 +0200
Karsten Hopp 90c6e3
--- src/proto/window.pro	2012-07-19 18:05:10.000000000 +0200
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 51,56 ****
Karsten Hopp 90c6e3
--- 51,58 ----
Karsten Hopp 90c6e3
  void win_setminheight __ARGS((void));
Karsten Hopp 90c6e3
  void win_drag_status_line __ARGS((win_T *dragwin, int offset));
Karsten Hopp 90c6e3
  void win_drag_vsep_line __ARGS((win_T *dragwin, int offset));
Karsten Hopp 90c6e3
+ void win_new_height __ARGS((win_T *wp, int height));
Karsten Hopp 90c6e3
+ void win_new_width __ARGS((win_T *wp, int width));
Karsten Hopp 90c6e3
  void win_comp_scroll __ARGS((win_T *wp));
Karsten Hopp 90c6e3
  void command_height __ARGS((void));
Karsten Hopp 90c6e3
  void last_status __ARGS((int morewin));
Karsten Hopp 90c6e3
*** ../vim-7.3.607/src/window.c	2012-07-16 17:31:48.000000000 +0200
Karsten Hopp 90c6e3
--- src/window.c	2012-07-19 18:05:18.000000000 +0200
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 54,60 ****
Karsten Hopp 90c6e3
  static void frame_insert __ARGS((frame_T *before, frame_T *frp));
Karsten Hopp 90c6e3
  static void frame_remove __ARGS((frame_T *frp));
Karsten Hopp 90c6e3
  #ifdef FEAT_VERTSPLIT
Karsten Hopp 90c6e3
- static void win_new_width __ARGS((win_T *wp, int width));
Karsten Hopp 90c6e3
  static void win_goto_ver __ARGS((int up, long count));
Karsten Hopp 90c6e3
  static void win_goto_hor __ARGS((int left, long count));
Karsten Hopp 90c6e3
  #endif
Karsten Hopp 90c6e3
--- 54,59 ----
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 71,77 ****
Karsten Hopp 90c6e3
  
Karsten Hopp 90c6e3
  static win_T *win_alloc __ARGS((win_T *after, int hidden));
Karsten Hopp 90c6e3
  static void set_fraction __ARGS((win_T *wp));
Karsten Hopp 90c6e3
- static void win_new_height __ARGS((win_T *wp, int height));
Karsten Hopp 90c6e3
  
Karsten Hopp 90c6e3
  #define URL_SLASH	1		/* path_is_url() has found "://" */
Karsten Hopp 90c6e3
  #define URL_BACKSLASH	2		/* path_is_url() has found ":\\" */
Karsten Hopp 90c6e3
--- 70,75 ----
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 5557,5563 ****
Karsten Hopp 90c6e3
   * This takes care of the things inside the window, not what happens to the
Karsten Hopp 90c6e3
   * window position, the frame or to other windows.
Karsten Hopp 90c6e3
   */
Karsten Hopp 90c6e3
!     static void
Karsten Hopp 90c6e3
  win_new_height(wp, height)
Karsten Hopp 90c6e3
      win_T	*wp;
Karsten Hopp 90c6e3
      int		height;
Karsten Hopp 90c6e3
--- 5555,5561 ----
Karsten Hopp 90c6e3
   * This takes care of the things inside the window, not what happens to the
Karsten Hopp 90c6e3
   * window position, the frame or to other windows.
Karsten Hopp 90c6e3
   */
Karsten Hopp 90c6e3
!     void
Karsten Hopp 90c6e3
  win_new_height(wp, height)
Karsten Hopp 90c6e3
      win_T	*wp;
Karsten Hopp 90c6e3
      int		height;
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 5697,5703 ****
Karsten Hopp 90c6e3
  /*
Karsten Hopp 90c6e3
   * Set the width of a window.
Karsten Hopp 90c6e3
   */
Karsten Hopp 90c6e3
!     static void
Karsten Hopp 90c6e3
  win_new_width(wp, width)
Karsten Hopp 90c6e3
      win_T	*wp;
Karsten Hopp 90c6e3
      int		width;
Karsten Hopp 90c6e3
--- 5695,5701 ----
Karsten Hopp 90c6e3
  /*
Karsten Hopp 90c6e3
   * Set the width of a window.
Karsten Hopp 90c6e3
   */
Karsten Hopp 90c6e3
!     void
Karsten Hopp 90c6e3
  win_new_width(wp, width)
Karsten Hopp 90c6e3
      win_T	*wp;
Karsten Hopp 90c6e3
      int		width;
Karsten Hopp 90c6e3
*** ../vim-7.3.607/src/version.c	2012-07-19 17:39:01.000000000 +0200
Karsten Hopp 90c6e3
--- src/version.c	2012-07-19 17:53:37.000000000 +0200
Karsten Hopp 90c6e3
***************
Karsten Hopp 90c6e3
*** 716,717 ****
Karsten Hopp 90c6e3
--- 716,719 ----
Karsten Hopp 90c6e3
  {   /* Add new patch number below this line */
Karsten Hopp 90c6e3
+ /**/
Karsten Hopp 90c6e3
+     608,
Karsten Hopp 90c6e3
  /**/
Karsten Hopp 90c6e3
Karsten Hopp 90c6e3
-- 
Karsten Hopp 90c6e3
Although the scythe isn't pre-eminent among the weapons of war, anyone who
Karsten Hopp 90c6e3
has been on the wrong end of, say, a peasants' revolt will know that in
Karsten Hopp 90c6e3
skilled hands it is fearsome.
Karsten Hopp 90c6e3
					-- (Terry Pratchett, Mort)
Karsten Hopp 90c6e3
Karsten Hopp 90c6e3
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 90c6e3
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 90c6e3
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 90c6e3
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///