John Sullivan recommended I file a bug to track this. The TextMatches in WebKit don't differentiate between active and inactive matches. It would be very useful for the ports that use TextMatches for FindInPage to be able to specify which TextMatches are active and which are not. This would also involve splitting up platformTextSearchHighlightColor into two, to provide an Active color and an Inactive color. I'm in the middle of writing such a patch. This bug tracks that effort.
Created attachment 29371 [details] Allowing the TextMatch marker to specify active/not Attached is a proposed patch that fixes this.
Comment on attachment 29371 [details] Allowing the TextMatch marker to specify active/not > Index: dom/Document.h > =================================================================== > --- dom/Document.h (revision 42365) > +++ dom/Document.h (working copy) > @@ -699,6 +699,8 @@ public: > void setRenderedRectForMarker(Node*, DocumentMarker, const IntRect&); > void invalidateRenderedRectsForMarkersInRect(const IntRect&); > void shiftMarkers(Node*, unsigned startOffset, int delta, DocumentMarker::MarkerType = DocumentMarker::AllMarkers); > + void setMarkersActive(Range*, bool); > + void setMarkersActive(Node*, unsigned, unsigned, bool); The two unsigned parameters here should be given names in this declaration since it's otherwise not clear what they represent. The patch otherwise seems fine to me. Please submit a new patch with this change.
Created attachment 29377 [details] Addressing review comments Reviewed in half an hour. Not a bad turnaround. Not at all. :)
Landed as: http://trac.webkit.org/changeset/42393
And the follow-up bustage fix: http://trac.webkit.org/changeset/42394