OLD | NEW |
1 /* | 1 /* |
2 * (C) 1999 Lars Knoll (knoll@kde.org) | 2 * (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 2000 Dirk Mueller (mueller@kde.org) | 3 * (C) 2000 Dirk Mueller (mueller@kde.org) |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. |
5 * All rights reserved. | 5 * All rights reserved. |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
483 return true; | 483 return true; |
484 } | 484 } |
485 return false; | 485 return false; |
486 } | 486 } |
487 | 487 |
488 bool InlineTextBox::GetEmphasisMarkPosition( | 488 bool InlineTextBox::GetEmphasisMarkPosition( |
489 const ComputedStyle& style, | 489 const ComputedStyle& style, |
490 TextEmphasisPosition& emphasis_position) const { | 490 TextEmphasisPosition& emphasis_position) const { |
491 // This function returns true if there are text emphasis marks and they are | 491 // This function returns true if there are text emphasis marks and they are |
492 // suppressed by ruby text. | 492 // suppressed by ruby text. |
493 if (style.GetTextEmphasisMark() == kTextEmphasisMarkNone) | 493 if (style.GetTextEmphasisMark() == TextEmphasisMark::kNone) |
494 return false; | 494 return false; |
495 | 495 |
496 emphasis_position = style.GetTextEmphasisPosition(); | 496 emphasis_position = style.GetTextEmphasisPosition(); |
497 // Ruby text is always over, so it cannot suppress emphasis marks under. | 497 // Ruby text is always over, so it cannot suppress emphasis marks under. |
498 if (emphasis_position == TextEmphasisPosition::kUnder) | 498 if (emphasis_position == TextEmphasisPosition::kUnder) |
499 return true; | 499 return true; |
500 | 500 |
501 LineLayoutBox containing_block = GetLineLayoutItem().ContainingBlock(); | 501 LineLayoutBox containing_block = GetLineLayoutItem().ContainingBlock(); |
502 // This text is not inside a ruby base, so it does not have ruby text over it. | 502 // This text is not inside a ruby base, so it does not have ruby text over it. |
503 if (!containing_block.IsRubyBase()) | 503 if (!containing_block.IsRubyBase()) |
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
748 for (; printed_characters < kLayoutObjectCharacterOffset; | 748 for (; printed_characters < kLayoutObjectCharacterOffset; |
749 printed_characters++) | 749 printed_characters++) |
750 fputc(' ', stderr); | 750 fputc(' ', stderr); |
751 fprintf(stderr, "(%d,%d) \"%s\"\n", Start(), Start() + Len(), | 751 fprintf(stderr, "(%d,%d) \"%s\"\n", Start(), Start() + Len(), |
752 value.Utf8().data()); | 752 value.Utf8().data()); |
753 } | 753 } |
754 | 754 |
755 #endif | 755 #endif |
756 | 756 |
757 } // namespace blink | 757 } // namespace blink |
OLD | NEW |