1. 08 Apr, 2011 1 commit
    • rniwa@webkit.org's avatar
      2011-04-08 Ryosuke Niwa <rniwa@webkit.org> · 4f635d62
      rniwa@webkit.org authored
              Reviewed by Tony Chang.
      
              dump-as-markup conversion: editing/pasteboard/paste-text-at-tabspan-001.html and paste-text-at-tabspan-002.html
              https://bugs.webkit.org/show_bug.cgi?id=58081
      
              Converted paste-text-at-tabspan-001.html and paste-text-at-tabspan-002.html to dump-as-markup tests.
              Also explained what to expect in each test.
      
              * editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Added.
              * editing/pasteboard/paste-text-at-tabspan-001.html:
              * editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Added.
              * editing/pasteboard/paste-text-at-tabspan-002.html:
              * platform/chromium-linux/editing/pasteboard/paste-text-at-tabspan-001-expected.checksum: Removed.
              * platform/chromium-linux/editing/pasteboard/paste-text-at-tabspan-001-expected.png: Removed.
              * platform/chromium-linux/editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Removed.
              * platform/chromium-linux/editing/pasteboard/paste-text-at-tabspan-002-expected.png: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-001-expected.checksum: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-001-expected.png: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-002-expected.png: Removed.
              * platform/chromium-win/editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-001-expected.checksum: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-001-expected.png: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-002-expected.png: Removed.
              * platform/gtk/editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-001-expected.checksum: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-001-expected.png: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-002-expected.png: Removed.
              * platform/mac/editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Removed.
              * platform/qt/editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Removed.
              * platform/qt/editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Removed.
              * platform/qt/editing/pasteboard/paste-text-at-tabspan-002-expected.png: Removed.
              * platform/qt/editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Removed.
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@83343 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4f635d62
  2. 09 Nov, 2005 1 commit
    • harrison's avatar
      Layout tests for <rdar://problem/4313925> · 90eb479a
      harrison authored
              Denver Regression: Mail: "TAB+paste+insert before" actually inserts after the pasted text
      
              * editing/inserting/insert-br-at-tabspan-001-expected.checksum: Added.
              * editing/inserting/insert-br-at-tabspan-001-expected.png: Added.
              * editing/inserting/insert-br-at-tabspan-001-expected.txt: Added.
              * editing/inserting/insert-br-at-tabspan-001.html: Added.
              * editing/inserting/insert-br-at-tabspan-002-expected.checksum: Added.
              * editing/inserting/insert-br-at-tabspan-002-expected.png: Added.
              * editing/inserting/insert-br-at-tabspan-002-expected.txt: Added.
              * editing/inserting/insert-br-at-tabspan-002.html: Added.
              * editing/inserting/insert-br-at-tabspan-003-expected.checksum: Added.
              * editing/inserting/insert-br-at-tabspan-003-expected.png: Added.
              * editing/inserting/insert-br-at-tabspan-003-expected.txt: Added.
              * editing/inserting/insert-br-at-tabspan-003.html: Added.
              * editing/inserting/insert-text-at-tabspan-001-expected.checksum: Added.
              * editing/inserting/insert-text-at-tabspan-001-expected.png: Added.
              * editing/inserting/insert-text-at-tabspan-001-expected.txt: Added.
              * editing/inserting/insert-text-at-tabspan-001.html: Added.
              * editing/inserting/insert-text-at-tabspan-002-expected.checksum: Added.
              * editing/inserting/insert-text-at-tabspan-002-expected.png: Added.
              * editing/inserting/insert-text-at-tabspan-002-expected.txt: Added.
              * editing/inserting/insert-text-at-tabspan-002.html: Added.
              * editing/inserting/insert-text-at-tabspan-003-expected.checksum: Added.
              * editing/inserting/insert-text-at-tabspan-003-expected.png: Added.
              * editing/inserting/insert-text-at-tabspan-003-expected.txt: Added.
              * editing/inserting/insert-text-at-tabspan-003.html: Added.
              * editing/pasteboard/paste-text-at-tabspan-001-expected.checksum: Added.
              * editing/pasteboard/paste-text-at-tabspan-001-expected.png: Added.
              * editing/pasteboard/paste-text-at-tabspan-001-expected.txt: Added.
              * editing/pasteboard/paste-text-at-tabspan-001.html: Added.
              * editing/pasteboard/paste-text-at-tabspan-002-expected.checksum: Added.
              * editing/pasteboard/paste-text-at-tabspan-002-expected.png: Added.
              * editing/pasteboard/paste-text-at-tabspan-002-expected.txt: Added.
              * editing/pasteboard/paste-text-at-tabspan-002.html: Added.
              * editing/pasteboard/paste-text-at-tabspan-003-expected.checksum: Added.
              * editing/pasteboard/paste-text-at-tabspan-003-expected.png: Added.
              * editing/pasteboard/paste-text-at-tabspan-003-expected.txt: Added.
              * editing/pasteboard/paste-text-at-tabspan-003.html: Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11101 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      90eb479a
  3. 29 Nov, 2004 1 commit
    • kocienda's avatar
      Reviewed by Chris · a42c2129
      kocienda authored
              Rewrite of paste code (specifically the ReplaceSelectionCommand class). Many more cases
              are handled correctly now, including selections that span multiple blocks, and cases
              where content on the pasteboard ends in newlines (or what appear to be newlines to a
              user, really block ends or BRs). I also made one small, but important change in the
              copy code to annotate the markup written to the pasteboard to support these selections
              ending in newlines.
      
              New header that defines a couple of constants used in copying and pasting.
      
              * ForwardingHeaders/editing/html_interchange.h: Added.
              * khtml/editing/html_interchange.h: Added.
      
              Rewrite of the ReplaceSelectionCommand. There are several new helper functions, as well
              as a new helper class, ReplacementFragment, which encapsulates information and functions
              pertaining to a document fragment that is being inserted into a document.
      
              * khtml/editing/htmlediting.cpp:
              (khtml::ReplacementFragment::ReplacementFragment):
              (khtml::ReplacementFragment::~ReplacementFragment):
              (khtml::ReplacementFragment::firstChild): Simple accessor.
              (khtml::ReplacementFragment::lastChild): Ditto.
              (khtml::ReplacementFragment::mergeStartNode): Looks at the nodes in a fragment and determines
              the starting node to use for merging into the block containing the start of the selection.
              (khtml::ReplacementFragment::mergeEndNode): Same as above, but for the end of the selection.
              (khtml::ReplacementFragment::pruneEmptyNodes): Simple helper.
              (khtml::ReplacementFragment::isInterchangeNewlineComment): Determines if a node is the
              special annotation comment added in by the copy code.
              (khtml::ReplacementFragment::removeNode): Simple helper.
              (khtml::isComment): Simple helper.
              (khtml::isProbablyBlock): Determines if a node is of a type that is usually rendered as a block.
              I would like to do better than this some day, but this check will hold us until I can do better.
              (khtml::ReplaceSelectionCommand::ReplaceSelectionCommand):
              (khtml::ReplaceSelectionCommand::~ReplaceSelectionCommand):
              (khtml::ReplaceSelectionCommand::doApply):
              (khtml::ReplaceSelectionCommand::completeHTMLReplacement): Figures out the right ending selection.
              * khtml/editing/htmlediting.h: Declarations for the new ReplacementFragment class.
              (khtml::ReplacementFragment::root):
              (khtml::ReplacementFragment::type):
              (khtml::ReplacementFragment::isEmpty):
              (khtml::ReplacementFragment::isSingleTextNode):
              (khtml::ReplacementFragment::isTreeFragment):
              (khtml::ReplacementFragment::hasMoreThanOneBlock):
              (khtml::ReplacementFragment::hasLogicalNewlineAtEnd):
      
              This smaller set of changes markup generation to add the newline annotation described in the
              comment at the start of this entry.
      
              * khtml/xml/dom2_rangeimpl.cpp:
              (DOM::RangeImpl::addCommentToHTMLMarkup): Simple helper.
              (DOM::RangeImpl::toHTML): Added new EAnnotateForInterchange default argument to control whether
              comment annotations are added to the markup generated.
              * khtml/xml/dom2_rangeimpl.h: Add some new declarations.
              * kwq/WebCoreBridge.mm:
              (-[WebCoreBridge markupStringFromRange:nodes:]): Request that markup resulting from call to
              DOM::RangeImpl::toHTML uses annotations when generating.
      
              New tests.
      
              * layout-tests/editing/pasteboard/paste-text-001-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-001.html: Added.
              * layout-tests/editing/pasteboard/paste-text-002-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-002.html: Added.
              * layout-tests/editing/pasteboard/paste-text-003-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-003.html: Added.
              * layout-tests/editing/pasteboard/paste-text-004-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-004.html: Added.
              * layout-tests/editing/pasteboard/paste-text-005-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-005.html: Added.
              * layout-tests/editing/pasteboard/paste-text-006-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-006.html: Added.
              * layout-tests/editing/pasteboard/paste-text-007-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-007.html: Added.
              * layout-tests/editing/pasteboard/paste-text-008-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-008.html: Added.
              * layout-tests/editing/pasteboard/paste-text-009-expected.txt: Added.
              * layout-tests/editing/pasteboard/paste-text-009.html: Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@8087 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a42c2129
  4. 12 Apr, 2004 1 commit
    • kocienda's avatar
      WebCore: · 69706495
      kocienda authored
              Reviewed by Dave
      
              Added execCommand support for cut/copy/paste.
      
              * khtml/xml/dom_docimpl.cpp:
              (DocumentImpl::execCommand): Added cut/copy/paste atoms and added else if cases
              for the commands.
              * kwq/KWQKHTMLPart.h:
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::issueCutCommand): Glue for calling from WebCore to do a cut in Cocoa.
              (KWQKHTMLPart::issueCopyCommand): Same as above, but for copy.
              (KWQKHTMLPart::issuePasteCommand): Same as above, but for paste.
              * kwq/WebCoreBridge.h: Declared issueCutCommand, issueCopyCommand, and issuePasteCommand
              to be implemented on the WebKit side of the bridge.
              * layout-tests/editing/editing.js: Added cut/copy/paste support to js library to support
              making layout tests.
              * layout-tests/editing/pasteboard/copy-paste-text-001-expected.txt: Added.
              * layout-tests/editing/pasteboard/copy-paste-text-001.html: Added.
              * layout-tests/editing/pasteboard/cut-paste-text-002-expected.txt: Added.
              * layout-tests/editing/pasteboard/cut-paste-text-002.html: Added.
              * layout-tests/editing/pasteboard/cut-text-001-expected.txt: Added.
              * layout-tests/editing/pasteboard/cut-text-001.html: Added.
      
      WebKit:
      
              Reviewed by Dave
      
              Added execCommand support for cut/copy/paste.
      
              * WebCoreSupport.subproj/WebBridge.m:
              (-[WebBridge issueCutCommand]): Glue for calling from WebCore to do a cut in Cocoa.
              (-[WebBridge issueCopyCommand]): Same as above, but for copy.
              (-[WebBridge issuePasteCommand]): Same as above, but for paste.
              * WebView.subproj/WebHTMLView.m:
              (-[WebHTMLView copy:]): Move this to private implementation category so the bridge can see it.
              (-[WebHTMLView cut:]): Ditto.
              (-[WebHTMLView paste:]): Ditto.
              * WebView.subproj/WebHTMLViewPrivate.h: Move copy;, cut:, and paste: to private implementation
              category so the bridge can see it.
              * WebView.subproj/WebView.m:
              (-[WebView copy:]): Implemented by calling WebHTMLView to do the work.
              (-[WebView cut:]): Ditto.
              (-[WebView paste:]): Ditto.
              * WebView.subproj/WebViewPrivate.h: Added all the NSReponder methods we plan to implement as
              part of the WebKit editing API.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      69706495
  5. 06 Apr, 2004 1 commit
    • kocienda's avatar
      Reviewed by me · 495c303e
      kocienda authored
              Added a new suite of layout tests for editing, all added
              in the new layout-tests/editing subtree.
      
              * layout-tests/editing/abe.jpg: Added.
              * layout-tests/editing/deleting/delete-block-contents-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-block-contents-001.html: Added.
              * layout-tests/editing/deleting/delete-block-contents-002-expected.txt: Added.
              * layout-tests/editing/deleting/delete-block-contents-002.html: Added.
              * layout-tests/editing/deleting/delete-block-contents-003-expected.txt: Added.
              * layout-tests/editing/deleting/delete-block-contents-003.html: Added.
              * layout-tests/editing/deleting/delete-br-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-001.html: Added.
              * layout-tests/editing/deleting/delete-br-002-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-002.html: Added.
              * layout-tests/editing/deleting/delete-br-003-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-003.html: Added.
              * layout-tests/editing/deleting/delete-br-004-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-004.html: Added.
              * layout-tests/editing/deleting/delete-br-005-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-005.html: Added.
              * layout-tests/editing/deleting/delete-br-006-expected.txt: Added.
              * layout-tests/editing/deleting/delete-br-006.html: Added.
              * layout-tests/editing/deleting/delete-character-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-character-001.html: Added.
              * layout-tests/editing/deleting/delete-contiguous-ws-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-contiguous-ws-001.html: Added.
              * layout-tests/editing/deleting/delete-image-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-image-001.html: Added.
              * layout-tests/editing/deleting/delete-image-002-expected.txt: Added.
              * layout-tests/editing/deleting/delete-image-002.html: Added.
              * layout-tests/editing/deleting/delete-image-003-expected.txt: Added.
              * layout-tests/editing/deleting/delete-image-003.html: Added.
              * layout-tests/editing/deleting/delete-leading-ws-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-leading-ws-001.html: Added.
              * layout-tests/editing/deleting/delete-selection-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-selection-001.html: Added.
              * layout-tests/editing/deleting/delete-trailing-ws-001-expected.txt: Added.
              * layout-tests/editing/deleting/delete-trailing-ws-001.html: Added.
              * layout-tests/editing/editing.js: Added.
              * layout-tests/editing/inserting/typing-001-expected.txt: Added.
              * layout-tests/editing/inserting/typing-001.html: Added.
              * layout-tests/editing/inserting/typing-002-expected.txt: Added.
              * layout-tests/editing/inserting/typing-002.html: Added.
              * layout-tests/editing/inserting/typing-around-br-001-expected.txt: Added.
              * layout-tests/editing/inserting/typing-around-br-001.html: Added.
              * layout-tests/editing/inserting/typing-around-image-001-expected.txt: Added.
              * layout-tests/editing/inserting/typing-around-image-001.html: Added.
              * layout-tests/editing/selection/extend-by-character-001-expected.txt: Added.
              * layout-tests/editing/selection/extend-by-character-001.html: Added.
              * layout-tests/editing/selection/extend-by-character-002-expected.txt: Added.
              * layout-tests/editing/selection/extend-by-character-002.html: Added.
              * layout-tests/editing/selection/extend-by-character-003-expected.txt: Added.
              * layout-tests/editing/selection/extend-by-character-003.html: Added.
              * layout-tests/editing/selection/extend-by-character-004-expected.txt: Added.
              * layout-tests/editing/selection/extend-by-character-004.html: Added.
              * layout-tests/editing/selection/extend-by-character-005-expected.txt: Added.
              * layout-tests/editing/selection/extend-by-character-005.html: Added.
              * layout-tests/editing/selection/move-by-character-001-expected.txt: Added.
              * layout-tests/editing/selection/move-by-character-001.html: Added.
              * layout-tests/editing/selection/move-by-character-002-expected.txt: Added.
              * layout-tests/editing/selection/move-by-character-002.html: Added.
              * layout-tests/editing/selection/move-by-character-003-expected.txt: Added.
              * layout-tests/editing/selection/move-by-character-003.html: Added.
              * layout-tests/editing/selection/move-by-character-004-expected.txt: Added.
              * layout-tests/editing/selection/move-by-character-004.html: Added.
              * layout-tests/editing/selection/move-by-character-005-expected.txt: Added.
              * layout-tests/editing/selection/move-by-character-005.html: Added.
              * layout-tests/editing/undo/redo-typing-001-expected.txt: Added.
              * layout-tests/editing/undo/redo-typing-001.html: Added.
              * layout-tests/editing/undo/undo-typing-001-expected.txt: Added.
              * layout-tests/editing/undo/undo-typing-001.html: Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6315 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      495c303e