diff options
author | Dundar Goc <gocdundar@gmail.com> | 2022-05-04 22:35:50 +0200 |
---|---|---|
committer | Dundar Goc <gocdundar@gmail.com> | 2022-05-07 14:54:01 +0200 |
commit | 2a378e6e82cececb12339f2df51ffe107039d867 (patch) | |
tree | acf9250e683b303d2a22ff32455100cc4f6802cf /src/nvim/hardcopy.c | |
parent | d9ec57e16a13f66a4b17edd872786e2c67348752 (diff) | |
download | rneovim-2a378e6e82cececb12339f2df51ffe107039d867.tar.gz rneovim-2a378e6e82cececb12339f2df51ffe107039d867.tar.bz2 rneovim-2a378e6e82cececb12339f2df51ffe107039d867.zip |
refactor: replace char_u variables and functions with char
Work on https://github.com/neovim/neovim/issues/459
Diffstat (limited to 'src/nvim/hardcopy.c')
-rw-r--r-- | src/nvim/hardcopy.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/hardcopy.c b/src/nvim/hardcopy.c index b2974854c1..1e9c69c390 100644 --- a/src/nvim/hardcopy.c +++ b/src/nvim/hardcopy.c @@ -589,7 +589,7 @@ static void prt_header(prt_settings_T *const psettings, const int pagenum, const int page_line = 0 - prt_header_height(); mch_print_start_line(true, page_line); for (char_u *p = tbuf; *p != NUL;) { - const int l = utfc_ptr2len(p); + const int l = utfc_ptr2len((char *)p); assert(l >= 0); if (mch_print_text_out(p, (size_t)l)) { page_line++; @@ -896,7 +896,7 @@ static colnr_T hardcopy_line(prt_settings_T *psettings, int page_line, prt_pos_T * Loop over the columns until the end of the file line or right margin. */ for (col = ppos->column; line[col] != NUL && !need_break; col += outputlen) { - if ((outputlen = utfc_ptr2len(line + col)) < 1) { + if ((outputlen = utfc_ptr2len((char *)line + col)) < 1) { outputlen = 1; } // syntax highlighting stuff. @@ -949,7 +949,7 @@ static colnr_T hardcopy_line(prt_settings_T *psettings, int page_line, prt_pos_T need_break = 1; } else { need_break = mch_print_text_out(line + col, (size_t)outputlen); - print_pos += utf_ptr2cells(line + col); + print_pos += utf_ptr2cells((char *)line + col); } } @@ -3002,7 +3002,7 @@ int mch_print_text_out(char_u *const textp, size_t len) } } if (prt_out_mbyte) { - const bool half_width = (utf_ptr2cells(p) == 1); + const bool half_width = (utf_ptr2cells((char *)p) == 1); if (half_width) { char_width /= 2; } |