Reviewed by Dave
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Apr 2004 14:13:42 +0000 (14:13 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Apr 2004 14:13:42 +0000 (14:13 +0000)
commitd4a17d8a6fce6232fa663c319366faa7ff416a90
treeaefd4040a9fc5649225d2f9ccf2c98e40ee44431
parentc8dbd473a548934f25d93fd1ada01566a38c1b29
    Reviewed by Dave

        Small collection of editing improvements.

        * ChangeLog:
        * khtml/editing/htmlediting_impl.cpp:
        (shouldDeleteUpstreamPosition): This was deleting significant spaces on preceding
        lines when the caret was at the start of a line. Fixed.
        (DeleteSelectionCommandImpl::doApply): Fixed a case where caret jumped to previous
        line when deleting a character at the start of a line after a BR.
        (InputNewlineCommandImpl::doApply): Handle more cases correctly. Previously, this
        only handled inserting a newline when the caret was already in a text node.
        (InputTextCommandImpl::prepareForTextInsertion): Ditto.
        (InputTextCommandImpl::execute): Ditto.
        * khtml/editing/htmlediting_impl.h:
        * khtml/rendering/render_block.cpp:
        (khtml::RenderBlock::checkSelectionPointIgnoringContinuations): Now can place caret
        with a click in an empty block.
        * khtml/rendering/render_block.h: Added checkSelectionPointIgnoringContinuations declaration.
        * khtml/rendering/render_replaced.cpp:
        (RenderReplaced::checkSelectionPointIgnoringContinuations): Now can place caret with a click
        on a replaced element.
        * khtml/rendering/render_replaced.h: Added checkSelectionPointIgnoringContinuations declaration.
        * khtml/rendering/render_text.cpp:
        (InlineTextBox::checkSelectionPoint): Now can place caret with a click in text on a line made "tall"
        by an image on the same line.
        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::createEditingTextNode): This creates a text node subclass that whill always create
        a renderer for itself.
        * khtml/xml/dom_docimpl.h:
        * khtml/xml/dom_position.cpp:
        (DOMPosition::isLastRenderedPositionInEditableBlock): Improved code to handle more cases.
        * khtml/xml/dom_textimpl.cpp:
        (TextImpl::TextImpl): Rolled out m_rendererIsNeeded flag.
        (TextImpl::rendererIsNeeded): Ditto.
        (EditingTextImpl::EditingTextImpl): New class.
        (EditingTextImpl::~EditingTextImpl): New.
        (EditingTextImpl::rendererIsNeeded): New. Always returns true.
        * khtml/xml/dom_textimpl.h: New EditingTextImpl class.
        * layout-tests/editing/deleting/delete-3608430-fix-expected.txt: Added.
        * layout-tests/editing/deleting/delete-3608430-fix.html: Added.
        * layout-tests/editing/deleting/delete-3608462-fix-expected.txt: Added.
        * layout-tests/editing/deleting/delete-3608462-fix.html: Added.
        * layout-tests/editing/deleting/delete-trailing-ws-002-expected.txt: Added.
        * layout-tests/editing/deleting/delete-trailing-ws-002.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6341 268f45cc-cd09-0410-ab3c-d52691b4dbfc
19 files changed:
LayoutTests/editing/deleting/delete-3608430-fix-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-3608430-fix.html [new file with mode: 0644]
LayoutTests/editing/deleting/delete-3608462-fix-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-3608462-fix.html [new file with mode: 0644]
LayoutTests/editing/deleting/delete-trailing-ws-002-expected.txt [new file with mode: 0644]
LayoutTests/editing/deleting/delete-trailing-ws-002.html [new file with mode: 0644]
WebCore/ChangeLog-2005-08-23
WebCore/khtml/editing/htmlediting_impl.cpp
WebCore/khtml/editing/htmlediting_impl.h
WebCore/khtml/rendering/render_block.cpp
WebCore/khtml/rendering/render_block.h
WebCore/khtml/rendering/render_replaced.cpp
WebCore/khtml/rendering/render_replaced.h
WebCore/khtml/rendering/render_text.cpp
WebCore/khtml/xml/dom_docimpl.cpp
WebCore/khtml/xml/dom_docimpl.h
WebCore/khtml/xml/dom_position.cpp
WebCore/khtml/xml/dom_textimpl.cpp
WebCore/khtml/xml/dom_textimpl.h