/Py-Screen-Saver

🖥️ A simple Screen Saver App Made with Python.

Primary LanguagePythonMIT LicenseMIT

🖥️ Py Screen Saver

GitHub License Code Style: Black

A simple screen saver app made with Python Tk that displays a clock in the center of the screen.

Screenshot

📥 Installation

  1. Clone Code

    use Git on your system

    git clone https://github.com/Mr-MRF-Dev/Py-Screen-Saver.git

    or use GitHub CLI

    gh repo clone Mr-MRF-Dev/Py-Screen-Saver
  2. Change your directory.

    cd Py-Screen-Saver
  3. Install tkinter and pyinstaller ( by using requirements.txt )

    pip install -r requirements.txt
  4. Create exe File

    cd src
    pyinstaller --noconfirm --onefile --windowed  .\main.py
  5. Change File Format to scr

    cd dist
    ren main.exe main.scr
  6. Move the file to C:/windows/system32 (Administrator access is required)

    mv main.scr C:/windows/system32
  7. Install the new screen saver (with registry):

     reg add "HKEY_CURRENT_USER\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\system32\main.scr /f

    reg add flags: /v <Valuename>, /t <Type>, /d <Data>, /f Adds the registry entry without prompting for confirmation. More about reg command

Done :)

💡 Tips

  • To see all screen savers:

    dir c:\windows\system32\*scr
  • You can adjust the duration of the screen timeout (600 sec):

    reg add "HKEY_CURRENT_USER\Control Panel\Desktop" /v ScreenSaveTimeOut /t REG_SZ /d 600 /f
  • Also, you don't need to rename the file to 'scr' extension. Instead, you can directly install the file with the 'exe' extension.

    reg add "HKEY_CURRENT_USER\Control Panel\Desktop" /v SCRNSAVE.EXE /t REG_SZ /d C:\Windows\system32\main.exe /f

🤝 Contributing

we welcome any contributions you may have. If you're interested in helping out, fork the repository and create an Issue and PR.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.