Mercurial > vim
diff runtime/doc/eval.txt @ 16133:eb087f8a26a8 v8.1.1071
patch 8.1.1071: cannot get composing characters from the screen
commit https://github.com/vim/vim/commit/2912abb3a2fd72074e3901c8ae1d4a77ce764675
Author: Bram Moolenaar <Bram@vim.org>
Date: Fri Mar 29 14:16:42 2019 +0100
patch 8.1.1071: cannot get composing characters from the screen
Problem: Cannot get composing characters from the screen.
Solution: Add screenchars() and screenstring(). (partly by Ozaki Kiichi,
closes #4059)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Fri, 29 Mar 2019 14:30:05 +0100 |
parents | 0375e54f0adc |
children | aef0f93d3eba |
line wrap: on
line diff
--- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -2525,8 +2525,10 @@ round({expr}) Float round off {expr} rubyeval({expr}) any evaluate |Ruby| expression screenattr({row}, {col}) Number attribute at screen position screenchar({row}, {col}) Number character at screen position +screenchars({row}, {col}) List List of characters at screen position screencol() Number current cursor column screenrow() Number current cursor row +screenstring({row}, {col}) String characters at screen position search({pattern} [, {flags} [, {stopline} [, {timeout}]]]) Number search for {pattern} searchdecl({name} [, {global} [, {thisblock}]]) @@ -7510,6 +7512,13 @@ screenchar({row}, {col}) *screenchar This is mainly to be used for testing. Returns -1 when row or col is out of range. +screenchars({row}, {col}) *screenchars()* + The result is a List of Numbers. The first number is the same + as what |screenchar()| returns. Further numbers are + composing characters on top of the base character. + This is mainly to be used for testing. + Returns an empty List when row or col is out of range. + screencol() *screencol()* The result is a Number, which is the current screen column of the cursor. The leftmost column has number 1. @@ -7531,6 +7540,14 @@ screenrow() *screenrow()* Note: Same restrictions as with |screencol()|. +screenstring({row}, {col}) *screenstring()* + The result is a String that contains the base character and + any composing characters at position [row, col] on the screen. + This is like |screenchars()| but returning a String with the + characters. + This is mainly to be used for testing. + Returns an empty String when row or col is out of range. + search({pattern} [, {flags} [, {stopline} [, {timeout}]]]) *search()* Search for regexp pattern {pattern}. The search starts at the cursor position (you can use |cursor()| to set it).