Changeset 20075 in webkit


Ignore:
Timestamp:
Mar 8, 2007 6:37:26 PM (17 years ago)
Author:
justing
Message:

LayoutTests:

Reviewed by harrison


<rdar://problem/4903193>
On particular page, Copy is so slow it seems like a hang

Less messy DOM trees:

  • editing/deleting/delete-3857753-fix-expected.txt:
  • editing/inserting/insert-3786362-fix-expected.txt:
  • editing/inserting/insert-3907422-fix-expected.txt:
  • editing/pasteboard/display-block-on-spans-expected.txt:
  • editing/pasteboard/paste-4035648-fix-expected.txt:
  • editing/pasteboard/paste-4039777-fix-expected.txt:
  • editing/pasteboard/paste-line-endings-001-expected.txt:
  • editing/pasteboard/paste-line-endings-006-expected.txt:
  • editing/pasteboard/paste-list-001-expected.txt:
  • editing/pasteboard/paste-pre-001-expected.txt:
  • editing/pasteboard/paste-pre-002-expected.txt:
  • editing/pasteboard/paste-table-001-expected.txt:
  • editing/pasteboard/paste-table-002-expected.txt:
  • editing/pasteboard/paste-text-003-expected.txt:
  • editing/pasteboard/paste-text-011-expected.txt:
  • editing/pasteboard/paste-text-015-expected.txt:
  • editing/pasteboard/paste-text-016-expected.txt:
  • editing/pasteboard/paste-text-017-expected.txt:
  • editing/pasteboard/styled-element-markup-expected.txt:
  • editing/pasteboard/testcase-9507-expected.txt:
  • editing/style/smoosh-styles-001-expected.txt:
  • editing/style/smoosh-styles-002-expected.txt:
  • fast/lists/drag-into-marker-expected.txt: Styles from style sheets are now inlined:
  • webarchive/test-duplicate-resources-expected.txt:
  • webarchive/test-frameset-expected.txt:
  • webarchive/test-link-href-expected.txt:\ Two levels of nesting are removed, but text nodes are no longer coalesced when they should be, investigating:
  • editing/pasteboard/block-wrappers-necessary-expected.txt:

WebCore:

Reviewed by harrison


<rdar://problem/4903193>
On particular page, Copy is so slow it seems like a hang


~2x speedup copying:
http://shakespeare.mit.edu/henryviii/full.html
Also produces less bloated markup.

  • editing/markup.cpp: (WebCore::startMarkup): Don't wrap text nodes in style spans. For Elements, don't inline styles inherited from ancestors. (WebCore::createMarkup): No longer necessary to find the root's default style and pass it to startMarkup. Add a wrapper span around the markup with the styles that all nodes in the markup inherit (the inheritable styles from the common ancestor container's computed style). Added a FIXME about unecessary markup for inline ancestors up to the commonAncestorBlock.
