OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) | 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) |
3 * (C) 1997 Torben Weis (weis@kde.org) | 3 * (C) 1997 Torben Weis (weis@kde.org) |
4 * (C) 1998 Waldo Bastian (bastian@kde.org) | 4 * (C) 1998 Waldo Bastian (bastian@kde.org) |
5 * (C) 1999 Lars Knoll (knoll@kde.org) | 5 * (C) 1999 Lars Knoll (knoll@kde.org) |
6 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 6 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc.
All rights reserved. | 7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc.
All rights reserved. |
8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
256 LogicalExtentComputedValues computedValues; | 256 LogicalExtentComputedValues computedValues; |
257 computePositionedLogicalWidth(computedValues); | 257 computePositionedLogicalWidth(computedValues); |
258 setLogicalWidth(computedValues.m_extent); | 258 setLogicalWidth(computedValues.m_extent); |
259 setLogicalLeft(computedValues.m_position); | 259 setLogicalLeft(computedValues.m_position); |
260 setMarginStart(computedValues.m_margins.m_start); | 260 setMarginStart(computedValues.m_margins.m_start); |
261 setMarginEnd(computedValues.m_margins.m_end); | 261 setMarginEnd(computedValues.m_margins.m_end); |
262 } | 262 } |
263 | 263 |
264 LayoutBlock* cb = containingBlock(); | 264 LayoutBlock* cb = containingBlock(); |
265 | 265 |
266 LayoutUnit availableLogicalWidth = containingBlockLogicalWidthForContent() +
(isOutOfFlowPositioned() ? cb->paddingLogicalWidth() : LayoutUnit()); | 266 LayoutUnit availableLogicalWidth = containingBlockLogicalWidthForContent(); |
267 bool hasPerpendicularContainingBlock = cb->style()->isHorizontalWritingMode(
) != style()->isHorizontalWritingMode(); | 267 bool hasPerpendicularContainingBlock = cb->style()->isHorizontalWritingMode(
) != style()->isHorizontalWritingMode(); |
268 LayoutUnit containerWidthInInlineDirection = hasPerpendicularContainingBlock
? perpendicularContainingBlockLogicalHeight() : availableLogicalWidth; | 268 LayoutUnit containerWidthInInlineDirection = hasPerpendicularContainingBlock
? perpendicularContainingBlockLogicalHeight() : availableLogicalWidth; |
269 | 269 |
270 Length styleLogicalWidth = style()->logicalWidth(); | 270 Length styleLogicalWidth = style()->logicalWidth(); |
271 if (!isLogicalWidthAuto()) { | 271 if (!isLogicalWidthAuto()) { |
272 setLogicalWidth(convertStyleLogicalWidthToComputedWidth(styleLogicalWidt
h, containerWidthInInlineDirection)); | 272 setLogicalWidth(convertStyleLogicalWidthToComputedWidth(styleLogicalWidt
h, containerWidthInInlineDirection)); |
273 } else { | 273 } else { |
274 // Subtract out any fixed margins from our available width for auto widt
h tables. | 274 // Subtract out any fixed margins from our available width for auto widt
h tables. |
275 LayoutUnit marginStart = minimumValueForLength(style()->marginStart(), a
vailableLogicalWidth); | 275 LayoutUnit marginStart = minimumValueForLength(style()->marginStart(), a
vailableLogicalWidth); |
276 LayoutUnit marginEnd = minimumValueForLength(style()->marginEnd(), avail
ableLogicalWidth); | 276 LayoutUnit marginEnd = minimumValueForLength(style()->marginEnd(), avail
ableLogicalWidth); |
(...skipping 1197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1474 | 1474 |
1475 LayoutUnit LayoutTable::paddingRight() const | 1475 LayoutUnit LayoutTable::paddingRight() const |
1476 { | 1476 { |
1477 if (collapseBorders()) | 1477 if (collapseBorders()) |
1478 return LayoutUnit(); | 1478 return LayoutUnit(); |
1479 | 1479 |
1480 return LayoutBlock::paddingRight(); | 1480 return LayoutBlock::paddingRight(); |
1481 } | 1481 } |
1482 | 1482 |
1483 } // namespace blink | 1483 } // namespace blink |
OLD | NEW |