-
Notifications
You must be signed in to change notification settings - Fork 6k
Make SkUnicode explicitly instead of relying on SkParagraph to make it for us #52086
Conversation
Flutter uses the public interface and also need access to the getters. See flutter/engine#52086 Change-Id: I84e2a09a65c63328ba20fee42a80cf851744cb14 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/840000 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Ben Wagner <bungeman@google.com> Auto-Submit: Kevin Lubick <kjlubick@google.com>
I was expecting a similar change to our CanvasKit side too: https://github.com/flutter/engine/blob/main/lib/web_ui/lib/src/engine/canvaskit/text.dart#L1133 Is there a reason CanvasKit didn't require a change? Also, I think @jason-simmons should take a look too. |
canvaskit did need changes, e.g. https://github.com/google/skia/blob/f7bfa8eef5b576b0d024216db7ee43353efc6ee3/modules/canvaskit/paragraph_bindings.cpp#L655-L660 However, the dart code you link shells out to CanvasKit, which didn't have any API changes (we hid those 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.
However, the dart code you link shells out to CanvasKit, which didn't have any API changes (we hid those away).
Nice! Thanks for clarifying.
LGTM!
…147537) flutter/engine@399837d...5165c71 2024-04-29 zanderso@users.noreply.github.com Remove references to goma (flutter/engine#52411) 2024-04-29 kjlubick@users.noreply.github.com Make SkUnicode explicitly instead of relying on SkParagraph to make it for us (flutter/engine#52086) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC jimgraham@google.com,rmistry@google.com,zra@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: 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
In https://skia-review.googlesource.com/c/skia/+/838417 Skia staged the removal of automatically creating an SkUnicode as part of the effort to make Skia more modular. Clients will now have to construct and SkUnicode and pass it to SkParagraph to provide the appropriate data. Flutter sometimes uses ICU and sometimes uses a "client" SkUnicode which makes use of the browser APIs to get the data.
We should come back to the skwasm code especially, because right now skwasm gets the data necessary to make an SkUnicode::Client, but stores it in the ParagraphBuilder, just to take it out again later to make the SkUnicode::Client and pass that back into the ParagraphBuilder. skwasm should just create the SkUnicode::Client directly and pass it to the ParagraphBuilder::make().
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.