@@ -74,7 +74,7 @@ box based on that box's size (as generated by the layout stage) and computed sty
74
74
This specification describes an API which allows developers to paint a part of a box in
75
75
response to size / computed style changes with an additional <<image>> function.
76
76
77
- Note: In a future version of the spec, support may be added for defining the clip, global alpha,
77
+ Note: In a future version of the spec, support could be added for defining the clip, global alpha,
78
78
filter on a portion of a box (for example on the background layers).
79
79
80
80
Paint Invalidation {#paint-invalidation}
@@ -107,9 +107,9 @@ When the computed style for a |box| changes, the user agent <em>must</em> run th
107
107
Performing <a>draw a paint image</a> results in the <a>paint valid flag</a> for a <<paint()>>
108
108
function on a box to be set to <a>paint-valid</a> .
109
109
110
- Note: In a future version of the spec, support may be added for partial invalidation. The user agent
111
- will be able to specify a region of the rendering context which needs to be re-painted by the
112
- paint class.
110
+ Note: In a future version of the spec, support could be added for partial invalidation. The user
111
+ agent will be able to specify a region of the rendering context which needs to be re-painted by
112
+ the paint class.
113
113
114
114
Paint Worklet {#paint-worklet}
115
115
==============================
@@ -315,9 +315,9 @@ called, the user agent <em>must</em> run the following steps:
315
315
Note: The list of input properties should only be looked up once, the class doesn't have the
316
316
opportunity to dynamically change its input properties.
317
317
318
- Note: In a future version of the spec, the author may be able to set an option to receive a
319
- different type of RenderingContext. In particular the author may want a WebGL rendering context
320
- to render 3D effects. There are complexities in setting up a WebGL rendering context to take the
318
+ Note: In a future version of the spec, the author could have the ability to receive a different type
319
+ of RenderingContext. In particular the author may want a WebGL rendering context to render 3D
320
+ effects. There are complexities in setting up a WebGL rendering context to take the
321
321
{{PaintSize}} and {{StylePropertyMap}} as inputs.
322
322
</div>
323
323
@@ -438,7 +438,7 @@ negotiation</a> algorithm which is responsible for rendering an <<image>>.
438
438
For the purposes of the <a>object size negotiation</a> algorithm, the paint image has no
439
439
<a>intrinsic dimensions</a> .
440
440
441
- Note: In a future version of the spec, the author may be able to specify the <a>intrinsic
441
+ Note: In a future version of the spec, the author could have the ability to specify the <a>intrinsic
442
442
dimensions</a> of the paint image. This will probably be exposed as a callback allowing the
443
443
author to define static <a>intrinsic dimensions</a> or dynamically updating the <a>intrinsic
444
444
dimensions</a> based on computed style and size changes.
@@ -534,8 +534,8 @@ following steps:
534
534
The user agent <em> may</em> also <a>create a WorkletGlobalScope</a> given the paint
535
535
{{Worklet}} and use that.
536
536
537
- Note: The user agent <em> may </em> use any policy for which {{PaintWorkletGlobalScope}} to
538
- select or create. It may use a single {{PaintWorkletGlobalScope}} or multiple and
537
+ Note: The user agent can use any policy for which {{PaintWorkletGlobalScope}} to select or
538
+ create. For example it could use a single {{PaintWorkletGlobalScope}} or multiple and
539
539
randomly assign between them.
540
540
541
541
13. Run <a>invoke a paint callback</a> given |name|, |inputArguments|, |concreteObjectSize|,
@@ -565,10 +565,10 @@ When the user agent wants to <dfn>invoke a paint callback</dfn> given |name|, |i
565
565
566
566
2. Let the image output be an <a>invalid image</a> and abort all these steps.
567
567
568
- Note: This handles the case where there may be a paint worklet global scope which didn't
568
+ Note: This handles the case where there could be a paint worklet global scope which didn't
569
569
receive the {{registerPaint(name, paintCtor)}} for |name| (however another global scope
570
- did). A paint callback which is invoked on the other global scope may succeed, but wont
571
- succeed on a subsequent frame when <a>draw a paint image</a> is called.
570
+ did). A paint callback which is invoked on the other global scope could succeed, but
571
+ wont succeed on a subsequent frame when <a>draw a paint image</a> is called.
572
572
573
573
3. Let |definition| be the result of <a>get</a> |paintDefinitionMap|[|name|] .
574
574
@@ -600,8 +600,8 @@ When the user agent wants to <dfn>invoke a paint callback</dfn> given |name|, |i
600
600
- "height" - The height given by |concreteObjectSize|.
601
601
- "alpha" - The <a for="paint definition">context alpha flag</a> given by |definition|.
602
602
603
- Note: The |renderingContext| must not be re-used between invocations of paint. Implicitly
604
- this means that there is no stored data, or state on the |renderingContext| between
603
+ Note: The |renderingContext| is not be re-used between invocations of paint. Implicitly this
604
+ means that there is no stored data, or state on the |renderingContext| between
605
605
invocations. For example you can't setup a clip on the context, and expect the same clip
606
606
to be applied next time the paint method is called.
607
607
@@ -622,13 +622,13 @@ When the user agent wants to <dfn>invoke a paint callback</dfn> given |name|, |i
622
622
623
623
If an exception is <a>thrown</a> the let the image output be an <a>invalid image</a> .
624
624
625
- Note: The user agent <em> should </em> consider long running paint functions similar to long running
626
- script in the main execution context. For example, they <em> should </em> show a "unresponsive
627
- script" dialog or similar. In addition user agents <em> should </em> provide tooling within their
628
- debugging tools to show authors how expensive their paint classes are.
625
+ Note: The user agent can consider long running paint functions similar to long running script in the
626
+ main execution context. For example, they could show a "unresponsive script" dialog or similar.
627
+ In addition user agents could provide tooling within their debugging tools to show authors how
628
+ expensive their paint classes are.
629
629
630
- Note: The contents of the resulting image are not designed to be accessible. Authors <em> should </em>
631
- communicate any useful information through the standard accessibility APIs.
630
+ Note: The contents of the resulting image are not designed to be accessible. Authors can communicate
631
+ any useful information through the standard accessibility APIs.
632
632
</div>
633
633
634
634
Examples {#examples}
0 commit comments