RESOLVED FIXED 134843
Implement textStylingAtPosition in WK2
https://bugs.webkit.org/show_bug.cgi?id=134843
Summary Implement textStylingAtPosition in WK2
Enrica Casucci
Reported 2014-07-11 14:04:04 PDT
Provide the same support we have in WebKit on iOS. <rdar://problem/17614981>
Attachments
Patch (10.86 KB, patch)
2014-07-11 14:09 PDT, Enrica Casucci
no flags
Patch2 (10.81 KB, patch)
2014-07-11 15:57 PDT, Enrica Casucci
benjamin: review+
Enrica Casucci
Comment 1 2014-07-11 14:09:17 PDT
Enrica Casucci
Comment 2 2014-07-11 15:57:19 PDT
Created attachment 234787 [details] Patch2 Fixes the OS X build.
Benjamin Poulain
Comment 3 2014-07-11 16:01:41 PDT
View in context: https://bugs.webkit.org/attachment.cgi?id=234779&action=review I don't know much about this code but the patch looks reasonable. > Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:1198 > + RetainPtr<CTFontDescriptorRef> fontDescriptor = adoptCF(CTFontDescriptorCreateWithNameAndSize(CFSTR("Helvetica"), 10)); This could be defined closer to where it is used. > Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:1205 > + fontDescriptor = adoptCF(CTFontDescriptorCreateCopyWithSymbolicTraits(fontDescriptor.get(), symbolicTraits, symbolicTraits)); Is there no way to create the font descriptor directly with the traits? It is a little ugly to create a font then copy it. > Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:1207 > + RetainPtr<CTFontRef> font = CTFontCreateWithFontDescriptor(fontDescriptor.get(), 10, nullptr); Shouldn't this use adoptCF? > Source/WebKit2/WebProcess/WebPage/WebPage.cpp:752 > + if (style) { WebKit style: if (RenderStyle* ...)
Enrica Casucci
Comment 4 2014-07-11 16:24:53 PDT
Committed revision 171015.
Note You need to log in before you can comment on or make changes to this bug.