-2

So I want to make a red filter for the screen, when using my Python app. I need it so I can use it in dark without having light pollution. Also I need to adjust the brightness. I found a library called screen_brightness_control, but I haven't found any way to adjust the temperature with it.

So I didn't find any Python library that can help me with making my screen light red (adjusting the temperature of the screen). I've haven't runed any code yet. It will be also helpful if someone also tells about a brightness adjust library. About the OS I am using Windows 11.

  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. – Blue Robin Mar 24 '23 at 02:20

1 Answers1

0

You can try "pyautogui" library

import pyautogui

pyautogui.PAUSE = 1  

#Navigate to display settings
pyautogui.hotkey('win', 'i')
pyautogui.typewrite('display')
pyautogui.press('enter')

#Select night light settings
pyautogui.press('tab', presses=4, interval=0.5)
pyautogui.press('enter')

#Enable night light and adjust brightness of screen
pyautogui.press('tab', interval=0.5)  
pyautogui.press('space')  
pyautogui.press('tab', presses=3, interval=0.5)  
pyautogui.press('enter')  
pyautogui.press('down', presses=3, interval=0.5)   
pyautogui.press('enter')  

#Close the settings
pyautogui.hotkey('alt', 'f4')