Skip to content

This application automatically switches between Windows' light and dark theme, depending on the current illumination.

License

Notifications You must be signed in to change notification settings

stephtr/BrightnessSwitch

Repository files navigation

BrightnessSwitch

Get it from Microsoft

Do you have a notebook with Fn and function keys combined and have issues with combinations like Alt+F4? Make sure to also check out FixSurfaceKeyboard.


BrightnessSwitch automatically switches between Windows' Light- and Dark-Theme, depending on the ambient brightness, detected via your device's light sensor.

Screenshot
Screenshot of the app

In order to control the switching mechanism, it adds a tray icon where one can enable or disable automatic switching of themes, but also an option to manually switch the theme.

If automatic switching is enabled and one switches the theme, machine learning (support vector machine, to be precise) is being used for optimizing the automatic switching mechanism.

Download

Running the app

The easiest and recommended way is to use the Microsoft Store version. If you prefer to manually run the app, follow these steps:

Download the latest release and extract it to a folder of your choice. The app is written in C# (.NET 5.0) and therefore needs the Desktop Runtime 5.0 to be installed. Then run BrightnessControl.exe, autostart with Windows can be enabled via the context menu.

Known issues

  • #8: On Windows 11, some apps (like Explorer) don't fully respect the theme change. So far, I don't know of any way to circumvent that.

Privacy

The app itself doesn't send any data to any server. For the Microsoft Store version, Windows may send some diagnostic informations to Microsoft.

Building from source

For building the app from scratch, you need to have the .NET SDK 5.0 (preview) installed.

After cloning or downloading the source, running dotnet run is sufficient for automatically restoring, building and running the app.

Included with the source is also a small Python script for analysing the app's SVM configuration. By running analysis.py, it shows a plot containing all your recent manual interventions as dots. The vertical line corresponds to the criteria for switching between light and dark theme with the shaded area being a measure for the uncertainty.

Screenshot analysis
Screenshot of the analysis tool

Changelog

For a list of recent changes, see the separate Changelog.

About

This application automatically switches between Windows' light and dark theme, depending on the current illumination.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published