| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Defines an iterator class that enumerates words supported by our spellchecker | 5 // Defines an iterator class that enumerates words supported by our spellchecker |
| 6 // from multi-language text. This class is used for filtering out characters | 6 // from multi-language text. This class is used for filtering out characters |
| 7 // not supported by our spellchecker. | 7 // not supported by our spellchecker. |
| 8 | 8 |
| 9 #ifndef CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ | 9 #ifndef CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ |
| 10 #define CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ | 10 #define CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ |
| 11 #pragma once | 11 #pragma once |
| 12 | 12 |
| 13 #include <string> | 13 #include <string> |
| 14 | 14 |
| 15 #include "unicode/ubrk.h" |
| 16 #include "unicode/uscript.h" |
| 17 |
| 15 #include "base/basictypes.h" | 18 #include "base/basictypes.h" |
| 16 #include "base/string16.h" | 19 #include "base/string16.h" |
| 17 #include "third_party/icu/public/common/unicode/ubrk.h" | |
| 18 #include "third_party/icu/public/common/unicode/uscript.h" | |
| 19 | 20 |
| 20 // A class which encapsulates language-specific operations used by | 21 // A class which encapsulates language-specific operations used by |
| 21 // SpellcheckWordIterator. When we set the spellchecker language, this class | 22 // SpellcheckWordIterator. When we set the spellchecker language, this class |
| 22 // creates rule sets that filter out the characters not supported by the | 23 // creates rule sets that filter out the characters not supported by the |
| 23 // spellchecker. (Please read the comment in the SpellcheckWordIterator class | 24 // spellchecker. (Please read the comment in the SpellcheckWordIterator class |
| 24 // about how to use this class.) | 25 // about how to use this class.) |
| 25 class SpellcheckCharAttribute { | 26 class SpellcheckCharAttribute { |
| 26 public: | 27 public: |
| 27 SpellcheckCharAttribute(); | 28 SpellcheckCharAttribute(); |
| 28 ~SpellcheckCharAttribute(); | 29 ~SpellcheckCharAttribute(); |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 const SpellcheckCharAttribute* attribute_; | 162 const SpellcheckCharAttribute* attribute_; |
| 162 | 163 |
| 163 // The ICU break iterator. | 164 // The ICU break iterator. |
| 164 UBreakIterator* iterator_; | 165 UBreakIterator* iterator_; |
| 165 | 166 |
| 166 DISALLOW_COPY_AND_ASSIGN(SpellcheckWordIterator); | 167 DISALLOW_COPY_AND_ASSIGN(SpellcheckWordIterator); |
| 167 }; | 168 }; |
| 168 | 169 |
| 169 #endif // CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ | 170 #endif // CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_WORDITERATOR_H_ |
| 170 | 171 |
| OLD | NEW |