Lines Matching refs:bd

35 static int	yank_copy_line(struct block_def *bd, long y_idx, int exclude_trailing_space);
1143 struct block_def bd; in op_yank() local
1220 block_prep(oap, &bd, lnum, FALSE); in op_yank()
1221 if (yank_copy_line(&bd, y_idx, oap->excl_tr_ws) == FAIL) in op_yank()
1238 bd.startspaces = 0; in op_yank()
1239 bd.endspaces = 0; in op_yank()
1251 bd.startspaces = (ce - cs + 1) in op_yank()
1275 bd.startspaces = oap->end.coladd in op_yank()
1281 bd.endspaces = oap->end.coladd in op_yank()
1291 bd.textlen = 0; in op_yank()
1293 bd.textlen = endcol - startcol + oap->inclusive; in op_yank()
1294 bd.textstart = p + startcol; in op_yank()
1295 if (yank_copy_line(&bd, y_idx, FALSE) == FAIL) in op_yank()
1461 yank_copy_line(struct block_def *bd, long y_idx, int exclude_trailing_space) in yank_copy_line() argument
1466 bd->endspaces = 0; in yank_copy_line()
1467 if ((pnew = alloc(bd->startspaces + bd->endspaces + bd->textlen + 1)) in yank_copy_line()
1471 vim_memset(pnew, ' ', (size_t)bd->startspaces); in yank_copy_line()
1472 pnew += bd->startspaces; in yank_copy_line()
1473 mch_memmove(pnew, bd->textstart, (size_t)bd->textlen); in yank_copy_line()
1474 pnew += bd->textlen; in yank_copy_line()
1475 vim_memset(pnew, ' ', (size_t)bd->endspaces); in yank_copy_line()
1476 pnew += bd->endspaces; in yank_copy_line()
1479 int s = bd->textlen + bd->endspaces; in yank_copy_line()
1481 while (VIM_ISWHITE(*(bd->textstart + s - 1)) && s > 0) in yank_copy_line()
1483 s = s - (*mb_head_off)(bd->textstart, bd->textstart + s - 1) - 1; in yank_copy_line()
1551 struct block_def bd; in do_put() local
1822 bd.textcol = 0; in do_put()
1828 bd.startspaces = 0; in do_put()
1829 bd.endspaces = 0; in do_put()
1850 bd.textcol = (colnr_T)(ptr - oldp); in do_put()
1855 bd.startspaces = col - vcol; in do_put()
1858 bd.endspaces = vcol - col; in do_put()
1859 bd.startspaces = incr - bd.endspaces; in do_put()
1860 --bd.textcol; in do_put()
1863 bd.textcol -= (*mb_head_off)(oldp, oldp + bd.textcol); in do_put()
1864 if (oldp[bd.textcol] != TAB) in do_put()
1870 bd.endspaces = 0; in do_put()
1890 && count > ((INT_MAX - (bd.startspaces + bd.endspaces)) in do_put()
1897 totlen = count * (yanklen + spaces) + bd.startspaces + bd.endspaces; in do_put()
1904 mch_memmove(ptr, oldp, (size_t)bd.textcol); in do_put()
1905 ptr += bd.textcol; in do_put()
1908 vim_memset(ptr, ' ', (size_t)bd.startspaces); in do_put()
1909 ptr += bd.startspaces; in do_put()
1926 vim_memset(ptr, ' ', (size_t)bd.endspaces); in do_put()
1927 ptr += bd.endspaces; in do_put()
1930 mch_memmove(ptr, oldp + bd.textcol + delcount, in do_put()
1931 (size_t)(oldlen - bd.textcol - delcount + 1)); in do_put()
1936 curwin->w_cursor.col += bd.startspaces; in do_put()
1947 curbuf->b_op_end.col = bd.textcol + totlen - 1; in do_put()