1. 12 May, 2011 1 commit
    • tonyg@chromium.org's avatar
      2011-05-10 Tony Gentilcore <tonyg@chromium.org> · 4b0a55f4
      tonyg@chromium.org authored
              Reviewed by Darin Adler.
      
              Perform some forward declarations suggested by include-what-you-use
              https://bugs.webkit.org/show_bug.cgi?id=60545
      
              * accessibility/AccessibilityObject.cpp:
              * accessibility/AccessibilityRenderObject.cpp:
              * accessibility/mac/AccessibilityObjectWrapper.mm:
              * dom/DocumentMarkerController.cpp:
              * dom/Position.cpp:
              * dom/PositionIterator.cpp:
              * dom/Range.cpp:
              * editing/ApplyBlockElementCommand.cpp:
              * editing/ApplyStyleCommand.cpp:
              * editing/Editor.cpp:
              * editing/EditorCommand.cpp:
              * editing/FrameSelection.cpp:
              * editing/HTMLInterchange.cpp:
              * editing/IndentOutdentCommand.cpp:
              * editing/ReplaceSelectionCommand.cpp:
              * editing/SpellChecker.h:
              * editing/SpellingCorrectionCommand.cpp:
              * editing/SpellingCorrectionController.h:
              * editing/TextCheckingHelper.cpp:
              * editing/TextIterator.h:
              * editing/htmlediting.h:
              * editing/markup.cpp:
              * editing/visible_units.cpp:
              * editing/visible_units.h:
              * fileapi/DOMFileSystem.cpp:
              * fileapi/DirectoryReaderSync.cpp:
              * fileapi/DirectoryReaderSync.h:
              * fileapi/FileEntry.h:
              * fileapi/FileWriter.h:
              * fileapi/FileWriterBase.h:
              * fileapi/FileWriterSync.h:
              * history/CachedFrame.cpp:
              * history/CachedPage.cpp:
              * history/HistoryItem.cpp:
              * history/HistoryItem.h:
              * history/PageCache.h:
              * loader/HistoryController.h:
              * loader/PingLoader.h:
              * loader/ResourceLoader.h:
              * loader/appcache/DOMApplicationCache.h:
              * loader/cache/CachedCSSStyleSheet.h:
              * loader/cache/CachedFont.cpp:
              * loader/cache/CachedFont.h:
              * loader/cache/CachedResourceRequest.cpp:
              * loader/cache/CachedResourceRequest.h:
              * loader/cache/MemoryCache.h:
              * notifications/Notification.cpp:
              * notifications/Notification.h:
              * notifications/NotificationCenter.cpp:
              * notifications/NotificationCenter.h:
              * page/Chrome.cpp:
              * page/Chrome.h:
              * page/DOMSelection.cpp:
              * page/DOMTimer.h:
              * page/DOMWindow.cpp:
              * page/EventHandler.cpp:
              * page/FocusController.h:
              * page/Geolocation.cpp:
              * page/Geolocation.h:
              * page/History.cpp:
              * rendering/RenderListBox.cpp:
              * workers/WorkerContext.cpp:
      2011-05-10  Tony Gentilcore  <tonyg@chromium.org>
      
              Reviewed by Darin Adler.
      
              Perform some forward declarations suggested by include-what-you-use
              https://bugs.webkit.org/show_bug.cgi?id=60545
      
              * src/WebHistoryItem.cpp:
              * src/WebNotification.cpp:
              * src/WebTextCheckingCompletionImpl.cpp:
              * src/mac/WebSubstringUtil.mm:
      2011-05-10  Tony Gentilcore  <tonyg@chromium.org>
      
              Reviewed by Darin Adler.
      
              Perform some forward declarations suggested by include-what-you-use
              https://bugs.webkit.org/show_bug.cgi?id=60545
      
              * Plugins/Hosted/WebHostedNetscapePluginView.mm:
              * WebView/WebFrame.mm:
      2011-05-10  Tony Gentilcore  <tonyg@chromium.org>
      
              Reviewed by Darin Adler.
      
              Perform some forward declarations suggested by include-what-you-use
              https://bugs.webkit.org/show_bug.cgi?id=60545
      
              * WebProcess/WebPage/mac/WebPageMac.mm:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@86325 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4b0a55f4
  2. 11 May, 2011 1 commit
    • jpu@apple.com's avatar
      2011-05-11 Jia Pu <jpu@apple.com> · fd2014cc
      jpu@apple.com authored
              Reviewed by Darin Adler.
      
              Autocorrection persists after deleting and retyping the same word at same location.
              https://bugs.webkit.org/show_bug.cgi?id=60555
              <rdar://problem/9373915>
      
              See WebCore/ChangeLog for detail.
      
              * platform/mac-leopard/Skipped:
              * platform/mac-snowleopard/Skipped:
              * platform/mac/editing/spelling/delete-autocorrected-word-2-expected.png: Added.
              * platform/mac/editing/spelling/delete-autocorrected-word-2-expected.txt: Added.
              * platform/mac/editing/spelling/delete-autocorrected-word-2.html: Added.
      2011-05-11  Jia Pu  <jpu@apple.com>
      
              Reviewed by Darin Adler.
      
              Autocorrection persists after deleting and retyping the same word at same location.
              https://bugs.webkit.org/show_bug.cgi?id=60555
              <rdar://problem/9373915>
      
              This patch intends to alleviate the issue of repetitively applying the same autocorrection
              when user delete and retype the same word at the same location. This scenario is especially
              common when autocorrection modifies the first letter of the word.
      
              This patch consists following major changes:
              1. Added a new marker type, DeletedAutocorrection. This marker is added to the whitespace that
                 precedes a deleted autocorrection. If the user later types the same original word at after
                 this whitespace, the autocorrection will not be applied again.
              2. In DeleteSelectionCommand, added code to notify SpellingCorrectionController about the
                 autocorrection that has just been deleted.
              3. In Editor and SpellingCorrectionController, added code to apply the marker and to suppress
                 autocorrection when necessary.
              4. The change in CompositeEditCommand::replaceTextInNode is necessary for preserving markers.
                 Otherwise, we will loose the DeletedAutocorrection on the whitespace, when inserting text
                 after the whitespace.
      
              Test: platform/mac/editing/spelling/delete-autocorrected-word-2.html
      
              * dom/DocumentMarker.h: Added new marker type DeletedAutocorrection.
              (WebCore::DocumentMarker::AllMarkers::AllMarkers):
              * dom/DocumentMarkerController.cpp:
              (WebCore::DocumentMarkerController::markersInRange): Support querying multiple marker types.
              * dom/DocumentMarkerController.h:
              * editing/CompositeEditCommand.cpp:
              (WebCore::CompositeEditCommand::replaceTextInNodeAndPreserveMarkers):
              (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring):
              (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit):
              * editing/CompositeEditCommand.h:
              * editing/DeleteSelectionCommand.cpp:
              (WebCore::DeleteSelectionCommand::DeleteSelectionCommand):
              (WebCore::DeleteSelectionCommand::fixupWhitespace):
              (WebCore::DeleteSelectionCommand::originalStringForAutocorrectionAtBeginningOfSelection): Extracting
                 the original string if we are deleting an autocorrection.
              (WebCore::DeleteSelectionCommand::doApply): Notify editor about the deleted autocorrection and its position.
              * editing/DeleteSelectionCommand.h:
              * editing/Editor.cpp:
              (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges): Moved all logic of determining
                 when to suppress an autocorrection into SpellingCorrectionController.
              (WebCore::Editor::deletedAutocorrectionAtPosition):
              * editing/Editor.h:
              * editing/InsertParagraphSeparatorCommand.cpp:
              (WebCore::InsertParagraphSeparatorCommand::doApply):
              * editing/SpellingCorrectionController.cpp:
              (WebCore::SpellingCorrectionController::respondToAppliedEditing):
              (WebCore::SpellingCorrectionController::deletedAutocorrectionAtPosition):
              (WebCore::SpellingCorrectionController::markPrecedingWhitespaceForDeletedAutocorrectionAfterCommand):
              (WebCore::SpellingCorrectionController::processMarkersOnTextToBeReplacedByResult):
              * editing/SpellingCorrectionController.h:
              (WebCore::SpellingCorrectionController::UNLESS_ENABLED):
              * editing/visible_units.cpp:
              (WebCore::isStartOfWord):
              * editing/visible_units.h:
              * manual-tests/autocorrection/spell-checking-after-reversion.html:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@86295 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fd2014cc
  3. 27 Apr, 2011 1 commit
    • morrita@google.com's avatar
      2011-04-19 MORITA Hajime <morrita@google.com> · 64550050
      morrita@google.com authored
              Reviewed by Tony Chang.
      
              [Refactoring] DocumentMarkerController::MarkerMapVectorPair should be replaced with a list of some class.
              https://bugs.webkit.org/show_bug.cgi?id=58113
      
              * Introduced RenderedDocumentMarker, a subclass of DocumentMarker.
              * Eliminated Vector<IntRect> and move the IntRect into RenderedDocumentMarker
              * Now MarkerMapVectorPair is no longer used.
      
              No new tests, No behavior change.
      
              * GNUmakefile.list.am:
              * WebCore.gypi:
              * WebCore.pro:
              * WebCore.vcproj/WebCore.vcproj:
              * WebCore.xcodeproj/project.pbxproj:
              * dom/DocumentMarker.h:
              * dom/DocumentMarkerController.cpp:
              (WebCore::DocumentMarkerController::addMarker):
              (WebCore::DocumentMarkerController::copyMarkers):
              (WebCore::DocumentMarkerController::removeMarkers):
              (WebCore::DocumentMarkerController::markerContainingPoint):
              (WebCore::DocumentMarkerController::markersForNode):
              (WebCore::DocumentMarkerController::renderedRectsForMarkers):
              (WebCore::DocumentMarkerController::removeMarkersFromList):
              (WebCore::DocumentMarkerController::repaintMarkers):
              (WebCore::DocumentMarkerController::setRenderedRectForMarker):
              (WebCore::DocumentMarkerController::invalidateRenderedRectsForMarkersInRect):
              (WebCore::DocumentMarkerController::shiftMarkers):
              (WebCore::DocumentMarkerController::setMarkersActive):
              (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
              (WebCore::DocumentMarkerController::showMarkers):
              * dom/DocumentMarkerController.h:
              * dom/RenderedDocumentMarker.h: Added.
              (WebCore::RenderedDocumentMarker::RenderedDocumentMarker):
              (WebCore::RenderedDocumentMarker::isRendered):
              (WebCore::RenderedDocumentMarker::contains):
              (WebCore::RenderedDocumentMarker::setRenderedRect):
              (WebCore::RenderedDocumentMarker::renderedRect):
              (WebCore::RenderedDocumentMarker::invalidate):
              (WebCore::RenderedDocumentMarker::invalidMarkerRect):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@85118 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      64550050
  4. 15 Apr, 2011 1 commit
    • morrita@google.com's avatar
      2011-04-07 MORITA Hajime <morrita@google.com> · 3e9aec70
      morrita@google.com authored
              Reviewed by Ryosuke Niwa.
      
              DocumentMaker::AllMarkers should not be a part of DocumentMarker::MarkerType
              https://bugs.webkit.org/show_bug.cgi?id=58112
      
              - Converted DocumentMarker::MarkerTypes from unsigned int to a class.
              - Converted DocumentMarker::AllMarkers from an enum entry to a subclass of MarkerTypes.
              - Changed type of some MarkerType argument on DocumentMarkerController API to MarkerTypes
                which should allow a combination of MarkerType constansts.
              - Removed some MarkerType arguments on DocumentMarkerController API
                which only received AllMarkers.
      
              No new tests, no behavior change.
      
              * WebCore.exp.in:
              * dom/DocumentMarker.h:
              (WebCore::DocumentMarker::MarkerTypes::MarkerTypes):
              (WebCore::DocumentMarker::MarkerTypes::contains):
              (WebCore::DocumentMarker::MarkerTypes::intersects):
              (WebCore::DocumentMarker::MarkerTypes::operator==):
              (WebCore::DocumentMarker::MarkerTypes::add):
              (WebCore::DocumentMarker::MarkerTypes::remove):
              (WebCore::DocumentMarker::AllMarkers::AllMarkers):
              * dom/DocumentMarkerController.cpp:
              (WebCore::DocumentMarkerController::possiblyHasMarkers):
              (WebCore::DocumentMarkerController::addMarker):
              (WebCore::DocumentMarkerController::copyMarkers):
              (WebCore::DocumentMarkerController::removeMarkers):
              (WebCore::DocumentMarkerController::markerContainingPoint):
              (WebCore::DocumentMarkerController::markersInRange):
              (WebCore::DocumentMarkerController::renderedRectsForMarkers):
              (WebCore::DocumentMarkerController::removeMarkersFromMarkerMapVectorPair):
              (WebCore::DocumentMarkerController::repaintMarkers):
              (WebCore::DocumentMarkerController::shiftMarkers):
              (WebCore::DocumentMarkerController::setMarkersActive):
              (WebCore::DocumentMarkerController::hasMarkers):
              (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
              * dom/DocumentMarkerController.h:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@83991 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3e9aec70
  5. 06 Apr, 2011 1 commit
    • commit-queue@webkit.org's avatar
      2011-04-06 Jia Pu <jpu@apple.com> · aad7ca2b
      commit-queue@webkit.org authored
              Reviewed by Darin Adler.
      
              [Mac] WebCore need to notify AppKit spell checker after user has modified autocorrected text.
              https://bugs.webkit.org/show_bug.cgi?id=57665
              <rdar://problem/7350477>
      
              We need to track how user modified an autocorrected word. If he changed it back to original
              text, we want to record AutocorrectionReverted response. And if he changed it to something
              else, we want to record AutocorrectionEdited response.
      
              To achieve this, we need to distringuish between text replacement caused by autocorrection
              from that due to other causes, such as reversion, text substitution, etc. So we added a new
              marker type "Autocorrected". We also need to be able to check for correction, even when we
              don't intend to actually carry out replacement. For this, we introduced a new TextCheckingOption
              value, "CheckForCorrection".
      
              We also added DocumentMarkerController::markersInRange() to retrieve a vector of markers in
              specified range, and of specified type.
      
              * dom/DocumentMarker.h:
              * dom/DocumentMarkerController.cpp:
              (WebCore::DocumentMarkerController::markersInRange):
              (WebCore::DocumentMarkerController::hasMarkers):
              * dom/DocumentMarkerController.h:
              * editing/Editor.cpp:
              (WebCore::markerTypesForAutocorrection):
              (WebCore::markersHaveIdenticalDescription):
              (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
              (WebCore::Editor::recordSpellcheckerResponseForModifiedCorrection):
              (WebCore::Editor::changeBackToReplacedString):
              (WebCore::Editor::markMisspellingsAndBadGrammar):
              (WebCore::Editor::applyCorrectionPanelInfo):
              (WebCore::Editor::unappliedSpellCorrection):
              (WebCore::Editor::textCheckingTypeMaskFor):
              * editing/Editor.h:
              * editing/SpellingCorrectionCommand.cpp:
              (WebCore::SpellingCorrectionCommand::doApply):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@83060 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      aad7ca2b
  6. 01 Mar, 2011 2 commits
    • mitz@apple.com's avatar
      Build fix. · 4d236cbf
      mitz@apple.com authored
      * dom/DocumentMarkerController.cpp:
      (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@80075 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4d236cbf
    • commit-queue@webkit.org's avatar
      2011-03-01 Jia Pu <jpu@apple.com> · 5396fd99
      commit-queue@webkit.org authored
              Reviewed by Darin Adler.
      
              Remove CorrectionIndicator markers sooner.
              https://bugs.webkit.org/show_bug.cgi?id=54893
              <rdar://problem/8997524>
      
              See WebCore/ChangeLog for detail.
      
              * platform/mac-leopard/Skipped:
              * platform/mac-snowleopard/Skipped:
              * platform/mac-tiger/Skipped:
              * platform/mac-wk2/Skipped:
              * platform/mac/editing/spelling/autocorrection-simple-expected.checksum:
              * platform/mac/editing/spelling/autocorrection-simple-expected.png:
              * platform/mac/editing/spelling/autocorrection-simple-expected.txt:
              * platform/mac/editing/spelling/autocorrection-simple.html:
              * platform/mac/editing/spelling/delete-into-autocorrected-word-expected.checksum:
              * platform/mac/editing/spelling/delete-into-autocorrected-word-expected.png:
              * platform/mac/editing/spelling/removing-underline-after-accepting-autocorrection-using-punctuation-expected.checksum: Added.
              * platform/mac/editing/spelling/removing-underline-after-accepting-autocorrection-using-punctuation-expected.png: Added.
              * platform/mac/editing/spelling/removing-underline-after-accepting-autocorrection-using-punctuation-expected.txt: Copied from LayoutTests/platform/mac/editing/spelling/autocorrection-simple-expected.txt.
              * platform/mac/editing/spelling/removing-underline-after-accepting-autocorrection-using-punctuation.html: Copied from LayoutTests/platform/mac/editing/spelling/autocorrection-simple.html.
      2011-03-01  Jia Pu  <jpu@apple.com>
      
              Reviewed by Darin Adler.
      
              Remove CorrectionIndicator markers sooner.
              https://bugs.webkit.org/show_bug.cgi?id=54893
              <rdar://problem/8997524>
      
              Test: platform/mac/editing/spelling/removing-underline-after-accepting-autocorrection-using-punctuation.html
      
              This patch changes the autocorrection behavior on Mac OS X. We want to remove CorrectionIndicator
              marker after any editing command if the command:
              1. is not a SpellingCorrectionCommand itself.
              2. is not the command that triggers the autocorrection.
              This is achieved by adding shouldRetainAutocorrectionIndicator() function to EditCommand. This function returns
              false for all commands derived from EditCommand, except SpellingCorrectionCommand and TypingCommand. This function
              always returns true for SpellingCorrectionCommand. For TypingCommand, the return value is determined by member
              variable m_shouldRetainAutocorrectionIndicator, which can be modified by passing option into the TypingCommand's
              public functions.
      
              To avoid constantly searching marker list, we use variable DocumentMarkerController::m_absentMarkerTypeCache
              to cache whether there is any marker of a particular type.
      
              This patch also fixes two minor existing bugs.
      
              1. We used to show reversion panel for word with CorrectionIndicator marker. This is incorrect because
              CorrectionIndicator marker can be removed from corrected words. Since all autocorrected words have Replacement
              marker unless the whole word is deleted, the correct behavior is to show reversion panel for word with Replacement
              marker, since all autocorrected words have such marker. However, since we don't want to show the reversion panel
              if an autocorrected word has been edited, we also check to see if the Replacement marker's description is null.
      
              This works as following:
              When we apply an autocorrection, we add Replacement marker to corrected word, and store original word
              as the marker's description. If the user edited the corrected word afterward, we set description to null.
              So when we decide whether to show a reversion panel, we not only check for the existence of Replacement
              marker, but also check if description is null.
      
              2. Fixed an assertion violation in Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited(), which would
              occur when deleting the first character in an editable area.
      
              * dom/DocumentMarker.h: Added m_possiblyExistingMarkerTypes to allow quickly checking whether a marker type is
                 completely in from the document.
      
              * dom/DocumentMarkerController.cpp: Most of the functions listed here are optimized for early return by checking
                 the return value of possiblyHasMarkers() at beginning.
              (WebCore::DocumentMarkerController::possiblyHasMarkers):
              (WebCore::DocumentMarkerController::DocumentMarkerController):
              (WebCore::DocumentMarkerController::detach):
              (WebCore::DocumentMarkerController::removeMarkers):
              (WebCore::DocumentMarkerController::addMarker):
              (WebCore::DocumentMarkerController::copyMarkers):
              (WebCore::DocumentMarkerController::markerContainingPoint):
              (WebCore::DocumentMarkerController::renderedRectsForMarkers):
              (WebCore::DocumentMarkerController::removeMarkersFromMarkerMapVectorPair):
              (WebCore::DocumentMarkerController::repaintMarkers):
              (WebCore::DocumentMarkerController::shiftMarkers):
              (WebCore::DocumentMarkerController::setMarkersActive):
              (WebCore::DocumentMarkerController::hasMarkers):
              (WebCore::DocumentMarkerController::clearDescriptionOnMarkersIntersectingRange):
              * dom/DocumentMarkerController.h:
              * editing/EditCommand.cpp:
              (WebCore::EditCommand::apply):
              (WebCore::EditCommand::shouldRetainAutocorrectionIndicator):
              (WebCore::EditCommand::setShouldRetainAutocorrectionIndicator):
              * editing/EditCommand.h:
              * editing/Editor.cpp:
              (WebCore::Editor::respondToChangedSelection):
              (WebCore::Editor::appliedEditing):
              (WebCore::Editor::insertTextWithoutSendingTextEvent):
              (WebCore::Editor::insertLineBreak):
              (WebCore::Editor::insertParagraphSeparator):
              (WebCore::Editor::markMisspellingsAfterTypingToWord):
              (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
              (WebCore::Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited):
              (WebCore::Editor::applyAutocorrectionBeforeTypingIfAppropriate):
              * editing/Editor.h:
              * editing/EditorCommand.cpp:
              (WebCore::executeInsertLineBreak):
              (WebCore::executeInsertParagraph):
              (WebCore::executeInsertText):
              * editing/SpellingCorrectionCommand.cpp:
              (WebCore::SpellingCorrectionCommand::shouldRetainAutocorrectionIndicator):
              * editing/SpellingCorrectionCommand.h:
              * editing/TypingCommand.cpp:
              (WebCore::TypingCommand::TypingCommand):
              (WebCore::TypingCommand::deleteSelection):
              (WebCore::TypingCommand::deleteKeyPressed):
              (WebCore::TypingCommand::forwardDeleteKeyPressed):
              (WebCore::TypingCommand::updateSelectionIfDifferentFromCurrentSelection):
              (WebCore::TypingCommand::insertText):
              (WebCore::TypingCommand::insertLineBreak):
              (WebCore::TypingCommand::insertParagraphSeparatorInQuotedContent):
              (WebCore::TypingCommand::insertParagraphSeparator):
              * editing/TypingCommand.h:
              (WebCore::TypingCommand::create):
              (WebCore::TypingCommand::shouldRetainAutocorrectionIndicator):
              (WebCore::TypingCommand::setShouldRetainAutocorrectionIndicator):
              * manual-tests/autocorrection/type-whitespace-to-dismiss-reversion.html:
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@80023 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5396fd99
  7. 03 Feb, 2011 1 commit
    • mitz@apple.com's avatar
      Reversion should not be marked as misspelled. · d157c068
      mitz@apple.com authored
      https://bugs.webkit.org/show_bug.cgi?id=53255
      
      Source/WebCore: 
      
      Patch by Jia Pu <jpu@apple.com> on 2011-02-03
      This patch includes fix for reported bug, and also some housekeeping changes.
      
      To implement desired behavior, we need:
      1. Add a new marker type, SpellCheckingExemption, since now we distingusish between text
         that shouldn't be spellchecked and text shouldn't be autocorrected.
      2. Make sure that there is no pending correction panel when we enter markAllMisspellingsAndBadGrammarInRanges().
         Otherwise the spell checking code in that function may interfere with autocorrection. This
         is achieved by explicitly applying pending correction when user types space, line break or
         paragraph break.
      
      Housekeeping code changes include:
      1. Change manual-tests that were broken by relocated WebCore directory.
      2. Use TextIterator in various DocumentMarkerController functions instead of using
         Node::traverseNextNode() directly.
      3. Allow passing multiple marker types into DocumentMarkerController::removeMarkers() and
         DocumentMarkerController::hasMarkers() to improve clarity and efficiency.
      4. Fixes of minor bugs that were exposed previously.
      
      * WebCore.exp.in: Change signature of DocumentMarkerController::removeMarkers().
      
      * dom/DocumentMarker.h: Added new marker type SpellCheckingExemption.
      
      * dom/DocumentMarkerController.cpp:
      (WebCore::DocumentMarkerController::removeMarkers): Use TextIterator to scan the range to be
         consistent with addMarker() function. Allow passing in multiple marker types in one call.
         Added a boolean argument to specify the behavior when removing markers that partially
         overlap the specified range.
      (WebCore::DocumentMarkerController::removeMarkersFromMarkerMapVectorPair): Allow passing in
         multiple marker types in one call.
      (WebCore::DocumentMarkerController::hasMarkers): Use TextIterator to scan the range to be
         consistent with addMarker() function. Allow passing in multiple marker types in one call.
      
      * dom/DocumentMarkerController.h: Allow passing in multiple marker types to removeMarkers()
         and hasMarkers(). Added a boolean argument to removeMarkers() to specify the behavior when
         removing markers that partially overlap the specified range.
      
      * editing/Editor.cpp:
      (WebCore::markerTypesForAutocorrection): Add SpellCheckingExemption marker when apply correction.
      (WebCore::markerTypesForReplacement): Ditto.
      (WebCore::Editor::respondToChangedSelection): Reordered call to dismissCorrectionPanel() and
         setSelection() to make sure there is no pending correction when entering
         markAllMisspellingsAndBadGrammarInRanges().
      (WebCore::Editor::appliedEditing): Only remove CorrectionIndicator markers when the command
         is a top level command to improve efficiency.
      (WebCore::Editor::insertTextWithoutSendingTextEvent): Added code to applying pending correction.
      (WebCore::Editor::insertLineBreak): Ditto.
      (WebCore::Editor::insertParagraphSeparator): Ditto.
      (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges): Don't mark mispelling if the
         text carries SpellCheckingExemption marker.
      (WebCore::Editor::correctionPanelTimerFired): Reset correction panel if the returned suggestion
         from spellchecker is an empty string.
      (WebCore::Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited):
         Use new DocumentMarkerController::removeMarkers() to replace custom implemenation to improve
         efficiency and readability.
      (WebCore::Editor::applyCorrectionPanelInfo): Remove the code that set caret position after
         applying correction, since it's unnecessary. Also, store pre-correction string together with
         the marker for reversion panel to use.
      (WebCore::Editor::applyAutocorrectionBeforeTypingIfAppropriate): Apply pending correction.
      (WebCore::Editor::changeSelectionAfterCommand): Moved marker removal code to Editor::appliedEditing()
         where we have access to EditCommand object.
      
      * editing/Editor.h: Added new function applyAutocorrectionAfterTypingIfAppropriate().
      
      * manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html: Change manual-tests that
         were broken by relocated WebCore directory.
      
      * manual-tests/autocorrection/autocorrection-cancelled-by-typing-1.html: Ditto.
      
      * manual-tests/autocorrection/autocorrection-contraction.html: Ditto.
      
      * manual-tests/autocorrection/continue-typing-to-dismiss-reversion.html: Ditto.
      
      * manual-tests/autocorrection/delete-to-dismiss-reversion.html: Ditto.
      
      * manual-tests/autocorrection/delete-to-end-of-word-to-show-reversion.html: Ditto.
      
      * manual-tests/autocorrection/dismiss-multiple-guesses.html: Ditto.
      
      * manual-tests/autocorrection/move-to-end-of-word-to-show-reversion.html: Ditto.
      
      * manual-tests/autocorrection/select-from-multiple-guesses.html: Ditto.
      
      * manual-tests/autocorrection/spell-checking-after-reversion.html: Added.
      
      * manual-tests/autocorrection/type-whitespace-to-dismiss-reversion.html: Change manual-tests that
         were broken by relocated WebCore directory.
      
      * rendering/InlineTextBox.cpp:
      (WebCore::InlineTextBox::paintDocumentMarkers): Code clean-up to be more concise.
      
      LayoutTests: 
      
      Patch by Jia Pu <jpu@apple.com> on 2011-02-03
      Rebaselined tests broken by https://bugs.webkit.org/show_bug.cgi?id=51389
      
      * platform/mac/editing/spelling/autocorrection-contraction-expected.png:
      * platform/mac/editing/spelling/autocorrection-contraction-expected.txt:
      * platform/mac/editing/spelling/autocorrection-delete-expected.png:
      * platform/mac/editing/spelling/autocorrection-delete-expected.txt:
      * platform/mac/editing/spelling/autocorrection-removing-underline-after-paste-expected.png:
      * platform/mac/editing/spelling/autocorrection-removing-underline-after-paste-expected.txt:
      * platform/mac/editing/spelling/autocorrection-removing-underline-expected.png:
      * platform/mac/editing/spelling/autocorrection-removing-underline-expected.txt:
      * platform/mac/editing/spelling/autocorrection-simple-expected.checksum:
      * platform/mac/editing/spelling/autocorrection-simple-expected.png:
      * platform/mac/editing/spelling/autocorrection-simple-expected.txt:
      * platform/mac/editing/spelling/autocorrection-simple.html:
      * platform/mac/editing/spelling/delete-autocorrected-word-1-expected.png:
      * platform/mac/editing/spelling/delete-autocorrected-word-1-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@77577 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d157c068
  8. 08 Jan, 2011 1 commit
  9. 12 Dec, 2010 1 commit
    • morrita@google.com's avatar
      2010-10-28 MORITA Hajime <morrita@google.com> · 7a18feed
      morrita@google.com authored
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              * editing/spelling/script-tests/spellcheck-paste.js: Added.
              * editing/spelling/spellcheck-paste.html: Added.
              * editing/spelling/spellcheck-paste-expected.txt: Added.
              * platform/chromium/test_expectations.txt:
              * platform/gtk/Skipped:
              * platform/mac-leopard/Skipped:
              * platform/mac-tiger/Skipped:
              * platform/mac-wk2/Skipped:
              * platform/qt/Skipped:
              * platform/win/Skipped:
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              - Introduced SpellChecker class to encapsulate asynchronous spell
                checker state: sequence id, requesting text and target node.
                This is also the first step to decompose spell-check related
                code to a separate class.
              - Added EditorClient::isAsynchronousSpellCheckingEnabled()
                to use async spellcheck API on the platform.
                These APIs are touched by SpellChecker.
              - Used SpellChecker to check a pasted test. Text to check is
                collected from the subtree under the editingRoot.
              - Added Setting::m_asynchronousSpellCheckingEnabled to control
                async spell checking.
      
              Test: editing/spelling/spellcheck-paste.html
      
              * CMakeLists.txt:
              * GNUmakefile.am:
              * WebCore.exp.in:
              * WebCore.gypi:
              * WebCore.pro:
              * WebCore.vcproj/WebCore.vcproj:
              * WebCore.xcodeproj/project.pbxproj:
              * dom/DocumentMarkerController.cpp:
              (WebCore::DocumentMarkerController::showMarkers):
              (showDocumentMarkers):
              * dom/DocumentMarkerController.h:
              * dom/PositionIterator.cpp:
              (WebCore::PositionIterator::setOffsetInLeafNode):
              * dom/PositionIterator.h:
              * editing/Editor.cpp:
              (WebCore::Editor::replaceSelectionWithFragment):
              (WebCore::Editor::Editor):
              (WebCore::findFirstMarkable):
              (WebCore::Editor::selectionStartHasSpellingMarkerFor):
              * editing/Editor.h:
              (WebCore::Editor::spellChecker):
              * editing/SpellChecker.cpp: Added.
              (WebCore::SpellChecker::SpellChecker):
              (WebCore::SpellChecker::~SpellChecker):
              (WebCore::SpellChecker::initRequest):
              (WebCore::SpellChecker::clearRequest):
              (WebCore::SpellChecker::isAsynchronousEnabled):
              (WebCore::SpellChecker::canCheckAsynchronously):
              (WebCore::SpellChecker::isBusy):
              (WebCore::SpellChecker::isValid):
              (WebCore::SpellChecker::isCheckable):
              (WebCore::SpellChecker::requestCheckingFor):
              (WebCore::forwardIterator):
              (WebCore::SpellChecker::didCheck):
              * editing/SpellChecker.h: Added.
              (WebCore::SpellCheckingResult::SpellCheckingResult):
              (WebCore::SpellCheckingResult::type):
              (WebCore::SpellCheckingResult::location):
              (WebCore::SpellCheckingResult::length):
              * loader/EmptyClients.h:
              (WebCore::EmptyEditorClient::requestCheckingOfString):
              * page/EditorClient.h:
              * page/Settings.cpp:
              (WebCore::Settings::Settings):
              * page/Settings.h:
              (WebCore::Settings::setAsynchronousSpellCheckingEnabled):
              (WebCore::Settings::asynchronousSpellCheckingEnabled):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * src/EditorClientImpl.h:
              (WebKit::EditorClientImpl::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/EditorClientEfl.h:
              (WebCore::EditorClientEfl::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/EditorClientGtk.h:
              (WebKit::EditorClient::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/EditorClientHaiku.h:
              (WebCore::EditorClientHaiku::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added asynchronous spell checking API to WebEditorClient using
              -[NSSpellChecker requestCheckingOfString].
              Note that WebEditorSpellCheckResponder is a small class to receive
              requested spell-checking result. Note that this feature is
              disabled at default.
      
              Also added [WebPreferences setAsynchronousSpellCheckingEnabled:] to
              enable the feature from LayoutTestController.
      
              * WebCoreSupport/WebEditorClient.h:
              * WebCoreSupport/WebEditorClient.mm:
              (-[WebEditorSpellCheckResponder initWithSender:WebCore::sequence:results:]):
              (-[WebEditorSpellCheckResponder perform]):
              (toCoreSpellingResult):
              (-[WebEditorSpellCheckResponder WTF::WebCore::]):
              (WebEditorClient::requestCheckingOfString):
              * WebView/WebPreferenceKeysPrivate.h:
              * WebView/WebPreferences.mm:
              (+[WebPreferences initialize]):
              (-[WebPreferences setAsynchronousSpellCheckingEnabled:]):
              (-[WebPreferences asynchronousSpellCheckingEnabled]):
              * WebView/WebPreferencesPrivate.h:
              * WebView/WebView.mm:
              (-[WebView _preferencesChangedNotification:]):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/EditorClientQt.h:
              (WebCore::EditorClientQt::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/WebEditorClient.h:
              (WebEditorClient::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebCoreSupport/EditorClientWinCE.h:
              (WebKit::EditorClient::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebKitSupport/EditorClientWx.h:
              (WebCore::EditorClientWx::requestCheckingOfString):
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added a stub implememntation.
      
              * WebProcess/WebCoreSupport/WebEditorClient.cpp:
              (WebKit::WebEditorClient::requestCheckingOfString):
              * WebProcess/WebCoreSupport/WebEditorClient.h:
      2010-10-28  MORITA Hajime  <morrita@google.com>
      
              Reviewed by Ojan Vafai.
      
              spellcheck does not check pasted text
              https://bugs.webkit.org/show_bug.cgi?id=40092
      
              Added LayoutTestController::setAsynchronousSpellCheckingEnabled()
              to control the setting.
      
              * DumpRenderTree/LayoutTestController.cpp:
              (setAsynchronousSpellCheckingEnabledCallback):
              (LayoutTestController::staticFunctions):
              * DumpRenderTree/LayoutTestController.h:
              * DumpRenderTree/chromium/LayoutTestController.h:
              * DumpRenderTree/chromium/LayoutTestController.cpp:
              (LayoutTestController::LayoutTestController):
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
              * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
              * DumpRenderTree/mac/DumpRenderTree.mm:
              (resetDefaultsToConsistentValues):
              * DumpRenderTree/mac/LayoutTestControllerMac.mm:
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
              * DumpRenderTree/qt/LayoutTestControllerQt.h:
              * DumpRenderTree/qt/LayoutTestControllerQt.cpp:
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
              * DumpRenderTree/win/LayoutTestControllerWin.cpp:
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
              * DumpRenderTree/wx/LayoutTestControllerWx.cpp:
              (LayoutTestController::setAsynchronousSpellCheckingEnabled):
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73886 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7a18feed
  10. 28 Oct, 2010 1 commit
    • commit-queue@webkit.org's avatar
      2010-10-28 Jia Pu <jpu@apple.com> · 08abac67
      commit-queue@webkit.org authored
              Reviewed by Dan Bernstein.
      
              Editing a word with misspell or autocorrection underline should remove the underline when the editing changes the word.
              https://bugs.webkit.org/show_bug.cgi?id=48078
              <rdar://problem/8579155>
      
              * platform/mac-leopard/Skipped: New tests don't apply to this platform.
              * platform/mac-snowleopard/Skipped: Ditto.
              * platform/mac-tiger/Skipped: Ditto.
              * platform/mac-wk2/Skipped: Ditto.
              * platform/mac/editing/spelling/autocorrection-delete-expected.checksum: Updated expected test result.
              * platform/mac/editing/spelling/autocorrection-delete-expected.png: Ditto.
              * platform/mac/editing/spelling/editing-multiple-words-with-markers-expected.txt: Added.
              * platform/mac/editing/spelling/editing-multiple-words-with-markers.html: Added.
              * platform/mac/editing/spelling/editing-word-with-marker-1-expected.txt: Added.
              * platform/mac/editing/spelling/editing-word-with-marker-1.html: Added.
              * platform/mac/editing/spelling/editing-word-with-marker-2-expected.txt: Added.
              * platform/mac/editing/spelling/editing-word-with-marker-2.html: Added.
      2010-10-28  Jia Pu  <jpu@apple.com>
      
              Reviewed by Dan Bernstein.
      
              Editing a word with misspell or autocorrection underline should remove the underline when the editing changes the word.
              https://bugs.webkit.org/show_bug.cgi?id=48078
              <rdar://problem/8579155>
      
              Tests: platform/mac/editing/spelling/editing-multiple-words-with-markers.html
                     platform/mac/editing/spelling/editing-word-with-marker-1.html
                     platform/mac/editing/spelling/editing-word-with-marker-2.html
      
              This patch is part of on-going improvement of autocorrection feature on Mac OS X. When an editing
              occurs, if it affects words (by deleting/inserting characters, spliting word, merging words) that
              have Spelling and/or CorrectionIndicator markers, we want to remove the markers. If subsequntial
              spelling checking finds spelling error in newlly formed words, it will add the markers back in.
      
              * dom/DocumentMarker.h: Changed MarkerType to bit masks to make search multiple types easier.
      
              * dom/DocumentMarkerController.cpp: Refactored two removeMarkers() methods to support remove
                markers with specific type from a node.
              (WebCore::DocumentMarkerController::removeMarkers): Changed signature to remove marker with specific type.
              (WebCore::DocumentMarkerController::removeMarkersFromMarkerMapVectorPair): Refactoring.
              (WebCore::DocumentMarkerController::hasMarkers): Convenience method to search markers in range.
      
              * dom/DocumentMarkerController.h: Added new methods and matched new signature of removeMarkers().
      
              * editing/Editor.cpp:
              (WebCore::Editor::respondToChangedContents): Remove existing markers if the change formed new word.
              (WebCore::Editor::cut): Remove markers on words that will be modified by this editing.
              (WebCore::Editor::paste): Ditto.
              (WebCore::Editor::pasteAsPlainText): Ditto.
              (WebCore::Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited): Main logic for removing
                markers on words affected by editing.
      
              * editing/Editor.h: Added removeSpellAndCorrectionMarkersFromWordsToBeEdited().  Added
                REMOVE_MARKERS_UPON_EDITING and SUPPORT_AUTOCORRECTION_PANEL macro to improve readability.
      
              * editing/TypingCommand.cpp:
              (WebCore::TypingCommand::insertText): Remove markers on words that will be modified by this editing.
              (WebCore::TypingCommand::deleteKeyPressed): Ditto.
              (WebCore::TypingCommand::forwardDeleteKeyPressed): Ditto.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70826 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      08abac67
  11. 22 Aug, 2010 1 commit
    • dbates@webkit.org's avatar
      2010-08-22 Daniel Bates <dbates@rim.com> · 858331b0
      dbates@webkit.org authored
              Reviewed by Eric Seidel.
      
              Encapsulate document marker management into DocumentMarkerController
              https://bugs.webkit.org/show_bug.cgi?id=44383
      
              Modify call sites in the Chromium port to use DocumentMarkerController.
      
              No functionality was changed, so no new tests.
      
              * src/WebFrameImpl.cpp:
              (WebKit::WebFrameImpl::stopFinding):
              (WebKit::WebFrameImpl::addMarker):
              (WebKit::WebFrameImpl::setMarkerActive):
      2010-08-22  Daniel Bates  <dbates@rim.com>
      
              Reviewed by Eric Seidel.
      
              Encapsulate document marker management into DocumentMarkerController
              https://bugs.webkit.org/show_bug.cgi?id=44383
      
              Modify call sites in the Apple Windows port to use DocumentMarkerController.
      
              No functionality was changed, so no new tests.
      
              * WebFrame.cpp:
              (WebFrame::unmarkAllMisspellings):
              (WebFrame::unmarkAllBadGrammar):
              * WebView.cpp:
              (WebView::rectsForTextMatches):
      2010-08-22  Daniel Bates  <dbates@rim.com>
      
              Reviewed by Eric Seidel.
      
              Encapsulate document marker management into DocumentMarkerController
              https://bugs.webkit.org/show_bug.cgi?id=44383
      
              Modify call sites in the Apple Mac port to use DocumentMarkerController.
      
              No functionality was changed, so no new tests.
      
              * WebView/WebFrame.mm:
              (-[WebFrame _unmarkAllBadGrammar]):
              (-[WebFrame _unmarkAllMisspellings]):
              * WebView/WebHTMLView.mm:
              (-[WebHTMLView unmarkAllTextMatches]):
              (-[WebHTMLView rectsForTextMatches]):
      2010-08-22  Daniel Bates  <dbates@rim.com>
      
              Reviewed by Eric Seidel.
      
              Encapsulate document marker management into DocumentMarkerController
              https://bugs.webkit.org/show_bug.cgi?id=44383
      
              Modify call sites in the EFL port to use DocumentMarkerController.
      
              No functionality was changed, so no new tests.
      
              * ewk/ewk_frame.cpp:
              (ewk_frame_text_matches_unmark_all):
      2010-08-22  Daniel Bates  <dbates@rim.com>
      
              Reviewed by Eric Seidel.
      
              Encapsulate document marker management into DocumentMarkerController
              https://bugs.webkit.org/show_bug.cgi?id=44383
      
              Moves the document marker management code in Document.cpp into its own
              class called DocumentMarkerController.
      
              No functionality was changed, so no new tests.
      
              * Android.mk: Added DocumentMarkerController.cpp 
              * CMakeLists.txt: Ditto.
              * GNUmakefile.am: Added DocumentMarkerController.cpp and DocumentMarkerController.h.
              * WebCore.exp.in: Substituted symbols __ZN7WebCore24DocumentMarkerController13removeMarkersENS_14DocumentMarker10MarkerTypeE
              and __ZN7WebCore24DocumentMarkerController23renderedRectsForMarkersENS_14DocumentMarker10MarkerTypeE for
              __ZN7WebCore8Document13removeMarkersENS_14DocumentMarker10MarkerTypeE and 
              __ZN7WebCore8Document23renderedRectsForMarkersENS_14DocumentMarker10MarkerTypeE, respectively.
              * WebCore.gypi: Added DocumentMarkerController.cpp and DocumentMarkerController.h.
              * WebCore.pro: Ditto.
              * WebCore.vcproj/WebCore.vcproj: Ditto.
              * WebCore.xcodeproj/project.pbxproj: Ditto.
              * dom/Document.cpp:
              (WebCore::Document::removedLastRef): Modified to call DocumentMarkerController::detach().
              (WebCore::Document::~Document): Removed "deleteAllValues(m_markers)" as DocumentMarkerController
              is stored in OwnPtr; so it will be destroyed automatically on Document destruction.
              (WebCore::Document::textInserted): Modified to use marker controller.
              (WebCore::Document::textRemoved): Ditto.
              * dom/Document.h:
              (WebCore::Document::markers): Added.
              * dom/DocumentMarkerController.cpp: Added.
              (WebCore::placeholderRectForMarker):
              (WebCore::DocumentMarkerController::detach):
              (WebCore::DocumentMarkerController::addMarker):
              (WebCore::DocumentMarkerController::removeMarkers):
              (WebCore::DocumentMarkerController::copyMarkers):
              (WebCore::DocumentMarkerController::markerContainingPoint):
              (WebCore::DocumentMarkerController::markersForNode):
              (WebCore::DocumentMarkerController::renderedRectsForMarkers):
              (WebCore::DocumentMarkerController::repaintMarkers):
              (WebCore::DocumentMarkerController::setRenderedRectForMarker):
              (WebCore::DocumentMarkerController::invalidateRenderedRectsForMarkersInRect):
              (WebCore::DocumentMarkerController::shiftMarkers):
              (WebCore::DocumentMarkerController::setMarkersActive):
              * dom/DocumentMarkerController.h: Added.
              (WebCore::DocumentMarkerController::~DocumentMarkerController):
              * editing/Editor.cpp:
              (WebCore::Editor::ignoreSpelling): Modified to use marker controller.
              (WebCore::findFirstMisspellingInRange): Ditto.
              (WebCore::findFirstGrammarDetailInRange): Ditto.
              (WebCore::Editor::advanceToNextMisspelling): Ditto.
              (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges): Ditto.
              (WebCore::Editor::changeBackToReplacedString): Ditto.
              * editing/SplitTextNodeCommand.cpp:
              (WebCore::SplitTextNodeCommand::doApply): Ditto.
              (WebCore::SplitTextNodeCommand::doUnapply): Ditto.
              * page/Frame.cpp:
              (WebCore::Frame::markAllMatchesForText): Ditto.
              (WebCore::Frame::setMarkedTextMatchesAreHighlighted): Ditto.
              (WebCore::Frame::respondToChangedSelection): Ditto.
              * page/FrameView.cpp:
              (WebCore::FrameView::getTickmarks): Ditto.
              (WebCore::FrameView::paintContents): Ditto.
              * page/Page.cpp:
              (WebCore::Page::unmarkAllTextMatches): Ditto.
              * rendering/HitTestResult.cpp:
              (WebCore::HitTestResult::spellingToolTip): Ditto.
              (WebCore::HitTestResult::replacedString): Ditto.
              * rendering/InlineTextBox.cpp:
              (WebCore::InlineTextBox::paintSpellingOrGrammarMarker): Ditto.
              (WebCore::InlineTextBox::paintTextMatchMarker): Ditto.
              (WebCore::InlineTextBox::computeRectForReplacementMarker): Ditto.
              (WebCore::InlineTextBox::paintDocumentMarkers): Ditto.
              * rendering/SVGInlineTextBox.cpp:
              (WebCore::SVGInlineTextBox::computeTextMatchMarkerRect): Ditto.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@65787 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      858331b0