@@ -258,9 +258,6 @@ interface Fragment {
258
258
readonly attribute double inlineSize;
259
259
readonly attribute double blockSize;
260
260
261
- readonly attribute double inlineOverflowSize;
262
- readonly attribute double blockOverflowSize;
263
-
264
261
attribute double inlineOffset;
265
262
attribute double blockOffset;
266
263
@@ -279,10 +276,6 @@ requires a different {{Fragment/inlineSize}} or {{Fragment/blockSize}} the autho
279
276
{{LayoutChild/layoutNextFragment()}} again with different arguments in order to get different
280
277
results.
281
278
282
- The {{Fragment}} has {{Fragment/inlineOverflowSize}} and {{Fragment/blockOverflowSize}} attributes.
283
- This is the size of the overflow area of the fragment. If the fragment didn't overflow these
284
- attributes will be the same as {{Fragment/inlineSize}} and {{Fragment/blockSize}} respectively.
285
-
286
279
The author inside the current layout can position a resulting {{Fragment}} by setting its
287
280
{{Fragment/inlineOffset}} and {{Fragment/blockOffset}} attributes. If not set by the author they
288
281
default to zero.
@@ -335,16 +328,13 @@ registerLayout('block-like', class extends Layout {
335
328
blockOffset += fragment.blockSize;
336
329
}
337
330
338
- const inlineOverflowSize = maxChildInlineSize + bordersAndPadding.inlineEnd;
339
- const blockOverflowSize = blockOffset + bordersAndPadding.blockEnd;
331
+ const contentSize = blockOffset + bordersAndPadding.blockEnd;
340
332
const blockSize = resolveBlockSize(
341
- constraintSpace, styleMap, blockOverflowSize );
333
+ constraintSpace, styleMap, contentSize );
342
334
343
335
return {
344
336
inlineSize: inlineSize,
345
337
blockSize: blockSize,
346
- inlineOverflowSize: inlineOverflowSize,
347
- blockOverflowSize: blockOverflowSize,
348
338
childFragments: childFragments,
349
339
};
350
340
}
@@ -381,9 +371,6 @@ interface ConstraintSpace {
381
371
readonly attribute double percentageInlineSize;
382
372
readonly attribute double percentageBlockSize;
383
373
384
- readonly attribute boolean inlineOverflow;
385
- readonly attribute boolean blockOverflow;
386
-
387
374
readonly attribute BlockFragmentationType blockFragmentationType;
388
375
};
389
376
@@ -481,8 +468,6 @@ registerLayout('flex-distribution-like', class {
481
468
return {
482
469
inlineSize: inlineSize,
483
470
blockSize: blockSize,
484
- inlineOverflowSize: Math.max(inlineSize, totalSize),
485
- blockOverflowSize: maxChildBlockSize,
486
471
childFragments: childFragments,
487
472
};
488
473
}
@@ -573,7 +558,6 @@ registerLayout('basic-inline', class extends Layout {
573
558
scrollbarSize.block;
574
559
575
560
const childFragments = [];
576
- let maxInlineSize = 0;
577
561
578
562
let currentLine = [];
579
563
let usedInlineSize = 0;
@@ -584,10 +568,6 @@ registerLayout('basic-inline', class extends Layout {
584
568
585
569
// Just a small little function which will update the above variables.
586
570
const nextLine = function() {
587
- if (usedInlineSize > maxInlineSize) {
588
- maxInlineSize = usedInlineSize;
589
- }
590
-
591
571
currentLine = [];
592
572
usedInlineSize = 0;
593
573
maxBaseline = 0;
@@ -668,19 +648,17 @@ registerLayout('basic-inline', class extends Layout {
668
648
669
649
// Determine our block size.
670
650
nextLine();
671
- const blockOverflowSize = lineOffset +
651
+ const contentSize = lineOffset +
672
652
bordersAndPadding.blockStart +
673
653
bordersAndPadding.blockEnd;
674
654
const blockSize = resolveBlockSize(constraintSpace,
675
655
styleMap,
676
- blockOverflowSize );
656
+ contentSize );
677
657
678
658
// Return our fragment.
679
659
const result = {
680
660
inlineSize: inlineSize,
681
661
blockSize: blockSize,
682
- inlineOverflowSize: maxInlineSize,
683
- blockOverflowSize: blockOverflowSize,
684
662
childFragments: childFragments,
685
663
}
686
664
@@ -866,6 +844,7 @@ map is empty; it is populated when {{registerLayout(name, layoutCtor)}} is calle
866
844
The {{LayoutWorkletGlobalScope}} has a <a>map</a> of <dfn>layout class instances</dfn> . Initially
867
845
this map is empty; it is populated when {{registerLayout(name, layoutCtor)}} is called.
868
846
847
+ <div algorithm>
869
848
When the <dfn method for=LayoutWorkletGlobalScope>registerLayout(|name|, |layoutCtor|)</dfn> method
870
849
is called, the user agent <em> must</em> run the following steps:
871
850
1. If the |name| is an empty string, <a>throw</a> a <a>TypeError</a> and abort all these steps.
@@ -991,6 +970,7 @@ is called, the user agent <em>must</em> run the following steps:
991
970
}
992
971
</pre>
993
972
</div>
973
+ </div>
994
974
995
975
Layout Engine {#layout-engine}
996
976
------------------------------
@@ -1076,8 +1056,6 @@ Performing Layout {#performing-layout}
1076
1056
dictionary FragmentResultOptions {
1077
1057
double inlineSize = 0;
1078
1058
double blockSize = 0;
1079
- double inlineOverflowSize = null;
1080
- double blockOverflowSize = null;
1081
1059
sequence<Fragment> childFragments = [];
1082
1060
BreakTokenOptions breakToken = null;
1083
1061
double alignmentBaseline = null;
@@ -1201,29 +1179,6 @@ context</a> for a given |box|, |constraintSpace|, |children| and an optional |br
1201
1179
1202
1180
- The <a>block size</a> is set to |fragmentResult|'s {{FragmentResultOptions/blockSize}} .
1203
1181
1204
- - The <b> inline overflow size</b> is set to |fragmentResult|'s
1205
- {{FragmentResultOptions/inlineOverflowSize}} if not null, otherwise it is set to
1206
- {{FragmentResultOptions/inlineSize}} .
1207
-
1208
- Issue: REMOVE THIS.
1209
-
1210
- - The <b> block overflow size</b> is set to |fragmentResult|'s
1211
- {{FragmentResultOptions/blockOverflowSize}} if not null, otherwise it is set to
1212
- {{FragmentResultOptions/blockSize}} .
1213
-
1214
- If the |constraintSpace|'s {{ConstraintSpace/inlineOverflow}} is <code> false</code> and
1215
- the <b> inline overflow size</b> is greater than the <a>inline size</a> and the <a>computed
1216
- value</a> for <a>inline</a> 'overflow' is ''overflow/auto'' then set |constraintSpace|'s
1217
- {{ConstraintSpace/inlineOverflow}} to <code> true</code> .
1218
-
1219
- If the |constraintSpace|'s {{ConstraintSpace/blockOverflow}} is <code> false</code> and the
1220
- <b> block overflow size</b> is greater than the <a>block size</a> and the <a>computed
1221
- value</a> for <a>block</a> 'overflow' is ''overflow/auto'' then set |constraintSpace|'s
1222
- {{ConstraintSpace/blockOverflow}} to <code> true</code> .
1223
-
1224
- If either {{ConstraintSpace/inlineOverflow}} or {{ConstraintSpace/blockOverflow}} were set
1225
- in the above steps, restart this algorithm with the updated |constraintSpace|.
1226
-
1227
1182
Note: In a future level of the specification there may be a way to more efficiently abort
1228
1183
a layout given a "scroll trigger line" on the constraint space.
1229
1184
0 commit comments