1" Test for breakindent 2" 3" Note: if you get strange failures when adding new tests, it might be that 4" while the test is run, the breakindent caching gets in its way. 5" It helps to change the tabstop setting and force a redraw (e.g. see 6" Test_breakindent08()) 7source check.vim 8CheckOption breakindent 9 10source view_util.vim 11 12let s:input ="\tabcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOP" 13 14func s:screen_lines(lnum, width) abort 15 return ScreenLines([a:lnum, a:lnum + 2], a:width) 16endfunc 17 18func s:compare_lines(expect, actual) 19 call assert_equal(join(a:expect, "\n"), join(a:actual, "\n")) 20endfunc 21 22func s:test_windows(...) 23 call NewWindow(10, 20) 24 setl ts=4 sw=4 sts=4 breakindent 25 put =s:input 26 exe get(a:000, 0, '') 27endfunc 28 29func s:close_windows(...) 30 call CloseWindow() 31 exe get(a:000, 0, '') 32endfunc 33 34func Test_breakindent01() 35 " simple breakindent test 36 call s:test_windows('setl briopt=min:0') 37 let lines = s:screen_lines(line('.'),8) 38 let expect = [ 39 \ " abcd", 40 \ " qrst", 41 \ " GHIJ", 42 \ ] 43 call s:compare_lines(expect, lines) 44 call s:close_windows() 45endfunc 46 47func Test_breakindent01_vartabs() 48 " like 01 but with vartabs feature 49 CheckFeature vartabs 50 call s:test_windows('setl briopt=min:0 vts=4') 51 let lines = s:screen_lines(line('.'),8) 52 let expect = [ 53 \ " abcd", 54 \ " qrst", 55 \ " GHIJ", 56 \ ] 57 call s:compare_lines(expect, lines) 58 call s:close_windows('set vts&') 59endfunc 60 61func Test_breakindent02() 62 " simple breakindent test with showbreak set 63 set sbr=>> 64 call s:test_windows('setl briopt=min:0 sbr=') 65 let lines = s:screen_lines(line('.'),8) 66 let expect = [ 67 \ " abcd", 68 \ " >>qr", 69 \ " >>EF", 70 \ ] 71 call s:compare_lines(expect, lines) 72 call s:close_windows('set sbr=') 73endfunc 74 75func Test_breakindent02_vartabs() 76 CheckFeature vartabs 77 " simple breakindent test with showbreak set 78 call s:test_windows('setl briopt=min:0 sbr=>> vts=4') 79 let lines = s:screen_lines(line('.'),8) 80 let expect = [ 81 \ " abcd", 82 \ " >>qr", 83 \ " >>EF", 84 \ ] 85 call s:compare_lines(expect, lines) 86 call s:close_windows('set sbr= vts&') 87endfunc 88 89func Test_breakindent03() 90 " simple breakindent test with showbreak set and briopt including sbr 91 call s:test_windows('setl briopt=sbr,min:0 sbr=++') 92 let lines = s:screen_lines(line('.'),8) 93 let expect = [ 94 \ " abcd", 95 \ "++ qrst", 96 \ "++ GHIJ", 97 \ ] 98 call s:compare_lines(expect, lines) 99 " clean up 100 call s:close_windows('set sbr=') 101endfunc 102 103func Test_breakindent03_vartabs() 104 " simple breakindent test with showbreak set and briopt including sbr 105 CheckFeature vartabs 106 call s:test_windows('setl briopt=sbr,min:0 sbr=++ vts=4') 107 let lines = s:screen_lines(line('.'),8) 108 let expect = [ 109 \ " abcd", 110 \ "++ qrst", 111 \ "++ GHIJ", 112 \ ] 113 call s:compare_lines(expect, lines) 114 " clean up 115 call s:close_windows('set sbr= vts&') 116endfunc 117 118func Test_breakindent04() 119 " breakindent set with min width 18 120 set sbr=<<< 121 call s:test_windows('setl sbr=NONE briopt=min:18') 122 let lines = s:screen_lines(line('.'),8) 123 let expect = [ 124 \ " abcd", 125 \ " qrstuv", 126 \ " IJKLMN", 127 \ ] 128 call s:compare_lines(expect, lines) 129 " clean up 130 call s:close_windows('set sbr=') 131 set sbr= 132endfunc 133 134func Test_breakindent04_vartabs() 135 " breakindent set with min width 18 136 CheckFeature vartabs 137 call s:test_windows('setl sbr= briopt=min:18 vts=4') 138 let lines = s:screen_lines(line('.'),8) 139 let expect = [ 140 \ " abcd", 141 \ " qrstuv", 142 \ " IJKLMN", 143 \ ] 144 call s:compare_lines(expect, lines) 145 " clean up 146 call s:close_windows('set sbr= vts&') 147endfunc 148 149func Test_breakindent05() 150 " breakindent set and shift by 2 151 call s:test_windows('setl briopt=shift:2,min:0') 152 let lines = s:screen_lines(line('.'),8) 153 let expect = [ 154 \ " abcd", 155 \ " qr", 156 \ " EF", 157 \ ] 158 call s:compare_lines(expect, lines) 159 call s:close_windows() 160endfunc 161 162func Test_breakindent05_vartabs() 163 " breakindent set and shift by 2 164 CheckFeature vartabs 165 call s:test_windows('setl briopt=shift:2,min:0 vts=4') 166 let lines = s:screen_lines(line('.'),8) 167 let expect = [ 168 \ " abcd", 169 \ " qr", 170 \ " EF", 171 \ ] 172 call s:compare_lines(expect, lines) 173 call s:close_windows('set vts&') 174endfunc 175 176func Test_breakindent06() 177 " breakindent set and shift by -1 178 call s:test_windows('setl briopt=shift:-1,min:0') 179 let lines = s:screen_lines(line('.'),8) 180 let expect = [ 181 \ " abcd", 182 \ " qrstu", 183 \ " HIJKL", 184 \ ] 185 call s:compare_lines(expect, lines) 186 call s:close_windows() 187endfunc 188 189func Test_breakindent06_vartabs() 190 " breakindent set and shift by -1 191 CheckFeature vartabs 192 call s:test_windows('setl briopt=shift:-1,min:0 vts=4') 193 let lines = s:screen_lines(line('.'),8) 194 let expect = [ 195 \ " abcd", 196 \ " qrstu", 197 \ " HIJKL", 198 \ ] 199 call s:compare_lines(expect, lines) 200 call s:close_windows('set vts&') 201endfunc 202 203func Test_breakindent07() 204 " breakindent set and shift by 1, Number set sbr=? and briopt:sbr 205 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu sbr=? nuw=4 cpo+=n') 206 let lines = s:screen_lines(line('.'),10) 207 let expect = [ 208 \ " 2 ab", 209 \ "? m", 210 \ "? x", 211 \ ] 212 call s:compare_lines(expect, lines) 213 " clean up 214 call s:close_windows('set sbr= cpo-=n') 215endfunc 216 217func Test_breakindent07_vartabs() 218 CheckFeature vartabs 219 " breakindent set and shift by 1, Number set sbr=? and briopt:sbr 220 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu sbr=? nuw=4 cpo+=n vts=4') 221 let lines = s:screen_lines(line('.'),10) 222 let expect = [ 223 \ " 2 ab", 224 \ "? m", 225 \ "? x", 226 \ ] 227 call s:compare_lines(expect, lines) 228 " clean up 229 call s:close_windows('set sbr= cpo-=n vts&') 230endfunc 231 232func Test_breakindent07a() 233 " breakindent set and shift by 1, Number set sbr=? and briopt:sbr 234 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu sbr=? nuw=4') 235 let lines = s:screen_lines(line('.'),10) 236 let expect = [ 237 \ " 2 ab", 238 \ " ? m", 239 \ " ? x", 240 \ ] 241 call s:compare_lines(expect, lines) 242 " clean up 243 call s:close_windows('set sbr=') 244endfunc 245 246func Test_breakindent07a_vartabs() 247 CheckFeature vartabs 248 " breakindent set and shift by 1, Number set sbr=? and briopt:sbr 249 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu sbr=? nuw=4 vts=4') 250 let lines = s:screen_lines(line('.'),10) 251 let expect = [ 252 \ " 2 ab", 253 \ " ? m", 254 \ " ? x", 255 \ ] 256 call s:compare_lines(expect, lines) 257 " clean up 258 call s:close_windows('set sbr= vts&') 259endfunc 260 261func Test_breakindent08() 262 " breakindent set and shift by 1, Number and list set sbr=# and briopt:sbr 263 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu nuw=4 sbr=# list cpo+=n ts=4') 264 " make sure, cache is invalidated! 265 set ts=8 266 redraw! 267 set ts=4 268 redraw! 269 let lines = s:screen_lines(line('.'),10) 270 let expect = [ 271 \ " 2 ^Iabcd", 272 \ "# opq", 273 \ "# BCD", 274 \ ] 275 call s:compare_lines(expect, lines) 276 call s:close_windows('set sbr= cpo-=n') 277endfunc 278 279func Test_breakindent08_vartabs() 280 CheckFeature vartabs 281 " breakindent set and shift by 1, Number and list set sbr=# and briopt:sbr 282 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu nuw=4 sbr=# list cpo+=n ts=4 vts=4') 283 " make sure, cache is invalidated! 284 set ts=8 285 redraw! 286 set ts=4 287 redraw! 288 let lines = s:screen_lines(line('.'),10) 289 let expect = [ 290 \ " 2 ^Iabcd", 291 \ "# opq", 292 \ "# BCD", 293 \ ] 294 call s:compare_lines(expect, lines) 295 call s:close_windows('set sbr= cpo-=n vts&') 296endfunc 297 298func Test_breakindent08a() 299 " breakindent set and shift by 1, Number and list set sbr=# and briopt:sbr 300 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu nuw=4 sbr=# list') 301 let lines = s:screen_lines(line('.'),10) 302 let expect = [ 303 \ " 2 ^Iabcd", 304 \ " # opq", 305 \ " # BCD", 306 \ ] 307 call s:compare_lines(expect, lines) 308 call s:close_windows('set sbr=') 309endfunc 310 311func Test_breakindent08a_vartabs() 312 CheckFeature vartabs 313 " breakindent set and shift by 1, Number and list set sbr=# and briopt:sbr 314 call s:test_windows('setl briopt=shift:1,sbr,min:0 nu nuw=4 sbr=# list vts=4') 315 let lines = s:screen_lines(line('.'),10) 316 let expect = [ 317 \ " 2 ^Iabcd", 318 \ " # opq", 319 \ " # BCD", 320 \ ] 321 call s:compare_lines(expect, lines) 322 call s:close_windows('set sbr= vts&') 323endfunc 324 325func Test_breakindent09() 326 " breakindent set and shift by 1, Number and list set sbr=# 327 call s:test_windows('setl briopt=shift:1,min:0 nu nuw=4 sbr=# list') 328 let lines = s:screen_lines(line('.'),10) 329 let expect = [ 330 \ " 2 ^Iabcd", 331 \ " #op", 332 \ " #AB", 333 \ ] 334 call s:compare_lines(expect, lines) 335 call s:close_windows('set sbr=') 336endfunc 337 338func Test_breakindent09_vartabs() 339 CheckFeature vartabs 340 " breakindent set and shift by 1, Number and list set sbr=# 341 call s:test_windows('setl briopt=shift:1,min:0 nu nuw=4 sbr=# list vts=4') 342 let lines = s:screen_lines(line('.'),10) 343 let expect = [ 344 \ " 2 ^Iabcd", 345 \ " #op", 346 \ " #AB", 347 \ ] 348 call s:compare_lines(expect, lines) 349 call s:close_windows('set sbr= vts&') 350endfunc 351 352func Test_breakindent10() 353 " breakindent set, Number set sbr=~ 354 call s:test_windows('setl cpo+=n sbr=~ nu nuw=4 nolist briopt=sbr,min:0') 355 " make sure, cache is invalidated! 356 set ts=8 357 redraw! 358 set ts=4 359 redraw! 360 let lines = s:screen_lines(line('.'),10) 361 let expect = [ 362 \ " 2 ab", 363 \ "~ mn", 364 \ "~ yz", 365 \ ] 366 call s:compare_lines(expect, lines) 367 call s:close_windows('set sbr= cpo-=n') 368endfunc 369 370func Test_breakindent10_vartabs() 371 CheckFeature vartabs 372 " breakindent set, Number set sbr=~ 373 call s:test_windows('setl cpo+=n sbr=~ nu nuw=4 nolist briopt=sbr,min:0 vts=4') 374 " make sure, cache is invalidated! 375 set ts=8 376 redraw! 377 set ts=4 378 redraw! 379 let lines = s:screen_lines(line('.'),10) 380 let expect = [ 381 \ " 2 ab", 382 \ "~ mn", 383 \ "~ yz", 384 \ ] 385 call s:compare_lines(expect, lines) 386 call s:close_windows('set sbr= cpo-=n vts&') 387endfunc 388 389func Test_breakindent11() 390 " test strdisplaywidth() 391 call s:test_windows('setl cpo-=n sbr=>> nu nuw=4 nolist briopt= ts=4') 392 let text = getline(2) 393 let width = strlen(text[1:]) + indent(2) + strlen(&sbr) * 3 " text wraps 3 times 394 call assert_equal(width, strdisplaywidth(text)) 395 call s:close_windows('set sbr=') 396 call assert_equal(4, strdisplaywidth("\t", 4)) 397endfunc 398 399func Test_breakindent11_vartabs() 400 CheckFeature vartabs 401 " test strdisplaywidth() 402 call s:test_windows('setl cpo-=n sbr=>> nu nuw=4 nolist briopt= ts=4 vts=4') 403 let text = getline(2) 404 let width = strlen(text[1:]) + 2->indent() + strlen(&sbr) * 3 " text wraps 3 times 405 call assert_equal(width, text->strdisplaywidth()) 406 call s:close_windows('set sbr= vts&') 407endfunc 408 409func Test_breakindent12() 410 " test breakindent with long indent 411 let s:input = "\t\t\t\t\t{" 412 call s:test_windows('setl breakindent linebreak briopt=min:10 nu numberwidth=3 ts=4 list listchars=tab:>-') 413 let lines = s:screen_lines(2,16) 414 let expect = [ 415 \ " 2 >--->--->--->", 416 \ " ---{ ", 417 \ "~ ", 418 \ ] 419 call s:compare_lines(expect, lines) 420 call s:close_windows('set nuw=4 listchars=') 421endfunc 422 423func Test_breakindent12_vartabs() 424 CheckFeature vartabs 425 " test breakindent with long indent 426 let s:input = "\t\t\t\t\t{" 427 call s:test_windows('setl breakindent linebreak briopt=min:10 nu numberwidth=3 ts=4 list listchars=tab:>- vts=4') 428 let lines = s:screen_lines(2,16) 429 let expect = [ 430 \ " 2 >--->--->--->", 431 \ " ---{ ", 432 \ "~ ", 433 \ ] 434 call s:compare_lines(expect, lines) 435 call s:close_windows('set nuw=4 listchars= vts&') 436endfunc 437 438func Test_breakindent13() 439 let s:input = "" 440 call s:test_windows('setl breakindent briopt=min:10 ts=8') 441 vert resize 20 442 call setline(1, [" a\tb\tc\td\te", " z y x w v"]) 443 1 444 norm! fbgj"ayl 445 2 446 norm! fygj"byl 447 call assert_equal('d', @a) 448 call assert_equal('w', @b) 449 call s:close_windows() 450endfunc 451 452func Test_breakindent13_vartabs() 453 CheckFeature vartabs 454 let s:input = "" 455 call s:test_windows('setl breakindent briopt=min:10 ts=8 vts=8') 456 vert resize 20 457 call setline(1, [" a\tb\tc\td\te", " z y x w v"]) 458 1 459 norm! fbgj"ayl 460 2 461 norm! fygj"byl 462 call assert_equal('d', @a) 463 call assert_equal('w', @b) 464 call s:close_windows('set vts&') 465endfunc 466 467func Test_breakindent14() 468 let s:input = "" 469 call s:test_windows('setl breakindent briopt= ts=8') 470 vert resize 30 471 norm! 3a1234567890 472 norm! a abcde 473 exec "norm! 0\<C-V>tex" 474 let lines = s:screen_lines(line('.'),8) 475 let expect = [ 476 \ "e ", 477 \ "~ ", 478 \ "~ ", 479 \ ] 480 call s:compare_lines(expect, lines) 481 call s:close_windows() 482endfunc 483 484func Test_breakindent14_vartabs() 485 CheckFeature vartabs 486 let s:input = "" 487 call s:test_windows('setl breakindent briopt= ts=8 vts=8') 488 vert resize 30 489 norm! 3a1234567890 490 norm! a abcde 491 exec "norm! 0\<C-V>tex" 492 let lines = s:screen_lines(line('.'),8) 493 let expect = [ 494 \ "e ", 495 \ "~ ", 496 \ "~ ", 497 \ ] 498 call s:compare_lines(expect, lines) 499 call s:close_windows('set vts&') 500endfunc 501 502func Test_breakindent15() 503 let s:input = "" 504 call s:test_windows('setl breakindent briopt= ts=8 sw=8') 505 vert resize 30 506 norm! 4a1234567890 507 exe "normal! >>\<C-V>3f0x" 508 let lines = s:screen_lines(line('.'),20) 509 let expect = [ 510 \ " 1234567890 ", 511 \ "~ ", 512 \ "~ ", 513 \ ] 514 call s:compare_lines(expect, lines) 515 call s:close_windows() 516endfunc 517 518func Test_breakindent15_vartabs() 519 CheckFeature vartabs 520 let s:input = "" 521 call s:test_windows('setl breakindent briopt= ts=8 sw=8 vts=8') 522 vert resize 30 523 norm! 4a1234567890 524 exe "normal! >>\<C-V>3f0x" 525 let lines = s:screen_lines(line('.'),20) 526 let expect = [ 527 \ " 1234567890 ", 528 \ "~ ", 529 \ "~ ", 530 \ ] 531 call s:compare_lines(expect, lines) 532 call s:close_windows('set vts&') 533endfunc 534 535func Test_breakindent16() 536 " Check that overlong lines are indented correctly. 537 let s:input = "" 538 call s:test_windows('setl breakindent briopt=min:0 ts=4') 539 call setline(1, "\t".repeat("1234567890", 10)) 540 resize 6 541 norm! 1gg$ 542 redraw! 543 let lines = s:screen_lines(1,10) 544 let expect = [ 545 \ " 789012", 546 \ " 345678", 547 \ " 901234", 548 \ ] 549 call s:compare_lines(expect, lines) 550 let lines = s:screen_lines(4,10) 551 let expect = [ 552 \ " 567890", 553 \ " 123456", 554 \ " 7890 ", 555 \ ] 556 call s:compare_lines(expect, lines) 557 call s:close_windows() 558endfunc 559 560func Test_breakindent16_vartabs() 561 CheckFeature vartabs 562 " Check that overlong lines are indented correctly. 563 let s:input = "" 564 call s:test_windows('setl breakindent briopt=min:0 ts=4 vts=4') 565 call setline(1, "\t".repeat("1234567890", 10)) 566 resize 6 567 norm! 1gg$ 568 redraw! 569 let lines = s:screen_lines(1,10) 570 let expect = [ 571 \ " 789012", 572 \ " 345678", 573 \ " 901234", 574 \ ] 575 call s:compare_lines(expect, lines) 576 let lines = s:screen_lines(4,10) 577 let expect = [ 578 \ " 567890", 579 \ " 123456", 580 \ " 7890 ", 581 \ ] 582 call s:compare_lines(expect, lines) 583 call s:close_windows('set vts&') 584endfunc 585 586func Test_breakindent17_vartabs() 587 CheckFeature vartabs 588 let s:input = "" 589 call s:test_windows('setl breakindent list listchars=tab:<-> showbreak=+++') 590 call setline(1, "\t" . repeat('a', 63)) 591 vert resize 30 592 norm! 1gg$ 593 redraw! 594 let lines = s:screen_lines(1, 30) 595 let expect = [ 596 \ "<-->aaaaaaaaaaaaaaaaaaaaaaaaaa", 597 \ " +++aaaaaaaaaaaaaaaaaaaaaaa", 598 \ " +++aaaaaaaaaaaaaa ", 599 \ ] 600 call s:compare_lines(expect, lines) 601 call s:close_windows('set breakindent& list& listchars& showbreak&') 602endfunc 603 604func Test_breakindent18_vartabs() 605 CheckFeature vartabs 606 let s:input = "" 607 call s:test_windows('setl breakindent list listchars=tab:<->') 608 call setline(1, "\t" . repeat('a', 63)) 609 vert resize 30 610 norm! 1gg$ 611 redraw! 612 let lines = s:screen_lines(1, 30) 613 let expect = [ 614 \ "<-->aaaaaaaaaaaaaaaaaaaaaaaaaa", 615 \ " aaaaaaaaaaaaaaaaaaaaaaaaaa", 616 \ " aaaaaaaaaaa ", 617 \ ] 618 call s:compare_lines(expect, lines) 619 call s:close_windows('set breakindent& list& listchars&') 620endfunc 621 622func Test_breakindent19_sbr_nextpage() 623 let s:input = "" 624 call s:test_windows('setl breakindent briopt=shift:2,sbr,min:18 sbr=>') 625 call setline(1, repeat('a', 200)) 626 norm! 1gg 627 redraw! 628 let lines = s:screen_lines(1, 20) 629 let expect = [ 630 \ "aaaaaaaaaaaaaaaaaaaa", 631 \ "> aaaaaaaaaaaaaaaaaa", 632 \ "> aaaaaaaaaaaaaaaaaa", 633 \ ] 634 call s:compare_lines(expect, lines) 635 " Scroll down one screen line 636 setl scrolloff=5 637 norm! 5gj 638 let lines = s:screen_lines(1, 20) 639 let expect = [ 640 \ "aaaaaaaaaaaaaaaaaaaa", 641 \ "> aaaaaaaaaaaaaaaaaa", 642 \ "> aaaaaaaaaaaaaaaaaa", 643 \ ] 644 call s:compare_lines(expect, lines) 645 redraw! 646 " moving the cursor doesn't change the text offset 647 norm! l 648 redraw! 649 let lines = s:screen_lines(1, 20) 650 call s:compare_lines(expect, lines) 651 652 setl breakindent briopt=min:18 sbr=> 653 norm! 5gj 654 let lines = s:screen_lines(1, 20) 655 let expect = [ 656 \ ">aaaaaaaaaaaaaaaaaaa", 657 \ ">aaaaaaaaaaaaaaaaaaa", 658 \ ">aaaaaaaaaaaaaaaaaaa", 659 \ ] 660 call s:compare_lines(expect, lines) 661 call s:close_windows('set breakindent& briopt& sbr&') 662endfunc 663 664func Test_breakindent20_cpo_n_nextpage() 665 let s:input = "" 666 call s:test_windows('setl breakindent briopt=min:14 cpo+=n number') 667 call setline(1, repeat('a', 200)) 668 norm! 1gg 669 redraw! 670 let lines = s:screen_lines(1, 20) 671 let expect = [ 672 \ " 1 aaaaaaaaaaaaaaaa", 673 \ " aaaaaaaaaaaaaaaa", 674 \ " aaaaaaaaaaaaaaaa", 675 \ ] 676 call s:compare_lines(expect, lines) 677 " Scroll down one screen line 678 setl scrolloff=5 679 norm! 5gj 680 redraw! 681 let lines = s:screen_lines(1, 20) 682 let expect = [ 683 \ "--1 aaaaaaaaaaaaaaaa", 684 \ " aaaaaaaaaaaaaaaa", 685 \ " aaaaaaaaaaaaaaaa", 686 \ ] 687 call s:compare_lines(expect, lines) 688 689 setl briopt+=shift:2 690 norm! 1gg 691 let lines = s:screen_lines(1, 20) 692 let expect = [ 693 \ " 1 aaaaaaaaaaaaaaaa", 694 \ " aaaaaaaaaaaaaa", 695 \ " aaaaaaaaaaaaaa", 696 \ ] 697 call s:compare_lines(expect, lines) 698 " Scroll down one screen line 699 norm! 5gj 700 let lines = s:screen_lines(1, 20) 701 let expect = [ 702 \ "--1 aaaaaaaaaaaaaa", 703 \ " aaaaaaaaaaaaaa", 704 \ " aaaaaaaaaaaaaa", 705 \ ] 706 call s:compare_lines(expect, lines) 707 708 call s:close_windows('set breakindent& briopt& cpo& number&') 709endfunc 710 711" vim: shiftwidth=2 sts=2 expandtab 712