Patch 8.0.1167
Problem:    Motif: typing in terminal window is slow.
Solution:   Do not redraw the whole terminal window but only was was changed.
Files:      src/terminal.c


*** ../vim-8.0.1166/src/terminal.c      2017-09-26 13:59:27.192906625 +0200
--- src/terminal.c      2017-09-30 20:39:22.875670335 +0200
***************
*** 41,46 ****
--- 41,47 ----
   * - in GUI vertical split causes problems.  Cursor is flickering. (Hirohito
   *   Higashi, 2017 Sep 19)
   * - Shift-Tab does not work.
+  * - after resizing windows overlap. (Boris Staletic, #2164)
   * - double click in Window toolbar starts Visual mode.
   * - Redirecting output does not work on MS-Windows, 
Test_terminal_redir_file()
   *   is disabled.
***************
*** 134,140 ****
      char_u    *tl_status_text; /* NULL or allocated */
  
      /* Range of screen rows to update.  Zero based. */
!     int               tl_dirty_row_start; /* -1 if nothing dirty */
      int               tl_dirty_row_end;   /* row below last one to update */
  
      garray_T  tl_scrollback;
--- 135,141 ----
      char_u    *tl_status_text; /* NULL or allocated */
  
      /* Range of screen rows to update.  Zero based. */
!     int               tl_dirty_row_start; /* MAX_ROW if nothing dirty */
      int               tl_dirty_row_end;   /* row below last one to update */
  
      garray_T  tl_scrollback;
***************
*** 1925,1930 ****
--- 1926,1935 ----
                                 clear_attr);
        }
      }
+ 
+     term->tl_dirty_row_start = MIN(term->tl_dirty_row_start, dest.start_row);
+     term->tl_dirty_row_end = MIN(term->tl_dirty_row_end, dest.end_row);
+ 
      redraw_buf_later(term->tl_buffer, NOT_VALID);
      return 1;
  }
***************
*** 2268,2275 ****
      vterm_state_get_cursorpos(state, &pos);
      position_cursor(wp, &pos);
  
!     /* TODO: Only redraw what changed. */
!     for (pos.row = 0; pos.row < wp->w_height; ++pos.row)
      {
        int off = screen_get_current_line_off();
        int max_col = MIN(wp->w_width, term->tl_cols);
--- 2273,2280 ----
      vterm_state_get_cursorpos(state, &pos);
      position_cursor(wp, &pos);
  
!     for (pos.row = term->tl_dirty_row_start; pos.row < term->tl_dirty_row_end
!                                         && pos.row < wp->w_height; ++pos.row)
      {
        int off = screen_get_current_line_off();
        int max_col = MIN(wp->w_width, term->tl_cols);
***************
*** 2352,2357 ****
--- 2357,2364 ----
        screen_line(wp->w_winrow + pos.row, wp->w_wincol,
                                                  pos.col, wp->w_width, FALSE);
      }
+     term->tl_dirty_row_start = MAX_ROW;
+     term->tl_dirty_row_end = 0;
  
      return OK;
  }
*** ../vim-8.0.1166/src/version.c       2017-09-30 20:04:31.636688591 +0200
--- src/version.c       2017-09-30 20:38:41.775926488 +0200
***************
*** 763,764 ****
--- 763,766 ----
  {   /* Add new patch number below this line */
+ /**/
+     1167,
  /**/

-- 
You can tune a file system, but you can't tuna fish
                                                        -- man tunefs

 /// Bram Moolenaar -- [email protected] -- 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    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui