| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006, 2007 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 448 { | 448 { |
| 449 for (const InlineFlowBox* rootBox = o.firstLineBox(); rootBox; rootBox = roo
tBox->nextLineBox()) { | 449 for (const InlineFlowBox* rootBox = o.firstLineBox(); rootBox; rootBox = roo
tBox->nextLineBox()) { |
| 450 writeInlineFlowBox(ts, *rootBox, indent); | 450 writeInlineFlowBox(ts, *rootBox, indent); |
| 451 } | 451 } |
| 452 } | 452 } |
| 453 | 453 |
| 454 static void writeTextRun(TextStream& ts, const LayoutText& o, const InlineTextBo
x& run) | 454 static void writeTextRun(TextStream& ts, const LayoutText& o, const InlineTextBo
x& run) |
| 455 { | 455 { |
| 456 // FIXME: For now use an "enclosingIntRect" model for x, y and logicalWidth,
although this makes it harder | 456 // FIXME: For now use an "enclosingIntRect" model for x, y and logicalWidth,
although this makes it harder |
| 457 // to detect any changes caused by the conversion to floating point. :( | 457 // to detect any changes caused by the conversion to floating point. :( |
| 458 int x = run.x(); | 458 int x = run.x().toInt(); |
| 459 int y = run.y(); | 459 int y = run.y().toInt(); |
| 460 int logicalWidth = (run.left() + run.logicalWidth()).ceil() - x; | 460 int logicalWidth = (run.left() + run.logicalWidth()).ceil() - x; |
| 461 | 461 |
| 462 // FIXME: Table cell adjustment is temporary until results can be updated. | 462 // FIXME: Table cell adjustment is temporary until results can be updated. |
| 463 if (o.containingBlock()->isTableCell()) | 463 if (o.containingBlock()->isTableCell()) |
| 464 y -= toLayoutTableCell(o.containingBlock())->intrinsicPaddingBefore(); | 464 y -= toLayoutTableCell(o.containingBlock())->intrinsicPaddingBefore(); |
| 465 | 465 |
| 466 ts << "text run at (" << x << "," << y << ") width " << logicalWidth; | 466 ts << "text run at (" << x << "," << y << ") width " << logicalWidth; |
| 467 if (!run.isLeftToRightDirection() || run.dirOverride()) { | 467 if (!run.isLeftToRightDirection() || run.dirOverride()) { |
| 468 ts << (!run.isLeftToRightDirection() ? " RTL" : " LTR"); | 468 ts << (!run.isLeftToRightDirection() ? " RTL" : " LTR"); |
| 469 if (run.dirOverride()) | 469 if (run.dirOverride()) |
| (...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 845 element->document().updateStyleAndLayout(); | 845 element->document().updateStyleAndLayout(); |
| 846 | 846 |
| 847 LayoutObject* layoutObject = element->layoutObject(); | 847 LayoutObject* layoutObject = element->layoutObject(); |
| 848 if (!layoutObject || !layoutObject->isListItem()) | 848 if (!layoutObject || !layoutObject->isListItem()) |
| 849 return String(); | 849 return String(); |
| 850 | 850 |
| 851 return toLayoutListItem(layoutObject)->markerText(); | 851 return toLayoutListItem(layoutObject)->markerText(); |
| 852 } | 852 } |
| 853 | 853 |
| 854 } // namespace blink | 854 } // namespace blink |
| OLD | NEW |