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

Unified Diff: third_party/WebKit/Source/core/paint/README.md

Issue 2844803007: Introduce FragmentData, and put ObjectPaintProperties into it. (Closed)
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/paint/README.md
diff --git a/third_party/WebKit/Source/core/paint/README.md b/third_party/WebKit/Source/core/paint/README.md
index 34d5d5712b14700197c4c57d573e17c72ec4c171..137202890c8d45be15dadddb82e8f10d5b523785 100644
--- a/third_party/WebKit/Source/core/paint/README.md
+++ b/third_party/WebKit/Source/core/paint/README.md
@@ -201,19 +201,45 @@ When this happens, we invalidate all `InlineBox`es in the first line.
TODO(wangxianzhu): add details
-## [`PrePaintTreeWalk`](PrePaintTreeWalk.h) (Slimming paint v2 only)
+## [`PrePaintTreeWalk`](PrePaintTreeWalk.h) (Slimming Paint invalidaiton/v2 only)
During `InPrePaint` document lifecycle state, this class is called to walk the whole
layout tree, beginning from the root FrameView, across frame boundaries. We do the
following during the tree walk:
-* Building paint property tree: creates paint property tree nodes for special
- things in the layout tree, including but not limit to: overflow clip, transform,
- fixed-pos, animation, mask, filter, etc. Also sets direct compositing reasons to be
- used later for compositing.
+### Building paint property trees (`PaintPropertyTreeBuilder`](PaintPropertyTreeBuilder.h)
+
+This class is responsible for building property trees
pdr. 2017/04/28 23:13:40 Nit: please fix the column wrapping.
chrishtr 2017/05/02 00:55:55 Done.
+(see [the platform paint README file](../../platform/graphics/paint/README.md)).
+
+Each `PaintLayer`'s `LayoutObject` has one or more `FragmentData` objects (see
+below for more on fragments). Every `FragmentData` has an `ObjectPaintProperties` object if any property nodes
+are induced by it. For example, if the object has a transform, its `ObjectPaintProperties::Transform()`
+field points at the `TransformPaintPropertyNode` representing that transform.
+
+The `NeedsPaintPropertyUpdate`, `SubtreeNeedsPaintPropertyUpdate` and `DescendantNeedsPaintPropertyUpdate`
+dirty bits on `LayoutObject` control how much of the layout tree is traversed during each `PrePaintTreeWalk`.
+
+#### Fragments
+
+In the absence of multicolumn/pagination, there is a 1:1 correspondence betwen
pdr. 2017/04/28 23:13:41 between
chrishtr 2017/05/02 00:55:55 Done
+self-painting `PaintLayer`s and `FragmentData`. If there is multicolumn/pagination, there
+may be more fragments. If a `PaintLayer` has a property node, each of its fragments will have
pdr. 2017/04/28 23:13:40 ... may be more `FragmentData`s.
chrishtr 2017/05/02 00:55:55 Done.
+one. The parent of a fragment's property node is the property node that belongs to the ancestor
+`PaintLayer` which part of the same column. For example, if there are 3 columns and both
pdr. 2017/04/28 23:13:40 ...which [is] part...
chrishtr 2017/05/02 00:55:56 Done.
+a parent and child `PaintLayer` have a transform, there wil be 3 `FragmentData`
pdr. 2017/04/28 23:13:41 will
chrishtr 2017/05/02 00:55:56 Done.
+objects for the parent, 3 for the child, each `FragmentData` will have its own
+`TransformPaintPropertyNode`, and the child's ith fragment's transform will point to the ith
+parent's transform.
+
+See [`LayoutMultiColumnFlowThread.h`](../layout/LayoutMultiColumnFlowThread.h)
+for a much more detail about multicolumn/pagination.
+
+### Paint invalidation: `PaintInvalidator` implements a tree walk that performs
+paint invalidation. TODO(wangxianzhu): expand on this.
+
+# [`PaintPropertyTreeBuilder`](PaintPropertyTreeBuilder.h) (Slimming Paint invalidation only)
-* Paint invalidation: Not implemented yet. TODO(wangxianzhu): add details after
- it's implemented.
## Paint result caching
« no previous file with comments | « third_party/WebKit/Source/core/paint/FragmentData.cpp ('k') | third_party/WebKit/Source/core/paint/RarePaintData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698