Lines Matching refs:col
621 colnr_T col; in searchit() local
671 if (pos->col == MAXCOL) in searchit()
676 && pos->col < MAXCOL - 2) in searchit()
679 if ((int)STRLEN(ptr) <= pos->col) in searchit()
682 start_char_len = (*mb_ptr2len)(ptr + pos->col); in searchit()
707 pos->col = 0; in searchit()
718 if (dir == BACKWARD && start_pos.col == 0 in searchit()
745 col = at_first_line && (options & SEARCH_COL) ? pos->col in searchit()
748 lnum, col, in searchit()
797 && (int)endpos.col - 1 in searchit()
798 < (int)start_pos.col + extra_col) in searchit()
799 : ((int)matchpos.col in searchit()
800 - (ptr[matchpos.col] == NUL) in searchit()
801 < (int)start_pos.col + extra_col))) in searchit()
817 matchcol = endpos.col; in searchit()
819 if (matchcol == matchpos.col in searchit()
831 matchcol = matchpos.col; in searchit()
895 && (int)regmatch.endpos[0].col - 1 in searchit()
896 < (int)start_pos.col in searchit()
902 && (int)regmatch.startpos[0].col in searchit()
903 < (int)start_pos.col in searchit()
927 matchcol = endpos.col; in searchit()
929 if (matchcol == matchpos.col in searchit()
944 matchcol = matchpos.col; in searchit()
996 && matchpos.col == endpos.col)) in searchit()
1001 pos->col = endpos.col; in searchit()
1002 if (endpos.col == 0) in searchit()
1007 pos->col = (colnr_T)STRLEN(ml_get_buf(buf, in searchit()
1013 --pos->col; in searchit()
1018 pos->col -= (*mb_head_off)(ptr, ptr + pos->col); in searchit()
1024 end_pos->col = matchpos.col; in searchit()
1030 pos->col = matchpos.col; in searchit()
1034 end_pos->col = endpos.col; in searchit()
1045 search_match_endcol = endpos.col; in searchit()
1143 pos->col = (int)STRLEN(ml_get_buf(buf, pos->lnum, FALSE)); in searchit()
1144 if (pos->col > 0) in searchit()
1145 --pos->col; in searchit()
1281 pos.col = MAXCOL - 2; // avoid overflow when adding 1 in do_search()
1286 pos.col = 0; in do_search()
1518 if (!spats[0].off.line && spats[0].off.off && pos.col < MAXCOL - 2) in do_search()
1528 pos.col = MAXCOL; in do_search()
1539 pos.col = 0; in do_search()
1589 pos.col = 0; in do_search()
1593 else if (pos.col < MAXCOL - 2) // just in case in do_search()
1729 pos->col = (colnr_T) (p - ptr); in search_for_exact_line()
1765 int col; in searchc() local
1813 col = curwin->w_cursor.col; in searchc()
1824 col += (*mb_ptr2len)(p + col); in searchc()
1825 if (col >= len) in searchc()
1830 if (col == 0) in searchc()
1832 col -= (*mb_head_off)(p, p + col - 1) + 1; in searchc()
1836 if (p[col] == c && stop) in searchc()
1839 else if (STRNCMP(p + col, lastc_bytes, lastc_bytelen) == 0 in searchc()
1849 if ((col += dir) < 0 || col >= len) in searchc()
1851 if (p[col] == c && stop) in searchc()
1861 col -= dir; in searchc()
1866 col += lastc_bytelen - 1; in searchc()
1869 col -= (*mb_head_off)(p, p + col); in searchc()
1872 curwin->w_cursor.col = col; in searchc()
1902 int col, in check_prevcol() argument
1906 --col; in check_prevcol()
1907 if (col > 0 && has_mbyte) in check_prevcol()
1908 col -= (*mb_head_off)(linep, linep + col); in check_prevcol()
1910 *prevcol = col; in check_prevcol()
1911 return (col >= 0 && linep[col] == ch) ? TRUE : FALSE; in check_prevcol()
1927 for (p = linep + startpos->col + 1; *p && *p != '('; ++p) in find_rawstring_end()
1929 delim_len = (p - linep) - startpos->col - 1; in find_rawstring_end()
1930 delim_copy = vim_strnsave(linep + startpos->col + 1, delim_len); in find_rawstring_end()
1938 ? startpos->col + 1 : 0); *p; ++p) in find_rawstring_end()
1940 if (lnum == endpos->lnum && (colnr_T)(p - line) >= endpos->col) in find_rawstring_end()
2166 if (*ptr == '#' && pos.col <= (colnr_T)(ptr - linep)) in findmatchlimit()
2176 else if (linep[pos.col] == '/') in findmatchlimit()
2178 if (linep[pos.col + 1] == '*') in findmatchlimit()
2182 pos.col++; in findmatchlimit()
2184 else if (pos.col > 0 && linep[pos.col - 1] == '*') in findmatchlimit()
2188 pos.col--; in findmatchlimit()
2191 else if (linep[pos.col] == '*') in findmatchlimit()
2193 if (linep[pos.col + 1] == '/') in findmatchlimit()
2198 else if (pos.col > 0 && linep[pos.col - 1] == '/') in findmatchlimit()
2217 if (linep[pos.col] == NUL && pos.col) in findmatchlimit()
2218 --pos.col; in findmatchlimit()
2221 initc = PTR2CHAR(linep + pos.col); in findmatchlimit()
2228 pos.col += mb_ptr2len(linep + pos.col); in findmatchlimit()
2240 int col, bslcnt = 0; in findmatchlimit() local
2244 for (col = pos.col; check_prevcol(linep, col, '\\', &col);) in findmatchlimit()
2267 pos.col = 0; in findmatchlimit()
2283 pos.col = (colnr_T) (ptr - linep); in findmatchlimit()
2341 if (lisp && comment_col != MAXCOL && pos.col > (colnr_T)comment_col) in findmatchlimit()
2354 if (lispcomm && pos.col < (colnr_T)comment_col) in findmatchlimit()
2357 if (pos.col == 0) // at start of line, go to prev. one in findmatchlimit()
2367 pos.col = (colnr_T)STRLEN(linep); // pos.col on trailing NUL in findmatchlimit()
2381 pos.col = comment_col; in findmatchlimit()
2386 --pos.col; in findmatchlimit()
2388 pos.col -= (*mb_head_off)(linep, linep + pos.col); in findmatchlimit()
2393 if (linep[pos.col] == NUL in findmatchlimit()
2398 && pos.col == (colnr_T)comment_col) in findmatchlimit()
2416 pos.col = 0; in findmatchlimit()
2427 pos.col += (*mb_ptr2len)(linep + pos.col); in findmatchlimit()
2429 ++pos.col; in findmatchlimit()
2436 if (pos.col == 0 && (flags & FM_BLOCKSTOP) && in findmatchlimit()
2450 if (linep[pos.col] == '*' && linep[pos.col + 1] == '/') in findmatchlimit()
2452 pos.col++; in findmatchlimit()
2462 if (pos.col == 0) in findmatchlimit()
2466 if (linep[pos.col - 1] == 'R' in findmatchlimit()
2467 && linep[pos.col] == '"' in findmatchlimit()
2468 && vim_strchr(linep + pos.col + 1, '(') != NULL) in findmatchlimit()
2479 match_pos.col--; in findmatchlimit()
2484 else if ( linep[pos.col - 1] == '/' in findmatchlimit()
2485 && linep[pos.col] == '*' in findmatchlimit()
2486 && (pos.col == 1 || linep[pos.col - 2] != '*') in findmatchlimit()
2487 && (int)pos.col < comment_col) in findmatchlimit()
2491 match_pos.col--; in findmatchlimit()
2493 else if (linep[pos.col - 1] == '*' && linep[pos.col] == '/') in findmatchlimit()
2497 else if (pos.col > 1 && linep[pos.col - 2] == '/' in findmatchlimit()
2498 && (int)pos.col <= comment_col) in findmatchlimit()
2499 pos.col -= 2; in findmatchlimit()
2526 if (ptr == linep + pos.col + backwards) in findmatchlimit()
2590 c = PTR2CHAR(linep + pos.col); in findmatchlimit()
2595 if (pos.col == 0 || linep[pos.col - 1] != '\\') in findmatchlimit()
2607 int col; in findmatchlimit() local
2609 for (col = pos.col - 1; col >= 0; --col) in findmatchlimit()
2610 if (linep[col] != '\\') in findmatchlimit()
2612 if ((((int)pos.col - 1 - col) & 1) == 0) in findmatchlimit()
2632 if (pos.col > 1) in findmatchlimit()
2634 if (linep[pos.col - 2] == '\'') in findmatchlimit()
2636 pos.col -= 2; in findmatchlimit()
2639 else if (linep[pos.col - 2] == '\\' && in findmatchlimit()
2640 pos.col > 2 && linep[pos.col - 3] == '\'') in findmatchlimit()
2642 pos.col -= 3; in findmatchlimit()
2647 else if (linep[pos.col + 1]) // forward search in findmatchlimit()
2649 if (linep[pos.col + 1] == '\\' && in findmatchlimit()
2650 linep[pos.col + 2] && linep[pos.col + 3] == '\'') in findmatchlimit()
2652 pos.col += 3; in findmatchlimit()
2655 else if (linep[pos.col + 2] == '\'') in findmatchlimit()
2657 pos.col += 2; in findmatchlimit()
2672 && pos.col > 1 in findmatchlimit()
2673 && check_prevcol(linep, pos.col, '\\', NULL) in findmatchlimit()
2674 && check_prevcol(linep, pos.col - 1, '#', NULL)) in findmatchlimit()
2683 int col, bslcnt = 0; in findmatchlimit() local
2687 for (col = pos.col; check_prevcol(linep, col, '\\', &col);) in findmatchlimit()
2904 regmatch.startpos[0].col = -1; in is_zero_width()
2924 regmatch.startpos[0].col++; in is_zero_width()
2926 pos.lnum, regmatch.startpos[0].col, NULL, NULL); in is_zero_width()
2930 && direction == FORWARD ? regmatch.startpos[0].col < pos.col in is_zero_width()
2931 : regmatch.startpos[0].col > pos.col); in is_zero_width()
2937 && regmatch.startpos[0].col == regmatch.endpos[0].col); in is_zero_width()
3047 pos.col = (colnr_T)STRLEN( in current_search()
3893 curwin->w_cursor.col = (colnr_T)(startp - line); in find_pattern_in_path()
4172 pos.col = tv_get_number_chk(&li->li_tv, &error) - 1; in f_searchcount()