35 posts
Location
why do you want to know
Posted 31 March 2018 - 04:10 PM
There's a bar at the top with the time and close etc, which I don't want the program to draw under/over. I want it to think that the height of the screen is smaller by 1.
355 posts
Location
Germany
Posted 31 March 2018 - 04:20 PM
You can override the term api for the environment the programs are running in. in there you can override behavior to adjust the getSize() height to be decremented by 1, setCursorPos to always go one line below.
Though you maybe want to be able to launch programs in full screen mode as well (which you could call compatibility mode), as there are many programs, that don't support multiple resolutions, and it is pretty much impossible for you to know, whether some anonymous program is supporting some resolution or not.
1426 posts
Location
Does anyone put something serious here?
Posted 31 March 2018 - 04:34 PM
It's probably worth having a look at how CraftOS implements this
using the multi-shell API. It creates a window which starts at the second line (see
launchProcess) and redirects to that.
7083 posts
Location
Tasmania (AU)
Posted 01 April 2018 - 03:52 AM
Indeed, one should use
term.redirect() instead of attempting to override term API functions.
That's the easy bit. The tricky bit is getting your OS's taskbar to actually "do stuff" while the user script is running - you'll need to put some research into coroutines for that to happen.