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 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
373 LayoutUnit logicalLeftLayoutOverflow() const { return style()->isHorizontalW ritingMode() ? layoutOverflowRect().x() : layoutOverflowRect().y(); } | 373 LayoutUnit logicalLeftLayoutOverflow() const { return style()->isHorizontalW ritingMode() ? layoutOverflowRect().x() : layoutOverflowRect().y(); } |
374 LayoutUnit logicalRightLayoutOverflow() const { return style()->isHorizontal WritingMode() ? layoutOverflowRect().maxX() : layoutOverflowRect().maxY(); } | 374 LayoutUnit logicalRightLayoutOverflow() const { return style()->isHorizontal WritingMode() ? layoutOverflowRect().maxX() : layoutOverflowRect().maxY(); } |
375 | 375 |
376 LayoutRect visualOverflowRect() const override; | 376 LayoutRect visualOverflowRect() const override; |
377 LayoutUnit logicalLeftVisualOverflow() const { return style()->isHorizontalW ritingMode() ? visualOverflowRect().x() : visualOverflowRect().y(); } | 377 LayoutUnit logicalLeftVisualOverflow() const { return style()->isHorizontalW ritingMode() ? visualOverflowRect().x() : visualOverflowRect().y(); } |
378 LayoutUnit logicalRightVisualOverflow() const { return style()->isHorizontal WritingMode() ? visualOverflowRect().maxX() : visualOverflowRect().maxY(); } | 378 LayoutUnit logicalRightVisualOverflow() const { return style()->isHorizontal WritingMode() ? visualOverflowRect().maxX() : visualOverflowRect().maxY(); } |
379 | 379 |
380 LayoutRect selfVisualOverflowRect() const { return m_overflow ? m_overflow-> selfVisualOverflowRect() : borderBoxRect(); } | 380 LayoutRect selfVisualOverflowRect() const { return m_overflow ? m_overflow-> selfVisualOverflowRect() : borderBoxRect(); } |
381 LayoutRect contentsVisualOverflowRect() const { return m_overflow ? m_overfl ow->contentsVisualOverflowRect() : LayoutRect(); } | 381 LayoutRect contentsVisualOverflowRect() const { return m_overflow ? m_overfl ow->contentsVisualOverflowRect() : LayoutRect(); } |
382 | 382 |
383 // These methods don't mean the box *actually* has top/left overflow. They mean that | |
cbiesinger
2016/05/11 19:44:00
maybe rename to canOverflowTo{Top,Left}?
| |
384 // *if* the box overflows, it will overflow to the top/left rather than the bottom/right. | |
385 // This happens when child content is laid out right-to-left (e.g. direction :rtl) or | |
386 // or bottom-to-top (e.g. direction:rtl writing-mode:vertical-rl). | |
387 virtual bool hasTopOverflow() const; | |
leviw_travelin_and_unemployed
2016/05/10 17:52:42
The name still strikes me as confusing (seems like
| |
388 virtual bool hasLeftOverflow() const; | |
389 | |
383 void addLayoutOverflow(const LayoutRect&); | 390 void addLayoutOverflow(const LayoutRect&); |
384 void addSelfVisualOverflow(const LayoutRect&); | 391 void addSelfVisualOverflow(const LayoutRect&); |
385 void addContentsVisualOverflow(const LayoutRect&); | 392 void addContentsVisualOverflow(const LayoutRect&); |
386 | 393 |
387 void addVisualEffectOverflow(); | 394 void addVisualEffectOverflow(); |
388 LayoutRectOutsets computeVisualEffectOverflowOutsets() const; | 395 LayoutRectOutsets computeVisualEffectOverflowOutsets() const; |
389 void addOverflowFromChild(LayoutBox* child) { addOverflowFromChild(child, ch ild->locationOffset()); } | 396 void addOverflowFromChild(LayoutBox* child) { addOverflowFromChild(child, ch ild->locationOffset()); } |
390 void addOverflowFromChild(LayoutBox* child, const LayoutSize& delta); | 397 void addOverflowFromChild(LayoutBox* child, const LayoutSize& delta); |
391 void clearLayoutOverflow(); | 398 void clearLayoutOverflow(); |
392 void clearAllOverflows() { m_overflow.clear(); } | 399 void clearAllOverflows() { m_overflow.clear(); } |
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
864 LayoutRect visualOverflowRectForPropagation(const ComputedStyle&) const; | 871 LayoutRect visualOverflowRectForPropagation(const ComputedStyle&) const; |
865 LayoutRect logicalLayoutOverflowRectForPropagation(const ComputedStyle&) con st; | 872 LayoutRect logicalLayoutOverflowRectForPropagation(const ComputedStyle&) con st; |
866 LayoutRect layoutOverflowRectForPropagation(const ComputedStyle&) const; | 873 LayoutRect layoutOverflowRectForPropagation(const ComputedStyle&) const; |
867 | 874 |
868 bool hasOverflowModel() const { return m_overflow.get(); } | 875 bool hasOverflowModel() const { return m_overflow.get(); } |
869 bool hasSelfVisualOverflow() const { return m_overflow && !borderBoxRect().c ontains(m_overflow->selfVisualOverflowRect()); } | 876 bool hasSelfVisualOverflow() const { return m_overflow && !borderBoxRect().c ontains(m_overflow->selfVisualOverflowRect()); } |
870 bool hasVisualOverflow() const { return m_overflow && !borderBoxRect().conta ins(visualOverflowRect()); } | 877 bool hasVisualOverflow() const { return m_overflow && !borderBoxRect().conta ins(visualOverflowRect()); } |
871 | 878 |
872 virtual bool needsPreferredWidthsRecalculation() const; | 879 virtual bool needsPreferredWidthsRecalculation() const; |
873 | 880 |
881 // See README.md for an explanation of scroll origin. | |
882 virtual IntSize originAdjustmentForScrollbars() const; | |
874 IntSize scrolledContentOffset() const; | 883 IntSize scrolledContentOffset() const; |
875 | 884 |
876 // Maps a rect in scrolling contents space to box space and apply overflow c lip if needed. | 885 // Maps a rect in scrolling contents space to box space and apply overflow c lip if needed. |
877 // Returns true if no clipping applied or the rect actually intersects the c lipping region. | 886 // Returns true if no clipping applied or the rect actually intersects the c lipping region. |
878 // If edgeInclusive is true, then this method may return true even | 887 // If edgeInclusive is true, then this method may return true even |
879 // if the resulting rect has zero area. | 888 // if the resulting rect has zero area. |
880 bool mapScrollingContentsRectToBoxSpace(LayoutRect&, ApplyOverflowClipFlag, VisualRectFlags = DefaultVisualRectFlags) const; | 889 bool mapScrollingContentsRectToBoxSpace(LayoutRect&, ApplyOverflowClipFlag, VisualRectFlags = DefaultVisualRectFlags) const; |
881 | 890 |
882 virtual bool hasRelativeLogicalWidth() const; | 891 virtual bool hasRelativeLogicalWidth() const; |
883 virtual bool hasRelativeLogicalHeight() const; | 892 virtual bool hasRelativeLogicalHeight() const; |
(...skipping 295 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1179 || breakValue == BreakLeft | 1188 || breakValue == BreakLeft |
1180 || breakValue == BreakPage | 1189 || breakValue == BreakPage |
1181 || breakValue == BreakRecto | 1190 || breakValue == BreakRecto |
1182 || breakValue == BreakRight | 1191 || breakValue == BreakRight |
1183 || breakValue == BreakVerso; | 1192 || breakValue == BreakVerso; |
1184 } | 1193 } |
1185 | 1194 |
1186 } // namespace blink | 1195 } // namespace blink |
1187 | 1196 |
1188 #endif // LayoutBox_h | 1197 #endif // LayoutBox_h |
OLD | NEW |