Skip to main content

How to add a shutdown shortcut similar to Alt+F4 in windows - Rudra Coder

Windows provide a very useful shortcut and that is Alt+F4 which opens a Shutdown Window I used to use this feature too much but when I migrated to Linux Linux does not provide any specific feature like that but I coded a simple application using PYTHON's framework PyQt5 and now I use this custom Shutdown Window and I am happy with that so why not this to you all.

Linux icons created by Freepik - Flaticon


 How It looks like:


This window includes some information about your system like the title of the window the time when you installed the OS and your current username and also your system name with your release version.

It has four options;

  1. Power Off
  2. Logout
  3. Suspend
  4. Reboot
How to setup the shortcut
You can set this up with ease you just have to download the file andset a shortcut from the setting.

Showing an example of ubuntu:
From the keyboard, settings go to Customise shortcuts

Go to Custom Shortcuts

Click On Add Shortcut

                  Give the path of the file and click on 
                  set a shortcut and press the keys you want 
                  the shortcut

You are all set after closing once check if everything is working fine if not then copy the command you added there for the shortcut and try to run it in the terminal there you can see what error you are getting actually.


Comments