| 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 * (C) 2007 David Smith (catfish.man@gmail.com) | 4 * (C) 2007 David Smith (catfish.man@gmail.com) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. |
| 6 * All rights reserved. | 6 * All rights reserved. |
| 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 1619 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1630 if (isAtomicInlineLevel() && linePositionMode == PositionOnContainingLine) | 1630 if (isAtomicInlineLevel() && linePositionMode == PositionOnContainingLine) |
| 1631 return LayoutBox::lineHeight(firstLine, direction, linePositionMode); | 1631 return LayoutBox::lineHeight(firstLine, direction, linePositionMode); |
| 1632 | 1632 |
| 1633 const ComputedStyle& style = | 1633 const ComputedStyle& style = |
| 1634 styleRef(firstLine && document().styleEngine().usesFirstLineRules()); | 1634 styleRef(firstLine && document().styleEngine().usesFirstLineRules()); |
| 1635 return LayoutUnit(style.computedLineHeight()); | 1635 return LayoutUnit(style.computedLineHeight()); |
| 1636 } | 1636 } |
| 1637 | 1637 |
| 1638 int LayoutBlock::beforeMarginInLineDirection( | 1638 int LayoutBlock::beforeMarginInLineDirection( |
| 1639 LineDirectionMode direction) const { | 1639 LineDirectionMode direction) const { |
| 1640 // InlineFlowBox::placeBoxesInBlockDirection will flip lines in |
| 1641 // case of verticalLR mode, so we can assume verticalRL for now. |
| 1640 return (direction == HorizontalLine ? marginTop() : marginRight()).toInt(); | 1642 return (direction == HorizontalLine ? marginTop() : marginRight()).toInt(); |
| 1641 } | 1643 } |
| 1642 | 1644 |
| 1643 int LayoutBlock::baselinePosition(FontBaseline baselineType, | 1645 int LayoutBlock::baselinePosition(FontBaseline baselineType, |
| 1644 bool firstLine, | 1646 bool firstLine, |
| 1645 LineDirectionMode direction, | 1647 LineDirectionMode direction, |
| 1646 LinePositionMode linePositionMode) const { | 1648 LinePositionMode linePositionMode) const { |
| 1647 // Inline blocks are replaced elements. Otherwise, just pass off to | 1649 // Inline blocks are replaced elements. Otherwise, just pass off to |
| 1648 // the base class. If we're being queried as though we're the root line | 1650 // the base class. If we're being queried as though we're the root line |
| 1649 // box, then the fact that we're an inline-block is irrelevant, and we behave | 1651 // box, then the fact that we're an inline-block is irrelevant, and we behave |
| (...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2208 } | 2210 } |
| 2209 | 2211 |
| 2210 return availableHeight; | 2212 return availableHeight; |
| 2211 } | 2213 } |
| 2212 | 2214 |
| 2213 bool LayoutBlock::hasDefiniteLogicalHeight() const { | 2215 bool LayoutBlock::hasDefiniteLogicalHeight() const { |
| 2214 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); | 2216 return availableLogicalHeightForPercentageComputation() != LayoutUnit(-1); |
| 2215 } | 2217 } |
| 2216 | 2218 |
| 2217 } // namespace blink | 2219 } // namespace blink |
| OLD | NEW |