This repository was archived by the owner on Feb 25, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6k
Add ability to control dithering on Paint #13868
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
ba31664
Add ability to control dithering with Paint
ds84182 dbe803e
Fix trailing spaces
ds84182 0361a0b
Move to a temporary static field on Paint so dithering can be turned …
ds84182 464c6e0
Fix trailing whitespace again
ds84182 d9cc3f5
Merge branch 'master' of https://github.com/flutter/engine
ds84182 28aa026
Merge branch 'master' of https://github.com/flutter/engine
ds84182 32712a2
Add image compare test for dithered and non-dithered gradients
ds84182 e55d3ea
Add empty constructor to Web UI Paint
ds84182 ec129ad
Fix up formatting and unify gradient that is being tested
ds84182 f732e2c
Copy documentation comment from dart:ui
ds84182 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be unnecessary, FWIW. The constructor is normally implied.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When it was omitted one of the web UI lints complained
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the one in
lib/ui/painting.darttoo and the lint should go away.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That constructor can't be removed because its used to set
_ditherto true ifenableDitheringis true. I could use cascade syntax on_data's initializer, but readability suffers a little.Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see. Ping @jonahwilliams and @yjbanov to see if the web tools (the lint) can be relaxed in this case. If not, I'm Ok with just having this dummy constructor. My experience is that there's already a lot of dummy/duplicate code in
lib/web_ui. The ideal future would be that we don't need any duplicate code inlib/web_ui, and this issue would go away naturally.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's keep this one. We are splitting the implementation between HTML and CanvasKit (#14320), and this constructor is becoming a
factory, which we cannot omit.