Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(497)

Side by Side Diff: third_party/WebKit/LayoutTests/paint/text/text-match-highlights-big-line-height.html

Issue 2802543002: Update window.internals.addTextMatchMarker() to take enum instead of bool (Closed)
Patch Set: Fix one more test, add k prefix Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 Text match highlight should not extend into the line spacing. 2 Text match highlight should not extend into the line spacing.
3 <div style="line-height: 30px; font-size: 15px"> 3 <div style="line-height: 30px; font-size: 15px">
4 <br id='b1'>AAA 4 <br id='b1'>AAA
5 </div> 5 </div>
6 6
7 <div style="line-height: 30px; font-size: 15px; writing-mode: vertical-rl"> 7 <div style="line-height: 30px; font-size: 15px; writing-mode: vertical-rl">
8 <br id='b2'>AAA 8 <br id='b2'>AAA
9 </div> 9 </div>
10 10
11 <script> 11 <script>
12 function highlightRange(element, start, end, active) { 12 function highlightRange(element, start, end, active) {
13 var range = document.createRange(); 13 var range = document.createRange();
14 range.setStart(element, start); 14 range.setStart(element, start);
15 range.setEnd(element, end); 15 range.setEnd(element, end);
16 internals.addTextMatchMarker(range, active); 16 internals.addTextMatchMarker(range, active);
17 } 17 }
18 18
19 if (window.internals) { 19 if (window.internals) {
20 onload = function() { 20 onload = function() {
21 highlightRange(document.getElementById('b1').nextSibling, 0, 3, false); 21 highlightRange(document.getElementById('b1').nextSibling, 0, 3, 'kInactive') ;
22 highlightRange(document.getElementById('b2').nextSibling, 0, 3, true); 22 highlightRange(document.getElementById('b2').nextSibling, 0, 3, 'kActive');
23 internals.setMarkedTextMatchesAreHighlighted(document, true); 23 internals.setMarkedTextMatchesAreHighlighted(document, true);
24 }; 24 };
25 } 25 }
26 </script> 26 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698