WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
207319
Draw underlines when specified in highlights
https://bugs.webkit.org/show_bug.cgi?id=207319
Summary
Draw underlines when specified in highlights
Megan Gardner
Reported
2020-02-05 18:00:33 PST
Draw underlines when specified in highlights
Attachments
Patch
(9.19 KB, patch)
2020-02-05 18:19 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Patch
(8.68 KB, patch)
2020-02-06 00:14 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Patch
(10.24 KB, patch)
2020-02-10 15:22 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Patch
(11.61 KB, patch)
2020-02-11 10:01 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Patch
(11.59 KB, patch)
2020-02-11 11:01 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Patch for landing
(11.59 KB, patch)
2020-02-11 12:58 PST
,
Megan Gardner
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Megan Gardner
Comment 1
2020-02-05 18:19:49 PST
Created
attachment 389928
[details]
Patch
Radar WebKit Bug Importer
Comment 2
2020-02-05 18:20:35 PST
<
rdar://problem/59210451
>
Simon Fraser (smfr)
Comment 3
2020-02-05 19:01:56 PST
Comment on
attachment 389928
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=389928&action=review
> Source/WebCore/ChangeLog:10 > + When determining if we have any text decorations, currently we were only lookin at the lineStyle,
lookin
> Source/WebCore/rendering/InlineTextBox.cpp:612 > + bool highlightDecorations = !collectMarkedTextsForHighlights(TextPaintPhase::Decoration).isEmpty();
haveHighlightDecorations. For symmetry, add bool haveTextDecorations = !textDecorations.isEmpty() and use it below.
> Source/WebCore/rendering/InlineTextBox.cpp:1203 > + auto textDecorations = lineStyle().textDecorationsInEffect() | TextDecorationPainter::textDecorationsInEffectForStyle(markedText.style.textDecorationStyles);
Took me a while to unpack this, with the auto and the |. It would be clearer as: auto textDecorations = lineStyle().textDecorationsInEffect() textDecorations.add(TextDecorationPainter::textDecorationsInEffectForStyle(markedText.style.textDecorationStyles)) or something.
> Source/WebCore/rendering/TextDecorationPainter.cpp:390 > +OptionSet<TextDecoration> TextDecorationPainter::textDecorationsInEffectForStyle(const TextDecorationPainter::Styles style)
const TextDecorationPainter::Styles&
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations-expected.html:16 > + #style1 { > + background-color: yellow; > + color:green; > + } > + #style2 { > + background-color: blue; > + color:red; > + } > + #style3 { > + background-color: purple; > + color:pink; > + }
Why I am I not seeing underline, overline or line-through here?
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations.html:5 > + <title>Multiple custom highlight pseudo elements.</title>
This seems stale.
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations.html:6 > + <link rel="help" href="
https://drafts.csswg.org/css-highlight-api-1/#creating-highlights
">
This seems wrong.
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations.html:8 > + <meta name="assert" content="Text decorations in highlights should be able to be specified.">
"should be able to be specified" is a bit vague. Maybe "should display"?
Megan Gardner
Comment 4
2020-02-06 00:14:54 PST
Created
attachment 389939
[details]
Patch
Simon Fraser (smfr)
Comment 5
2020-02-06 11:10:10 PST
Comment on
attachment 389939
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=389939&action=review
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations-expected.html:11 > + O<span id="style1">n</span>e t<span id="style1">w</span>o th<span id="style1">ree</span>
Use class not id (and change the selector above to .style1. Also make the text bigger so that failures are more obvious (more pixels).
> LayoutTests/http/wpt/css/css-highlight-api/highlight-text-decorations.html:13 > + <style> > + ::highlight(example-highlight1) { > + text-decoration: underline; > + } > + </style>
Extra indent here.
Megan Gardner
Comment 6
2020-02-10 15:22:42 PST
Created
attachment 390301
[details]
Patch
Megan Gardner
Comment 7
2020-02-11 10:01:17 PST
Created
attachment 390381
[details]
Patch
Megan Gardner
Comment 8
2020-02-11 11:01:51 PST
Created
attachment 390392
[details]
Patch
Megan Gardner
Comment 9
2020-02-11 12:58:41 PST
Created
attachment 390408
[details]
Patch for landing
WebKit Commit Bot
Comment 10
2020-02-11 13:53:05 PST
Comment on
attachment 390408
[details]
Patch for landing Clearing flags on attachment: 390408 Committed
r256360
: <
https://trac.webkit.org/changeset/256360
>
WebKit Commit Bot
Comment 11
2020-02-11 13:53:07 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug