Find-in-page per block using FindBuffer

This CL introduces FindBuffer, which Find-in-page will use to find
matches instead of using FindPlainText that uses TextIterator.

Since find-in-page matches can't span multiple blocks, we are using
that fact to know where we can separate the text in the document.
FindBuffer collects text one block at a time, and then finds the match
in that block. We trigger FindBuffer text collection & finding many
times until it goes through everything. FindInPage uses TextSearcherICU
to find text, and uses flat-tree traversal, ComputedStyle, and
LayoutObject + NGOffsetMapping, whereas the previous way was to use
TextIterator.

This CL also changes the way we handle newlines - newlines will be
saved as object replacement character/whitespaces for Find-in-page
purposes. Some tests that rely on newlines are deleted as a result.
Note:
This change is not user-visible because it is not possible to do a
Find-in-page from the UI with newlines.

See doc for details:
https://docs.google.com/document/d/1D5q7ZMrLPfilXnIGI3SOL0mwdiQC7SQEtGWk-9ysbMg/edit?usp=sharing

Bug: 868227
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_layout_ng
Change-Id: Id5dd7e6c428f59442d02ec88ea0cec6eb4e64c22
Reviewed-on: https://chromium-review.googlesource.com/c/1282425
Commit-Queue: Rakina Zata Amni <rakina@chromium.org>
Reviewed-by: Elly Fong-Jones <ellyjones@chromium.org>
Reviewed-by: Xiaocheng Hu <xiaochengh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#616701}
7 files changed