vim-patch:9.1.0147: Cannot keep a buffer focused in a window

Problem:  Cannot keep a buffer focused in a window
          (Amit Levy)
Solution: Add the 'winfixbuf' window-local option
          (Colin Kennedy)

fixes:  vim/vim#6445
closes: vim/vim#13903

2157035637

N/A patch:
vim-patch:58f1e5c0893a
This commit is contained in:
Colin Kennedy
2023-12-25 20:41:09 -08:00
committed by zeertzjq
parent a09ddd7ce5
commit 141182d6c6
27 changed files with 3414 additions and 23 deletions

View File

@@ -3564,8 +3564,10 @@ static char *get_line_and_copy(linenr_T lnum, char *buf)
/// @param action What to do when we find it
/// @param start_lnum first line to start searching
/// @param end_lnum last line for searching
/// @param forceit If true, always switch to the found path
void find_pattern_in_path(char *ptr, Direction dir, size_t len, bool whole, bool skip_comments,
int type, int count, int action, linenr_T start_lnum, linenr_T end_lnum)
int type, int count, int action, linenr_T start_lnum, linenr_T end_lnum,
int forceit)
{
SearchedFile *files; // Stack of included files
SearchedFile *bigger; // When we need more space
@@ -4025,7 +4027,7 @@ search_line:
break;
}
if (!GETFILE_SUCCESS(getfile(curwin_save->w_buffer->b_fnum, NULL,
NULL, true, lnum, false))) {
NULL, true, lnum, forceit))) {
break; // failed to jump to file
}
} else {
@@ -4035,7 +4037,7 @@ search_line:
check_cursor();
} else {
if (!GETFILE_SUCCESS(getfile(0, files[depth].name, NULL, true,
files[depth].lnum, false))) {
files[depth].lnum, forceit))) {
break; // failed to jump to file
}
// autocommands may have changed the lnum, we don't