Nitin Duseja
Résumé
Case 10 · 2026 Windows 11 Desktop Utility · GitHub

AutoDarkMode

Windows 11 system utility automating dynamic theme switching with DWM Mica & solar positioning

Year
2026
Role
Systems Developer & Desktop Engineer
Team
Independent Desktop System
Duration
5 months
View Repository on GitHub

Interface & Functionality

Application Screenshots & Previews

The problem

What was being asked

Context

Windows 11 lacks a native, location-aware automated theme scheduler that seamlessly transitions the desktop environment, Windows Terminal, apps, and wallpapers between light and dark modes based on real-time solar elevation without jarring flickers or excessive battery drain.

The solution

What was built

Slip 1

Engineered a native Windows utility using Tauri 2 and Rust featuring an ultra-low-power background engine consuming under 12MB RAM and 0% idle CPU

Slip 2

Implemented offline astronomical NOAA Solar Position algorithms to calculate exact dawn, dusk, and twilight curves without requiring external API requests

Slip 3

Leveraged low-level Win32 APIs and registry listeners to broadcast WM_SETTINGCHANGE messages system-wide for smooth, flicker-free transitions

Slip 4

Crafted a fluent Windows 11 UI with Svelte 5 and native DWM Mica material effects that conform to modern desktop design guidelines

The architecture

How it holds together

Rust Core Daemon & Win32 Broadcast Rail

Monitors system timers and power state events, recalculating solar angles and broadcasting synchronized theme changes across active HWNDs.

Astronomical NOAA Solar Calculation Engine

Pure mathematical engine running entirely offline to determine solar zenith and twilight transitions from local latitude and longitude.

Key Metrics & Impact

Demonstrated Results

Challenges

The parts that tried to break it

Handling Modern Standby wake events

Laptops waking from sleep at new times missed scheduler ticks. Subscribed to PBT_APMRESUMEAUTOMATIC power broadcasts to immediately recalculate sun positions upon wake.

Win32 broadcast deadlocks

Broadcasting WM_SETTINGCHANGE to hung third-party windows could freeze the utility. Solved with SendMessageTimeoutW using SMTO_ABORTIFHUNG and a strict 500ms timeout.

Decisions

Calls somebody owns

Offline NOAA algorithms over network APIs

Eliminated network dependency and privacy concerns by performing all solar trigonometric calculations locally.

Svelte 5 for lightweight settings UI

Enabled an instant-loading, featherlight configuration experience with fine-grained reactivity and minimal JS overhead.

Learning carried forward

The best desktop utilities are the ones you forget are running. True background software must be whisper-quiet, completely reliable, and respectful of system resources.