
Auto Theme switches the Unity Editor Light/Dark by schedule or matching the OS. One‑click toolbar toggle, Force Light/Dark overrides, and per‑user preferences.🌞 Auto-Theme for Unity – Let Your Editor Follow the Sun! 🌙You've probably experienced it:Your desktop switches to light mode during the day for better visibility as sunlight floods your room. Most apps follow suit—automatically adjusting to match your system theme.But not all do…Unity doesn’t.Auto-Theme is your solution!Automatically switch between light and dark modes in the Unity Editor based on the time of day. Set your preferred times, and let Auto-Theme handle the rest—so you can focus on creating, not tweaking settings.Make the Unity Editor match your day. Auto Theme switches Light/Dark by schedule, matching your OS, or manual overrides—with a one‑click toolbar toggle.🔧 Key Features⚡ Force Light / Force Dark — instant override🕒 4 Modes Schedule — set Dark/Light start times (HH:mm), midnight wrap supported🖥️ Match System — follow Windows/macOS/GNOME/KDE system theme🧭 Toolbar Button — top‑right flat icon, cycles modes with a click👤 Per‑User Settings — saved in EditorPrefs; no project assets modified🚀 Immediate Apply — changes apply instantly; background check every ~30s🎛️ Clean UI — Preferences page under Edit → Preferences → Arawn → Auto ThemeWhy It HelpsComfort: automatic Light/Dark reduces eye strain across long sessions.Consistency: Match System keeps Unity aligned with your desktop.Speed: toggle on the toolbar—no window diving.What’s IncludedAutoTheme.cs (Editor‑only): runtime logic + Preferences UI + toolbar integration.Icon pack: sun.png, moon.png, auto.png (sun+moon), system.png (gear).README.md documentation.How It WorksDetermines desired skin from Mode.Writes UserSkin (0 Light / 1 Dark) and calls InternalEditorUtility.SwitchSkinAndRepaintAllViews().Polls about every 30 seconds; Preferences/toolbar changes apply immediately.OS Theme DetectionWindows: AppsUseLightTheme (HKCU\…\Personalize).macOS: defaults read -g AppleInterfaceStyle.Linux (GNOME/KDE): gsettings color-scheme / gtk-theme, KDE kdeglobals.If undetectable, falls back to Schedule.Compatibility & RequirementsEditor‑only. No runtime impact on builds.Platforms: Windows, macOS (untested), Linux (supports GNOME/KDE for OS matching, tested on Zorin OS and CachyOS with GNOME DE).InstallationPlace AutoTheme.cs under Assets/Arawn/AutoTheme/Editor/.Place icons in Assets/Arawn/AutoTheme/Icons/ (32×32 white‑on‑transparent).Open Edit → Preferences → Arawn → Auto Theme, choose Mode.(Schedule) Enter times in HH:mm (24‑hour).Editor-Only SolutionLightweight; a single timer check ~every 30s.On macOS/Linux, tiny helper processes (defaults, gsettings) may spawn with a short timeout (~700 ms).Technical Details:Uses Unity internal editor skin APIs (no public API exists).If another tool also sets UserSkin, last writer wins.Some Linux DEs beyond GNOME/KDE may require a custom probe.OS change detection is polled; event‑driven hooks can be added later if desired.RefactoringIcon Creation