Location:
trunk
Files:
31 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r20072 r20075  
     12007-03-08  Justin Garcia  <justin.garcia@apple.com>
     2
     3        Reviewed by harrison
     4       
     5        <rdar://problem/4903193>
     6        On particular page, Copy is so slow it seems like a hang
     7
     8        Less messy DOM trees:
     9        * editing/deleting/delete-3857753-fix-expected.txt:
     10        * editing/inserting/insert-3786362-fix-expected.txt:
     11        * editing/inserting/insert-3907422-fix-expected.txt:
     12        * editing/pasteboard/display-block-on-spans-expected.txt:
     13        * editing/pasteboard/paste-4035648-fix-expected.txt:
     14        * editing/pasteboard/paste-4039777-fix-expected.txt:
     15        * editing/pasteboard/paste-line-endings-001-expected.txt:
     16        * editing/pasteboard/paste-line-endings-006-expected.txt:
     17        * editing/pasteboard/paste-list-001-expected.txt:
     18        * editing/pasteboard/paste-pre-001-expected.txt:
     19        * editing/pasteboard/paste-pre-002-expected.txt:
     20        * editing/pasteboard/paste-table-001-expected.txt:
     21        * editing/pasteboard/paste-table-002-expected.txt:
     22        * editing/pasteboard/paste-text-003-expected.txt:
     23        * editing/pasteboard/paste-text-011-expected.txt:
     24        * editing/pasteboard/paste-text-015-expected.txt:
     25        * editing/pasteboard/paste-text-016-expected.txt:
     26        * editing/pasteboard/paste-text-017-expected.txt:
     27        * editing/pasteboard/styled-element-markup-expected.txt:
     28        * editing/pasteboard/testcase-9507-expected.txt:
     29        * editing/style/smoosh-styles-001-expected.txt:
     30        * editing/style/smoosh-styles-002-expected.txt:
     31        * fast/lists/drag-into-marker-expected.txt:
     32        Styles from style sheets are now inlined:
     33        * webarchive/test-duplicate-resources-expected.txt:
     34        * webarchive/test-frameset-expected.txt:
     35        * webarchive/test-link-href-expected.txt:\
     36        Two levels of nesting are removed, but text nodes are no
     37        longer coalesced when they should be, investigating:
     38        * editing/pasteboard/block-wrappers-necessary-expected.txt:
     39
    1402007-03-08  Maciej Stachowiak  <mjs@apple.com>
    241
  • trunk/LayoutTests/editing/deleting/delete-3857753-fix-expected.txt

    r19648 r20075  
    2121          RenderText {#text} at (0,0) size 25x28
    2222            text run at (0,0) width 25: "on"
    23           RenderInline {SPAN} at (0,0) size 12x28
    24             RenderInline {I} at (0,0) size 12x28
     23          RenderInline {I} at (0,0) size 12x28
     24            RenderInline {SPAN} at (0,0) size 12x28
    2525              RenderText {#text} at (25,0) size 12x28
    2626                text run at (25,0) width 12: "o"
  • trunk/LayoutTests/editing/inserting/insert-3786362-fix-expected.txt

    r19605 r20075  
    66EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    77EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    8 EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > BODY > HTML > #document toDOMRange:range from 1 of SPAN > DIV > DIV > BODY > HTML > #document to 1 of SPAN > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     8EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > BODY > HTML > #document toDOMRange:range from 2 of DIV > DIV > BODY > HTML > #document to 2 of DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    99EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1010EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    3333          RenderText {#text} at (2,2) size 11x28
    3434            text run at (2,2) width 11: "a"
    35           RenderInline {SPAN} at (0,0) size 0x18
    36             RenderBR {BR} at (13,24) size 0x0
    37           RenderInline {SPAN} at (0,0) size 0x18
    38             RenderBR {BR} at (2,30) size 0x28
    39 caret: position 0 of child 0 {BR} of child 2 {SPAN} of child 3 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     35          RenderBR {BR} at (13,24) size 0x0
     36          RenderBR {BR} at (2,30) size 0x28
     37caret: position 0 of child 2 {BR} of child 3 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/inserting/insert-3907422-fix-expected.txt

    r19605 r20075  
    3535            RenderText {#text} at (22,0) size 21x18
    3636              text run at (22,0) width 21: "foo"
     37        RenderBlock (anonymous) at (0,86) size 784x0
    3738        RenderBlock {DIV} at (0,102) size 784x52
    3839          RenderBlock (anonymous) at (0,0) size 784x0
     
    4344            RenderText {#text} at (0,0) size 22x18
    4445              text run at (0,0) width 22: "baz"
    45         RenderBlock (anonymous) at (0,154) size 784x0
    4646caret: position 3 of child 1 {#text} of child 1 {DIV} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/block-wrappers-necessary-expected.txt

    r19605 r20075  
    1414EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of P > CENTER > DIV > DIV > BODY > HTML > #document to 0 of P > CENTER > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1515EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    16 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 85 of #text > P > SPAN > P > CENTER > DIV > DIV > BODY > HTML > #document to 85 of #text > P > SPAN > P > CENTER > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     16EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 85 of #text > P > P > CENTER > DIV > DIV > BODY > HTML > #document to 85 of #text > P > P > CENTER > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1717EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1818EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    4343          RenderBlock {CENTER} at (2,20) size 780x150
    4444            RenderBlock {P} at (0,0) size 780x150
    45               RenderBlock (anonymous) at (0,0) size 780x0
    46                 RenderInline {SPAN} at (0,0) size 0x0
    47               RenderBlock (anonymous) at (0,0) size 780x110
    48                 RenderBlock {P} at (0,0) size 780x110
    49                   RenderText {#text} at (0,0) size 76x22
    50                     text run at (0,0) width 76: "This is an "
    51                   RenderInline {B} at (0,0) size 82x22
    52                     RenderText {#text} at (76,0) size 82x22
    53                       text run at (76,0) width 82: "interactive"
    54                   RenderText {#text} at (158,0) size 622x44
    55                     text run at (158,0) width 622: " documentation site, so please help out by posting any useful information that you've "
    56                     text run at (325,22) width 129: "had to search out."
    57                   RenderBR {BR} at (454,39) size 0x0
    58                   RenderText {#text} at (20,44) size 115x22
    59                     text run at (20,44) width 115: "(Adding to this "
    60                   RenderInline {A} at (0,0) size 107x22 [color=#0000EE]
    61                     RenderText {#text} at (135,44) size 107x22
    62                       text run at (135,44) width 107: "wiki is so easy"
    63                   RenderText {#text} at (242,44) size 207x22
    64                     text run at (242,44) width 207: ", you can't screw it up). See "
    65                   RenderInline {A} at (0,0) size 114x22 [color=#0000EE]
    66                     RenderText {#text} at (449,44) size 114x22
    67                       text run at (449,44) width 114: "Wiki Reference"
    68                   RenderText {#text} at (563,44) size 196x22
    69                     text run at (563,44) width 196: " for text formatting syntax."
    70                   RenderBR {BR} at (759,61) size 0x0
    71                   RenderText {#text} at (161,66) size 283x22
    72                     text run at (161,66) width 283: "Info for setting up your own wiki is at "
    73                   RenderInline {A} at (0,0) size 170x22 [color=#0000EE]
    74                     RenderText {#text} at (444,66) size 170x22
    75                       text run at (444,66) width 170: "about howto.apple.com"
    76                   RenderText {#text} at (614,66) size 5x22
    77                     text run at (614,66) width 5: "."
    78                   RenderBR {BR} at (619,83) size 0x0
    79                   RenderText {#text} at (96,88) size 514x22
    80                     text run at (96,88) width 514: "Check out a cool wiki editor application that helps in wiki generation: "
    81                   RenderInline {A} at (0,0) size 73x22 [color=#0000EE]
    82                     RenderText {#text} at (610,88) size 73x22
    83                       text run at (610,88) width 73: "Wikinator"
    84               RenderBlock (anonymous) at (0,128) size 780x0
    85                 RenderInline {SPAN} at (0,0) size 0x0
    86                 RenderInline {SPAN} at (0,0) size 0x0
    87               RenderBlock (anonymous) at (0,128) size 780x22
    88                 RenderBlock {P} at (0,0) size 780x22
    89                   RenderText {#text} at (85,0) size 610x22
    90                     text run at (85,0) width 610: "Start browsing the topics below, or use the search field at the bottom of every page."
     45              RenderBlock {P} at (0,0) size 780x110
     46                RenderText {#text} at (0,0) size 71x22
     47                  text run at (0,0) width 71: "This is an"
     48                RenderText {#text} at (71,0) size 5x22
     49                  text run at (71,0) width 5: " "
     50                RenderInline {B} at (0,0) size 82x22
     51                  RenderText {#text} at (76,0) size 82x22
     52                    text run at (76,0) width 82: "interactive"
     53                RenderText {#text} at (158,0) size 5x22
     54                  text run at (158,0) width 5: " "
     55                RenderText {#text} at (163,0) size 617x44
     56                  text run at (163,0) width 617: "documentation site, so please help out by posting any useful information that you've "
     57                  text run at (325,22) width 129: "had to search out."
     58                RenderBR {BR} at (454,39) size 0x0
     59                RenderText {#text} at (20,44) size 110x22
     60                  text run at (20,44) width 110: "(Adding to this"
     61                RenderText {#text} at (130,44) size 5x22
     62                  text run at (130,44) width 5: " "
     63                RenderInline {A} at (0,0) size 107x22 [color=#0000EE]
     64                  RenderText {#text} at (135,44) size 107x22
     65                    text run at (135,44) width 107: "wiki is so easy"
     66                RenderText {#text} at (242,44) size 202x22
     67                  text run at (242,44) width 202: ", you can't screw it up). See"
     68                RenderText {#text} at (444,44) size 5x22
     69                  text run at (444,44) width 5: " "
     70                RenderInline {A} at (0,0) size 114x22 [color=#0000EE]
     71                  RenderText {#text} at (449,44) size 114x22
     72                    text run at (449,44) width 114: "Wiki Reference"
     73                RenderText {#text} at (563,44) size 5x22
     74                  text run at (563,44) width 5: " "
     75                RenderText {#text} at (568,44) size 191x22
     76                  text run at (568,44) width 191: "for text formatting syntax."
     77                RenderBR {BR} at (759,61) size 0x0
     78                RenderText {#text} at (161,66) size 278x22
     79                  text run at (161,66) width 278: "Info for setting up your own wiki is at"
     80                RenderText {#text} at (439,66) size 5x22
     81                  text run at (439,66) width 5: " "
     82                RenderInline {A} at (0,0) size 170x22 [color=#0000EE]
     83                  RenderText {#text} at (444,66) size 170x22
     84                    text run at (444,66) width 170: "about howto.apple.com"
     85                RenderText {#text} at (614,66) size 5x22
     86                  text run at (614,66) width 5: "."
     87                RenderBR {BR} at (619,83) size 0x0
     88                RenderText {#text} at (96,88) size 509x22
     89                  text run at (96,88) width 509: "Check out a cool wiki editor application that helps in wiki generation:"
     90                RenderText {#text} at (605,88) size 5x22
     91                  text run at (605,88) width 5: " "
     92                RenderInline {A} at (0,0) size 73x22 [color=#0000EE]
     93                  RenderText {#text} at (610,88) size 73x22
     94                    text run at (610,88) width 73: "Wikinator"
     95              RenderBlock {P} at (0,128) size 780x22
     96                RenderText {#text} at (85,0) size 610x22
     97                  text run at (85,0) width 610: "Start browsing the topics below, or use the search field at the bottom of every page."
    9198              RenderBlock (anonymous) at (0,168) size 780x0
    92                 RenderInline {SPAN} at (0,0) size 0x0
    93 caret: position 85 of child 0 {#text} of child 0 {P} of child 1 {SPAN} of child 1 {P} of child 1 {CENTER} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     99caret: position 85 of child 0 {#text} of child 1 {P} of child 1 {P} of child 1 {CENTER} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/display-block-on-spans-expected.txt

    r19605 r20075  
    55EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of #text > B > SPAN > DIV > BODY > HTML > #document to 4 of #text > B > SPAN > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    66EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    7 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 4 of #text > B > SPAN > B > SPAN > DIV > BODY > HTML > #document to 4 of #text > B > SPAN > B > SPAN > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     7EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 4 of #text > B > SPAN > DIV > BODY > HTML > #document to 4 of #text > B > SPAN > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    88EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    99EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    3535        RenderBlock {SPAN} at (0,18) size 784x18
    3636          RenderInline {B} at (0,0) size 182x18
    37             RenderInline {SPAN} at (0,0) size 30x18
    38               RenderInline {B} at (0,0) size 30x18
    39                 RenderText {#text} at (0,0) size 30x18
    40                   text run at (0,0) width 30: "This"
     37            RenderText {#text} at (0,0) size 30x18
     38              text run at (0,0) width 30: "This"
    4139            RenderText {#text} at (30,0) size 152x18
    4240              text run at (30,0) width 152: " is another paragraph."
    43 caret: position 4 of child 0 {#text} of child 0 {B} of child 0 {SPAN} of child 0 {B} of child 2 {SPAN} of child 5 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     41caret: position 4 of child 0 {#text} of child 0 {B} of child 2 {SPAN} of child 5 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-4035648-fix-expected.txt

    r19605 r20075  
    4747      RenderBlock {DIV} at (0,264) size 784x88
    4848        RenderBlock {DIV} at (0,0) size 784x88 [border: (2px solid #FF0000)]
    49           RenderInline {SPAN} at (0,0) size 0x18
    50             RenderBR {BR} at (2,2) size 0x28
    51           RenderInline {SPAN} at (0,0) size 45x18
    52             RenderInline {B} at (0,0) size 45x28
    53               RenderText {#text} at (2,30) size 45x28
    54                 text run at (2,30) width 45: "bold"
    55               RenderBR {BR} at (47,52) size 0x0
     49          RenderBR {BR} at (2,2) size 0x28
     50          RenderInline {B} at (0,0) size 45x28
     51            RenderText {#text} at (2,30) size 45x28
     52              text run at (2,30) width 45: "bold"
     53            RenderBR {BR} at (47,52) size 0x0
    5654          RenderText {#text} at (2,58) size 49x28
    5755            text run at (2,58) width 49: "plain"
  • trunk/LayoutTests/editing/pasteboard/paste-4039777-fix-expected.txt

    r19605 r20075  
    55EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of #text > LI > UL > DIV > DIV > BODY > HTML > #document to 5 of #text > LI > UL > DIV > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    66EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    7 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 1 of #text > LI > UL > DIV > SPAN > DIV > DIV > BODY > HTML > #document to 1 of #text > LI > UL > DIV > SPAN > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     7EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 1 of #text > LI > UL > DIV > DIV > DIV > BODY > HTML > #document to 1 of #text > LI > UL > DIV > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    88EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    99EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    5353      RenderBlock {DIV} at (0,364) size 784x188
    5454        RenderBlock {DIV} at (0,0) size 784x188 [border: (2px solid #FF0000)]
    55           RenderBlock (anonymous) at (2,2) size 780x0
    56             RenderInline {SPAN} at (0,0) size 0x0
    57           RenderBlock (anonymous) at (2,26) size 780x28
    58             RenderBlock {UL} at (0,0) size 780x28
    59               RenderListItem {LI} at (40,0) size 740x28
     55          RenderBlock {UL} at (2,26) size 780x28
     56            RenderListItem {LI} at (40,0) size 740x28
     57              RenderListMarker at (-22,0) size 9x28: bullet
     58              RenderText {#text} at (723,0) size 17x28
     59                text run at (723,0) width 17: "A"
     60          RenderBlock {DIV} at (2,78) size 780x56
     61            RenderBlock {UL} at (0,0) size 780x56
     62              RenderListItem {LI} at (40,0) size 740x56
    6063                RenderListMarker at (-22,0) size 9x28: bullet
    61                 RenderText {#text} at (723,0) size 17x28
    62                   text run at (723,0) width 17: "A"
    63           RenderBlock (anonymous) at (2,78) size 780x0
    64             RenderInline {SPAN} at (0,0) size 0x0
    65             RenderInline {SPAN} at (0,0) size 0x0
    66           RenderBlock (anonymous) at (2,78) size 780x56
    67             RenderBlock {DIV} at (0,0) size 780x56
    68               RenderBlock {UL} at (0,0) size 780x56
    69                 RenderListItem {LI} at (40,0) size 740x56
    70                   RenderListMarker at (-22,0) size 9x28: bullet
    71                   RenderInline {A} at (0,0) size 16x28 [color=#0000EE]
    72                     RenderText {#text} at (718,0) size 16x28
    73                       text run at (718,0) width 16: "B"
    74                   RenderText {#text} at (734,0) size 6x28
    75                     text run at (734,0) width 6: " "
    76                   RenderBR {BR} at (740,22) size 0x0
    77                   RenderText {#text} at (724,28) size 16x28
    78                     text run at (724,28) width 16: "C"
     64                RenderInline {A} at (0,0) size 16x28 [color=#0000EE]
     65                  RenderText {#text} at (718,0) size 16x28
     66                    text run at (718,0) width 16: "B"
     67                RenderText {#text} at (734,0) size 6x28
     68                  text run at (734,0) width 6: " "
     69                RenderBR {BR} at (740,22) size 0x0
     70                RenderText {#text} at (724,28) size 16x28
     71                  text run at (724,28) width 16: "C"
    7972          RenderBlock (anonymous) at (2,158) size 780x28
    80             RenderInline {SPAN} at (0,0) size 0x0
    8173            RenderBR {BR} at (780,0) size 0x28
    8274          RenderBlock {DIV} at (2,186) size 780x0
    83 caret: position 1 of child 3 {#text} of child 0 {LI} of child 0 {UL} of child 0 {DIV} of child 1 {SPAN} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     75caret: position 1 of child 3 {#text} of child 0 {LI} of child 0 {UL} of child 1 {DIV} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-line-endings-001-expected.txt

    r19605 r20075  
    1212EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 1 of DIV > DIV > BODY > HTML > #document to 2 of DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1313EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    14 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 1 of SPAN > DIV > DIV > BODY > HTML > #document to 1 of SPAN > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     14EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 2 of DIV > DIV > BODY > HTML > #document to 2 of DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1515EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1616EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    4444          RenderText {#text} at (2,2) size 78x28
    4545            text run at (2,2) width 78: "line one"
    46           RenderInline {SPAN} at (0,0) size 0x18
    47             RenderBR {BR} at (80,24) size 0x0
     46          RenderBR {BR} at (80,24) size 0x0
    4847          RenderText {#text} at (2,30) size 79x28
    4948            text run at (2,30) width 79: "line two"
  • trunk/LayoutTests/editing/pasteboard/paste-line-endings-006-expected.txt

    r19605 r20075  
    4646          RenderText {#text} at (2,2) size 78x28
    4747            text run at (2,2) width 78: "line one"
    48           RenderInline {SPAN} at (0,0) size 0x18
    49             RenderBR {BR} at (80,24) size 0x0
     48          RenderBR {BR} at (80,24) size 0x0
    5049          RenderText {#text} at (2,30) size 7x28
    5150            text run at (2,30) width 7: "l"
  • trunk/LayoutTests/editing/pasteboard/paste-list-001-expected.txt

    r19648 r20075  
    4545                RenderText {#text} at (0,0) size 211x28
    4646                  text run at (0,0) width 211: "I should be number 3."
    47             RenderBlock (anonymous) at (0,112) size 716x0
     47              RenderBlock (anonymous) at (40,84) size 676x0
    4848caret: position 21 of child 0 {#text} of child 2 {LI} of child 1 {OL} of child 5 {LI} of child 4 {OL} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-pre-001-expected.txt

    r19605 r20075  
    1010EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of PRE > DIV > DIV > BODY > HTML > #document to 0 of PRE > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1111EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    12 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 7 of #text > PRE > SPAN > PRE > DIV > DIV > BODY > HTML > #document to 7 of #text > PRE > SPAN > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     12EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 7 of #text > PRE > PRE > DIV > DIV > BODY > HTML > #document to 7 of #text > PRE > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1313EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1414EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    4747        RenderBlock {DIV} at (0,0) size 784x108 [border: (2px solid #FF0000)]
    4848          RenderBlock {PRE} at (2,26) size 780x56
    49             RenderBlock (anonymous) at (0,0) size 780x0
    50               RenderInline {SPAN} at (0,0) size 0x0
    51             RenderBlock (anonymous) at (0,0) size 780x56
    52               RenderBlock {PRE} at (0,0) size 780x56
    53                 RenderText {#text} at (0,0) size 42x56
    54                   text run at (0,0) width 42: "foo"
    55                   text run at (42,0) width 0: " "
    56                   text run at (0,28) width 42: "bar"
     49            RenderBlock {PRE} at (0,0) size 780x56
     50              RenderText {#text} at (0,0) size 42x56
     51                text run at (0,0) width 42: "foo"
     52                text run at (42,0) width 0: " "
     53                text run at (0,28) width 42: "bar"
    5754            RenderBlock (anonymous) at (0,80) size 780x0
    58               RenderInline {SPAN} at (0,0) size 0x0
    59 caret: position 7 of child 0 {#text} of child 0 {PRE} of child 0 {SPAN} of child 1 {PRE} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     55caret: position 7 of child 0 {#text} of child 0 {PRE} of child 1 {PRE} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-pre-002-expected.txt

    r19605 r20075  
    55EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of #text > PRE > DIV > DIV > BODY > HTML > #document to 7 of #text > PRE > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    66EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    7 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 7 of #text > PRE > SPAN > PRE > DIV > DIV > BODY > HTML > #document to 7 of #text > PRE > SPAN > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     7EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 7 of #text > PRE > PRE > DIV > DIV > BODY > HTML > #document to 7 of #text > PRE > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    88EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    99EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    2727        RenderBlock {DIV} at (0,0) size 784x30
    2828          RenderBlock {PRE} at (0,0) size 784x30
    29             RenderBlock (anonymous) at (0,0) size 784x0
    30               RenderInline {SPAN} at (0,0) size 0x0
    31             RenderBlock (anonymous) at (0,0) size 784x30
    32               RenderBlock {PRE} at (0,0) size 784x30
    33                 RenderText {#text} at (0,0) size 24x30
    34                   text run at (0,0) width 24: "foo"
    35                   text run at (24,0) width 0: " "
    36                   text run at (0,15) width 24: "bar"
     29            RenderBlock {PRE} at (0,0) size 784x30
     30              RenderText {#text} at (0,0) size 24x30
     31                text run at (0,0) width 24: "foo"
     32                text run at (24,0) width 0: " "
     33                text run at (0,15) width 24: "bar"
    3734            RenderBlock (anonymous) at (0,43) size 784x0
    38               RenderInline {SPAN} at (0,0) size 0x0
    39 caret: position 7 of child 0 {#text} of child 0 {PRE} of child 0 {SPAN} of child 1 {PRE} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     35caret: position 7 of child 0 {#text} of child 0 {PRE} of child 1 {PRE} of child 1 {DIV} of child 3 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-table-001-expected.txt

    r19648 r20075  
    6868                  RenderText {#text} at (2,2) size 197x18
    6969                    text run at (2,2) width 197: "I should be in the right column."
     70          RenderBlock (anonymous) at (0,54) size 756x0
    7071          RenderTable {TABLE} at (0,54) size 292x54 [border: (2px outset #808080)]
    7172            RenderTableSection {TBODY} at (2,2) size 288x50
     
    8283                  RenderText {#text} at (2,2) size 197x18
    8384                    text run at (2,2) width 197: "I should be in the right column."
    84           RenderBlock (anonymous) at (0,108) size 756x0
    8585caret: position 32 of child 0 {#text} of child 1 {TD} of child 1 {TR} of child 0 {TBODY} of child 2 {TABLE} of child 3 {P} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-table-002-expected.txt

    r19605 r20075  
    1010EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of DIV > DIV > DIV > BODY > HTML > #document to 0 of DIV > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1111EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    12 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 5 of #text > DIV > SPAN > DIV > DIV > DIV > BODY > HTML > #document to 5 of #text > DIV > SPAN > DIV > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     12EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 5 of #text > DIV > DIV > DIV > DIV > BODY > HTML > #document to 5 of #text > DIV > DIV > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1313EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1414EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    1717foo     bar
    1818ghijk
    19 <div id="test" class="editing"> <div>abcdef<span class="Apple-style-span" style="font-size: 16px; "><div style="font-size: 24px; text-align: center; "><table style="font-size: 16px; text-align: auto; -webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; "><tbody style=""><tr style=""><td style="">foo</td><td style="">bar</td></tr></tbody></table>ghijk</div></span> </div> </div>
     19<div id="test" class="editing" style="border-top-width: 2px; border-right-width: 2px; border-bottom-width: 2px; border-left-width: 2px; border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-top-color: red; border-right-color: red; border-bottom-color: red; border-left-color: red; font-size: 24px; "> <div>abcdef<div style="text-align: center; "><table><tbody><tr><td>foo</td><td>bar</td></tr></tbody></table>ghijk</div> </div> </div>
    2020
  • trunk/LayoutTests/editing/pasteboard/paste-text-003-expected.txt

    r19605 r20075  
    112112          RenderText {#text} at (63,0) size 285x28
    113113            text run at (63,0) width 285: "is a tide in the affairs of men,"
    114           RenderInline {SPAN} at (0,0) size 0x18
    115         RenderBlock (anonymous) at (14,42) size 756x56
    116           RenderBlock {DIV} at (0,0) size 756x56 [border: (2px solid #FF0000)]
    117             RenderText {#text} at (14,14) size 434x28
    118               text run at (14,14) width 434: "Which taken at the flood leads on to fortune."
     114        RenderBlock {DIV} at (14,42) size 756x56 [border: (2px solid #FF0000)]
     115          RenderText {#text} at (14,14) size 434x28
     116            text run at (14,14) width 434: "Which taken at the flood leads on to fortune."
    119117        RenderBlock (anonymous) at (14,98) size 756x0
    120           RenderInline {SPAN} at (0,0) size 0x0
    121118        RenderBlock {DIV} at (14,98) size 756x252 [border: (2px solid #FF0000)]
    122119          RenderBlock (anonymous) at (14,14) size 728x0
     
    127124              text run at (94,14) width 285: "is a tide in the affairs of men,"
    128125          RenderBlock (anonymous) at (14,70) size 728x0
    129             RenderInline {SPAN} at (0,0) size 0x0
    130           RenderBlock (anonymous) at (14,70) size 728x56
    131             RenderBlock {DIV} at (0,0) size 728x56 [border: (2px solid #FF0000)]
    132               RenderText {#text} at (14,14) size 434x28
    133                 text run at (14,14) width 434: "Which taken at the flood leads on to fortune."
     126          RenderBlock {DIV} at (14,70) size 728x56 [border: (2px solid #FF0000)]
     127            RenderText {#text} at (14,14) size 434x28
     128              text run at (14,14) width 434: "Which taken at the flood leads on to fortune."
    134129          RenderBlock (anonymous) at (14,126) size 728x0
    135             RenderInline {SPAN} at (0,0) size 0x0
    136130          RenderBlock {DIV} at (14,126) size 728x112 [border: (2px solid #FF0000)]
    137131            RenderBlock (anonymous) at (14,14) size 700x28
  • trunk/LayoutTests/editing/pasteboard/paste-text-011-expected.txt

    r19605 r20075  
    99EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of P > BODY > HTML > #document to 0 of P > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1010EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    11 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 5 of #text > B > FONT > P > DIV > SPAN > B > FONT > P > BODY > HTML > #document to 5 of #text > B > FONT > P > DIV > SPAN > B > FONT > P > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     11EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 5 of #text > B > FONT > P > DIV > B > FONT > P > BODY > HTML > #document to 5 of #text > B > FONT > P > DIV > B > FONT > P > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1212EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1313EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    3131          RenderInline {FONT} at (0,0) size 0x0
    3232            RenderInline {B} at (0,0) size 0x0
    33               RenderInline {SPAN} at (0,0) size 0x0
    3433        RenderBlock (anonymous) at (0,0) size 784x58
    3534          RenderBlock {DIV} at (0,0) size 784x58
     
    4443                  RenderText {#text} at (0,0) size 55x20
    4544                    text run at (0,0) width 55: "there"
     45            RenderBlock (anonymous) at (0,74) size 784x0
    4646        RenderBlock (anonymous) at (0,74) size 784x0
    4747          RenderInline {FONT} at (0,0) size 0x0
    4848            RenderInline {B} at (0,0) size 0x0
    49               RenderInline {SPAN} at (0,0) size 0x0
    50           RenderInline {FONT} at (0,0) size 0x0
    51             RenderInline {B} at (0,0) size 0x0
    52           RenderInline {FONT} at (0,0) size 0x0
    53             RenderInline {B} at (0,0) size 0x0
    54 caret: position 5 of child 0 {#text} of child 0 {B} of child 0 {FONT} of child 1 {P} of child 0 {DIV} of child 0 {SPAN} of child 0 {B} of child 0 {FONT} of child 4 {P} of child 1 {BODY} of child 0 {HTML} of document
     49caret: position 5 of child 0 {#text} of child 0 {B} of child 0 {FONT} of child 1 {P} of child 0 {DIV} of child 0 {B} of child 0 {FONT} of child 4 {P} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-text-015-expected.txt

    r19605 r20075  
    1616EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of P > DIV > DIV > BODY > HTML > #document to 0 of P > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    1717EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    18 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     18EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1919EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    2020EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
    21 EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document toDOMRange:range from 0 of P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document to 0 of P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     21EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 3 of #text > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document toDOMRange:range from 0 of P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document to 0 of P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    2222EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    2323EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
    24 EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document to 0 of P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
     24EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document to 0 of P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    2525EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    26 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > P > DIV > SPAN > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > DIV > SPAN > P > DIV > SPAN > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     26EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > P > SPAN > DIV > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document to 3 of #text > P > SPAN > DIV > P > SPAN > DIV > P > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    2727EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    2828EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    3535        RenderBlock {DIV} at (0,0) size 784x140 [border: (2px solid #FF0000)]
    3636          RenderBlock {P} at (14,14) size 756x112
    37             RenderBlock (anonymous) at (0,0) size 756x0
    38               RenderInline {SPAN} at (0,0) size 0x0
    39             RenderBlock (anonymous) at (0,0) size 756x112
    40               RenderBlock {DIV} at (0,0) size 756x112
     37            RenderBlock {DIV} at (0,0) size 756x112
     38              RenderBlock (anonymous) at (0,0) size 756x0
     39                RenderInline {SPAN} at (0,0) size 0x0
     40              RenderBlock (anonymous) at (0,0) size 756x112
    4141                RenderBlock {P} at (0,0) size 756x28
    4242                  RenderText {#text} at (0,0) size 32x28
     
    4646                    text run at (0,0) width 31: "bar"
    4747                RenderBlock {P} at (0,56) size 756x56
    48                   RenderBlock (anonymous) at (0,0) size 756x0
    49                     RenderInline {SPAN} at (0,0) size 0x0
    50                   RenderBlock (anonymous) at (0,0) size 756x56
    51                     RenderBlock {DIV} at (0,0) size 756x56
     48                  RenderBlock {DIV} at (0,0) size 756x56
     49                    RenderBlock (anonymous) at (0,0) size 756x0
     50                      RenderInline {SPAN} at (0,0) size 0x0
     51                    RenderBlock (anonymous) at (0,0) size 756x56
    5252                      RenderBlock {P} at (0,0) size 756x28
    5353                        RenderText {#text} at (0,0) size 32x28
     
    5656                        RenderText {#text} at (0,0) size 31x28
    5757                          text run at (0,0) width 31: "bar"
     58                    RenderBlock (anonymous) at (0,56) size 756x0
     59                      RenderInline {SPAN} at (0,0) size 0x0
    5860                  RenderBlock (anonymous) at (0,56) size 756x0
    59                     RenderInline {SPAN} at (0,0) size 0x0
     61              RenderBlock (anonymous) at (0,112) size 756x0
     62                RenderInline {SPAN} at (0,0) size 0x0
    6063            RenderBlock (anonymous) at (0,112) size 756x0
    61               RenderInline {SPAN} at (0,0) size 0x0
    62 caret: position 3 of child 0 {#text} of child 1 {P} of child 0 {DIV} of child 0 {SPAN} of child 2 {P} of child 0 {DIV} of child 0 {SPAN} of child 0 {P} of child 1 {DIV} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     64caret: position 3 of child 0 {#text} of child 1 {P} of child 0 {SPAN} of child 0 {DIV} of child 2 {P} of child 0 {SPAN} of child 0 {DIV} of child 0 {P} of child 1 {DIV} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/paste-text-016-expected.txt

    r19605 r20075  
    4444                text run at (0,0) width 319: "Should be first line of document."
    4545              RenderBR {BR} at (319,22) size 0x0
    46               RenderInline {SPAN} at (0,0) size 0x0
    47             RenderBlock (anonymous) at (0,28) size 756x28
    48               RenderBlock {P} at (0,0) size 756x28
    49                 RenderText {#text} at (0,0) size 130x28
    50                   text run at (0,0) width 130: "***TEST***"
     46            RenderBlock {P} at (0,28) size 756x28
     47              RenderText {#text} at (0,0) size 130x28
     48                text run at (0,0) width 130: "***TEST***"
    5149            RenderBlock (anonymous) at (0,56) size 756x56
    52               RenderInline {SPAN} at (0,0) size 0x0
    5350              RenderBR {BR} at (0,0) size 0x28
    5451              RenderText {#text} at (0,28) size 128x28
  • trunk/LayoutTests/editing/pasteboard/paste-text-017-expected.txt

    r19605 r20075  
    4141            RenderBR {BR} at (0,0) size 0x28
    4242          RenderBlock {DIV} at (2,58) size 780x56
    43             RenderBlock (anonymous) at (0,0) size 780x0
    44               RenderInline {SPAN} at (0,0) size 0x0
    45             RenderBlock (anonymous) at (0,0) size 780x28
    46               RenderBlock {DIV} at (0,0) size 780x28
    47                 RenderText {#text} at (0,0) size 36x28
    48                   text run at (0,0) width 36: "two"
     43            RenderBlock {DIV} at (0,0) size 780x28
     44              RenderText {#text} at (0,0) size 36x28
     45                text run at (0,0) width 36: "two"
    4946            RenderBlock (anonymous) at (0,28) size 780x28
    50               RenderInline {SPAN} at (0,0) size 0x0
    5147              RenderBR {BR} at (0,0) size 0x28
    5248          RenderBlock {DIV} at (2,114) size 780x28
  • trunk/LayoutTests/editing/pasteboard/styled-element-markup-expected.txt

    r19605 r20075  
    88EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    99EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    10 EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document toDOMRange:range from 1 of DIV > BODY > HTML > #document to 1 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     10EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document toDOMRange:range from 1 of SPAN > DIV > BODY > HTML > #document to 1 of SPAN > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    1111EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    1212EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    3030          RenderImage {IMG} at (354,0) size 76x103
    3131      RenderBlock {DIV} at (0,207) size 784x103
    32         RenderImage {IMG} at (0,0) size 76x103
    33 caret: position 1 of child 0 {IMG} of child 6 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     32        RenderInline {SPAN} at (0,0) size 76x14
     33          RenderImage {IMG} at (0,0) size 76x103
     34caret: position 1 of child 0 {IMG} of child 0 {SPAN} of child 6 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/pasteboard/testcase-9507-expected.txt

    r19605 r20075  
    33EDITING DELEGATE: shouldInsertNode:#document-fragment replacingDOMRange:range from 1 of #text > DIV > DIV > BODY > HTML > #document to 3 of #text > DIV > DIV > DIV > DIV > BODY > HTML > #document givenAction:WebViewInsertActionPasted
    44EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    5 EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > DIV > DIV > SPAN > DIV > DIV > BODY > HTML > #document to 3 of #text > DIV > DIV > SPAN > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
     5EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 3 of #text > DIV > DIV > DIV > DIV > BODY > HTML > #document to 3 of #text > DIV > DIV > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
    66EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
    77EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
     
    2020            RenderText {#text} at (0,0) size 32x28
    2121              text run at (0,0) width 32: "foo"
    22             RenderInline {SPAN} at (0,0) size 0x18
    23           RenderBlock (anonymous) at (2,30) size 780x28
    24             RenderBlock {DIV} at (0,0) size 780x28 [color=#FF0000]
    25               RenderBlock {DIV} at (0,0) size 780x28
    26                 RenderText {#text} at (0,0) size 31x28
    27                   text run at (0,0) width 31: "bar"
     22          RenderBlock {DIV} at (2,30) size 780x28 [color=#FF0000]
     23            RenderBlock {DIV} at (0,0) size 780x28
     24              RenderText {#text} at (0,0) size 31x28
     25                text run at (0,0) width 31: "bar"
    2826          RenderBlock (anonymous) at (2,58) size 780x0
    29             RenderInline {SPAN} at (0,0) size 0x0
    3027          RenderBlock {DIV} at (2,58) size 780x0 [color=#FF0000]
    31 caret: position 3 of child 0 {#text} of child 0 {DIV} of child 0 {DIV} of child 1 {SPAN} of child 1 {DIV} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
     28caret: position 3 of child 0 {#text} of child 0 {DIV} of child 1 {DIV} of child 1 {DIV} of child 1 {DIV} of child 1 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/editing/style/smoosh-styles-001-expected.txt

    r19605 r20075  
    5757              RenderText {#text} at (25,2) size 34x28
    5858                text run at (25,2) width 34: "cde"
    59               RenderInline {SPAN} at (0,0) size 20x18
    60                 RenderInline {SPAN} at (0,0) size 20x28 [color=#FF0000]
     59              RenderInline {SPAN} at (0,0) size 20x28 [color=#FF0000]
     60                RenderInline {SPAN} at (0,0) size 20x28
    6161                  RenderText {#text} at (59,2) size 20x28
    6262                    text run at (59,2) width 20: "fg"
  • trunk/LayoutTests/editing/style/smoosh-styles-002-expected.txt

    r19605 r20075  
    5656              RenderText {#text} at (31,2) size 46x37
    5757                text run at (31,2) width 46: "cde"
    58               RenderInline {SPAN} at (0,0) size 24x18
    59                 RenderInline {SPAN} at (0,0) size 24x28 [color=#FF0000]
     58              RenderInline {SPAN} at (0,0) size 24x37 [color=#FF0000]
     59                RenderInline {SPAN} at (0,0) size 24x28
    6060                  RenderText {#text} at (77,8) size 24x28
    6161                    text run at (77,8) width 24: "fg"
  • trunk/LayoutTests/fast/lists/drag-into-marker-expected.txt

    r18670 r20075  
    77        RenderListItem {LI} at (41,1) size 710x55
    88          RenderListMarker at (-36,0) size 16x55: black square
    9           RenderInline {SPAN} at (0,0) size 124x18
    10             RenderInline {SPAN} at (0,0) size 124x55
    11               RenderText {#text} at (0,0) size 124x55
    12                 text run at (0,0) width 124: "world "
     9          RenderInline {SPAN} at (0,0) size 124x55
     10            RenderText {#text} at (0,0) size 124x55
     11              text run at (0,0) width 124: "world "
    1312          RenderText {#text} at (124,0) size 95x55
    1413            text run at (124,0) width 95: "hello"
     
    2221          text run at (0,54) width 371: "this test drags a bit of text over the list marker and drops it. "
    2322          text run at (371,54) width 386: "It should be pasted into the list item, which is contenteditable."
    24 selection start: position 0 of child 0 {#text} of child 0 {SPAN} of child 0 {SPAN} of child 0 {LI} of child 1 {UL} of child 0 {BODY} of child 0 {HTML} of document
    25 selection end:   position 6 of child 0 {#text} of child 0 {SPAN} of child 0 {SPAN} of child 0 {LI} of child 1 {UL} of child 0 {BODY} of child 0 {HTML} of document
     23selection start: position 0 of child 0 {#text} of child 0 {SPAN} of child 0 {LI} of child 1 {UL} of child 0 {BODY} of child 0 {HTML} of document
     24selection end:   position 6 of child 0 {#text} of child 0 {SPAN} of child 0 {LI} of child 1 {UL} of child 0 {BODY} of child 0 {HTML} of document
  • trunk/LayoutTests/webarchive/test-duplicate-resources-expected.txt

    r20018 r20075  
    1212&lt;link rel="stylesheet" href="resources/test-style.css" type="text/css"&gt;
    1313&lt;/head&gt;&lt;body&gt;
    14 &lt;div&gt;
     14&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    1515  &lt;img src="resources/apple.gif"&gt;
    1616&lt;/div&gt;
    17 &lt;div&gt;
     17&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    1818  This is not a frameset.  This text should be red sans-serif.
    1919&lt;/div&gt;
    20 &lt;div&gt;
     20&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    2121  &lt;img src="resources/apple.gif"&gt;
    2222&lt;/div&gt;
     
    4343&lt;link rel="stylesheet" href="test-style.css" type="text/css"&gt;
    4444&lt;/head&gt;&lt;body&gt;
    45 &lt;div&gt;
     45&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    4646  &lt;img src="apple.gif"&gt;
    4747&lt;/div&gt;
    48 &lt;div&gt;
     48&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    4949  This is a subframe.  This text should be red sans-serif.
    5050&lt;/div&gt;
    51 &lt;div&gt;
     51&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    5252  &lt;img src="apple.gif"&gt;
    5353&lt;/div&gt;
  • trunk/LayoutTests/webarchive/test-frameset-expected.txt

    r20018 r20075  
    3030&lt;link rel="stylesheet" href="test-style.css" type="text/css"&gt;
    3131&lt;/head&gt;&lt;body&gt;
    32 &lt;div&gt;
     32&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    3333  &lt;img src="apple.gif"&gt;
    3434&lt;/div&gt;
    35 &lt;div&gt;
     35&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    3636  This is a subframe.  This text should be red sans-serif.
    3737&lt;/div&gt;
    38 &lt;div&gt;
     38&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    3939  &lt;img src="apple.gif"&gt;
    4040&lt;/div&gt;
  • trunk/LayoutTests/webarchive/test-link-href-expected.txt

    r20018 r20075  
    1313&lt;link rel="stylesheet" href="resources/test-style.css" type="text/css"&gt;
    1414&lt;/head&gt;&lt;body&gt;
    15 &lt;div&gt;
     15&lt;div style="font-family: Arial, Helvetica, sans-serif; color: red; "&gt;
    1616This text should be red sans-serif.
    1717&lt;/div&gt;
  • trunk/WebCore/ChangeLog

    r20074 r20075  
     12007-03-08  Justin Garcia  <justin.garcia@apple.com>
     2
     3        Reviewed by harrison
     4       
     5        <rdar://problem/4903193>
     6        On particular page, Copy is so slow it seems like a hang
     7       
     8        ~2x speedup copying:
     9        http://shakespeare.mit.edu/henryviii/full.html
     10        Also produces less bloated markup.
     11
     12        * editing/markup.cpp:
     13        (WebCore::startMarkup): Don't wrap text nodes in style spans.
     14        For Elements, don't inline styles inherited from ancestors.
     15        (WebCore::createMarkup): No longer necessary to find
     16        the root's default style and pass it to startMarkup.
     17        Add a wrapper span around the markup with the styles
     18        that all nodes in the markup inherit (the inheritable
     19        styles from the common ancestor container's computed style).
     20        Added a FIXME about unecessary markup for inline ancestors
     21        up to the commonAncestorBlock.
     22
    1232007-03-08  Darin Adler  <darin@apple.com>
    224
  • trunk/WebCore/WebCore.xcodeproj/project.pbxproj

    r20067 r20075  
    1119811198                        isa = PBXProject;
    1119911199                        buildConfigurationList = 149C284308902B11008A9EFC /* Build configuration list for PBXProject "WebCore" */;
    11200                         compatibilityVersion = "Xcode 2.4";
    1120111200                        hasScannedForEncodings = 1;
    1120211201                        knownRegions = (
     
    1121311212                        projectDirPath = "";
    1121411213                        projectRoot = "";
    11215                         shouldCheckCompatibility = 1;
    1121611214                        targets = (
    1121711215                                93F198A508245E59001E9ABC /* WebCore */,
  • trunk/WebCore/editing/markup.cpp

    r19951 r20075  
    154154}
    155155
    156 static DeprecatedString startMarkup(const Node *node, const Range *range, EAnnotateForInterchange annotate, CSSMutableStyleDeclaration *defaultStyle)
     156static DeprecatedString startMarkup(const Node *node, const Range *range, EAnnotateForInterchange annotate)
    157157{
    158158    bool documentIsHTML = node->document()->isHTMLDocument();
     
    169169            bool useRenderedText = annotate && !enclosingNodeWithTag(const_cast<Node*>(node), selectTag);
    170170            DeprecatedString markup = useRenderedText ? escapeTextForMarkup(renderedText(node, range), false) : escapeTextForMarkup(stringValueForRange(node, range).deprecatedString(), false);
    171             if (defaultStyle) {
    172                 Node *element = node->parentNode();
    173                 if (element) {
    174                     RefPtr<CSSComputedStyleDeclaration> computedStyle = Position(element, 0).computedStyle();
    175                     RefPtr<CSSMutableStyleDeclaration> style = computedStyle->copyInheritableProperties();
    176                     // Styles that Mail blockquotes contribute should only be placed on the Mail blockquote, to help
    177                     // us differentiate those styles from ones that the user has applied.  This helps us
    178                     // get the color of content pasted into blockquotes right.
    179                     removeEnclosingMailBlockquoteStyle(style.get(), const_cast<Node*>(node));
    180                    
    181                     defaultStyle->diff(style.get());
    182                     if (style->length() > 0) {
    183                         // FIXME: Handle case where style->cssText() has illegal characters in it, like "
    184                         DeprecatedString openTag = DeprecatedString("<span class=\"") + AppleStyleSpanClass + "\" style=\"" + style->cssText().deprecatedString() + "\">";
    185                         markup = openTag + markup + "</span>";
    186                     }
    187                 }           
    188             }
    189171            return annotate ? convertHTMLTextToInterchangeFormat(markup, static_cast<const Text*>(node)) : markup;
    190172        }
     
    209191            markup += el->nodeNamePreservingCase().deprecatedString();
    210192            String additionalStyle;
    211             if (defaultStyle && el->isHTMLElement() && !isMailBlockquote(node)) {
    212                 RefPtr<CSSComputedStyleDeclaration> computedStyle = Position(const_cast<Element*>(el), 0).computedStyle();
    213                 RefPtr<CSSMutableStyleDeclaration> style = computedStyle->copyInheritableProperties();
    214                 style->merge(styleFromMatchedRulesForElement(const_cast<Element*>(el)).get());
    215                
    216                 // Styles that Mail blockquotes contribute should only be placed on the Mail blockquote, to help
    217                 // us differentiate those styles from ones that the user has applied.  This helps us
    218                 // get the color of content pasted into blockquotes right.
    219                 removeEnclosingMailBlockquoteStyle(style.get(), const_cast<Node*>(node));
    220                
    221                 defaultStyle->diff(style.get());
    222                 if (style->length() > 0) {
    223                     CSSMutableStyleDeclaration *inlineStyleDecl = static_cast<const HTMLElement*>(el)->inlineStyleDecl();
    224                     if (inlineStyleDecl)
    225                         inlineStyleDecl->diff(style.get());
     193            if (el->isHTMLElement()) {
     194                RefPtr<CSSMutableStyleDeclaration> style = styleFromMatchedRulesForElement(const_cast<Element*>(el));
     195                if (style->length() > 0)
    226196                    additionalStyle = style->cssText();
    227                 }
    228197            }
    229198            NamedAttrMap *attrs = el->attributes();
     
    311280            if (nodes)
    312281                nodes->append(current);
    313             me += startMarkup(current, 0, DoNotAnnotateForInterchange, 0);
     282            me += startMarkup(current, 0, DoNotAnnotateForInterchange);
    314283        }
    315284        // print children
     
    385354    Node *lastClosed = 0;
    386355    Vector<Node*> ancestorsToClose;
    387 
    388     // Calculate the "default style" for this markup and put those styles
    389     // in a top level span instead of inlining them.
    390     Node* root = highestEditableRoot(range->startPosition());
    391     if (!root) {
    392         root = range->startPosition().node();
    393         while (root && !root->hasTagName(bodyTag))
    394             root = root->parentNode();
    395         if (!root)
    396             root = doc->documentElement();
    397     }
    398     Position pos(root, 0);
    399     RefPtr<CSSComputedStyleDeclaration> computedStyle = pos.computedStyle();
    400     RefPtr<CSSMutableStyleDeclaration> defaultStyle = computedStyle->copyInheritableProperties();
    401356   
    402357    Node* startNode = range->startNode();
     
    434389        // Add the node to the markup.
    435390        if (addMarkupForNode) {
    436             markups.append(startMarkup(n, range, annotate, defaultStyle.get()));
     391            markups.append(startMarkup(n, range, annotate));
    437392            if (nodes)
    438393                nodes->append(n);
     
    471426                        // or b) ancestors that we never encountered during a pre-order traversal starting at startNode:
    472427                        ASSERT(startNode->isDescendantOf(parent));
    473                         markups.prepend(startMarkup(parent, range, annotate, defaultStyle.get()));
     428                        markups.prepend(startMarkup(parent, range, annotate));
    474429                        markups.append(endMarkup(parent));
    475430                        if (nodes)
     
    488443    ASSERT(ec == 0);
    489444   
     445    // Add a wrapper span with the styles that all of the nodes in the markup inherit.
     446    if (!commonAncestor->isElementNode())
     447        commonAncestor = commonAncestor->parentNode();
     448   
     449    if (commonAncestor) {
     450        RefPtr<CSSComputedStyleDeclaration> computedStyle = new CSSComputedStyleDeclaration(commonAncestor);
     451        RefPtr<CSSMutableStyleDeclaration> style = computedStyle->copyInheritableProperties();
     452        // Styles that Mail blockquotes contribute should only be placed on the Mail blockquote, to help
     453        // us differentiate those styles from ones that the user has applied.  This helps us
     454        // get the color of content pasted into blockquotes right.
     455        removeEnclosingMailBlockquoteStyle(style.get(), commonAncestor);
     456       
     457        if (style->length() > 0) {
     458            // FIXME: Handle case where style->cssText() has illegal characters in it, like "
     459            DeprecatedString openTag = DeprecatedString("<span class=\"") + AppleStyleSpanClass + "\" style=\"" + style->cssText().deprecatedString() + "\">";
     460            markups.prepend(openTag);
     461            markups.append("</span>");
     462        }
     463    }
     464   
    490465    // Add ancestors up to the common ancestor block so inline ancestors such as FONT and B are part of the markup.
     466    // FIXME: This seems unecessary.
    491467    if (lastClosed) {
    492468        for (Node *ancestor = lastClosed->parentNode(); ancestor; ancestor = ancestor->parentNode()) {
     
    509485                    break;
    510486            }
    511             markups.prepend(startMarkup(ancestor, range, annotate, defaultStyle.get()));
     487            markups.prepend(startMarkup(ancestor, range, annotate));
    512488            markups.append(endMarkup(ancestor));
    513489            if (nodes) {
     
    529505        for (Node *ancestor = commonAncestorBlock; ancestor; ancestor = ancestor->parentNode()) {
    530506            if (isMailBlockquote(ancestor)) {
    531                 markups.prepend(startMarkup(ancestor, range, annotate, defaultStyle.get()));
     507                markups.prepend(startMarkup(ancestor, range, annotate));
    532508                markups.append(endMarkup(ancestor));
    533509            }
     
    535511    }
    536512   
    537     root = range->startPosition().node();
     513    Node* root = range->startPosition().node();
    538514    while (root && !root->hasTagName(bodyTag))
    539515        root = root->parentNode();
     
    555531        style->merge(inheritedComputedProperties.get());
    556532       
    557         // Pull off default styles because those will be added via the top level style span.
    558         defaultStyle->diff(style.get());
    559        
    560533        // Bring the background attribute over, but not as an attribute because a background attribute on a div
    561534        // appears to have no effect.
     
    566539        markups.append("</div>");
    567540    }
    568    
    569     // add in the "default style" for this markup
    570     // FIXME: Handle case where value has illegal characters in it, like "
    571     DeprecatedString openTag = DeprecatedString("<span class=\"") + AppleStyleSpanClass + "\" style=\"" + defaultStyle->cssText().deprecatedString() + "\">";
    572     markups.prepend(openTag);
    573     markups.append("</span>");
    574541
    575542    doc->frame()->editor()->deleteButtonController()->enable();
Note: See TracChangeset for help on using the changeset viewer.