| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 class Range; | 33 class Range; |
| 34 class SpellCheckerClient; | 34 class SpellCheckerClient; |
| 35 class TextCheckerClient; | 35 class TextCheckerClient; |
| 36 struct TextCheckingResult; | 36 struct TextCheckingResult; |
| 37 | 37 |
| 38 class TextCheckingParagraph { | 38 class TextCheckingParagraph { |
| 39 STACK_ALLOCATED(); | 39 STACK_ALLOCATED(); |
| 40 public: | 40 public: |
| 41 explicit TextCheckingParagraph(const EphemeralRange& checkingRange); | 41 explicit TextCheckingParagraph(const EphemeralRange& checkingRange); |
| 42 TextCheckingParagraph(const EphemeralRange& checkingRange, const EphemeralRa
nge& paragraphRange); | 42 TextCheckingParagraph(const EphemeralRange& checkingRange, const EphemeralRa
nge& paragraphRange); |
| 43 TextCheckingParagraph(PassRefPtrWillBeRawPtr<Range> checkingRange, PassRefPt
rWillBeRawPtr<Range> paragraphRange); | 43 TextCheckingParagraph(RawPtr<Range> checkingRange, RawPtr<Range> paragraphRa
nge); |
| 44 ~TextCheckingParagraph(); | 44 ~TextCheckingParagraph(); |
| 45 | 45 |
| 46 int rangeLength() const; | 46 int rangeLength() const; |
| 47 EphemeralRange subrange(int characterOffset, int characterCount) const; | 47 EphemeralRange subrange(int characterOffset, int characterCount) const; |
| 48 int offsetTo(const Position&) const; | 48 int offsetTo(const Position&) const; |
| 49 void expandRangeToNextEnd(); | 49 void expandRangeToNextEnd(); |
| 50 | 50 |
| 51 const String& text() const; | 51 const String& text() const; |
| 52 // Why not let clients call these functions on text() themselves? | 52 // Why not let clients call these functions on text() themselves? |
| 53 String textSubstring(unsigned pos, unsigned len = INT_MAX) const { return te
xt().substring(pos, len); } | 53 String textSubstring(unsigned pos, unsigned len = INT_MAX) const { return te
xt().substring(pos, len); } |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 int findFirstGrammarDetail(const Vector<GrammarDetail>& grammarDetails, int
badGrammarPhraseLocation, int startOffset, int endOffset, bool markAll) const; | 102 int findFirstGrammarDetail(const Vector<GrammarDetail>& grammarDetails, int
badGrammarPhraseLocation, int startOffset, int endOffset, bool markAll) const; |
| 103 bool unifiedTextCheckerEnabled() const; | 103 bool unifiedTextCheckerEnabled() const; |
| 104 }; | 104 }; |
| 105 | 105 |
| 106 void checkTextOfParagraph(TextCheckerClient&, const String&, TextCheckingTypeMas
k, Vector<TextCheckingResult>&); | 106 void checkTextOfParagraph(TextCheckerClient&, const String&, TextCheckingTypeMas
k, Vector<TextCheckingResult>&); |
| 107 bool unifiedTextCheckerEnabled(const LocalFrame*); | 107 bool unifiedTextCheckerEnabled(const LocalFrame*); |
| 108 | 108 |
| 109 } // namespace blink | 109 } // namespace blink |
| 110 | 110 |
| 111 #endif // TextCheckingHelper_h | 111 #endif // TextCheckingHelper_h |
| OLD | NEW |