CSInlineColorViz icon indicating copy to clipboard operation
CSInlineColorViz copied to clipboard

Doesn't show colors in winui nuget package generic.xaml

Open palenshus opened this issue 9 months ago • 2 comments

If you have the winui package downloaded, the colors are defined in this resource dictionary file:

%userprofile%\.nuget\packages\microsoft.windowsappsdk\1.7.250310001\lib\net6.0-windows10.0.22621.0\Microsoft.WinUI\Themes\generic.xaml

Or whatever version you have installed...

If you open that in VS, it'd be awesome if the extension showed the colors of those hex colors, for example line 7600:

<Color x:Key="LayerOnAcrylicFillColorDefault">#40FFFFFF</Color>

I suspect it doesn't because the file isn't part of the sln, but if there's some way you can get that to work it'd be awesome!

Btw, a quick way to navigate to that file is if you have a xaml file in your own project that uses a themeresource, you can F12 (go to definition on that color): <... Background="{ThemeResource ControlFillColorDefault}">

palenshus avatar Mar 21 '25 00:03 palenshus

I have a different solution for visualizing colors inside a Resource Dictionary. - (Not yet public. I'm a tease I know) As that's not a C# thing it won't come here, but I'll leave this open as a reminder to come back and update when that's public

mrlacey avatar Mar 21 '25 11:03 mrlacey

Excellent, thanks for the quick response! Looking forward to it

palenshus avatar Mar 21 '25 17:03 palenshus