Another LinuxMint question. The machine this software is going to will be running 24/7. To prolong the life of the monitor the client wants to enable the screen saver.
Is there a way for a Xojo app to simulate the keypress (to wake the monitor) or cancel the screensaver?
Why not provide the screen saver functionality by displaying a black full screen window after a set amount of time. That way you can control how and when the screen shows up.
That’s not what the client asked for. And unless I’m mistaken, having a black screen isn’t quite the same as having it powered off (which is what happens after the screensaver times out).
There is a command-line utility called xdotool which can simulate key presses and mouse movements fairly easily… just use shell to pass a call to it with specific arguments.
You now have a solution thanks to Eric Brown, but for the record, a black screen will be viewed by any Energy Star compliant device as a signal to sleep. Anything more recent than 2000 basically.