Peek function.
Darkodaaa opened this issue ยท 2 comments
A function for monitors/terminals.
When called the function needs an x and y coordinate like.
monitor = peripheral.find("monitor")
char, bg, fg = monitor.peek(x, y)
Or
char, bg, fg = term.peek(x, y)
Return the charater, the background and the foreground color at the given location.
I'd use this to take screen shots within CC computers or screen recordings.
Thanks for the issue!
This should mostly be possible already by creating a window, running your program with the term redirected to that window,and then calling Window.getLine
to read back the contents.
I don't want to add a way to read arbitrary terminals - the comments in #563 and #272 go into a bit more detail on this.