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 27 matching lines...) Expand all Loading... |
38 class ShapeOutsideInfo; | 38 class ShapeOutsideInfo; |
39 | 39 |
40 struct PaintInfo; | 40 struct PaintInfo; |
41 | 41 |
42 enum SizeType { MainOrPreferredSize, MinSize, MaxSize }; | 42 enum SizeType { MainOrPreferredSize, MinSize, MaxSize }; |
43 enum AvailableLogicalHeightType { ExcludeMarginBorderPadding, IncludeMarginBorde
rPadding }; | 43 enum AvailableLogicalHeightType { ExcludeMarginBorderPadding, IncludeMarginBorde
rPadding }; |
44 // When painting, overlay scrollbars do not take up space and should not affect | 44 // When painting, overlay scrollbars do not take up space and should not affect |
45 // clipping behavior. During hit testing, overlay scrollbars behave like regular | 45 // clipping behavior. During hit testing, overlay scrollbars behave like regular |
46 // scrollbars and should change how hit testing is clipped. | 46 // scrollbars and should change how hit testing is clipped. |
47 enum MarginDirection { BlockDirection, InlineDirection }; | 47 enum MarginDirection { BlockDirection, InlineDirection }; |
| 48 enum BackgroundRectType { BackgroundClipRect, BackgroundKnownOpaqueRect }; |
48 | 49 |
49 enum ShouldComputePreferred { ComputeActual, ComputePreferred }; | 50 enum ShouldComputePreferred { ComputeActual, ComputePreferred }; |
50 | 51 |
51 enum ApplyOverflowClipFlag { | 52 enum ApplyOverflowClipFlag { |
52 ApplyOverflowClip, | 53 ApplyOverflowClip, |
53 // Don't apply overflow clipping or scrolling. | 54 // Don't apply overflow clipping or scrolling. |
54 ApplyNonScrollOverflowClip | 55 ApplyNonScrollOverflowClip |
55 }; | 56 }; |
56 | 57 |
57 using SnapAreaSet = HashSet<const LayoutBox*>; | 58 using SnapAreaSet = HashSet<const LayoutBox*>; |
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
348 | 349 |
349 // The content area of the box (excludes padding - and intrinsic padding for
table cells, etc... - and border). | 350 // The content area of the box (excludes padding - and intrinsic padding for
table cells, etc... - and border). |
350 LayoutRect contentBoxRect() const { return LayoutRect(borderLeft() + padding
Left(), borderTop() + paddingTop(), contentWidth(), contentHeight()); } | 351 LayoutRect contentBoxRect() const { return LayoutRect(borderLeft() + padding
Left(), borderTop() + paddingTop(), contentWidth(), contentHeight()); } |
351 LayoutSize contentBoxOffset() const { return LayoutSize(borderLeft() + paddi
ngLeft(), borderTop() + paddingTop()); } | 352 LayoutSize contentBoxOffset() const { return LayoutSize(borderLeft() + paddi
ngLeft(), borderTop() + paddingTop()); } |
352 // The content box in absolute coords. Ignores transforms. | 353 // The content box in absolute coords. Ignores transforms. |
353 IntRect absoluteContentBox() const; | 354 IntRect absoluteContentBox() const; |
354 // The offset of the content box in absolute coords, ignoring transforms. | 355 // The offset of the content box in absolute coords, ignoring transforms. |
355 IntSize absoluteContentBoxOffset() const; | 356 IntSize absoluteContentBoxOffset() const; |
356 // The content box converted to absolute coords (taking transforms into acco
unt). | 357 // The content box converted to absolute coords (taking transforms into acco
unt). |
357 FloatQuad absoluteContentQuad() const; | 358 FloatQuad absoluteContentQuad() const; |
358 // The clip rect of the background. | 359 // The enclosing rectangle of the background with given opacity requirement. |
359 LayoutRect backgroundClipRect() const; | 360 LayoutRect backgroundRect(BackgroundRectType) const; |
360 | 361 |
361 // This returns the content area of the box (excluding padding and border).
The only difference with contentBoxRect is that computedCSSContentBoxRect | 362 // This returns the content area of the box (excluding padding and border).
The only difference with contentBoxRect is that computedCSSContentBoxRect |
362 // does include the intrinsic padding in the content box as this is what som
e callers expect (like getComputedStyle). | 363 // does include the intrinsic padding in the content box as this is what som
e callers expect (like getComputedStyle). |
363 LayoutRect computedCSSContentBoxRect() const { return LayoutRect(borderLeft(
) + computedCSSPaddingLeft(), borderTop() + computedCSSPaddingTop(), clientWidth
() - computedCSSPaddingLeft() - computedCSSPaddingRight(), clientHeight() - comp
utedCSSPaddingTop() - computedCSSPaddingBottom()); } | 364 LayoutRect computedCSSContentBoxRect() const { return LayoutRect(borderLeft(
) + computedCSSPaddingLeft(), borderTop() + computedCSSPaddingTop(), clientWidth
() - computedCSSPaddingLeft() - computedCSSPaddingRight(), clientHeight() - comp
utedCSSPaddingTop() - computedCSSPaddingBottom()); } |
364 | 365 |
365 void addOutlineRects(Vector<LayoutRect>&, const LayoutPoint& additionalOffse
t, IncludeBlockVisualOverflowOrNot) const override; | 366 void addOutlineRects(Vector<LayoutRect>&, const LayoutPoint& additionalOffse
t, IncludeBlockVisualOverflowOrNot) const override; |
366 | 367 |
367 // Use this with caution! No type checking is done! | 368 // Use this with caution! No type checking is done! |
368 LayoutBox* previousSiblingBox() const; | 369 LayoutBox* previousSiblingBox() const; |
369 LayoutBox* previousInFlowSiblingBox() const; | 370 LayoutBox* previousInFlowSiblingBox() const; |
(...skipping 854 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1224 || breakValue == BreakLeft | 1225 || breakValue == BreakLeft |
1225 || breakValue == BreakPage | 1226 || breakValue == BreakPage |
1226 || breakValue == BreakRecto | 1227 || breakValue == BreakRecto |
1227 || breakValue == BreakRight | 1228 || breakValue == BreakRight |
1228 || breakValue == BreakVerso; | 1229 || breakValue == BreakVerso; |
1229 } | 1230 } |
1230 | 1231 |
1231 } // namespace blink | 1232 } // namespace blink |
1232 | 1233 |
1233 #endif // LayoutBox_h | 1234 #endif // LayoutBox_h |
OLD | NEW |