| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999 Lars Knoll (knoll@kde.org) | 2 * (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights |
| 4 * reserved. | 4 * reserved. |
| 5 * Copyright (C) 2007-2009 Torch Mobile, Inc. | 5 * Copyright (C) 2007-2009 Torch Mobile, Inc. |
| 6 * Copyright (C) 2011 Google Inc. All rights reserved. | 6 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| 11 * version 2 of the License, or (at your option) any later version. | 11 * version 2 of the License, or (at your option) any later version. |
| 12 * | 12 * |
| 13 * This library is distributed in the hope that it will be useful, | 13 * This library is distributed in the hope that it will be useful, |
| 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 16 * Library General Public License for more details. | 16 * Library General Public License for more details. |
| 17 * | 17 * |
| 18 * You should have received a copy of the GNU Library General Public License | 18 * You should have received a copy of the GNU Library General Public License |
| 19 * along with this library; see the file COPYING.LIB. If not, write to | 19 * along with this library; see the file COPYING.LIB. If not, write to |
| 20 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, | 20 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 21 * Boston, MA 02110-1301, USA. | 21 * Boston, MA 02110-1301, USA. |
| 22 */ | 22 */ |
| 23 | 23 |
| 24 #include "platform/text/TextBreakIterator.h" | 24 #include "platform/text/TextBreakIterator.h" |
| 25 | 25 |
| 26 #include "platform/text/Character.h" | 26 #include "platform/text/Character.h" |
| 27 #include "wtf/ASCIICType.h" | 27 #include "platform/wtf/ASCIICType.h" |
| 28 #include "wtf/StdLibExtras.h" | 28 #include "platform/wtf/StdLibExtras.h" |
| 29 #include "wtf/text/CharacterNames.h" | 29 #include "platform/wtf/text/CharacterNames.h" |
| 30 | 30 |
| 31 #include <unicode/uchar.h> | 31 #include <unicode/uchar.h> |
| 32 #include <unicode/uvernum.h> | 32 #include <unicode/uvernum.h> |
| 33 | 33 |
| 34 namespace blink { | 34 namespace blink { |
| 35 | 35 |
| 36 unsigned numGraphemeClusters(const String& string) { | 36 unsigned numGraphemeClusters(const String& string) { |
| 37 unsigned stringLength = string.length(); | 37 unsigned stringLength = string.length(); |
| 38 | 38 |
| 39 if (!stringLength) | 39 if (!stringLength) |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 | 380 |
| 381 int LazyLineBreakIterator::nextBreakablePositionKeepAll(int pos) { | 381 int LazyLineBreakIterator::nextBreakablePositionKeepAll(int pos) { |
| 382 if (m_string.is8Bit()) | 382 if (m_string.is8Bit()) |
| 383 return nextBreakablePosition<LChar, LineBreakType::Normal>( | 383 return nextBreakablePosition<LChar, LineBreakType::Normal>( |
| 384 *this, m_string.characters8(), m_string.length(), pos); | 384 *this, m_string.characters8(), m_string.length(), pos); |
| 385 return nextBreakablePositionKeepAllInternal(*this, m_string.characters16(), | 385 return nextBreakablePositionKeepAllInternal(*this, m_string.characters16(), |
| 386 m_string.length(), pos); | 386 m_string.length(), pos); |
| 387 } | 387 } |
| 388 | 388 |
| 389 } // namespace blink | 389 } // namespace blink |
| OLD | NEW |