130 posts
Location
Yes
Posted 14 January 2018 - 12:31 PM
7083 posts
Location
Tasmania (AU)
Posted 15 January 2018 - 12:47 AM
You can't access a display's content directly, so you'll need to pass it through a buffer.
By default, advanced computers already do this, using the
window API for the purposes of
multishell. You can redraw the terminal assigned to the current tab using "term.current().redraw()". Some control over what gets redrawn and where can be obtained using the window's
reposition function.
By moving a window around within
another window, it should be possible to redraw any specific portion you wish. You might find it simpler to use a custom buffer specifically built for this purpose, though.
467 posts
Location
Van Diemen's Land
Posted 18 January 2018 - 05:12 AM
You could split your screen into segments with windows (buffers), however drawing to them would be quite difficult as you would need to calculate where your GUI needs to be laid out over all of them at once.
Think of 4 monitors stacked in a square, with Windows (the OS this time) desktop over all of them at once. You could save a part of a screen, but only the screen of one of the monitors. So you'd be saving a quarter of the whole desktop.
But at least you could copy the screen's contents, turn the screen off, turn it back on again, draw something to it separately etc. etc.
However, easiest way to go is just separating objects on your screen as buffers (as Bomb Bloke has said). The way I said is probably the most complicated it can get, and is still limited to saving a screen at a time.