-
Notifications
You must be signed in to change notification settings - Fork 707
[css-inline-3] text-box-trim vs fragmentation #5335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I propose that we apply
The spec would say: if the contents of an element with Note: in other words, Note: the second sentence is to avoid a circularity. In terms of implementation, this will require a mechanism to lay out "without trimming" and then adjust layout to take into account trimming, but I think that will be needed anyway in order to detect the "last line to trim" in cases where it isn't clear from markup. |
I can see why trimming at the top of a page might be something to avoid in cases where the browser doesn't know how to draw into the page margin/padding area, so it makes sense to allow it. But I doubt it's ideal, because it doesn't allow authors to control things lining up in such cases. We probably want to (eventually) get trimming to work equally on pages and columns. Also, there's really two questions here:
Either way, we probably need to enable ink overflow of line boxes to spill out of the page content area. |
I suggest yes, for the column case.
I suggest no. |
The CSS Working Group just discussed
The full IRC log of that discussion<Frances> github-bot #335<Frances> fantasai: One consideration is when requesting text-box:trim, if it lands at the top of the page, we have ink spilling out of the page. Currently gets clipped out. If specifying cap height and land at the top of the page, accent marks will get clipped. <Frances> fantasai: Do we want to specify that ink-overflow can spill onto the padding area and if so do we want to allow implementations to pull content. How to approach the problem of clipping? <Frances> fantasai: Trim at the bottom of the page or at the next page? We need some way to control it and make it happen, with a consistent top edge. <bradk> +1 to allowing ink to spill over, similar to box-shadow <Rossen_> q? <Frances> fantasai: Need a way to handle text-box-trim for the correct padding and border of content. Two issues: clipping and separate control for fragmentation breaks. <fantasai> s/Need a way to handle text-box-trim for the correct padding and border of content./If using text-box-trim for correct spacing between content and border, don't necessarily want to trim at fragmentation breaks/ <Frances> chris h: Bbecause it is more difficult to implement with more complexities, text-box-trim does not apply for printing <Frances> Rossen: Allows for additive behavior in the future. Need to specify it correctly. <fantasai> s/Trim at the bottom/Other question is, if the paragraphs fragments in the middle, do we trim at the bottom/ <astearns> -1 to not applying to print. Would there be a way to allow it in print except for at page breaks? <Frances> Florian: Need to define cleanly the boundary. In typography such as using css to make printed material or like printing. About fragmentation, should not say print, possibly relevant. <Frances> Florian: Needs to work for printing. We need to work on this and not call the compat trap. <Frances> fantasai: Shouldn't disable trim for printing, need to spec the ideal behavior to the extent that it can be printed. Might allow user agents that can't do that, shift it down the page to use the text glyphs. <Rossen_> ack fantasai <Frances> chris h: The two together sound fine. <Frances> PROPOSAL: ink-overflow spills out of the page content area into padding and margins, user agents that can't draw paint overflow may shift content down to avoid clipping. <fantasai> s/paint overflow/ink overflow/ <fantasai> +1 <Frances> rossen: objections? <Frances> RESOLUTION: ink-overflow spills out of the page content area into padding and margins, user agents that can't draw paint overflow may shift content down to avoid clipping <Frances> fantasai: A question around text-box-trim taking affect. Should be a separate property to control them indepdently. <Frances> Chris H: Specify in the property, not overflow between columns. <Rossen_> s/RESOLUTION/RESOLVED/ <dbaron> s/Specify in the property/just operates at the top of the first fragment and the bottom of the last fragment/ <dbaron> fantasai: I'd want it to follow box-decoration-break <Frances> PROPOSAL: Should text-box-trim apply at fragmentation breaks, depends on the box-decoration-break property <Frances> Rossen: Objections? <Frances> RESOLVED: Should text-box-trim apply at fragmentation breaks, depend on the box-decoration-break property <chrishtr> Thanks all! <Frances> fantasai: fragmentation case possibly need an independent control. Could be a separate feature. <Rossen_> Zakim, end meeting |
The `text-box-trim` should apply only to the top of the first fragment and the bottom of the last fragment, resolved at w3c/csswg-drafts#5335. This patch adds tests for this, `001` for when the `text-box-trim` is applied to the multicol container, and `002` for when a box with `text-box-trim` is block fragmented by ancestor multicol. Bug: 40254880 Change-Id: Ice29f39cbef0c20284edd809942754176a395d23 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5564105 Reviewed-by: Kent Tamura <[email protected]> Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1305545}
The `text-box-trim` should apply only to the top of the first fragment and the bottom of the last fragment, resolved at w3c/csswg-drafts#5335. This patch adds tests for this, `001` for when the `text-box-trim` is applied to the multicol container, and `002` for when a box with `text-box-trim` is block fragmented by ancestor multicol. Bug: 40254880 Change-Id: Ice29f39cbef0c20284edd809942754176a395d23 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5564105 Reviewed-by: Kent Tamura <[email protected]> Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1305545}
… a=testonly Automatic update from web-platform-tests [text-box-trim] Add tests for multi-col The `text-box-trim` should apply only to the top of the first fragment and the bottom of the last fragment, resolved at w3c/csswg-drafts#5335. This patch adds tests for this, `001` for when the `text-box-trim` is applied to the multicol container, and `002` for when a box with `text-box-trim` is block fragmented by ancestor multicol. Bug: 40254880 Change-Id: Ice29f39cbef0c20284edd809942754176a395d23 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5564105 Reviewed-by: Kent Tamura <[email protected]> Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1305545} -- wpt-commits: 592dc0a3df19c530baec9079edce72a2625b798e wpt-pr: 46470
… a=testonly Automatic update from web-platform-tests [text-box-trim] Add tests for multi-col The `text-box-trim` should apply only to the top of the first fragment and the bottom of the last fragment, resolved at w3c/csswg-drafts#5335. This patch adds tests for this, `001` for when the `text-box-trim` is applied to the multicol container, and `002` for when a box with `text-box-trim` is block fragmented by ancestor multicol. Bug: 40254880 Change-Id: Ice29f39cbef0c20284edd809942754176a395d23 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5564105 Reviewed-by: Kent Tamura <[email protected]> Commit-Queue: Kent Tamura <[email protected]> Auto-Submit: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1305545} -- wpt-commits: 592dc0a3df19c530baec9079edce72a2625b798e wpt-pr: 46470
@jensimmons and I discussed the related (but now a bit different) question of what |
The CSS Working Group just discussed The full IRC log of that discussion<astearns> q+<andreubotella> fantasai: I was chatting with Jen Simmons about how text-box-trim interacts with fragmentation. We have a discussion about setting text-box-trim in a box in the flow that gets fragment, but not on the multicol element. There's a lot of column boxes inside it, should it apply to any of them? <andreubotella> Probably makes sense to apply to the first and last line box in each column <andreubotella> assuming there's no intervening padding or borders <chrishtr> +1 <miriam> +1 <andreubotella> frivoal: makes sense to me <andreubotella> astearns: I know of a use case where we'd want to trim all of the top and bottom (?) of a column except for the very first and last. But we can handle that with the :column element <andreubotella> frivoal: I'm aware of that for trimming margins, but this issue is about trimming the top and bottom of lines. Is that correct as well? <andreubotella> astearns: You might be right that it might apply only to margins. There might also be a usefulness for lines. But yes, it should apply only to the top and bottom if it applies to multicolumn <andreubotella> bfgeek: My concern is that if applied to the end, it might shorten the column box, which might change the fragmentation point <andreubotella> fantasai: When fragmenting, you'd have to be aware of whether the line box to add to a page is trimmed or not <astearns> ack astearns <andreubotella> bfgeek: It's more complex, because of interactions with collapsing margins at the end <andreubotella> I dont' know if this is implementable for end trimming <andreubotella> frivoal: In this issue we're talking about trimming leading in lines, does that also affect? <dholbert> q+ <andreubotella> astearns: We might need some make-forward-progress algorithm where you decide where the fragmentation break is, then apply the trimming, and not reconsider the break <andreubotella> fantasai: It's similar to when trying to see if something fits, you truncate the margins. If there are borders or padding, you already cannot trim. It's different between line boxes and at the end of the element, so when you evaluate whether you fit, you trim the line box <andreubotella> if additional content fits, then you move forwards <andreubotella> frivoal: it's clear it's desirable, but not clear how doable. Can we edit it later if it's too hard? <andreubotella> fantasai: I think that's reasonable. Because margins are invisible, it doesn't matter whether you consider the box trim or not. It's only when placing the content and checking wherther it fits before the end of the page is when you need to consider trimming <andreubotella> bfgeek: What is the behavior with empty elements that are after this? <andreubotella> If there's a subsequent empty element. That's not considered (?) if there's an empty element afterwards <andreubotella> That's complex because we don't want to arbitrarily look forwards to see if this is the last <andreubotella> fantasai: If the bottom edge of my box is 1em from the bottom of the page, but it has a bottom-margin of 2em <andreubotella> we truncate the margin to the extent necessary to make it fit <astearns> ack dholbert <andreubotella> dholbert: when fantasai was talking about how it works in practice, discounting the text-box-trim for the purposes of seeing if the element fits, should it also make the element draw a smaller border box if it happens to fit when this is taken into account? <andreubotella> should the border box extend to the bottom of the column? <andreubotella> s/border box/background/ <andreubotella> fantasai: do you mean a block background or an inline background? <andreubotella> dholbert: if the line of text has a background, i'm thinking of a span that has a background <andreubotella> ... <andreubotella> fantasai: as an author, you don't want to combine text-box-trim with a block background <andreubotella> in the long term, we might want to have a control for this, similar to margin-trim for margins, but this would be the default <fantasai> s/margin-trim/margin-break/ <andreubotella> astearns: should we specify the behavior as florian suggested, and reopen the issue if there are implementability concerns? or do we take it back to the issue for now? <andreubotella> fantasai: I think this is what people would want if they set text-box-trim on multicolumn. The alternative is it doesn't apply at all <andreubotella> frivoal: If it applies only to the first column, it's worse because you have unbalanced columns <andreubotella> astearns: any objections, dholbert and bfgeek? <andreubotella> bfgeek; there's some complexity because, the way it works we'd need to backtrack. For example, you place a line box, there's 10px of space remaining. You need to lay out the next line box, because it might only be 8px <andreubotella> But if it's 12px high, you need to backtrack and go to the previous line box, and then trim it, which is a bit scary <andreubotella> you don't know if it's the last line box until you lay out the next line <andreubotella> frivoal: Having it only apply to the first column and not the others will be ugly. In general, for the problem, if we only trim at the first column it's bad <andreubotella> same for printing and pagination, if you have a multi-page document, you want the top and bottom to match <andreubotella> bfgeek: At the minimum we'd want trim-top. I'll talk to Morten to see how feasible is trimming the bottom if we have to backtrack <andreubotella> fantasai: Once you've decided that the line box fits, you can forget about whether you trimmed it. It only matters if you drew a background, and if you do, you have the question of where it ends <andreubotella> You have to make sure the background doesn't go beyond the fragmentainer edge <andreubotella> bfgeek: It affects more things than that <andreubotella> astearns: We should table the discussion of how it should work for now. bfgeek, are you okay having the conversation with Morten before resolving? <andreubotella> bfgeek: yeah <andreubotella> frivoal: Can we resolve to do it on the start side and leave the end side open? <andreubotella> astearns: We'll discuss that next time <dholbert> fwiw the "in what ways is the column-end-trimming observable [and how do we need to tidy up after ourselves after placing that line]"is the bit that I'm wondering about too |
The CSS Working Group just discussed
The full IRC log of that discussion<dholbert> fantasai: this issue is the same, but now for text-box-trim<dholbert> fantasai: if you apply text-box-trim to a multicol container, it applies to the first formatted line of each column, and analogous for the last <astearns> q? <dholbert> PROPOSED RESOLUTION: if you apply text-box-trim to a multicol container, it applies to the first formatted line of each column, and analogous for the last <dholbert> RESOLVED: if you apply text-box-trim to a multicol container, it applies to the first formatted line of each column, and analogous for the last |
There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770}
There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770}
There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770}
In our implementation, we will not apply text box trimming at page boundaries, since we're unable to paint document contents outside the page area. Since this is an implementation-specific thing (but still spec-compliant), add an internal test. See w3c/csswg-drafts#5335 (comment) Bug: 41494433 Change-Id: Ibb5e585228b2430b0fb779b64d80bcbb2d97df39 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5962276 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Rune Lillesveen <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373792}
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Koji Ishii <[email protected]> Cr-Commit-Position: refs/heads/main@{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <mstenshochromium.org> Reviewed-by: Koji Ishii <kojiichromium.org> Cr-Commit-Position: refs/heads/main{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817 UltraBlame original commit: bf38d089a241450f904e3a1bd082db60c87e348f
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <mstenshochromium.org> Reviewed-by: Koji Ishii <kojiichromium.org> Cr-Commit-Position: refs/heads/main{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817 UltraBlame original commit: bf38d089a241450f904e3a1bd082db60c87e348f
… columns., a=testonly Automatic update from web-platform-tests [text-box-trim] Trim at the start/end of columns. There are now two types of text box trimming: The already existing one, trimming at the start or end of a node. And the new one, trimming at the start or end of a fragmentainer. We need to distinguish between these, since they aren't active at the same times. Therefore, the old "should text box trim start/end" flags are now qualified with "node" (e.g. ShouldTextBoxTrimNodeStart()), and the new ones are qualified with "fragmentainer" (e.g. ShouldTextBoxTrimFragmentainerStart()). When text-box-trim is specified inside a fragmentation context, it should not cause trimming at fragmentainer breaks, unless box-decoration-break is 'clone'. See w3c/csswg-drafts#5335 (comment) When text-box-trim is specified on a multicol container (i.e. NOT inside the fragmentation context that the multicol container establishes), it should cause trimming at fragmentainer breaks. See w3c/csswg-drafts#5335 (comment) Update text-box-trim-multicol-001.html, since we now trim at fragmentainer boundaries. Also make the multicol container slightly shorter, to demonstrate that we also trim at the end of columns. Make the multicol container in text-box-trim-multicol-002.html slightly taller, to demonstrate that there's trimming at the end of columns in that case (trimming is specified on a multicol descendant, and box-decoration-break is not 'clone'). Also add more tests for trimming at column boundaries, and also some basic printing tests that simply test that text-box trimming still works, at least when they're not next to a page boundary. Blink (and all other browsers, I think) cannot paint outside the page area, so trimming is disabled at page boundaries. There will be an internal WPT test for that in an upcoming CL. Set widows and orphans to 1 in the tests. They are not meant to be affected by orphans / widows requirements anyway, but our widows calculation code is currently causing trouble for text box trimming (two different types of relayout not getting along too well), so just set it to 1 for now. A follow-up CL will fix this. Bug: 41494433 Change-Id: Ic4fc97ecf4cce3f52d5c3d8d44c3188c53970002 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5961725 Commit-Queue: Morten Stenshorne <mstenshochromium.org> Reviewed-by: Koji Ishii <kojiichromium.org> Cr-Commit-Position: refs/heads/main{#1373770} -- wpt-commits: 35a534039299fb6e3e3e27056eaf5e22342be458 wpt-pr: 48817 UltraBlame original commit: bf38d089a241450f904e3a1bd082db60c87e348f
From #3240 (comment)
The text was updated successfully, but these errors were encountered: