[go: nahoru, domu]

[Paint Preview] Blink Implementation of Paint Preview

This CL implements the required code to capture paint previews in Blink.
The majority of the code is shared with printing; however, new flags are
introduced to handle the differences between printing and painting of
previews. This CL *does not* introduce support for OOP iframe paint
previews and scrolling them (to be handled in a separate CL).

Desired Behaviors;
- Paint Previews should look exactly like the current webpage and should
  not reformat in the way printing does. This includes ignoring print
  display tags and the simplifications used in painting.
- Paint Previews should re-layout to be the full contents of the page
  not just the viewport. This is achieved by printing to a canvas the
  size of the document (single page).
- Paint Previews should print to a single Skia Picture (per frame)
  rather than a Metafile Skia Document.

Design doc: go/fdt-design
Part of landing:
https://chromium-review.googlesource.com/c/chromium/src/+/1786583

Bug: 1001109
Change-Id: If0e947befea8ecc78b2cbee950e8c1cbd8e1281e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1844057
Reviewed-by: Elly Fong-Jones <ellyjones@chromium.org>
Reviewed-by: Philip Rogers <pdr@chromium.org>
Commit-Queue: Calder Kitagawa <ckitagawa@chromium.org>
Cr-Commit-Position: refs/heads/master@{#713822}
20 files changed