Command Shortcut to turn off screen XFCE

I do not believe this can easily be done since the hardware power button is assigned a specific task that is essential.
It is possible, but probably not worth the risk.

What you can do is save the command as an autokey command:

Or as a Script

#!/bin/bash
xset dpms force off

Then set a keyboard shortcut to the /path/to/script

Make the script executable with (replace script-name' with the actual name of the file you saved):

chmod +x script-name.sh

1 Like