Reviewed by John
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 1 Mar 2005 17:48:57 +0000 (17:48 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 1 Mar 2005 17:48:57 +0000 (17:48 +0000)
commit7aa128cc98a73992f28ba2c61b37cf6deea61895
treea06373d53e858aa1ed1cffd679188b7d5632d2d8
parentf39e0816c51bc2f9426d381d9862263e0d102773
    Reviewed by John

        Fix for this bug:

        <rdar://problem/3996605> Insert paragraph command puts new block in wrong place, creating difficult-to-handle HTML

        * khtml/editing/htmlediting.cpp:
        (khtml::InsertParagraphSeparatorCommand::doApply): Look for the upstream-most block to insert after
        when at the visible end of a block. This helps to avoid some undesirable sequences of markup which
        Dave says will be vary hard to render. Changing the command in this way avoids the "limitations"
        of the render tree by not asking it to render markup we do not want to make anyway.

        All these tests change, but either in insignificant ways, or for the better.

        * layout-tests/editing/deleting/delete-3959464-fix-expected.txt:
        * layout-tests/editing/inserting/insert-div-001-expected.txt:
        * layout-tests/editing/inserting/insert-div-002-expected.txt:
        * layout-tests/editing/inserting/insert-div-004-expected.txt:
        * layout-tests/editing/inserting/insert-div-005-expected.txt:
        * layout-tests/editing/inserting/insert-div-009-expected.txt:
        * layout-tests/editing/inserting/insert-div-024-expected.txt:
        * layout-tests/editing/pasteboard/paste-text-011-expected.txt:
        * layout-tests/editing/pasteboard/paste-text-013-expected.txt:
        * layout-tests/editing/pasteboard/paste-text-015-expected.txt:
        * layout-tests/editing/style/block-style-004-expected.txt:
        * layout-tests/editing/style/block-style-005-expected.txt:
        * layout-tests/editing/style/block-style-006-expected.txt:
        * layout-tests/editing/style/remove-underline-across-paragraph-expected.txt:
        * layout-tests/editing/style/remove-underline-across-paragraph-in-bold-expected.txt:
        * layout-tests/editing/style/remove-underline-after-paragraph-expected.txt:
        * layout-tests/editing/style/remove-underline-after-paragraph-in-bold-expected.txt:

        New test to check specific problem mentioned in the bug.

        * layout-tests/editing/inserting/insert-div-026-expected.txt: Added.
        * layout-tests/editing/inserting/insert-div-026.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@8725 268f45cc-cd09-0410-ab3c-d52691b4dbfc
21 files changed:
LayoutTests/editing/deleting/delete-3959464-fix-expected.txt
LayoutTests/editing/inserting/insert-div-001-expected.txt
LayoutTests/editing/inserting/insert-div-002-expected.txt
LayoutTests/editing/inserting/insert-div-004-expected.txt
LayoutTests/editing/inserting/insert-div-005-expected.txt
LayoutTests/editing/inserting/insert-div-009-expected.txt
LayoutTests/editing/inserting/insert-div-024-expected.txt
LayoutTests/editing/inserting/insert-div-026-expected.txt [new file with mode: 0644]
LayoutTests/editing/inserting/insert-div-026.html [new file with mode: 0644]
LayoutTests/editing/pasteboard/paste-text-011-expected.txt
LayoutTests/editing/pasteboard/paste-text-013-expected.txt
LayoutTests/editing/pasteboard/paste-text-015-expected.txt
LayoutTests/editing/style/block-style-004-expected.txt
LayoutTests/editing/style/block-style-005-expected.txt
LayoutTests/editing/style/block-style-006-expected.txt
LayoutTests/editing/style/remove-underline-across-paragraph-expected.txt
LayoutTests/editing/style/remove-underline-across-paragraph-in-bold-expected.txt
LayoutTests/editing/style/remove-underline-after-paragraph-expected.txt
LayoutTests/editing/style/remove-underline-after-paragraph-in-bold-expected.txt
WebCore/ChangeLog-2005-08-23
WebCore/khtml/editing/htmlediting.cpp