`[lints] workspace = true` in place of its own tables, as CLAUDE.md asks of every new crate (CodeRabbit): it now
also gets the workspace's cognitive_complexity, too_many_arguments and wildcard_imports denies. The workspace's
unsafe_code is deny, not forbid, so the win32 module's #[allow(unsafe_code)] still applies, and an unsafe block
anywhere else in the crate fails to compile.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CvoftKWm1wYSXdzRBwvFR3
When the display configuration, the window's display path or its advanced-colour state can't be
read, `monitor_color` answered with the monitor's profile as if Windows weren't colour-managing the
desktop. If it was (HDR, Auto Color Management), previews were converted twice. It now answers
`Unknown`, as the crate's other failures do, so previews stay sRGB (Windows 10 before 1709 and
drivers that don't report the state included).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GfjNkJiMUagz3DN3zoV2rV
While no monitor profile is chosen in Settings > Display, Windows now shows
previews through the profile Windows Color System assigns to the monitor
showing the window (per-user or system), as macOS and Linux already do. It is
read about once a second, so moving the window to another monitor and changing
the profile in Windows are followed without a restart. While Windows
colour-manages the desktop itself (HDR, Auto Color Management), previews stay
sRGB.
The Win32 calls live in a new L0 helper crate, crates/wincolor, the second
crate allowed `unsafe` after crates/sysmem (SAFETY comments on every block,
safe API, Unknown on any failure); CLAUDE.md and AGENTS.md name it. GDI's
GetICMProfileW keeps the profile a process first saw, so WCS is read directly
and GetICMProfileW is only a fallback.
The profile-file loader moves from the Linux-only colord.rs to a shared
profile_file.rs (unchanged), with a cache that re-reads a file only when it
changes.
Verified on Windows 11 by setting and clearing a Display P3 profile and
toggling HDR while the app ran.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01K93HTyCiwYvbRGaAkjPvXn