Replies: 1 comment
-
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Its not clear to me from the documentation what this is supposed to do. Am I right in thinking if you do
get_text(a, b, -1, -1)
, then it supposed to return the contents of the terminal from(a, b)
to(a+rows, b+cols)
whererows
andcols
is the size of the terminal.If so, lets say the terminal size is 80x20 with sufficient content in the scrollback buffer. If we do something like
get_text(100, 0, -1, -1)
, I think its supposed to be interpreted asget_text(100, 0, 180, 20)
. Buttym
will return nothing because it will interpret this asget_text(100, 0, 80, 20)
which is an invalid range. Is this by design or is this a bug?Would it make sense to change
get_text(0, 0, -1, -1)
to return the entire scrollback buffer?. I know we can already do this by combiningget_cursor_position()
.Also would it make sense to add a new builtin
get_text_visible()
to fetch the currently visible area of terminal. Seevte_terminal_get_text()
.Beta Was this translation helpful? Give feedback.
All reactions