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 Apple Inc. All right r
eserved. | 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010 Apple Inc. All right r
eserved. |
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 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
482 // We only need to add a fake run for a given isolated span once during
each call to createBidiRunsForLine. | 482 // We only need to add a fake run for a given isolated span once during
each call to createBidiRunsForLine. |
483 // We'll be called for every span inside the isolated span so we just ig
nore subsequent calls. | 483 // We'll be called for every span inside the isolated span so we just ig
nore subsequent calls. |
484 // We also avoid creating a fake run until we hit a child that warrants
one, e.g. we skip floats. | 484 // We also avoid creating a fake run until we hit a child that warrants
one, e.g. we skip floats. |
485 if (m_haveAddedFakeRunForRootIsolate || RenderBlock::shouldSkipCreatingR
unsForObject(obj)) | 485 if (m_haveAddedFakeRunForRootIsolate || RenderBlock::shouldSkipCreatingR
unsForObject(obj)) |
486 return; | 486 return; |
487 m_haveAddedFakeRunForRootIsolate = true; | 487 m_haveAddedFakeRunForRootIsolate = true; |
488 // obj and pos together denote a single position in the inline, from whi
ch the parsing of the isolate will start. | 488 // obj and pos together denote a single position in the inline, from whi
ch the parsing of the isolate will start. |
489 // We don't need to mark the end of the run because this is implicit: it
is either endOfLine or the end of the | 489 // We don't need to mark the end of the run because this is implicit: it
is either endOfLine or the end of the |
490 // isolate, when we call createBidiRunsForLine it will stop at whichever
comes first. | 490 // isolate, when we call createBidiRunsForLine it will stop at whichever
comes first. |
491 addPlaceholderRunForIsolatedInline(resolver, obj, pos); | 491 addPlaceholderRunForIsolatedInline(resolver, obj, pos); |
| 492 // FIXME: Inline isolates don't work properly with collapsing whitespace
, see webkit.org/b/109624 |
| 493 // For now, if we enter an isolate between midpoints, we increment our c
urrent midpoint or else |
| 494 // we'll leave the isolate and ignore the content that follows. |
| 495 MidpointState<InlineIterator>& midpointState = resolver.midpointState(); |
| 496 if (midpointState.betweenMidpoints && midpointState.midpoints[midpointSt
ate.currentMidpoint].object() == obj) { |
| 497 midpointState.betweenMidpoints = false; |
| 498 ++midpointState.currentMidpoint; |
| 499 } |
492 } | 500 } |
493 | 501 |
494 private: | 502 private: |
495 unsigned m_nestedIsolateCount; | 503 unsigned m_nestedIsolateCount; |
496 bool m_haveAddedFakeRunForRootIsolate; | 504 bool m_haveAddedFakeRunForRootIsolate; |
497 }; | 505 }; |
498 | 506 |
499 template <> | 507 template <> |
500 inline void InlineBidiResolver::appendRun() | 508 inline void InlineBidiResolver::appendRun() |
501 { | 509 { |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
533 m_sor = m_eor; | 541 m_sor = m_eor; |
534 } | 542 } |
535 | 543 |
536 m_direction = WTF::Unicode::OtherNeutral; | 544 m_direction = WTF::Unicode::OtherNeutral; |
537 m_status.eor = WTF::Unicode::OtherNeutral; | 545 m_status.eor = WTF::Unicode::OtherNeutral; |
538 } | 546 } |
539 | 547 |
540 } | 548 } |
541 | 549 |
542 #endif // InlineIterator_h | 550 #endif // InlineIterator_h |
OLD | NEW |