Reland "Update all uses of mutable SkPath methods to use SkPathBuilder"#178142
Merged
auto-submit[bot] merged 2 commits intoflutter:masterfrom Nov 7, 2025
Merged
Reland "Update all uses of mutable SkPath methods to use SkPathBuilder"#178142auto-submit[bot] merged 2 commits intoflutter:masterfrom
auto-submit[bot] merged 2 commits intoflutter:masterfrom
Conversation
…er#177738) Skia is removing the APIs that allow changing an SkPath. This updates those callsites to use SkPathBuilder where appropriate. ## Pre-launch Checklist - [x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [x] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [x] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [x] I signed the [CLA]. - [ ] I listed at least one issue that this PR fixes in the description above. - [x] I updated/added relevant documentation (doc comments with `///`). - [x] I added new tests to check the change I am making, or this PR is [test-exempt]. - [x] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [ ] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord]. **Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
…ut path using SkPathBuilder::operator= addPath does not copy all of the needed attributes of the source path
Contributor
There was a problem hiding this comment.
Code Review
This pull request updates the codebase to use SkPathBuilder instead of mutable SkPath methods, aligning with modern Skia practices. The changes are extensive and consistently applied across the display list, Impeller, UI, and tools code. The fix in tools/path_ops to correctly handle path attributes during Op is also noted and appears correct. I have reviewed the changes and found no issues.
kjlubick
approved these changes
Nov 7, 2025
| SkPath p1 = one->snapshot(); | ||
| SkPath p2 = two->snapshot(); | ||
| if (std::optional<SkPath> result = Op(p1, p2, op)) { | ||
| *one = result.value(); |
Contributor
There was a problem hiding this comment.
nit: use the explicit SkPathBuilder constructor here so we don't hide the change.
Member
Author
There was a problem hiding this comment.
SkPathBuilder has an implementation of operator= that takes an SkPath - this is not implicitly constructing an SkPathBuilder.
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 8, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 9, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 9, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 11, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 11, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 11, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 12, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 12, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 12, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 13, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Nov 14, 2025
auto-submit bot
pushed a commit
to flutter/packages
that referenced
this pull request
Nov 14, 2025
Manual roll requested by [email protected] flutter/flutter@ee23168...c3f2704 2025-11-08 [email protected] Roll Dart SDK from cf69b162e2eb to 34902d333e4d (19 revisions) (flutter/flutter#178183) 2025-11-07 [email protected] Roll Skia from 513b15b675f5 to 38d87df93572 (5 revisions) (flutter/flutter#178179) 2025-11-07 [email protected] [ Tool ] Ignore invalid UTF-8 from ADB's stdout (flutter/flutter#178170) 2025-11-07 [email protected] Roll Skia from 581d1ecd5029 to 513b15b675f5 (1 revision) (flutter/flutter#178165) 2025-11-07 [email protected] Reland "Update all uses of mutable SkPath methods to use SkPathBuilder" (flutter/flutter#178142) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
IvoneDjaja
pushed a commit
to IvoneDjaja/flutter
that referenced
this pull request
Nov 22, 2025
…r" (flutter#178142) This is a reland of flutter#177738 with a fix to the `Op` function in `tools/path_ops`. To match the previous behavior, `Op` will use `SkPathBuilder::operator=` to copy the result path so that attributes like the fill type will be copied. --------- Co-authored-by: Kaylee Lubick <[email protected]>
reidbaker
pushed a commit
to AbdeMohlbi/flutter
that referenced
this pull request
Dec 10, 2025
…r" (flutter#178142) This is a reland of flutter#177738 with a fix to the `Op` function in `tools/path_ops`. To match the previous behavior, `Op` will use `SkPathBuilder::operator=` to copy the result path so that attributes like the fill type will be copied. --------- Co-authored-by: Kaylee Lubick <[email protected]>
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Feb 11, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This is a reland of #177738 with a fix to the
Opfunction intools/path_ops.To match the previous behavior,
Opwill useSkPathBuilder::operator=to copy the result path so that attributes like the fill type will be copied.