OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. |
5 * | 5 * |
6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
10 * | 10 * |
(...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
622 } | 622 } |
623 | 623 |
624 // Is the specified break-before or break-after value supported on this obje
ct? It needs to be | 624 // Is the specified break-before or break-after value supported on this obje
ct? It needs to be |
625 // in-flow all the way up to a fragmentation context that supports the speci
fied value. | 625 // in-flow all the way up to a fragmentation context that supports the speci
fied value. |
626 bool isBreakBetweenControllable(EBreak) const; | 626 bool isBreakBetweenControllable(EBreak) const; |
627 | 627 |
628 // Is the specified break-inside value supported on this object? It needs to
be contained by a | 628 // Is the specified break-inside value supported on this object? It needs to
be contained by a |
629 // fragmentation context that supports the specified value. | 629 // fragmentation context that supports the specified value. |
630 bool isBreakInsideControllable(EBreak) const; | 630 bool isBreakInsideControllable(EBreak) const; |
631 | 631 |
632 EBreak breakAfter() const; | 632 virtual EBreak breakAfter() const; |
633 EBreak breakBefore() const; | 633 virtual EBreak breakBefore() const; |
634 EBreak breakInside() const; | 634 EBreak breakInside() const; |
635 | 635 |
| 636 // Join two adjacent break values specified on break-before and/or break-aft
er. avoid* values |
| 637 // win over auto values, and forced break values win over avoid* values. |fi
rstValue| is |
| 638 // specified on an element earlier in the flow than |secondValue|. This meth
od is used at class |
| 639 // A break points [1], to join the values of the previous break-after and th
e next |
| 640 // break-before, to figure out whether we may, must, or should not, break at
that point. It is |
| 641 // also used when propagating break-before values from first children and br
eak-after values on |
| 642 // last children to their container. |
| 643 // |
| 644 // [1] https://drafts.csswg.org/css-break/#possible-breaks |
| 645 static EBreak joinFragmentainerBreakValues(EBreak firstValue, EBreak secondV
alue); |
| 646 |
636 static bool isForcedFragmentainerBreakValue(EBreak); | 647 static bool isForcedFragmentainerBreakValue(EBreak); |
637 | 648 |
638 bool hasForcedBreakBefore() const; | 649 EBreak classABreakPointValue(EBreak previousBreakAfterValue) const; |
639 bool hasForcedBreakAfter() const; | 650 |
| 651 // Return true if we should insert a break in front of this box. The box nee
ds to start at a |
| 652 // valid class A break point in order to allow a forced break. To determine
whether or not to |
| 653 // break, we also need to know the break-after value of the previous in-flow
sibling. |
| 654 bool needsForcedBreakBefore(EBreak previousBreakAfterValue) const; |
640 | 655 |
641 LayoutRect localOverflowRectForPaintInvalidation() const override; | 656 LayoutRect localOverflowRectForPaintInvalidation() const override; |
642 bool mapToVisualRectInAncestorSpace(const LayoutBoxModelObject* ancestor, La
youtRect&, VisualRectFlags = DefaultVisualRectFlags) const override; | 657 bool mapToVisualRectInAncestorSpace(const LayoutBoxModelObject* ancestor, La
youtRect&, VisualRectFlags = DefaultVisualRectFlags) const override; |
643 virtual void invalidatePaintForOverhangingFloats(bool paintAllDescendants); | 658 virtual void invalidatePaintForOverhangingFloats(bool paintAllDescendants); |
644 | 659 |
645 LayoutUnit containingBlockLogicalHeightForGetComputedStyle() const; | 660 LayoutUnit containingBlockLogicalHeightForGetComputedStyle() const; |
646 | 661 |
647 LayoutUnit containingBlockLogicalWidthForContent() const override; | 662 LayoutUnit containingBlockLogicalWidthForContent() const override; |
648 LayoutUnit containingBlockLogicalHeightForContent(AvailableLogicalHeightType
) const; | 663 LayoutUnit containingBlockLogicalHeightForContent(AvailableLogicalHeightType
) const; |
649 | 664 |
(...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1140 || breakValue == BreakLeft | 1155 || breakValue == BreakLeft |
1141 || breakValue == BreakPage | 1156 || breakValue == BreakPage |
1142 || breakValue == BreakRecto | 1157 || breakValue == BreakRecto |
1143 || breakValue == BreakRight | 1158 || breakValue == BreakRight |
1144 || breakValue == BreakVerso; | 1159 || breakValue == BreakVerso; |
1145 } | 1160 } |
1146 | 1161 |
1147 } // namespace blink | 1162 } // namespace blink |
1148 | 1163 |
1149 #endif // LayoutBox_h | 1164 #endif // LayoutBox_h |
OLD | NEW |