fluid icon indicating copy to clipboard operation
fluid copied to clipboard

Make color filter independent of CultureInfo.CurrentCulture

Open JustusGreiberORGADATA opened this issue 2 years ago • 5 comments

I actually wanted to fix a different bug regarding layout file resolution, but all color tests were failing on my german Windows machine so this had to come first.

Color filters need to generate and parse valid CSS values. The syntax of these is always independent of the currently set culture, so the filters must reflect that by using CultureInfo.InvariantCulture.

The Visual Studio auto formatter also changed stuff like

if ((uint) red > 255)

to

if ((uint)red > 255)

There seems to be no .editorconfig in this repository so I don't know if this is right 🤷‍♂️. If you don't want this, I will change it back :).

JustusGreiberORGADATA avatar Jun 03 '22 22:06 JustusGreiberORGADATA

I actually wanted to fix a different bug regarding layout file resolution, but all color tests were failing on my german Windows machine so this had to come first.

Could you please write down a failing test, so I could try from my side, before we dig into your changes - which supposed to fix the culture issue -

There seems to be no .editorconfig in this repository so I don't know if this is right 🤷‍♂️. If you don't want this, I will change it back :).

I suggest to revert the changes, we could consider this in .editorconfig if we do so

hishamco avatar Jun 04 '22 21:06 hishamco

Could you please write down a failing test, so I could try from my side, before we dig into your changes - which supposed to fix the culture issue -

ok I removed the changes and replaced them with a commit that just adds a few failing tests, that should show the problem 😊.

JustusGreiberORGADATA avatar Jun 05 '22 12:06 JustusGreiberORGADATA

@JustusGreiberORGADATA I expect you will comment your fix, seems not ;) add your fix into another commit .. time to review

Thanks

hishamco avatar Jun 05 '22 13:06 hishamco

@hishamco Added the fix again 👍

JustusGreiberORGADATA avatar Jun 05 '22 13:06 JustusGreiberORGADATA

I surprised when I saw another file has been changes, then I realize that you did that ;) Just few minutes to finalize my review

hishamco avatar Jun 05 '22 14:06 hishamco