| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ight reserved. | 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ight reserved. |
| 4 * Copyright (C) 2010 Google Inc. All rights reserved. | 4 * Copyright (C) 2010 Google 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 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 216 if (box->isInlineTextBox()) { | 216 if (box->isInlineTextBox()) { |
| 217 InlineTextBox* text = toInlineTextBox(box); | 217 InlineTextBox* text = toInlineTextBox(box); |
| 218 text->setStart(r->m_start); | 218 text->setStart(r->m_start); |
| 219 text->setLen(r->m_stop - r->m_start); | 219 text->setLen(r->m_stop - r->m_start); |
| 220 text->setDirOverride(r->dirOverride()); | 220 text->setDirOverride(r->dirOverride()); |
| 221 if (r->m_hasHyphen) | 221 if (r->m_hasHyphen) |
| 222 text->setHasHyphen(true); | 222 text->setHasHyphen(true); |
| 223 } | 223 } |
| 224 } | 224 } |
| 225 | 225 |
| 226 // We should have a root inline box. It should be unconstructed and | |
| 227 // be the last continuation of our line list. | |
| 228 ASSERT(lastLineBox() && !lastLineBox()->isConstructed()); | 226 ASSERT(lastLineBox() && !lastLineBox()->isConstructed()); |
| 229 | 227 |
| 230 // Set the m_selectedChildren flag on the root inline box if one of the leaf
inline box | 228 // Set the m_selectedChildren flag on the root inline box if one of the leaf
inline box |
| 231 // from the bidi runs walk above has a selection state. | 229 // from the bidi runs walk above has a selection state. |
| 232 if (rootHasSelectedChildren) | 230 if (rootHasSelectedChildren) |
| 233 lastLineBox()->root().setHasSelectedChildren(true); | 231 lastLineBox()->root().setHasSelectedChildren(true); |
| 234 | 232 |
| 235 // Set bits on our inline flow boxes that indicate which sides should | 233 // Set bits on our inline flow boxes that indicate which sides should |
| 236 // paint borders/margins/padding. This knowledge will ultimately be used wh
en | 234 // paint borders/margins/padding. This knowledge will ultimately be used wh
en |
| 237 // we determine the horizontal positions and widths of all the inline boxes
on | 235 // we determine the horizontal positions and widths of all the inline boxes
on |
| (...skipping 1352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1590 float logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false).toFloat
(); | 1588 float logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false).toFloat
(); |
| 1591 float availableLogicalWidth = logicalRightOffsetForLine(logicalHeight(), fal
se) - logicalLeft; | 1589 float availableLogicalWidth = logicalRightOffsetForLine(logicalHeight(), fal
se) - logicalLeft; |
| 1592 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid
th, availableLogicalWidth, 0); | 1590 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid
th, availableLogicalWidth, 0); |
| 1593 | 1591 |
| 1594 if (!style()->isLeftToRightDirection()) | 1592 if (!style()->isLeftToRightDirection()) |
| 1595 return logicalWidth() - logicalLeft; | 1593 return logicalWidth() - logicalLeft; |
| 1596 return logicalLeft; | 1594 return logicalLeft; |
| 1597 } | 1595 } |
| 1598 | 1596 |
| 1599 } | 1597 } |
| OLD | NEW |