Skip to content

fix: Color.ToString now returns the expected format - #6437

Merged
mergify[bot] merged 7 commits into
unoplatform:masterfrom
VitezslavImrysek:dev/viim/color-fix
Jul 18, 2021
Merged

mergify[bot] merged 7 commits into
unoplatform:masterfrom
VitezslavImrysek:dev/viim/color-fix

Conversation

@VitezslavImrysek

@VitezslavImrysek VitezslavImrysek commented Jul 9, 2021 •

Copy link
Copy Markdown
Contributor

GitHub Issue (If applicable): #5189

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

Color.ToString() returns in format '[#AABBCCDD]' which is incorrect.

What is the new behavior?

Color.ToString() now returns in format '#AABBCCDD'.

PR Checklist

Please check if your PR fulfills the following requirements:

@VitezslavImrysek
VitezslavImrysek requested a review from a team July 9, 2021 10:44
@gitpod-io

gitpod-io Bot commented Jul 9, 2021

Copy link
Copy Markdown

@MartinZikmund MartinZikmund left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🏎️

…and IFormatProvider.ToString 'provider' parameter is renamed to 'formatProvider'.
@MartinZikmund

Copy link
Copy Markdown
Member

The change of IFormattable to explicitly implemented is potentially breaking, but it is very unlikely someone was using the method anyway and it matches UWP.

@jeromelaban jeromelaban left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution!

@jeromelaban jeromelaban added the ready-to-merge Automatically merge the PR once all '.mergify.yml' policies are met label Jul 13, 2021
@robloo

robloo commented Jul 16, 2021

Copy link
Copy Markdown
Contributor

Shouldn't this somehow be fixed to the InvariantCulture? Allowing a format provider might theoretically cause invalid formats. Although, I'm not sure of any culture where it would cause an issue.

Comment thread src/Uno.UWP/UI/Color.cs Resolved
@jeromelaban

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@jeromelaban

Copy link
Copy Markdown
Member

@mergify
mergify Bot merged commit ece6481 into unoplatform:master Jul 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Automatically merge the PR once all '.mergify.yml' policies are met

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants