1. 03 Jan, 2006 1 commit
    • eseidel's avatar
      Bug #: 6109 · ef508986
      eseidel authored
      Submitted by: eseidel
      Reviewed by: darin
              No functionality changes, no tests possible.
      
              khtml/editing should use RefPtr instead of manual ref/deref
              http://bugzilla.opendarwin.org/show_bug.cgi?id=6109
      
              Results in a slight performance gain < 1% on the PLT.
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::toRange):
              * khtml/editing/SelectionController.h:
              * khtml/editing/append_node_command.cpp:
              (khtml::AppendNodeCommand::AppendNodeCommand):
              (khtml::AppendNodeCommand::doApply):
              (khtml::AppendNodeCommand::doUnapply):
              * khtml/editing/append_node_command.h:
              (khtml::AppendNodeCommand::~AppendNodeCommand):
              (khtml::AppendNodeCommand::appendChild):
              (khtml::AppendNodeCommand::parentNode):
              * khtml/editing/apply_style_command.cpp:
              (khtml::StyleChange::init):
              (khtml::ApplyStyleCommand::removeInlineStyle):
              * khtml/editing/apply_style_command.h:
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::deleteInsignificantText):
              * khtml/editing/delete_from_text_node_command.cpp:
              (khtml::DeleteFromTextNodeCommand::DeleteFromTextNodeCommand):
              * khtml/editing/delete_from_text_node_command.h:
              (khtml::DeleteFromTextNodeCommand::~DeleteFromTextNodeCommand):
              (khtml::DeleteFromTextNodeCommand::node):
              * khtml/editing/delete_selection_command.cpp:
              (khtml::DeleteSelectionCommand::initializePositionData):
              (khtml::DeleteSelectionCommand::saveTypingStyleState):
              (khtml::DeleteSelectionCommand::handleGeneralDelete):
              (khtml::DeleteSelectionCommand::calculateEndingPosition):
              (khtml::DeleteSelectionCommand::calculateTypingStyleAfterDelete):
              (khtml::DeleteSelectionCommand::clearTransientState):
              * khtml/editing/delete_selection_command.h:
              * khtml/editing/edit_command.cpp:
              (khtml::EditCommand::EditCommand):
              (khtml::EditCommand::~EditCommand):
              (khtml::EditCommand::setTypingStyle):
              (khtml::EditCommand::styleAtPosition):
              * khtml/editing/edit_command.h:
              (khtml::EditCommand::document):
              (khtml::EditCommand::typingStyle):
              * khtml/editing/insert_into_text_node_command.cpp:
              (khtml::InsertIntoTextNodeCommand::InsertIntoTextNodeCommand):
              * khtml/editing/insert_into_text_node_command.h:
              (khtml::InsertIntoTextNodeCommand::~InsertIntoTextNodeCommand):
              (khtml::InsertIntoTextNodeCommand::node):
              * khtml/editing/insert_node_before_command.cpp:
              (khtml::InsertNodeBeforeCommand::InsertNodeBeforeCommand):
              (khtml::InsertNodeBeforeCommand::doApply):
              (khtml::InsertNodeBeforeCommand::doUnapply):
              * khtml/editing/insert_node_before_command.h:
              (khtml::InsertNodeBeforeCommand::~InsertNodeBeforeCommand):
              (khtml::InsertNodeBeforeCommand::insertChild):
              (khtml::InsertNodeBeforeCommand::refChild):
              * khtml/editing/insert_paragraph_separator_command.cpp:
              (khtml::InsertParagraphSeparatorCommand::InsertParagraphSeparatorCommand):
              (khtml::InsertParagraphSeparatorCommand::~InsertParagraphSeparatorCommand):
              (khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion):
              (khtml::InsertParagraphSeparatorCommand::applyStyleAfterInsertion):
              * khtml/editing/insert_paragraph_separator_command.h:
              * khtml/editing/join_text_nodes_command.cpp:
              (khtml::JoinTextNodesCommand::JoinTextNodesCommand):
              (khtml::JoinTextNodesCommand::doApply):
              (khtml::JoinTextNodesCommand::doUnapply):
              * khtml/editing/join_text_nodes_command.h:
              (khtml::JoinTextNodesCommand::~JoinTextNodesCommand):
              (khtml::JoinTextNodesCommand::firstNode):
              (khtml::JoinTextNodesCommand::secondNode):
              * khtml/editing/jsediting.cpp:
              * khtml/editing/markup.cpp:
              (khtml::createMarkup):
              (khtml::createFragmentFromMarkup):
              (khtml::createFragmentFromText):
              (khtml::createFragmentFromNodeList):
              * khtml/editing/markup.h:
              * khtml/editing/merge_identical_elements_command.cpp:
              (khtml::MergeIdenticalElementsCommand::MergeIdenticalElementsCommand):
              (khtml::MergeIdenticalElementsCommand::doApply):
              (khtml::MergeIdenticalElementsCommand::doUnapply):
              * khtml/editing/merge_identical_elements_command.h:
              (khtml::MergeIdenticalElementsCommand::~MergeIdenticalElementsCommand):
              * khtml/editing/move_selection_command.cpp:
              (khtml::MoveSelectionCommand::MoveSelectionCommand):
              (khtml::MoveSelectionCommand::~MoveSelectionCommand):
              (khtml::MoveSelectionCommand::doApply):
              * khtml/editing/move_selection_command.h:
              * khtml/editing/rebalance_whitespace_command.cpp:
              * khtml/editing/rebalance_whitespace_command.h:
              (khtml::RebalanceWhitespaceCommand::~RebalanceWhitespaceCommand):
              * khtml/editing/remove_css_property_command.cpp:
              (khtml::RemoveCSSPropertyCommand::RemoveCSSPropertyCommand):
              * khtml/editing/remove_css_property_command.h:
              (khtml::RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand):
              (khtml::RemoveCSSPropertyCommand::styleDeclaration):
              * khtml/editing/remove_node_attribute_command.cpp:
              (khtml::RemoveNodeAttributeCommand::RemoveNodeAttributeCommand):
              * khtml/editing/remove_node_attribute_command.h:
              (khtml::RemoveNodeAttributeCommand::~RemoveNodeAttributeCommand):
              (khtml::RemoveNodeAttributeCommand::element):
              * khtml/editing/remove_node_command.cpp:
              (khtml::RemoveNodeCommand::RemoveNodeCommand):
              (khtml::RemoveNodeCommand::doApply):
              (khtml::RemoveNodeCommand::doUnapply):
              * khtml/editing/remove_node_command.h:
              (khtml::RemoveNodeCommand::~RemoveNodeCommand):
              (khtml::RemoveNodeCommand::node):
              * khtml/editing/remove_node_preserving_children_command.cpp:
              (khtml::RemoveNodePreservingChildrenCommand::RemoveNodePreservingChildrenCommand):
              * khtml/editing/remove_node_preserving_children_command.h:
              (khtml::RemoveNodePreservingChildrenCommand::~RemoveNodePreservingChildrenCommand):
              (khtml::RemoveNodePreservingChildrenCommand::node):
              * khtml/editing/replace_selection_command.cpp:
              (khtml::ReplacementFragment::ReplacementFragment):
              (khtml::ReplacementFragment::~ReplacementFragment):
              (khtml::ReplacementFragment::enclosingBlock):
              (khtml::ReplacementFragment::removeNodePreservingChildren):
              (khtml::ReplacementFragment::removeNode):
              (khtml::ReplacementFragment::insertFragmentForTestRendering):
              (khtml::ReplacementFragment::restoreTestRenderingNodesToFragment):
              (khtml::ReplaceSelectionCommand::fixupNodeStyles):
              (khtml::computeAndStoreNodeDesiredStyle):
              (khtml::NodeDesiredStyle::NodeDesiredStyle):
              (khtml::ReplaceSelectionCommand::ReplaceSelectionCommand):
              (khtml::ReplaceSelectionCommand::~ReplaceSelectionCommand):
              (khtml::ReplaceSelectionCommand::doApply):
              (khtml::ReplaceSelectionCommand::completeHTMLReplacement):
              (khtml::ReplaceSelectionCommand::updateNodesInserted):
              * khtml/editing/replace_selection_command.h:
              (khtml::NodeDesiredStyle::node):
              (khtml::NodeDesiredStyle::style):
              (khtml::ReplacementFragment::root):
              * khtml/editing/set_node_attribute_command.cpp:
              (khtml::SetNodeAttributeCommand::SetNodeAttributeCommand):
              * khtml/editing/set_node_attribute_command.h:
              (khtml::SetNodeAttributeCommand::~SetNodeAttributeCommand):
              (khtml::SetNodeAttributeCommand::element):
              * khtml/editing/split_element_command.cpp:
              (khtml::SplitElementCommand::SplitElementCommand):
              (khtml::SplitElementCommand::doApply):
              (khtml::SplitElementCommand::doUnapply):
              * khtml/editing/split_element_command.h:
              (khtml::SplitElementCommand::~SplitElementCommand):
              * khtml/editing/split_text_node_command.cpp:
              (khtml::SplitTextNodeCommand::SplitTextNodeCommand):
              (khtml::SplitTextNodeCommand::doApply):
              (khtml::SplitTextNodeCommand::doUnapply):
              * khtml/editing/split_text_node_command.h:
              (khtml::SplitTextNodeCommand::~SplitTextNodeCommand):
              (khtml::SplitTextNodeCommand::node):
              * khtml/editing/split_text_node_containing_element.cpp:
              (khtml::SplitTextNodeContainingElementCommand::SplitTextNodeContainingElementCommand):
              (khtml::SplitTextNodeContainingElementCommand::doApply):
              * khtml/editing/split_text_node_containing_element_command.h:
              (khtml::SplitTextNodeContainingElementCommand::~SplitTextNodeContainingElementCommand):
              * khtml/editing/visible_position.cpp:
              (khtml::makeRange):
              * khtml/editing/visible_position.h:
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::range):
              (khtml::SimplifiedBackwardsTextIterator::range):
              (khtml::CharacterIterator::range):
              (khtml::findPlainText):
              * khtml/editing/visible_text.h:
              (khtml::WordAwareIterator::range):
              * khtml/editing/wrap_contents_in_dummy_span_command.cpp:
              (khtml::WrapContentsInDummySpanCommand::WrapContentsInDummySpanCommand):
              (khtml::WrapContentsInDummySpanCommand::doApply):
              (khtml::WrapContentsInDummySpanCommand::doUnapply):
              * khtml/editing/wrap_contents_in_dummy_span_command.h:
              (khtml::WrapContentsInDummySpanCommand::~WrapContentsInDummySpanCommand):
              * kwq/DOMHTML.mm:
              (-[DOMHTMLDocument _createDocumentFragmentWithMarkupString:baseURLString:]):
              (-[DOMHTMLDocument _createDocumentFragmentWithText:]):
              * kwq/WebCoreBridge.mm:
              (-[WebCoreBridge documentFragmentWithMarkupString:baseURLString:]):
              (-[WebCoreBridge documentFragmentWithText:]):
              (-[WebCoreBridge documentFragmentWithNodesAsParagraphs:]):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11854 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ef508986
  2. 30 Dec, 2005 3 commits
    • darin's avatar
      Reviewed by Maciej. · 7baeccde
      darin authored
              - http://bugzilla.opendarwin.org/show_bug.cgi?id=4557
                rename unusual strcmp and strcasecmp for DOMString family
      
              Added new functions named equal and equalIgnoringCase.
      
              * khtml/xml/dom_stringimpl.h: Changed the type of the length parameter to computeHash to unsigned
              to match the rest of the interface. Added equal and equalIgnoringCase functions. Added a
              version of the hash function that works on char* to CaseInsensitiveHash as preparation for an
              atomic string change.
              * khtml/xml/dom_stringimpl.cpp: Moved the QT_ALLOC_QCHAR_VEC and QT_DELETE_QCHAR_VEC macros
              here, and changed them into inline functions.
              (DOM::equal): Implemented.
              (DOM::equalIgnoringCase): Implemented.
              (DOM::DOMStringImpl::computeHash): Changed parameter type to unsigned to match other similar
              functions.
      
              * khtml/dom/dom_string.h: Removed unnecessary friend declarations. Changed operator
              overloads for == and != to call through inline to DOMStringImpl. Replaced strcasecmp
              with equalIgnoringCase, overloaded for one more combination of parameters. Removed strcmp.
              * khtml/dom/dom_string.cpp: Removed functions that are now implemented in DOMStringImpl*.
      
              * khtml/xml/dom_atomicstring.h: Removed a redundant const. Removed unnecessary
              friend declarations. Removed AtomicString::equal. Filled out a larger set of == and
              != operator implementations, mostly with inlines calling through to DOMStringImpl.
              Renamed equalsIgnoreCase to equalIgnoringCase and filled out a larger set as above.
              * khtml/xml/dom_atomicstring.cpp: Renamed AtomicString::equal to just ==.
              Removed some implementation of == and equalsIgnoreCase that are replaced by inlines.
      
              * khtml/html/html_listimpl.cpp:
              (DOM::HTMLOListElementImpl::parseMappedAttribute):
              (DOM::HTMLLIElementImpl::parseMappedAttribute):
              Use the "==" operator instead of strcmp.
      
              * khtml/css/cssstyleselector.cpp: (khtml::CSSStyleSelector::checkOneSelector):
              Use equalIgnoringCase instead of equalsIgnoreCase.
      
              * khtml/rendering/render_form.cpp:
              (RenderSlider::updateFromElement): Fixed bug where a temporary DOMString was put into
              a const DOMString&. Changed some DOMString to AtomicString as appropriate, and also
              used equalIgnoringCase instead of strcasecmp.
              (RenderSlider::slotSliderValueChanged): More of the same.
      
              * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv): Replaced use of strcasecmp
              with equalIgnoringCase. Added parentheses to fix incorrect operator precedence in one case
              (&& binds tighter than ||) which fixes a crash when using a http-equiv pragma when there
              is no part (not sure how to reproduce that).
      
              * khtml/khtml_part.cpp:
              (updateState):
              (KHTMLPart::selectionStartHasStyle):
              * khtml/ecma/kjs_html.cpp: (KJS::KJS::HTMLDocument::putValueProperty):
              * khtml/editing/apply_style_command.cpp:
              (khtml::StyleChange::checkForLegacyHTMLStyleChange):
              (khtml::StyleChange::currentlyHasStyle):
              (khtml::hasTextDecorationProperty):
              (khtml::ApplyStyleCommand::extractTextDecorationStyle):
              (khtml::ApplyStyleCommand::extractAndNegateTextDecorationStyle):
              * khtml/html/html_baseimpl.cpp:
              (HTMLBodyElementImpl::parseMappedAttribute):
              (HTMLFrameElementImpl::parseMappedAttribute):
              * khtml/html/html_blockimpl.cpp:
              (HTMLDivElementImpl::parseMappedAttribute):
              (HTMLHRElementImpl::parseMappedAttribute):
              (HTMLParagraphElementImpl::parseMappedAttribute):
              (HTMLMarqueeElementImpl::parseMappedAttribute):
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::parseMappedAttribute):
              (HTMLElementImpl::addHTMLAlignment):
              (HTMLElementImpl::setContentEditable):
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::parseMappedAttribute):
              (DOM::HTMLButtonElementImpl::parseMappedAttribute):
              (DOM::HTMLInputElementImpl::setInputType):
              (DOM::HTMLInputElementImpl::parseMappedAttribute):
              (DOM::HTMLKeygenElementImpl::appendFormData):
              (DOM::HTMLTextAreaElementImpl::parseMappedAttribute):
              * khtml/html/html_imageimpl.cpp: (DOM::HTMLAreaElementImpl::parseMappedAttribute):
              * khtml/html/html_inlineimpl.cpp: (DOM::HTMLBRElementImpl::parseMappedAttribute):
              * khtml/html/html_tableimpl.cpp: (DOM::HTMLTablePartElementImpl::parseMappedAttribute):
              * khtml/html/htmlparser.cpp: (HTMLParser::handleError):
              Use equalIgnoringCase instead of strcasecmp.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11847 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7baeccde
    • ap's avatar
      - Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6289 · 9bbc4e38
      ap authored
              REGRESSION: firstCharacterForRange(0, 0) returns a 0x0 rect
      
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::rangeFromLocationAndLength):
              Only special-case (0, 0) ranges for empty documents.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11845 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      9bbc4e38
    • andersca's avatar
      2005-12-30 Anders Carlsson <andersca@mac.com> · e1be1a16
      andersca authored
              Reviewed by Eric.
      
      		- Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6297
      		XMLSerializer should use createMarkup.
      
              * khtml/ecma/xmlserializer.cpp:
              (KJS::XMLSerializerProtoFunc::callAsFunction):
      		Use createMarkup instead of NodeImpl::toString.
      
              * khtml/editing/markup.cpp:
              (khtml::startMarkup):
      		escape attribute values and ignore document fragment nodes.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11839 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e1be1a16
  3. 28 Dec, 2005 1 commit
  4. 23 Dec, 2005 1 commit
    • eseidel's avatar
      Bug #: 6138 · c644a61a
      eseidel authored
      Submitted by: eseidel
      Reviewed by: mjs
              Remove many use of .qstring()
              Convert several instances of QStrings to DOMStrings
              Add DOMString::replace(QChar, QChar)
              Remove (unused) KWQLabel, KWQKGlobal
              Slight performance improvement.
              Also fixed ChangeLog line endings from previous commit.
              http://bugzilla.opendarwin.org/show_bug.cgi?id=6138
      
              No tests needed, no functionality changes.
      
              * ChangeLog: Fixed line endings
              * ForwardingHeaders/kglobal.h: Removed.
              * ForwardingHeaders/qlabel.h: Removed.
              * WebCore.xcodeproj/project.pbxproj: removed KWQLabel
              * khtml/css/css_base.cpp:
              (CSSSelector::selectorText):
              * khtml/css/css_stylesheetimpl.cpp:
              (MediaListImpl::setMediaText):
              * khtml/css/cssstyleselector.cpp:
              (khtml::checkPseudoState):
              * khtml/dom/dom_string.h:
              (DOM::DOMString::replace):
              * khtml/ecma/kjs_css.cpp:
              (KJS::DOMCSSStyleDeclaration::put):
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNode::put):
              (KJS::DOMAttr::put):
              (KJS::DOMDocument::put):
              * khtml/ecma/kjs_events.cpp:
              (KJS::JSAbstractEventListener::handleEvent):
              * khtml/ecma/kjs_html.cpp:
              (KJS::KJS::HTMLDocument::put):
              (KJS::KJS::HTMLElementFunction::callAsFunction):
              (KJS::KJS::HTMLElement::put):
              (KJS::KJS::Context2DFunction::callAsFunction):
              (KJS::Context2D::putValueProperty):
              * khtml/ecma/kjs_proxy.cpp:
              (KJSProxyImpl::evaluate):
              * khtml/ecma/kjs_window.cpp:
              (KJS::Window::isSafeScript):
              (KJS::WindowFunc::callAsFunction):
              (KJS::ScheduledAction::execute):
              * khtml/ecma/xmlhttprequest.cpp:
              (KJS::XMLHttpRequest::send):
              (KJS::XMLHttpRequestProtoFunc::callAsFunction):
              * khtml/ecma/xmlhttprequest.h:
              * khtml/editing/jsediting.cpp:
              (DOM::JSEditor::queryCommandSupported):
              * khtml/editing/markup.cpp:
              (khtml::stringValueForRange):
              (khtml::startMarkup):
              * khtml/html/html_baseimpl.cpp:
              (HTMLBodyElementImpl::parseMappedAttribute):
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::addHTMLAlignment):
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::formData):
              (DOM::HTMLInputElementImpl::appendFormData):
              (DOM::HTMLTextAreaElementImpl::updateValue):
              * khtml/html/html_headimpl.cpp:
              (HTMLLinkElementImpl::parseMappedAttribute):
              * khtml/html/html_imageimpl.cpp:
              (DOM::HTMLImageElementImpl::parseMappedAttribute):
              * khtml/html/html_objectimpl.cpp:
              (DOM::HTMLObjectElementImpl::parseMappedAttribute):
              (DOM::HTMLParamElementImpl::isURLAttribute):
              * khtml/html/html_objectimpl.h:
              * khtml/html/html_tableimpl.cpp:
              (DOM::HTMLTableElementImpl::addChild):
              (DOM::HTMLTableElementImpl::parseMappedAttribute):
              (DOM::HTMLTablePartElementImpl::parseMappedAttribute):
              (DOM::HTMLTableSectionElementImpl::addChild):
              (DOM::HTMLTableRowElementImpl::addChild):
              * khtml/html/htmltokenizer.cpp:
              (khtml::HTMLTokenizer::parseTag):
              * khtml/khtml_part.cpp:
              (KHTMLPart::executeScript):
              (KHTMLPart::checkEmitLoadEvent):
              * khtml/misc/loader.cpp:
              (CachedObject::finish):
              (CachedCSSStyleSheet::checkNotify):
              (CachedXSLStyleSheet::checkNotify):
              (CachedXBLDocument::checkNotify):
              (DocLoader::requestImage):
              (DocLoader::requestStyleSheet):
              (DocLoader::requestScript):
              (Loader::servePendingRequests):
              (Loader::cancelRequests):
              * khtml/rendering/render_applet.cpp:
              * khtml/rendering/render_block.cpp:
              (khtml::RenderBlock::updateFirstLetter):
              * khtml/rendering/render_box.cpp:
              (RenderBox::~RenderBox):
              * khtml/rendering/render_form.cpp:
              (RenderFormElement::slotTextChanged):
              (RenderLineEdit::updateFromElement):
              (RenderTextArea::updateFromElement):
              (RenderTextArea::text):
              * khtml/rendering/render_form.h:
              * khtml/rendering/render_frames.cpp:
              (RenderPartObject::updateWidget):
              * khtml/rendering/render_line.cpp:
              (khtml::EllipsisBox::paint):
              * khtml/rendering/render_list.cpp:
              (RenderListItem::paint):
              (RenderListMarker::paint):
              * khtml/rendering/render_text.cpp:
              (khtml::RenderText::RenderText):
              (khtml::RenderText::position):
              * khtml/xml/dom_docimpl.cpp:
              (DOMImplementationImpl::hasFeature):
              (DocumentImpl::getElementByAccessKey):
              (DocumentImpl::recalcStyleSelector):
              (DocumentImpl::defaultEventHandler):
              * khtml/xml/dom_elementimpl.cpp:
              (ElementImpl::recalcStyle):
              * khtml/xml/dom_nodeimpl.cpp:
              (DOM::NodeImpl::dump):
              (DOM::appendAttributeDesc):
              (DOM::NodeImpl::showNode):
              * khtml/xml/dom_stringimpl.cpp:
              (DOM::DOMStringImpl::lower):
              * khtml/xml/xml_tokenizer.cpp:
              (khtml::XMLTokenizer::executeScripts):
              * khtml/xsl/xsl_stylesheetimpl.cpp:
              (DOM::XSLStyleSheetImpl::loadChildSheets):
              * kwq/KWQKHTMLPart.h:
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::documentViewForNode):
              (KWQKHTMLPart::runJavaScriptAlert):
              (KWQKHTMLPart::runJavaScriptConfirm):
              (KWQKHTMLPart::runJavaScriptPrompt):
              (KWQKHTMLPart::addMessageToConsole):
              (KWQKHTMLPart::passWheelEventToChildWidget):
              (KWQKHTMLPart::shouldDragAutoNode):
              (KWQKHTMLPart::snapshotDragImage):
              (convertAttributesToUnderlines):
              (KWQKHTMLPart::setMarkedTextRange):
              (KWQKHTMLPart::mousePressNode):
              * kwq/KWQKGlobal.h: Removed.
              * kwq/KWQKGlobal.mm: Removed.
              * kwq/KWQLabel.h: Removed.
              * kwq/KWQLabel.mm: Removed.
              * kwq/KWQLineEdit.h:
              * kwq/KWQLineEdit.mm:
              (QLineEdit::setText):
              (QLineEdit::text):
              (QLineEdit::setAutoSaveName):
              (QLineEdit::setPlaceholderString):
              * kwq/KWQPainter.mm:
              (QPainter::compositeOperatorFromString):
              * kwq/KWQSignal.h:
              * kwq/KWQSignal.mm:
              (KWQSignal::call):
              * kwq/KWQSlot.h:
              * kwq/KWQSlot.mm:
              (KWQSlot::call):
              * kwq/KWQString.h:
              * kwq/KWQString.mm:
              * kwq/KWQTextEdit.h:
              * kwq/KWQTextEdit.mm:
              (QTextEdit::setText):
              (QTextEdit::text):
              (QTextEdit::textWithHardLineBreaks):
              * ksvg2/scripts/cssmakeprops: removed kglobal.h
              * ksvg2/scripts/cssmakevalues: removed kglobal.h
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11751 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c644a61a
  5. 21 Dec, 2005 2 commits
    • darin's avatar
      Reviewed by Justin. · 26f5b365
      darin authored
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6142
                intermittent failures in some paste tests
      
              * khtml/editing/apply_style_command.cpp:
              (khtml::ApplyStyleCommand::applyBlockStyle): Call new updateLayout member function.
              (khtml::ApplyStyleCommand::applyInlineStyle): Ditto.
              (khtml::ApplyStyleCommand::pushDownTextDecorationStyleAtBoundaries): Ditto.
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::addBlockPlaceholderIfNeeded): Ditto.
              (khtml::CompositeEditCommand::findBlockPlaceholder): Ditto.
              (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): Ditto.
              * khtml/editing/delete_selection_command.cpp:
              (khtml::DeleteSelectionCommand::fixupWhitespace): Ditto.
              (khtml::DeleteSelectionCommand::moveNodesAfterNode): Ditto.
              * khtml/editing/edit_command.cpp:
              (khtml::EditCommand::apply): Ditto.
              (khtml::EditCommand::unapply): Ditto.
              (khtml::EditCommand::reapply): Ditto.
              (khtml::EditCommand::updateLayout): Added. Calls updateLayoutIgnorePendingStylesheets
              on the document.
              * khtml/editing/edit_command.h: Added updateLayout member function.
              * khtml/editing/insert_line_break_command.cpp:
              (khtml::InsertLineBreakCommand::doApply): Call new updateLayout member function.
              * khtml/editing/insert_paragraph_separator_command.cpp:
              (khtml::InsertParagraphSeparatorCommand::doApply): Ditto.
              * khtml/editing/jsediting.cpp:
              (DOM::JSEditor::execCommand): Call updateLayoutIgnorePendingStylesheets instead of updateLayout.
              (DOM::JSEditor::queryCommandEnabled): Ditto.
              (DOM::JSEditor::queryCommandIndeterm): Ditto.
              (DOM::JSEditor::queryCommandState): Ditto.
              (DOM::JSEditor::queryCommandValue): Ditto.
              * khtml/editing/markup.cpp: (khtml::createMarkup): Ditto.
              * khtml/editing/replace_selection_command.cpp:
              (khtml::ReplacementFragment::insertFragmentForTestRendering): Ditto.
              (khtml::ReplaceSelectionCommand::fixupNodeStyles): Call new updateLayout member function.
              (khtml::ReplacementFragment::computeStylesUsingTestRendering): Call
              updateLayoutIgnorePendingStylesheets instead of updateLayout.
              (khtml::ReplaceSelectionCommand::doApply): Call new updateLayout member function.
              (khtml::ReplaceSelectionCommand::removeLinePlaceholderIfNeeded): Ditto.
              (khtml::ReplaceSelectionCommand::completeHTMLReplacement): Ditto.
              * khtml/editing/visible_units.cpp:
              (khtml::previousLinePosition): Call updateLayoutIgnorePendingStylesheets instead of updateLayout.
              (khtml::nextLinePosition): Ditto.
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::innerText): Ditto.
              * kwq/WebCoreBridge.mm:
              (-[WebCoreBridge setSelectedDOMRange:affinity:closeTyping:]): Ditto.
              (-[WebCoreBridge smartDeleteRangeForProposedRange:]): Ditto.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11723 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      26f5b365
    • harrison's avatar
      Reviewed by Justin). · 5f9e7101
      harrison authored
              <rdar://problem/4039777> Pasting particular snippet of HTML containing list items and a link creates too many list items
              - Fixed paste crash by making calling RenderBox::deleteLineBoxWrapper() from RenderObject::remove(),
              so that the connection is broken before the InlineBox's parent gets deleted.
              - Fixed overzealous style changes when setting the style on a specific range of elements.  These specific
              ranges are derived programmatically, e.g. as a part of pasting, so they must be respected exactly rather
              than modified by converting the endpoints to VisiblePositions.
      
              Test cases coming soon.
      
              * khtml/editing/apply_style_command.cpp:
              (khtml::ApplyStyleCommand::ApplyStyleCommand):
              (khtml::ApplyStyleCommand::updateStartEnd):
              (khtml::ApplyStyleCommand::startPosition):
              (khtml::ApplyStyleCommand::endPosition):
              (khtml::ApplyStyleCommand::applyBlockStyle):
              (khtml::ApplyStyleCommand::applyRelativeFontStyleChange):
              (khtml::ApplyStyleCommand::applyInlineStyle):
              (khtml::ApplyStyleCommand::removeInlineStyle):
              (khtml::ApplyStyleCommand::splitTextAtStartIfNeeded):
              (khtml::ApplyStyleCommand::splitTextAtEndIfNeeded):
              (khtml::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
              (khtml::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
              (khtml::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
              (khtml::ApplyStyleCommand::mergeEndWithNextIfIdentical):
              (khtml::ApplyStyleCommand::joinChildTextNodes):
              * khtml/editing/apply_style_command.h:
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::applyStyle):
              * khtml/editing/composite_edit_command.h:
              * khtml/editing/insert_line_break_command.cpp:
              (khtml::InsertLineBreakCommand::doApply):
              * khtml/editing/replace_selection_command.cpp:
              (khtml::ReplaceSelectionCommand::fixupNodeStyles):
              (khtml::ReplaceSelectionCommand::completeHTMLReplacement):
              * khtml/rendering/render_box.cpp:
              (RenderBox::destroy):
              (RenderBox::deleteLineBoxWrapper):
              * khtml/rendering/render_box.h:
              * khtml/rendering/render_list.cpp:
              (RenderListMarker::~RenderListMarker):
              (RenderListMarker::setStyle):
              * khtml/rendering/render_object.cpp:
              (RenderObject::remove):
              * khtml/rendering/render_object.h:
              * khtml/rendering/render_replaced.cpp:
              (RenderWidget::destroy):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11718 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5f9e7101
  6. 20 Dec, 2005 2 commits
  7. 12 Dec, 2005 2 commits
    • justing's avatar
      Reviewed by harrison · 3eaa3678
      justing authored
              <rdar://problem/4040763> VisiblePosition constructor can return a result outside of the original
      
              This bug was filed as a reminder to remove the workaround for
              <rdar://problem/4033202>.  We fixed the problems with
              VisiblePosition causing 4033202, so I removed the workaround
              and added a layout test.
      
              * khtml/editing/visible_units.cpp:
              (khtml::previousLinePosition):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11557 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3eaa3678
    • harrison's avatar
      Reviewed by Justin. · 6f0532d6
      harrison authored
      	<rdar://problem/4027704> Paste of HTML list content can break list structure by dropping empty list items
      
      	Fixed by having ReplaceSelectionCommand remove empty nodes just
      	from the ancestors of the node(s) moved by mergeStart, rather
      	than scanning the whole fragment.
      
      	Layout tests added:
      	    editing/pasteboard/paste-table-001.html
      	    editing/pasteboard/paste-list-001.html
      
              * khtml/editing/replace_selection_command.cpp:
              (khtml::ReplaceSelectionCommand::isProbablyTableStructureNode):
              (khtml::ReplaceSelectionCommand::pruneEmptyNodes):
      	Removed no longer needed functions.
      
              (khtml::ReplaceSelectionCommand::doApply):
      	Remove ancestor nodes emptied by mergeStart.
      	Do that instead of calling pruneEmptyNodes().
      
              * khtml/editing/replace_selection_command.h:
              (khtml::ReplacementFragment::desiredStyles):
      	Removed pruneEmptyNodes().
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11555 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6f0532d6
  8. 10 Dec, 2005 1 commit
    • darin's avatar
      LayoutTests: · 74ac63fc
      darin authored
              Reviewed and landed by Darin.
      
              Test for: http://bugzilla.opendarwin.org/show_bug.cgi?id=6029
              plainText() returns a partial result when the node contains RTL text
      
              * fast/dom/inner-text-rtl-expected.txt: Added.
              * fast/dom/inner-text-rtl.html: Added.
      
      WebCore:
      
              Reviewed and landed by Darin.
      
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6029
                plainText() returns a partial result when the node contains RTL text
      
              Test: fast/dom/inner-text-rtl.html
      
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::handleTextBox): Avoid advancing m_sortedTextBoxes if textBoxEnd wasn't reached.
              * kwq/KWQListImpl.h:
              * kwq/KWQListImpl.mm:
              (KWQListImpl::getNext): Added.
              (KWQListImpl::getPrev): Added.
              * kwq/KWQPtrList.h:
              (QPtrList::getNext): Added.
              (QPtrList::getPrev): Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11522 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      74ac63fc
  9. 09 Dec, 2005 1 commit
    • justing's avatar
      <rdar://problem/4370209> Reproducible crash when pasting over whitespace:pre text · 076923db
      justing authored
              <rdar://problem/4370220> Double or triple clicking in whitespace:pre text creates incorrect selections
              Some preparation for a fix for:
              <radar://problem/4364427> triple-click includes first item on next line (www.apple.com, but I think I've seen it elsewhere)
      
              There were a few bugs in endOfParagraph's and endOfLine's handling of IncludeLineBreak.
              The IncludeLinebreak concept also doesn't make sense: when asked to
              IncludeLineBreak, "endOfParagraph" would return the start of the next paragraph.
              Callers that want this funtionality should just call endOfParagraph and then get next()
              if it exists.
              In endOfParagraph's whitespace:pre handling, when the input visible position
              was at the end of a text node with whitespace:pre, that text node was searched
              for '/n'.  It should be skipped.
      
              Reviewed by harrison
      
              Added new layout tests in editing/pasting and editing/selection
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::validate):
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
              * khtml/editing/visible_units.cpp:
              (khtml::endOfLine):
              (khtml::isEndOfLine):
              (khtml::endOfParagraph):
              (khtml::isEndOfParagraph):
              * khtml/editing/visible_units.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11514 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      076923db
  10. 05 Dec, 2005 1 commit
    • justing's avatar
      <http://bugzilla.opendarwin.org/show_bug.cgi?id=5936> · 80d46695
      justing authored
              REGRESSION: selection keeps growing after double-click
              Also filed as <rdar://problem/4364425>
      
              Reviewed by darin, harrison
      
              Rolled back previous change, simplified expansion, fixed
              adjustForEditableContent to work in cases where start/end are
              distinct from base/extent, renamed m_baseIsStart to m_baseIsFirst.
      
              Added two new layout tests in editing/selection to test
              modifying selections created with double and triple clicks.
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::SelectionController):
              (khtml::SelectionController::init):
              (khtml::SelectionController::operator=):
              (khtml::SelectionController::expandUsingGranularity):
              (khtml::SelectionController::adjustForEditableContent):
              (khtml::SelectionController::validate):
              * khtml/editing/SelectionController.h:
              * khtml/khtml_part.cpp:
              (KHTMLPart::handleMouseMoveEventSelection):
              (KHTMLPart::khtmlMouseMoveEvent):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11467 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      80d46695
  11. 03 Dec, 2005 1 commit
    • justing's avatar
      <http://bugzilla.opendarwin.org/show_bug.cgi?id=5856> · 4182d224
      justing authored
              Selection based in an editable block can extend outside
      
              validate() used to do expansion of the selection.  The expansion
              itself wasn't validated, so it could create a selection
              that extended outside an editable area.  Also m_base and
              m_extent weren't updated with the results of the expansion.
      
              Reviewed by darin
      
              Layout tests added:
              * editing/selection/expanding-selections
              * editing/selection/expanding-selections2
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::expandUsingGranularity): Does the expansion.
              (khtml::SelectionController::validate): Removed the granularity parameter.
              * khtml/editing/SelectionController.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11426 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4182d224
  12. 02 Dec, 2005 1 commit
    • justing's avatar
      <http://bugzilla.opendarwin.org/show_bug.cgi?id=4003> · 51fbb169
      justing authored
              contentEditable div cannot be edited if it starts out with empty or <p/>
      
              Reviewed/tweaked/landed by justin
      
              * khtml/editing/visible_position.cpp:
              (khtml::VisiblePosition::init): A position at the original block
              shouldn't be considered 'outside' the original block.
              (khtml::hasRenderedChildrenWithHeight): Added.
              (khtml::VisiblePosition::isCandidate): A block flow element with
              rendered children may be considered a candidate for a visible
              position, as long as its children do not have a positive height.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11394 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      51fbb169
  13. 01 Dec, 2005 2 commits
    • mjs's avatar
      JavaScriptCore: · 3936425b
      mjs authored
              Reviewed by Tim Hatcher.
      
      	- removed deprecated reset, isNull and nonNull methods
      
              * kxmlcore/RefPtr.h:
      
      WebCore:
      
              Reviewed by Tim Hatcher.
      
      	- removed deprecated reset, isNull and nonNull methods
      	- replaced use of KWQRefPtr with RefPtr
      
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNode::toBoolean):
              (KJS::DOMNode::toPrimitive):
              (KJS::DOMNode::toString):
              (KJS::DOMNodeList::toPrimitive):
              * khtml/ecma/kjs_html.cpp:
              (KJS::OptionConstructorImp::construct):
              * khtml/ecma/xmlhttprequest.cpp:
              (KJS::XMLHttpRequest::getValueProperty):
              (KJS::XMLHttpRequest::putValueProperty):
              (KJS::XMLHttpRequest::mark):
              (KJS::XMLHttpRequest::changeState):
              (KJS::XMLHttpRequest::open):
              * khtml/editing/edit_command.cpp:
              * khtml/html/html_tableimpl.cpp:
              (DOM::HTMLTableSectionElementImpl::insertRow):
              (DOM::HTMLTableSectionElementImpl::deleteRow):
              (DOM::HTMLTableRowElementImpl::insertCell):
              (DOM::HTMLTableRowElementImpl::deleteCell):
              * khtml/khtml_part.cpp:
              (KHTMLPart::scheduleScript):
              (KHTMLPart::executeScheduledScript):
              (KHTMLPart::clear):
              (KHTMLPart::khtmlMousePressEvent):
              * khtml/khtmlview.cpp:
              (KHTMLViewPrivate::reset):
              (KHTMLView::updateDragAndDrop):
              (KHTMLView::cancelDragAndDrop):
              (KHTMLView::performDragAndDrop):
              * khtml/rendering/render_block.cpp:
              (khtml::RenderBlock::updateFirstLetter):
              * khtml/rendering/render_text.cpp:
              (RenderText::setStyle):
              * khtml/xml/dom_docimpl.cpp:
              (DocumentImpl::prepareMouseEvent):
              * khtml/xml/dom_elementimpl.cpp:
              (NamedAttrMapImpl::setNamedItem):
              * khtml/xml/dom_nodeimpl.h:
              (DOM::NodeImpl::MouseEvent::MouseEvent):
              * kwq/KWQArrayImpl.h:
              * kwq/KWQArrayImpl.mm:
              (KWQArrayImpl::KWQArrayPrivate::KWQArrayPrivate):
              (KWQArrayImpl::duplicate):
              (KWQArrayImpl::detach):
              * kwq/KWQClipboard.mm:
              (KWQClipboard::setDragImage):
              (KWQClipboard::dragNSImage):
              * kwq/KWQFontMetrics.h:
              * kwq/KWQFontMetrics.mm:
              (QFontMetricsPrivate::QFontMetricsPrivate):
              (QFontMetrics::setFont):
              (QFontMetrics::ascent):
              (QFontMetrics::descent):
              (QFontMetrics::lineSpacing):
              (QFontMetrics::xHeight):
              (QFontMetrics::width):
              (QFontMetrics::floatWidth):
              (QFontMetrics::checkSelectionPoint):
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::paint):
              (KWQKHTMLPart::openURLFromPageCache):
              (KWQKHTMLPart::khtmlMousePressEvent):
              (KWQKHTMLPart::khtmlMouseMoveEvent):
              (KWQKHTMLPart::dragSourceMovedTo):
              (KWQKHTMLPart::dragSourceEndedAt):
              (KWQKHTMLPart::mouseDown):
              (KWQKHTMLPart::snapshotDragImage):
              (KWQKHTMLPart::markMisspellings):
              (KWQKHTMLPart::setMarkedTextRange):
              * kwq/KWQMapImpl.h:
              * kwq/KWQMapImpl.mm:
              (KWQMapImpl::KWQMapPrivate::KWQMapPrivate):
              (KWQMapImpl::copyOnWrite):
              (KWQMapImpl::swap):
              * kwq/KWQRefPtr.h: Removed.
              * kwq/KWQRegExp.h:
              * kwq/KWQRegExp.mm:
              (QRegExp::KWQRegExpPrivate::KWQRegExpPrivate):
              (QRegExp::operator=):
              * kwq/KWQValueListImpl.h:
              * kwq/KWQValueListImpl.mm:
              (KWQValueListImpl::KWQValueListPrivate::KWQValueListPrivate):
              (KWQValueListImpl::operator=):
              (KWQValueListImpl::copyOnWrite):
              * kwq/KWQVariant.h:
              * kwq/KWQVariant.mm:
              (QVariant::QVariantPrivate::):
              (QVariant::QVariantPrivate::QVariantPrivate):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11392 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3936425b
    • mjs's avatar
      JavaScriptCore: · bb3d15c2
      mjs authored
              Rubber stamped by Eric.
      
      	- renamed SharedPtr to RefPtr via script
      
              * JavaScriptCore.xcodeproj/project.pbxproj:
              * kjs/function.cpp:
              (KJS::GlobalFuncImp::callAsFunction):
              * kjs/function.h:
              * kjs/function_object.cpp:
              (FunctionObjectImp::construct):
              * kjs/internal.cpp:
              (KJS::Parser::parse):
              (KJS::InterpreterImp::checkSyntax):
              (KJS::InterpreterImp::evaluate):
              * kjs/internal.h:
              * kjs/nodes.h:
              * kjs/nodes2string.cpp:
              (KJS::SourceStream::operator<<):
              * kjs/protect.h:
              * kxmlcore/RefPtr.h: Added.
              (KXMLCore::RefPtr::RefPtr):
              (KXMLCore::RefPtr::~RefPtr):
              (KXMLCore::RefPtr::isNull):
              (KXMLCore::RefPtr::notNull):
              (KXMLCore::RefPtr::reset):
              (KXMLCore::RefPtr::get):
              (KXMLCore::RefPtr::operator*):
              (KXMLCore::RefPtr::operator->):
              (KXMLCore::RefPtr::operator!):
              (KXMLCore::RefPtr::operator UnspecifiedBoolType):
              (KXMLCore::::operator):
              (KXMLCore::operator==):
              (KXMLCore::operator!=):
              (KXMLCore::static_pointer_cast):
              (KXMLCore::const_pointer_cast):
              * kxmlcore/SharedPtr.h: Removed.
      
      WebCore:
      
              Rubber stamped by Eric.
      
      	- renamed SharedPtr to RefPtr via script
      
              * ForwardingHeaders/kxmlcore/RefPtr.h: Added.
              * ForwardingHeaders/kxmlcore/SharedPtr.h: Removed.
              * khtml/css/css_computedstyle.h:
              * khtml/ecma/XSLTProcessor.cpp:
              (KJS::XSLTProcessorProtoFunc::callAsFunction):
              * khtml/ecma/XSLTProcessor.h:
              * khtml/ecma/domparser.h:
              * khtml/ecma/kjs_css.h:
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNamedNodesCollection::DOMNamedNodesCollection):
              (KJS::DOMNamedNodesCollection::getOwnPropertySlot):
              * khtml/ecma/kjs_dom.h:
              * khtml/ecma/kjs_events.h:
              * khtml/ecma/kjs_html.cpp:
              (KJS::HTMLDocument::namedItemGetter):
              (KJS::KJS::HTMLCollection::getNamedItems):
              (KJS::OptionConstructorImp::construct):
              * khtml/ecma/kjs_html.h:
              * khtml/ecma/kjs_range.h:
              * khtml/ecma/kjs_traversal.h:
              * khtml/ecma/kjs_views.h:
              * khtml/ecma/kjs_window.cpp:
              (KJS::Window::namedItemGetter):
              * khtml/ecma/xmlhttprequest.h:
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::toRange):
              * khtml/editing/SelectionController.h:
              * khtml/editing/apply_style_command.cpp:
              (khtml::StyleChange::init):
              (khtml::StyleChange::currentlyHasStyle):
              (khtml::ApplyStyleCommand::doApply):
              (khtml::ApplyStyleCommand::applyRelativeFontStyleChange):
              (khtml::ApplyStyleCommand::removeCSSStyle):
              (khtml::hasTextDecorationProperty):
              (khtml::ApplyStyleCommand::extractTextDecorationStyle):
              (khtml::ApplyStyleCommand::extractAndNegateTextDecorationStyle):
              (khtml::ApplyStyleCommand::pushDownTextDecorationStyleAroundNode):
              (khtml::ApplyStyleCommand::removeInlineStyle):
              (khtml::ApplyStyleCommand::addInlineStyleIfNeeded):
              (khtml::ApplyStyleCommand::computedFontSize):
              * khtml/editing/apply_style_command.h:
              * khtml/editing/edit_command.cpp:
              (khtml::EditCommandPtr::EditCommandPtr):
              (khtml::EditCommandPtr::operator=):
              * khtml/editing/edit_command.h:
              * khtml/editing/markup.cpp:
              (khtml::startMarkup):
              * khtml/editing/visible_position.cpp:
              (khtml::makeRange):
              * khtml/editing/visible_position.h:
              * khtml/editing/visible_range.h:
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::range):
              (khtml::SimplifiedBackwardsTextIterator::range):
              (khtml::CharacterIterator::range):
              (khtml::TextIterator::rangeFromLocationAndLength):
              (khtml::findPlainText):
              * khtml/editing/visible_text.h:
              (khtml::WordAwareIterator::range):
              * khtml/editing/visible_units.cpp:
              (khtml::previousBoundary):
              (khtml::nextBoundary):
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::children):
              * khtml/html/html_elementimpl.h:
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::elements):
              (DOM::HTMLSelectElementImpl::add):
              (DOM::HTMLSelectElementImpl::optionsHTMLCollection):
              * khtml/html/html_formimpl.h:
              * khtml/html/html_imageimpl.cpp:
              (DOM::HTMLMapElementImpl::areas):
              * khtml/html/html_imageimpl.h:
              * khtml/html/html_miscimpl.cpp:
              (DOM::HTMLCollectionImpl::namedItems):
              * khtml/html/html_miscimpl.h:
              * khtml/html/html_tableimpl.cpp:
              (DOM::HTMLTableElementImpl::rows):
              (DOM::HTMLTableElementImpl::tBodies):
              (DOM::HTMLTableSectionElementImpl::insertRow):
              (DOM::HTMLTableSectionElementImpl::deleteRow):
              (DOM::HTMLTableSectionElementImpl::rows):
              (DOM::HTMLTableRowElementImpl::insertCell):
              (DOM::HTMLTableRowElementImpl::deleteCell):
              (DOM::HTMLTableRowElementImpl::cells):
              * khtml/html/html_tableimpl.h:
              * khtml/html/htmlparser.cpp:
              (HTMLParser::parseToken):
              (HTMLParser::insertNode):
              * khtml/khtml_events.h:
              * khtml/khtml_part.cpp:
              (KHTMLPart::selectionHasStyle):
              (KHTMLPart::selectionStartHasStyle):
              (KHTMLPart::selectionComputedStyle):
              (KHTMLPart::applyEditingStyleToBodyElement):
              (KHTMLPart::removeEditingStyleFromBodyElement):
              * khtml/khtmlpart_p.h:
              * khtml/khtmlview.cpp:
              (KHTMLView::viewportMousePressEvent):
              (KHTMLView::viewportMouseDoubleClickEvent):
              (KHTMLView::viewportMouseReleaseEvent):
              (KHTMLView::dispatchMouseEvent):
              * khtml/misc/shared.h:
              * khtml/rendering/bidi.cpp:
              * khtml/rendering/render_block.cpp:
              (khtml::RenderBlock::updateFirstLetter):
              * khtml/rendering/render_line.h:
              * khtml/rendering/render_text.cpp:
              (RenderText::setStyle):
              (RenderText::originalString):
              (RenderTextFragment::originalString):
              * khtml/rendering/render_text.h:
              * khtml/xml/dom2_eventsimpl.h:
              * khtml/xml/dom2_rangeimpl.cpp:
              (DOM::rangeOfContents):
              * khtml/xml/dom2_rangeimpl.h:
              * khtml/xml/dom_docimpl.cpp:
              (DocumentImpl::adoptNode):
              (DocumentImpl::setFocusNode):
              (DocumentImpl::addMarker):
              (DocumentImpl::removeMarkers):
              (DocumentImpl::applyXSLTransform):
              (DocumentImpl::images):
              (DocumentImpl::applets):
              (DocumentImpl::embeds):
              (DocumentImpl::objects):
              (DocumentImpl::links):
              (DocumentImpl::forms):
              (DocumentImpl::anchors):
              (DocumentImpl::all):
              (DocumentImpl::windowNamedItems):
              (DocumentImpl::documentNamedItems):
              (DocumentImpl::getElementsByName):
              * khtml/xml/dom_docimpl.h:
              (DOM::DocumentImpl::transformSourceDocument):
              * khtml/xml/dom_elementimpl.cpp:
              (ElementImpl::setAttributeNode):
              (ElementImpl::removeAttributeNode):
              (NamedAttrMapImpl::removeNamedItemNS):
              (NamedAttrMapImpl::setNamedItem):
              (NamedAttrMapImpl::removeNamedItem):
              * khtml/xml/dom_elementimpl.h:
              (DOM::ElementImpl::setAttributeNodeNS):
              * khtml/xml/dom_nodeimpl.cpp:
              (DOM::NodeImpl::childNodes):
              (DOM::NodeImpl::dispatchWindowEvent):
              (DOM::NodeImpl::dispatchMouseEvent):
              (DOM::NodeImpl::getElementsByTagNameNS):
              (DOM::ContainerNodeImpl::insertBefore):
              (DOM::ContainerNodeImpl::replaceChild):
              (DOM::ContainerNodeImpl::appendChild):
              (DOM::ContainerNodeImpl::addChild):
              * khtml/xml/dom_nodeimpl.h:
              (DOM::NodeImpl::getElementsByTagName):
              (DOM::NamedNodeMapImpl::removeNamedItem):
              (DOM::NamedNodeMapImpl::setNamedItemNS):
              * khtml/xml/dom_xmlimpl.h:
              * khtml/xsl/xslt_processorimpl.cpp:
              (DOM::XSLTProcessorImpl::createDocumentFromSource):
              (DOM::createFragmentFromSource):
              (DOM::xsltStylesheetPointer):
              (DOM::xmlDocPtrFromNode):
              (DOM::XSLTProcessorImpl::transformToString):
              (DOM::XSLTProcessorImpl::transformToDocument):
              (DOM::XSLTProcessorImpl::transformToFragment):
              (DOM::XSLTProcessorImpl::getParameter):
              * khtml/xsl/xslt_processorimpl.h:
              * kwq/KWQClipboard.h:
              * kwq/KWQKHTMLPart.h:
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::findString):
              (KWQKHTMLPart::advanceToNextMisspelling):
              (KWQKHTMLPart::fontForSelection):
              (KWQKHTMLPart::markMisspellings):
              (KWQKHTMLPart::shouldClose):
              * kwq/WebCoreBridge.mm:
              (-[WebCoreBridge convertToNSRange:DOM::]):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11375 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      bb3d15c2
  14. 29 Nov, 2005 1 commit
  15. 28 Nov, 2005 1 commit
    • justing's avatar
      <http://bugzilla.opendarwin.org/show_bug.cgi?id=5354> · 24fe3d4f
      justing authored
              Corner case where you can select outside the bounds of an editable block.
      
              Reviewed by darin
      
              Updated/added editing test cases to reflect fix.
      
              * khtml/editing/visible_position.cpp:
              (khtml::VisiblePosition::init):
              It's ok to do some hunting to find a valid VisblePosition given a position
              that is not somewhere visible, like inside an empty div, but only leave the
              block containing the position used to construct the VisiblePosition if we
              can't find a VisiblePosition inside that block.
              We weren't using the equivalentDeepPosition of the input position to make
              the initUpstream/initDownstream decision, so we were sometimes moving
              past [br, 0], which is what having initUpstream around is supposed to prevent.
              I got rid of initUpstream and included the check to prevent moving
              past [br, 0] inside the now generalized init().
      
              * khtml/editing/visible_units.cpp:
              (khtml::endOfParagraph):
              After the changes to VisiblePosition::init(), asking for the visible position
              at  [br, 1] isn't the right way to include a line break.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11323 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      24fe3d4f
  16. 20 Nov, 2005 1 commit
    • eseidel's avatar
      Bug #: 5711 · 7811b780
      eseidel authored
      Submitted by: eseidel
      Reviewed by: mjs
              Remove #if !APPLE_CHANGES and #if 0 blocks.  No functional changes.
              http://bugzilla.opendarwin.org/show_bug.cgi?id=5711
      
              * khtml/css/css_computedstyle.cpp:
              (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
              * khtml/css/css_valueimpl.cpp:
              (DOM::CSSMutableStyleDeclarationImpl::setProperty):
              (DOM::CSSPrimitiveValueImpl::computeLength):
              (DOM::CSSPrimitiveValueImpl::computeLengthFloat):
              (DOM::CSSPrimitiveValueImpl::cssText):
              (DOM::FontFamilyValueImpl::FontFamilyValueImpl):
              * khtml/css/css_valueimpl.h:
              * khtml/css/cssparser.cpp:
              (qFatal):
              (CSSParser::parseValue):
              (CSSParser::parseDashboardRegions):
              * khtml/css/cssstyleselector.cpp:
              (khtml::):
              (khtml::colorForCSSValue):
              (khtml::CSSStyleSelector::applyDeclarations):
              (khtml::CSSStyleSelector::applyProperty):
              (khtml::CSSStyleSelector::checkForTextSizeAdjust):
              * khtml/css/cssstyleselector.h:
              * khtml/dom/dom_node.h:
              * khtml/ecma/kjs_binding.cpp:
              * khtml/ecma/kjs_binding.h:
              * khtml/ecma/kjs_css.cpp:
              (KJS::DOMStyleSheetList::getOwnPropertySlot):
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNode::getValueProperty):
              (KJS::NodeConstructor::getValueProperty):
              (KJS::DOMExceptionConstructor::getValueProperty):
              * khtml/ecma/kjs_html.cpp:
              (KJS::HTMLElement::getOwnPropertySlot):
              (KJS::KJS::HTMLElementFunction::callAsFunction):
              (KJS::KJS::HTMLElement::put):
              * khtml/ecma/kjs_html.h:
              * khtml/ecma/kjs_navigator.cpp:
              (KJS::Navigator::getValueProperty):
              (KJS::PluginBase::refresh):
              * khtml/ecma/kjs_proxy.cpp:
              (KJSProxyImpl::evaluate):
              (KJSProxyImpl::initScript):
              * khtml/ecma/kjs_window.cpp:
              (KJS::allowPopUp):
              (KJS::Window::getValueProperty):
              (KJS::Window::put):
              (KJS::Window::resumeTimeouts):
              (KJS::Window::scheduleClose):
              (KJS::Window::isSafeScript):
              (KJS::WindowFunc::callAsFunction):
              (KJS::WindowQObject::hasTimeouts):
              (KJS::Location::put):
              (KJS::LocationFunc::callAsFunction):
              (KJS::BarInfo::getValueProperty):
              * khtml/ecma/kjs_window.h:
              * khtml/ecma/xmlhttprequest.cpp:
              (KJS::XMLHttpRequestQObject::slotData):
              (KJS::XMLHttpRequest::send):
              (KJS::XMLHttpRequest::processSyncLoadResults):
              (KJS::XMLHttpRequest::slotData):
              * khtml/ecma/xmlhttprequest.h:
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::debugPosition):
              * khtml/editing/append_node_command.cpp:
              * khtml/editing/apply_style_command.cpp:
              * khtml/editing/break_blockquote_command.cpp:
              * khtml/editing/composite_edit_command.cpp:
              * khtml/editing/delete_from_text_node_command.cpp:
              * khtml/editing/delete_selection_command.cpp:
              * khtml/editing/edit_command.cpp:
              * khtml/editing/htmlediting.cpp:
              * khtml/editing/insert_into_text_node_command.cpp:
              * khtml/editing/insert_line_break_command.cpp:
              * khtml/editing/insert_node_before_command.cpp:
              * khtml/editing/insert_paragraph_separator_command.cpp:
              * khtml/editing/insert_text_command.cpp:
              * khtml/editing/join_text_nodes_command.cpp:
              * khtml/editing/jsediting.cpp:
              * khtml/editing/markup.cpp:
              * khtml/editing/merge_identical_elements_command.cpp:
              * khtml/editing/move_selection_command.cpp:
              * khtml/editing/rebalance_whitespace_command.cpp:
              * khtml/editing/remove_css_property_command.cpp:
              * khtml/editing/remove_node_attribute_command.cpp:
              * khtml/editing/remove_node_command.cpp:
              * khtml/editing/remove_node_preserving_children_command.cpp:
              * khtml/editing/replace_selection_command.cpp:
              * khtml/editing/set_node_attribute_command.cpp:
              * khtml/editing/split_element_command.cpp:
              * khtml/editing/split_text_node_command.cpp:
              * khtml/editing/split_text_node_containing_element.cpp:
              * khtml/editing/typing_command.cpp:
              * khtml/editing/visible_position.cpp:
              * khtml/editing/wrap_contents_in_dummy_span_command.cpp:
              * khtml/html/html_documentimpl.cpp:
              (DOM::HTMLDocumentImpl::referrer):
              (DOM::HTMLDocumentImpl::cookie):
              (DOM::HTMLDocumentImpl::setCookie):
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::attach):
              (DOM::HTMLFormElementImpl::formData):
              (DOM::HTMLFormElementImpl::submit):
              (DOM::HTMLFormElementImpl::parseMappedAttribute):
              (DOM::HTMLGenericFormElementImpl::isMouseFocusable):
              (DOM::HTMLGenericFormElementImpl::defaultEventHandler):
              (DOM::HTMLInputElementImpl::setInputType):
              (DOM::HTMLInputElementImpl::type):
              (DOM::HTMLInputElementImpl::canHaveSelection):
              (DOM::HTMLInputElementImpl::selectionStart):
              (DOM::HTMLInputElementImpl::selectionEnd):
              (DOM::HTMLInputElementImpl::setSelectionStart):
              (DOM::HTMLInputElementImpl::setSelectionEnd):
              (DOM::HTMLInputElementImpl::select):
              (DOM::HTMLInputElementImpl::setSelectionRange):
              (DOM::HTMLInputElementImpl::click):
              (DOM::HTMLInputElementImpl::accessKeyAction):
              (DOM::HTMLInputElementImpl::rendererIsNeeded):
              (DOM::HTMLInputElementImpl::createRenderer):
              (DOM::HTMLInputElementImpl::attach):
              (DOM::HTMLInputElementImpl::altText):
              (DOM::HTMLInputElementImpl::appendFormData):
              (DOM::HTMLInputElementImpl::valueWithDefault):
              (DOM::HTMLInputElementImpl::storesValueSeparateFromAttribute):
              (DOM::HTMLInputElementImpl::defaultEventHandler):
              (DOM::HTMLSelectElementImpl::state):
              (DOM::HTMLSelectElementImpl::restoreState):
              (DOM::HTMLKeygenElementImpl::appendFormData):
              * khtml/html/html_formimpl.h:
              (DOM::HTMLInputElementImpl::):
              * khtml/html/html_imageimpl.cpp:
              (HTMLImageLoader::updateFromElement):
              (HTMLImageElementImpl::parseMappedAttribute):
              * khtml/html/html_inlineimpl.cpp:
              (DOM::HTMLAnchorElementImpl::isMouseFocusable):
              * khtml/html/html_objectimpl.cpp:
              (DOM::HTMLAppletElementImpl::getMember):
              (DOM::HTMLAppletElementImpl::callMember):
              (DOM::HTMLAppletElementImpl::allParamsAvailable):
              (DOM::HTMLEmbedElementImpl::getEmbedInstance):
              (DOM::HTMLObjectElementImpl::HTMLObjectElementImpl):
              (DOM::HTMLObjectElementImpl::getObjectInstance):
              (DOM::HTMLObjectElementImpl::rendererIsNeeded):
              * khtml/html/html_objectimpl.h:
              (DOM::HTMLObjectElementImpl::isDocNamedItem):
              * khtml/html/html_tableimpl.cpp:
              (DOM::HTMLTableElementImpl::HTMLTableElementImpl):
              (DOM::HTMLTableElementImpl::parseMappedAttribute):
              * khtml/html/htmlparser.cpp:
              (HTMLParser::handleIsindex):
              * khtml/html/htmltokenizer.cpp:
              (khtml::HTMLTokenizer::scriptExecution):
              * khtml/html/htmltokenizer.h:
              * khtml/khtml_part.cpp:
              (KHTMLPart::KHTMLPart):
              (KHTMLPart::init):
              (KHTMLPart::~KHTMLPart):
              (KHTMLPart::restoreURL):
              (KHTMLPart::didOpenURL):
              (KHTMLPart::stopLoading):
              (KHTMLPart::createJavaContext):
              (KHTMLPart::setAutoloadImages):
              (KHTMLPart::clear):
              (KHTMLPart::receivedFirstData):
              (KHTMLPart::slotFinished):
              (KHTMLPart::childBegin):
              (KHTMLPart::begin):
              (KHTMLPart::write):
              (KHTMLPart::gotoAnchor):
              (KHTMLPart::slotLoaderRequestStarted):
              (KHTMLPart::slotLoaderRequestDone):
              (KHTMLPart::checkCompleted):
              (KHTMLPart::completeURL):
              (KHTMLPart::scheduleHistoryNavigation):
              (KHTMLPart::urlCursor):
              (KHTMLPart::text):
              (KHTMLPart::selectedText):
              (KHTMLPart::hasSelection):
              (KHTMLPart::setSelection):
              (KHTMLPart::urlSelected):
              (KHTMLPart::requestFrameName):
              (KHTMLPart::requestObject):
              (KHTMLPart::processObjectRequest):
              (KHTMLPart::submitForm):
              (KHTMLPart::slotChildStarted):
              (KHTMLPart::slotChildCompleted):
              (KHTMLPart::childFrame):
              (KHTMLPart::findFrame):
              (KHTMLPart::frameExists):
              (KHTMLPart::parentPart):
              (KHTMLPart::emitSelectionChanged):
              (KHTMLPart::setZoomFactor):
              (KHTMLPart::reparseConfiguration):
              (KHTMLPart::khtmlMousePressEvent):
              (KHTMLPart::khtmlMouseMoveEvent):
              (KHTMLPart::startAutoScroll):
              (KHTMLPart::stopAutoScroll):
              (KHTMLPart::shouldChangeSelection):
              (KHTMLPart::appliedEditing):
              (KHTMLPart::unappliedEditing):
              (KHTMLPart::reappliedEditing):
              (KHTMLPart::copyToPasteboard):
              (KHTMLPart::cutToPasteboard):
              (KHTMLPart::pasteFromPasteboard):
              (KHTMLPart::pasteAndMatchStyle):
              (KHTMLPart::transpose):
              (KHTMLPart::redo):
              (KHTMLPart::undo):
              * khtml/khtml_part.h:
              (KHTMLPart::didFirstLayout):
              * khtml/khtmlpart_p.h:
              (KHTMLPartPrivate::KHTMLPartPrivate):
              (KHTMLPartPrivate::~KHTMLPartPrivate):
              * khtml/khtmlview.cpp:
              (KHTMLViewPrivate::KHTMLViewPrivate):
              (KHTMLViewPrivate::~KHTMLViewPrivate):
              (KHTMLViewPrivate::reset):
              (KHTMLView::KHTMLView):
              (KHTMLView::~KHTMLView):
              (KHTMLView::resetScrollBars):
              (KHTMLView::init):
              (KHTMLView::clear):
              (KHTMLView::resizeEvent):
              (KHTMLView::initScrollBars):
              (KHTMLView::layout):
              (KHTMLView::updateDashboardRegions):
              (KHTMLView::viewportMousePressEvent):
              (KHTMLView::viewportMouseDoubleClickEvent):
              (KHTMLView::viewportMouseMoveEvent):
              (KHTMLView::viewportMouseReleaseEvent):
              (KHTMLView::keyPressEvent):
              (KHTMLView::contentsContextMenuEvent):
              (KHTMLView::dispatchDragEvent):
              (KHTMLView::focusNextPrevNode):
              (KHTMLView::mediaType):
              (KHTMLView::setScrollBarsMode):
              (KHTMLView::restoreScrollBar):
              (KHTMLView::viewportWheelEvent):
              * khtml/khtmlview.h:
              * khtml/misc/decoder.cpp:
              (Decoder::setEncoding):
              (Decoder::decode):
              (Decoder::flush):
              * khtml/misc/decoder.h:
              * khtml/misc/helper.cpp:
              (khtml::findWordBoundary):
              (khtml::nextWordFromIndex):
              (khtml::findSentenceBoundary):
              (khtml::nextSentenceFromIndex):
              * khtml/misc/helper.h:
              * khtml/misc/loader.cpp:
              (CachedObject::~CachedObject):
              (CachedImageCallback::clear):
              (CachedImage::CachedImage):
              (CachedImage::tiled_pixmap):
              (CachedImage::pixmap):
              (CachedImage::setShowAnimations):
              (CachedImage::clear):
              (CachedImage::data):
              (CachedImage::error):
              (DocLoader::DocLoader):
              (DocLoader::requestImage):
              (DocLoader::requestStyleSheet):
              (DocLoader::requestScript):
              (DocLoader::requestXSLStyleSheet):
              (DocLoader::requestXBLDocument):
              (Loader::Loader):
              (Loader::~Loader):
              (Loader::servePendingRequests):
              (Loader::slotFinished):
              (Loader::slotData):
              (Loader::numRequests):
              (Loader::cancelRequests):
              (Loader::removeBackgroundDecodingRequest):
              (Cache::init):
              (Cache::requestImage):
              (Cache::requestStyleSheet):
              (Cache::requestScript):
              (Cache::requestXSLStyleSheet):
              (Cache::requestXBLDocument):
              * khtml/misc/loader.h:
              (khtml::CachedObject::CachedObject):
              * khtml/misc/stringit.h:
              (khtml::TokenizerSubstring::TokenizerSubstring):
              * khtml/rendering/render_applet.cpp:
              (RenderApplet::RenderApplet):
              (RenderApplet::layout):
              (RenderEmptyApplet::RenderEmptyApplet):
              (RenderEmptyApplet::layout):
              * khtml/rendering/render_applet.h:
              * khtml/rendering/render_canvas.cpp:
              (RenderCanvas::setBestTruncatedAt):
              * khtml/rendering/render_canvas.h:
              (khtml::RenderCanvas::printImages):
              * khtml/rendering/render_container.cpp:
              (RenderContainer::addChild):
              (RenderContainer::removeChildNode):
              (RenderContainer::appendChildNode):
              (RenderContainer::insertChildNode):
              * khtml/rendering/render_flexbox.cpp:
              (khtml::RenderFlexibleBox::layoutVerticalBox):
              * khtml/rendering/render_flow.cpp:
              (RenderFlow::paintLines):
              (RenderFlow::paintFocusRing):
              * khtml/rendering/render_flow.h:
              * khtml/rendering/render_form.cpp:
              (RenderFormElement::baselinePosition):
              (RenderFormElement::setStyle):
              (RenderFormElement::updateFromElement):
              (RenderFormElement::layout):
              (RenderLineEdit::RenderLineEdit):
              (RenderLineEdit::slotReturnPressed):
              (RenderLineEdit::addSearchResult):
              (RenderLineEdit::calcMinMaxWidth):
              (RenderLineEdit::setStyle):
              (RenderLineEdit::updateFromElement):
              (RenderFileButton::RenderFileButton):
              (RenderFileButton::calcMinMaxWidth):
              (RenderFileButton::slotClicked):
              (RenderFileButton::updateFromElement):
              (RenderFileButton::select):
              (ComboBoxWidget::event):
              (ComboBoxWidget::eventFilter):
              (RenderSelect::updateFromElement):
              (RenderSelect::layout):
              (RenderTextArea::RenderTextArea):
              (RenderTextArea::calcMinMaxWidth):
              (RenderTextArea::setStyle):
              (RenderTextArea::updateFromElement):
              (RenderTextArea::text):
              (RenderTextArea::selectionStart):
              (RenderTextArea::selectionEnd):
              (RenderTextArea::setSelectionStart):
              (RenderTextArea::setSelectionEnd):
              (RenderTextArea::setSelectionRange):
              * khtml/rendering/render_form.h:
              (khtml::RenderFormElement::intrinsicMargin):
              (khtml::RenderLineEdit::canHaveIntrinsicMargins):
              (khtml::RenderSelect::canHaveIntrinsicMargins):
              (khtml::RenderTextArea::canHaveIntrinsicMargins):
              * khtml/rendering/render_frames.cpp:
              (RenderFrameSet::userResize):
              (RenderFrame::slotViewCleared):
              (RenderPartObject::layout):
              (RenderPartObject::slotViewCleared):
              * khtml/rendering/render_image.cpp:
              (RenderImage::setPixmap):
              (RenderImage::resetAnimation):
              (RenderImage::paint):
              (RenderImage::layout):
              * khtml/rendering/render_image.h:
              * khtml/rendering/render_layer.cpp:
              (khtml::RenderLayer::scrollToOffset):
              (khtml::RenderLayer::updateScrollInfoAfterLayout):
              (khtml::RenderLayer::paintScrollbars):
              (khtml::setClip):
              (khtml::RenderLayer::paintLayer):
              (khtml::RenderLayer::hitTest):
              * khtml/rendering/render_layer.h:
              * khtml/rendering/render_line.cpp:
              (khtml::InlineFlowBox::paintDecorations):
              * khtml/rendering/render_list.cpp:
              (RenderListMarker::paint):
              * khtml/rendering/render_list.h:
              (khtml::RenderListItem::markerStringValue):
              * khtml/rendering/render_object.cpp:
              (RenderObject::addFocusRingRects):
              (RenderObject::paintOutline):
              (RenderObject::setStyle):
              (RenderObject::removeFromObjectLists):
              (RenderObject::remove):
              (RenderObject::backslashAsCurrencySymbol):
              * khtml/rendering/render_object.h:
              * khtml/rendering/render_replaced.cpp:
              (RenderWidget::resizeWidget):
              (RenderWidget::sendConsumedMouseUp):
              (RenderWidget::setStyle):
              * khtml/rendering/render_replaced.h:
              * khtml/rendering/render_style.cpp:
              (StyleVisualData::StyleVisualData):
              (StyleCSS3NonInheritedData::operator==):
              (textSizeAdjust):
              (StyleCSS3InheritedData):
              (StyleCSS3InheritedData::operator==):
              (RenderStyle::diff):
              * khtml/rendering/render_style.h:
              (khtml::StyleVisualData::operator==):
              (khtml::RenderStyle::textSizeAdjust):
              (khtml::RenderStyle::setDashboardRegion):
              (khtml::RenderStyle::setTextSizeAdjust):
              * khtml/rendering/render_text.h:
              * khtml/xml/dom_docimpl.cpp:
              (DocumentImpl::DocumentImpl):
              (DocumentImpl::~DocumentImpl):
              (DocumentImpl::updateTitle):
              (DocumentImpl::recalcStyle):
              (DocumentImpl::updateRendering):
              (DocumentImpl::attach):
              (DocumentImpl::detach):
              (DocumentImpl::getAccObjectCache):
              (DocumentImpl::updateSelection):
              (DocumentImpl::implicitClose):
              (DocumentImpl::processHttpEquiv):
              (DocumentImpl::updateStyleSelector):
              (DocumentImpl::setFocusNode):
              * khtml/xml/dom_docimpl.h:
              * khtml/xml/dom_elementimpl.cpp:
              (ElementImpl::recalcStyle):
              * khtml/xml/dom_elementimpl.h:
              * khtml/xml/dom_nodeimpl.cpp:
              (DOM::NodeImpl::dispatchKeyEvent):
              (DOM::NodeImpl::createRendererIfNeeded):
              * khtml/xml/dom_position.cpp:
              * khtml/xml/dom_textimpl.h:
              * khtml/xml/dom_xmlimpl.h:
              * khtml/xml/xml_tokenizer.cpp:
              (khtml::Tokenizer::Tokenizer):
              (khtml::Tokenizer::finishedParsing):
              (khtml::XMLTokenizer::error):
              * khtml/xml/xml_tokenizer.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11271 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7811b780
  17. 16 Nov, 2005 1 commit
    • justing's avatar
      · cd0cc5de
      justing authored
              Reviewed by darin
              
              <rdar://problem/4108909> Editing delegate gets extra webViewDidChangeSelection: notifications
              
              Editing operations used to set an empty selection on the part before 
              doing work.  Doing this 1) isn't necessary* 2) creates an extra didChangeSelection 
              notification (4108909) 3) produces a strange shouldChangeSelection call after the 
              editing operation is complete, i.e. "shouldChangeSelection from null to ...?"
              
              There are still strange shouldChangeSelection calls after this change. For example, 
              after a delete, the selection before the delete no longer exists, so it probably 
              doesn't make sense to ask the delegate if WebKit shouldChangeSelection.  This is filed 
              as 4343068.
              
              * This was added on 2004-09-28 in order to mark misspellings in the selection to 
              be operated on (marking misspellings is a side effect of setting a selection).  
              Misspellings in the old selection are still marked, but not until after the operation 
              is complete.  Since some editing operations remove the selection from the document 
              (i.e. delete or undo-typing), respondToChangedSelection no longer assumes that the old 
              selection is in the document.
              
              Updated layout tests to reflect this change.
              
              * khtml/editing/edit_command.cpp:
              (khtml::EditCommand::EditCommand): Don't set the part's selection to empty before editing.
              (khtml::EditCommand::apply): Ditto.
              (khtml::EditCommand::unapply): Ditto.
              (khtml::EditCommand::reapply): Ditto.
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::respondToChangedSelection): Don't assume that the old selection is still in the document.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11223 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      cd0cc5de
  18. 14 Nov, 2005 2 commits
    • justing's avatar
      Reviewed by harrison · b3eed1ca
      justing authored
              <rdar://problem/4180820> Erroneous spacing between lines introduced on paste
      
              Updated layout test results in editing/style
              Added layout test in editing/pasteboard
      
              * khtml/css/css_valueimpl.cpp:
              Fixed a comment.
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
              Don't use clones of paragraphs already in the document to hold paragraph
              contents, since they are likely to introduce unwanted styles, just use
              a generic paragraph element.  It's less likely, but still possible that a generic
              paragraph element will have unwanted style, so we may want to eventually
              use class=Apple-style-block.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11188 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b3eed1ca
    • harrison's avatar
      Reviewed by Darin. · be11d7ec
      harrison authored
              <rdar://problem/4337532> Paragraph concatenation fails
      
              Updated editing/deleting tests to correctly check this behavior.
      
              * khtml/editing/delete_selection_command.cpp:
              (khtml::DeleteSelectionCommand::initializePositionData):
              Remove erroneous check for isStartOfParagraph(visibleEnd) when deciding whether to clear m_mergeBlocksAfterDelete.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11186 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      be11d7ec
  19. 09 Nov, 2005 1 commit
    • harrison's avatar
      Reviewed by Justin. · 74ab1547
      harrison authored
              <rdar://problem/4313925> Denver Regression: Mail: "TAB+paste+insert before" actually inserts after the pasted text
      
              - added tab span editing functions in composite_edit_command.cpp
              - called them from insertText, insertLineBreak, and replaceSelection commands
              - also exposed some handy tab span funcs from htmlediting.cpp
      
              Tests added in editing/insertion and editing/pasteboard.
      
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::positionOutsideTabSpan):
              (khtml::CompositeEditCommand::insertNodeAtTabSpanPosition):
              * khtml/editing/composite_edit_command.h:
              * khtml/editing/htmlediting.cpp:
              (khtml::positionBeforeNode):
              (khtml::positionAfterNode):
              (khtml::tabSpanNode):
              (khtml::positionBeforeTabSpan):
              * khtml/editing/htmlediting.h:
              * khtml/editing/insert_line_break_command.cpp:
              (khtml::InsertLineBreakCommand::doApply):
              * khtml/editing/insert_text_command.cpp:
              (khtml::InsertTextCommand::prepareForTextInsertion):
              * khtml/editing/replace_selection_command.cpp:
              (khtml::ReplaceSelectionCommand::doApply):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11100 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      74ab1547
  20. 08 Nov, 2005 1 commit
    • mjs's avatar
      LayoutTests: · 3bd301c4
      mjs authored
              Reviewed by Eric, Geoff and Darin.
      
      	- added test cases for <rdar://problem/4118258> XML DOM trees freed prematurely unless reference held to document node (causes crash)
      
      	Also updated the GC tests to try a little harder to trigger GC,
      	the old way might not work as well with the reworking of SimpleNumber.
      
              * fast/dom/gc-1.html:
              * fast/dom/gc-2.html:
              * fast/dom/gc-3.html:
              * fast/dom/gc-5.html:
              * fast/dom/gc-6-expected.txt: Added.
              * fast/dom/gc-6.html: Added.
              * fast/dom/gc-7-expected.txt: Added.
              * fast/dom/gc-7.html: Added.
      
      WebCore:
      
              Reviewed by Eric, Geoff and Darin.
      
      	- fixed <rdar://problem/4118258> XML DOM trees freed prematurely unless reference held to document node (causes crash)
      
      	I changed the design for how DOM nodes maintain their reference to
      	the document. Instead of using DocumentPtr, an indirect reference
      	which would go null in a clean way when the document is destroyed,
      	they now have a different strategy.
      
      	Nodes that belong to the document now hold a special kind of
      	reference on the document - a "self only reference". When a
      	document has no regular references but still has self-only
      	references, it won't be destroyed, but it will drop all its
      	children. This allows detached nodees to still have a valid
      	document reference, but they won't keep the rest of the DOM alive
      	or cause circular references.
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::toRange):
              * khtml/editing/visible_position.cpp:
              (khtml::makeRange):
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::range):
              (khtml::SimplifiedBackwardsTextIterator::range):
              * khtml/html/html_baseimpl.cpp:
              (HTMLBodyElementImpl::HTMLBodyElementImpl):
              (HTMLFrameElementImpl::HTMLFrameElementImpl):
              (HTMLFrameSetElementImpl::HTMLFrameSetElementImpl):
              (HTMLHeadElementImpl::HTMLHeadElementImpl):
              (HTMLHtmlElementImpl::HTMLHtmlElementImpl):
              (HTMLIFrameElementImpl::HTMLIFrameElementImpl):
              * khtml/html/html_baseimpl.h:
              * khtml/html/html_blockimpl.cpp:
              (HTMLBlockquoteElementImpl::HTMLBlockquoteElementImpl):
              (HTMLDivElementImpl::HTMLDivElementImpl):
              (HTMLHRElementImpl::HTMLHRElementImpl):
              (HTMLHeadingElementImpl::HTMLHeadingElementImpl):
              (HTMLParagraphElementImpl::HTMLParagraphElementImpl):
              (HTMLPreElementImpl::HTMLPreElementImpl):
              (HTMLMarqueeElementImpl::HTMLMarqueeElementImpl):
              * khtml/html/html_blockimpl.h:
              * khtml/html/html_canvasimpl.cpp:
              (HTMLCanvasElementImpl::HTMLCanvasElementImpl):
              * khtml/html/html_canvasimpl.h:
              * khtml/html/html_documentimpl.cpp:
              (DOM::HTMLDocumentImpl::createTokenizer):
              (DOM::HTMLDocumentImpl::determineParseMode):
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::HTMLElementImpl):
              (HTMLElementImpl::createContextualFragment):
              (HTMLElementImpl::setInnerText):
              (HTMLElementImpl::setOuterText):
              * khtml/html/html_elementimpl.h:
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::HTMLFormElementImpl):
              (DOM::HTMLGenericFormElementImpl::HTMLGenericFormElementImpl):
              (DOM::HTMLButtonElementImpl::HTMLButtonElementImpl):
              (DOM::HTMLFieldSetElementImpl::HTMLFieldSetElementImpl):
              (DOM::HTMLInputElementImpl::HTMLInputElementImpl):
              (DOM::HTMLLabelElementImpl::HTMLLabelElementImpl):
              (DOM::HTMLLegendElementImpl::HTMLLegendElementImpl):
              (DOM::HTMLSelectElementImpl::HTMLSelectElementImpl):
              (DOM::HTMLKeygenElementImpl::HTMLKeygenElementImpl):
              (DOM::HTMLOptGroupElementImpl::HTMLOptGroupElementImpl):
              (DOM::HTMLOptionElementImpl::HTMLOptionElementImpl):
              (DOM::HTMLOptionElementImpl::setText):
              (DOM::HTMLTextAreaElementImpl::HTMLTextAreaElementImpl):
              (DOM::HTMLIsIndexElementImpl::HTMLIsIndexElementImpl):
              * khtml/html/html_formimpl.h:
              * khtml/html/html_headimpl.cpp:
              (HTMLBaseElementImpl::HTMLBaseElementImpl):
              (HTMLLinkElementImpl::HTMLLinkElementImpl):
              (HTMLMetaElementImpl::HTMLMetaElementImpl):
              (HTMLScriptElementImpl::HTMLScriptElementImpl):
              (HTMLStyleElementImpl::HTMLStyleElementImpl):
              (HTMLTitleElementImpl::HTMLTitleElementImpl):
              * khtml/html/html_headimpl.h:
              * khtml/html/html_imageimpl.cpp:
              (HTMLImageElementImpl::HTMLImageElementImpl):
              (HTMLMapElementImpl::HTMLMapElementImpl):
              (HTMLAreaElementImpl::HTMLAreaElementImpl):
              * khtml/html/html_imageimpl.h:
              * khtml/html/html_inlineimpl.cpp:
              (DOM::HTMLAnchorElementImpl::HTMLAnchorElementImpl):
              (DOM::HTMLBRElementImpl::HTMLBRElementImpl):
              (DOM::HTMLFontElementImpl::HTMLFontElementImpl):
              (DOM::HTMLModElementImpl::HTMLModElementImpl):
              (DOM::HTMLQuoteElementImpl::HTMLQuoteElementImpl):
              * khtml/html/html_inlineimpl.h:
              * khtml/html/html_listimpl.h:
              (DOM::HTMLUListElementImpl::HTMLUListElementImpl):
              (DOM::HTMLDirectoryElementImpl::HTMLDirectoryElementImpl):
              (DOM::HTMLMenuElementImpl::HTMLMenuElementImpl):
              (DOM::HTMLOListElementImpl::HTMLOListElementImpl):
              (DOM::HTMLLIElementImpl::HTMLLIElementImpl):
              (DOM::HTMLDListElementImpl::HTMLDListElementImpl):
              * khtml/html/html_miscimpl.cpp:
              (DOM::HTMLBaseFontElementImpl::HTMLBaseFontElementImpl):
              * khtml/html/html_miscimpl.h:
              * khtml/html/html_objectimpl.cpp:
              (DOM::HTMLAppletElementImpl::HTMLAppletElementImpl):
              (DOM::HTMLEmbedElementImpl::HTMLEmbedElementImpl):
              (DOM::HTMLObjectElementImpl::HTMLObjectElementImpl):
              (DOM::HTMLParamElementImpl::HTMLParamElementImpl):
              * khtml/html/html_objectimpl.h:
              * khtml/html/html_tableimpl.cpp:
              (DOM::HTMLTableElementImpl::HTMLTableElementImpl):
              (DOM::HTMLTableElementImpl::createTHead):
              (DOM::HTMLTableElementImpl::createTFoot):
              (DOM::HTMLTableElementImpl::createCaption):
              (DOM::HTMLTableElementImpl::insertRow):
              (DOM::HTMLTableSectionElementImpl::HTMLTableSectionElementImpl):
              (DOM::HTMLTableSectionElementImpl::insertRow):
              (DOM::HTMLTableRowElementImpl::insertCell):
              (DOM::HTMLTableCellElementImpl::HTMLTableCellElementImpl):
              (DOM::HTMLTableColElementImpl::HTMLTableColElementImpl):
              * khtml/html/html_tableimpl.h:
              (DOM::HTMLTablePartElementImpl::HTMLTablePartElementImpl):
              (DOM::HTMLTableRowElementImpl::HTMLTableRowElementImpl):
              (DOM::HTMLTableCaptionElementImpl::HTMLTableCaptionElementImpl):
              * khtml/html/htmlfactory.cpp:
              (DOM::htmlConstructor):
              (DOM::headConstructor):
              (DOM::bodyConstructor):
              (DOM::baseConstructor):
              (DOM::linkConstructor):
              (DOM::metaConstructor):
              (DOM::styleConstructor):
              (DOM::titleConstructor):
              (DOM::frameConstructor):
              (DOM::framesetConstructor):
              (DOM::iframeConstructor):
              (DOM::formConstructor):
              (DOM::buttonConstructor):
              (DOM::inputConstructor):
              (DOM::isindexConstructor):
              (DOM::fieldsetConstructor):
              (DOM::labelConstructor):
              (DOM::legendConstructor):
              (DOM::optgroupConstructor):
              (DOM::optionConstructor):
              (DOM::selectConstructor):
              (DOM::textareaConstructor):
              (DOM::dlConstructor):
              (DOM::ulConstructor):
              (DOM::olConstructor):
              (DOM::dirConstructor):
              (DOM::menuConstructor):
              (DOM::liConstructor):
              (DOM::blockquoteConstructor):
              (DOM::divConstructor):
              (DOM::headingConstructor):
              (DOM::hrConstructor):
              (DOM::paragraphConstructor):
              (DOM::preConstructor):
              (DOM::basefontConstructor):
              (DOM::fontConstructor):
              (DOM::modConstructor):
              (DOM::anchorConstructor):
              (DOM::imageConstructor):
              (DOM::mapConstructor):
              (DOM::areaConstructor):
              (DOM::canvasConstructor):
              (DOM::appletConstructor):
              (DOM::embedConstructor):
              (DOM::objectConstructor):
              (DOM::paramConstructor):
              (DOM::scriptConstructor):
              (DOM::tableConstructor):
              (DOM::tableCaptionConstructor):
              (DOM::tableColConstructor):
              (DOM::tableRowConstructor):
              (DOM::tableCellConstructor):
              (DOM::tableSectionConstructor):
              (DOM::brConstructor):
              (DOM::quoteConstructor):
              (DOM::marqueeConstructor):
              (DOM::HTMLElementFactory::createHTMLElement):
              * khtml/html/htmlparser.cpp:
              (HTMLParser::HTMLParser):
              (HTMLParser::~HTMLParser):
              * khtml/html/htmlparser.h:
              (HTMLParser::doc):
              * khtml/html/htmltokenizer.cpp:
              (khtml::HTMLTokenizer::HTMLTokenizer):
              (khtml::HTMLTokenizer::parseTag):
              (khtml::parseHTMLDocumentFragment):
              * khtml/html/htmltokenizer.h:
              * khtml/misc/loader.h:
              * khtml/misc/shared.h:
              (khtml::TreeShared::~TreeShared):
              (khtml::TreeShared::destroy):
              (khtml::TreeShared::deref):
              * khtml/xbl/xbl_tokenizer.cpp:
              (XBL::XBLTokenHandler::XBLTokenHandler):
              * khtml/xbl/xbl_tokenizer.h:
              (XBL::):
              * khtml/xml/dom2_rangeimpl.cpp:
              (DOM::RangeImpl::RangeImpl):
              (DOM::RangeImpl::setStart):
              (DOM::RangeImpl::setEnd):
              (DOM::RangeImpl::processContents):
              (DOM::RangeImpl::cloneRange):
              (DOM::RangeImpl::setStartAfter):
              (DOM::RangeImpl::setEndBefore):
              (DOM::RangeImpl::setEndAfter):
              (DOM::RangeImpl::setStartBefore):
              (DOM::rangeOfContents):
              * khtml/xml/dom2_rangeimpl.h:
              * khtml/xml/dom_docimpl.cpp:
              (DOMImplementationImpl::createDocumentType):
              (DOMImplementationImpl::createDocument):
              (DocumentImpl::DocumentImpl):
              (DocumentImpl::destroy):
              (DocumentImpl::~DocumentImpl):
              (DocumentImpl::createDocumentFragment):
              (DocumentImpl::createTextNode):
              (DocumentImpl::createComment):
              (DocumentImpl::createCDATASection):
              (DocumentImpl::createProcessingInstruction):
              (DocumentImpl::createEntityReference):
              (DocumentImpl::createEditingTextNode):
              (DocumentImpl::createElementNS):
              (DocumentImpl::setTitle):
              (DocumentImpl::removeTitle):
              (DocumentImpl::createRange):
              (DocumentImpl::createTokenizer):
              (DocumentImpl::implicitClose):
              (DocumentImpl::setHoverNode):
              (DocumentImpl::setActiveNode):
              (DocumentImpl::setFocusNode):
              (DocumentImpl::createAttributeNS):
              (DocumentFragmentImpl::DocumentFragmentImpl):
              (DocumentFragmentImpl::cloneNode):
              (DocumentTypeImpl::DocumentTypeImpl):
              * khtml/xml/dom_docimpl.h:
              (DOM::DocumentImpl::selfOnlyRef):
              (DOM::DocumentImpl::selfOnlyDeref):
              (DOM::DocumentImpl::focusNode):
              (DOM::DocumentImpl::hoverNode):
              (DOM::DocumentImpl::activeNode):
              * khtml/xml/dom_elementimpl.cpp:
              (AttributeImpl::allocateImpl):
              (AttrImpl::AttrImpl):
              (AttrImpl::cloneNode):
              (ElementImpl::ElementImpl):
              (StyledElementImpl::StyledElementImpl):
              * khtml/xml/dom_elementimpl.h:
              * khtml/xml/dom_nodeimpl.cpp:
              (DOM::NodeImpl::NodeImpl):
              (DOM::NodeImpl::setDocument):
              (DOM::NodeImpl::~NodeImpl):
              (DOM::NodeImpl::dispatchEvent):
              (DOM::NodeImpl::dispatchWindowEvent):
              (DOM::NodeImpl::dispatchMouseEvent):
              (DOM::NodeImpl::checkAddChild):
              (DOM::ContainerNodeImpl::ContainerNodeImpl):
              (DOM::ContainerNodeImpl::removeAllChildren):
              (DOM::ContainerNodeImpl::~ContainerNodeImpl):
              * khtml/xml/dom_nodeimpl.h:
              (DOM::NodeImpl::inDocument):
              (DOM::NodeImpl::getDocument):
              * khtml/xml/dom_textimpl.cpp:
              (CharacterDataImpl::CharacterDataImpl):
              (CommentImpl::CommentImpl):
              (TextImpl::TextImpl):
              (TextImpl::createNew):
              (CDATASectionImpl::CDATASectionImpl):
              (CDATASectionImpl::createNew):
              (EditingTextImpl::EditingTextImpl):
              * khtml/xml/dom_textimpl.h:
              * khtml/xml/dom_xmlimpl.cpp:
              (DOM::EntityImpl::EntityImpl):
              (DOM::EntityReferenceImpl::EntityReferenceImpl):
              (DOM::EntityReferenceImpl::cloneNode):
              (DOM::NotationImpl::NotationImpl):
              (DOM::ProcessingInstructionImpl::ProcessingInstructionImpl):
              (DOM::ProcessingInstructionImpl::cloneNode):
              * khtml/xml/dom_xmlimpl.h:
              * khtml/xml/xml_tokenizer.cpp:
              (khtml::XMLTokenizer::XMLTokenizer):
              (khtml::XMLTokenizer::startElementNs):
              (khtml::XMLTokenizer::enterText):
              (khtml::XMLTokenizer::processingInstruction):
              (khtml::XMLTokenizer::cdataBlock):
              (khtml::XMLTokenizer::comment):
              (khtml::XMLTokenizer::internalSubset):
              (khtml::XMLTokenizer::finish):
              (khtml::XMLTokenizer::insertErrorMessageBlock):
              (khtml::XMLTokenizer::executeScripts):
              (khtml::newXMLTokenizer):
              * khtml/xml/xml_tokenizer.h:
              * khtml/xsl/xslt_processorimpl.cpp:
              (DOM::createFragmentFromSource):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11096 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3bd301c4
  21. 07 Nov, 2005 1 commit
    • justing's avatar
      Reviewed by harrison · 140053e8
      justing authored
              <rdar://problem/4125131> REGRESSION (Mail): after certain steps,
              extra blank line appears when typing past end of reply-quoted text
              <rdar://problem/4024996> Applying block styles can cause assertion
              failure in inline style removal
      
              Prevent VisiblePositions at [br, 1] at the end of root editable elements.
      
              Layout tests added:
              * inserting/insert-at-end-01.html
              * inserting/insert-at-end-02.html
      
              Layout tests changed (fixed):
              * editing/deleting/delete-br-011.html
              * editing/deleting/delete-at-paragraph-boundaries-011.html
              * editing/inserting/insert-3786362-fix.html
      
              * khtml/editing/apply_style_command.cpp:
              (khtml::ApplyStyleCommand::applyInlineStyle):
              Do the layout before calculating start/end positions, not after,
              since upstream/downstream need to know who is rendered/unrendered.
              Don't do equivalentRangeCompliantPosition() on the start position
              in addition to downstream(), since it a) is confusing, b) frequently
              causes start/end to be equal, making removeInlineStyle a no-op and
              c) causes an assertion to fire.
              Only reset start/end using endingSelection() if splitTextElement was
              needed, since reseting start/end negates the work done above to swap
              start/end if they are backwards.
              When the start position points off the end of a node, that node should
              be skipped in all cases, not just the start.node() != end.node() case.
      
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::appendBlockPlaceholder):
              (khtml::CompositeEditCommand::insertBlockPlaceholder):
              Placeholders should be allowed in nodes that aren't blockFlow, for example,
              deleting the b in <div><span>b</span></div> should insert a placeholder.
              The assertion here should really be something like isBlockFlow ||
              isInlineFlow, but I can't assert those until deletion improves (4244964).
      
              * khtml/editing/delete_selection_command.cpp:
              (khtml::DeleteSelectionCommand::calculateTypingStyleAfterDelete):
              Don't try to select the placeholder when applying style to it.  It
              isn't necessary, and it's now impossible to do at the end of the
              document in any case.
      
              * khtml/editing/visible_position.cpp:
              (khtml::VisiblePosition::initDownstream):
              Don't create VisiblePositions at [br, 1] at the end of editable blocks, it
              produces strange/inconsistent editing behavior at the end of the document.
      
              * khtml/khtml_part.cpp: Fixed a comment.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11086 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      140053e8
  22. 03 Nov, 2005 1 commit
    • justing's avatar
      Bugzilla 5604: plainText (visible_text.cpp) performance improvement · 63a41815
      justing authored
              Reviewed by justin and darin
      
              Optimized plainText for a ~100% speedup in most cases.
      
              No test cases added, change only effects performance.
      
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::rangeLength): Removed an extraneous comment.
              (khtml::plainText): The length of the string to be created was
              pre-calculated to avoid the expense of many QString::append() calls.
              Removed this since TextIterator::advance() is much more expensive
              than append.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11048 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      63a41815
  23. 02 Nov, 2005 2 commits
    • harrison's avatar
      Reviewed by Justin. · a34f5242
      harrison authored
              Tests added in editing/inserting.
      
              <rdar://problem/4017861> in reply, extra line is inserted after pressing return on blank quoted line
              Also, did some minor cleanup.
      
              * khtml/editing/break_blockquote_command.cpp:
              (khtml::BreakBlockquoteCommand::BreakBlockquoteCommand):
              (khtml::BreakBlockquoteCommand::doApply):
              Make sure not to clone parent of skipped BR unless there are siblings to move over.
              * khtml/editing/break_blockquote_command.h:
              * khtml/editing/jsediting.cpp:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11030 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a34f5242
    • hyatt's avatar
      Fix for 5587, implement pre-wrap and pre-line white-space values. · dca76e92
      hyatt authored
              Reviewed by mjs
      
      	Tests Added in fast/text/whitespace
      
              * khtml/css/css_computedstyle.cpp:
              (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
              * khtml/css/cssparser.cpp:
              (CSSParser::parseValue):
              * khtml/css/cssstyleselector.cpp:
              (khtml::CSSStyleSelector::applyProperty):
              * khtml/css/cssvalues.in:
              * khtml/css/html4.css:
              * khtml/ecma/kjs_html.cpp:
              (KJS::HTMLElement::preGetter):
              (KJS::HTMLElement::preSetter):
              * khtml/ecma/kjs_html.h:
              (KJS::HTMLElement::):
              * khtml/editing/visible_text.cpp:
              (khtml::TextIterator::handleTextNode):
              * khtml/editing/visible_units.cpp:
              (khtml::startOfParagraph):
              (khtml::endOfParagraph):
              * khtml/html/html_blockimpl.cpp:
              (HTMLPreElementImpl::mapToEntry):
              (HTMLPreElementImpl::parseMappedAttribute):
              (HTMLPreElementImpl::wrap):
              (HTMLPreElementImpl::setWrap):
              * khtml/html/html_blockimpl.h:
              * khtml/rendering/bidi.cpp:
              (khtml::checkMidpoints):
              (khtml::RenderBlock::computeHorizontalPositionsForLine):
              (khtml::RenderBlock::layoutInlineChildren):
              (khtml::RenderBlock::skipNonBreakingSpace):
              (khtml::RenderBlock::skipWhitespace):
              (khtml::RenderBlock::findNextLineBreak):
              * khtml/rendering/render_block.cpp:
              (khtml:::RenderFlow):
              (khtml::RenderBlock::setStyle):
              (khtml::RenderBlock::calcMinMaxWidth):
              (khtml::stripTrailingSpace):
              (khtml::RenderBlock::calcInlineMinMaxWidth):
              (khtml::RenderBlock::dump):
              * khtml/rendering/render_block.h:
              * khtml/rendering/render_layer.h:
              (khtml::):
              * khtml/rendering/render_line.cpp:
              (khtml::shouldDrawDecoration):
              * khtml/rendering/render_object.cpp:
              (RenderObject::tabWidth):
              * khtml/rendering/render_style.h:
              (khtml::):
              (khtml::RenderStyle::autoWrap):
              (khtml::RenderStyle::preserveNewline):
              (khtml::RenderStyle::collapseWhiteSpace):
              (khtml::RenderStyle::isCollapsibleWhiteSpace):
              (khtml::RenderStyle::breakOnlyAfterWhiteSpace):
              * khtml/rendering/render_table.cpp:
              (RenderTableCell::calcMinMaxWidth):
              * khtml/rendering/render_text.cpp:
              (RenderText::caretRect):
              (RenderText::trimmedMinMaxWidth):
              (RenderText::calcMinMaxWidth):
              (RenderText::width):
              * khtml/xml/dom_elementimpl.h:
              (DOM::):
              * khtml/xml/dom_textimpl.cpp:
              (TextImpl::rendererIsNeeded):
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::attributedString):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11028 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      dca76e92
  24. 01 Nov, 2005 2 commits
    • justing's avatar
      Reviewed by harrison · e9d34437
      justing authored
              Tweaked my previous fix for caret movement while scrolling.
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::SelectionController): Forgot to copy m_caretPositionOnLayout.
              (khtml::SelectionController::operator=): Ditto.
              (khtml::SelectionController::layout): Initialize m_caretPositionOnLayout to a dummy value when the selection isNone.
              * khtml/editing/SelectionController.h: Tweaked my comment.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11022 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e9d34437
    • justing's avatar
      Reviewed by harrison · de678427
      justing authored
              Fixed <rdar://problem/3690705> caret does not move when scrolling overflow: auto editable area
      
              * manual-tests/caretScrolling.html: Added.
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::SelectionController): Removed the unused expectedVisibleRect
              (khtml::SelectionController::operator=): Ditto.
              (khtml::SelectionController::layout): Save the caret's absolute position on layout.
              (khtml::SelectionController::caretRect): Adjust the returned caret rect for offset due to scrolling since the last layout.
              (khtml::SelectionController::paintCaret):
              * khtml/editing/SelectionController.h:
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::nextKeyViewInFrame): Small tweak to a previous change.
              * kwq/KWQRect.h:
              (QRect::moveTopLeft): Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@11018 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      de678427
  25. 31 Oct, 2005 1 commit
  26. 27 Oct, 2005 1 commit
    • eseidel's avatar
      Bug #: 5404 · 363bc0d4
      eseidel authored
      Submitted by: eseidel
      Reviewed by: mjs & darin
              Various fixes to createMarkup and toString code to properly
              support serialization of XML.
              http://bugzilla.opendarwin.org/show_bug.cgi?id=5404
      
              * khtml/editing/markup.cpp:
              (khtml::startMarkup):
              (khtml::doesHTMLForbidEndTag):
              (khtml::shouldSelfClose):
              (khtml::endMarkup):
              (khtml::markup):
              (khtml::createFragmentFromMarkup):
              (khtml::createMarkup):
              * khtml/html/html_elementimpl.cpp:
              (HTMLElementImpl::createContextualFragment):
              (HTMLElementImpl::toString):
              * khtml/html/htmltokenizer.cpp:
              (khtml::parseHTMLDocumentFragment):
              * khtml/html/htmltokenizer.h:
              * khtml/xml/dom_xmlimpl.cpp:
              (DOM::ProcessingInstructionImpl::ProcessingInstructionImpl):
              (DOM::ProcessingInstructionImpl::~ProcessingInstructionImpl):
              (DOM::ProcessingInstructionImpl::toString):
              * khtml/xml/dom_xmlimpl.h:
              (DOM::ProcessingInstructionImpl::sheet):
              (DOM::ProcessingInstructionImpl::setStyleSheet):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10978 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      363bc0d4
  27. 07 Oct, 2005 1 commit
    • harrison's avatar
      Reviewed by Justin. · 17bab067
      harrison authored
              "<rdar://problem/4064017> Safari crashes at -[WebCoreBridge firstRectForDOMRange:] + 92"
      
              * khtml/editing/delete_selection_command.cpp:
              (khtml::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
              Do not insert placeholder if selection ends at a BR.
      
              (khtml::DeleteSelectionCommand::handleGeneralDelete):
              No need to preserve starting BR because insertPlaceholderForAncestorBlockContent already did.
      
              * khtml/xml/dom_position.cpp:
              (DOM::Position::upstream):
              (DOM::Position::downstream):
              Fixed to return original position instead of invisible position when no suitable position found upstream.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10786 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      17bab067
  28. 06 Oct, 2005 1 commit
    • justing's avatar
      Reviewed by harrison · c268ef22
      justing authored
              <rdar://problem/4073133> Tabbing between editable elements leads to loss of keyboard focus
              <rdar://problem/3690719> "Select All" when in an editable area selects the whole containing document
              <rdar://problem/3690703> selection is allowed to span editable area and rest of document
      
              * khtml/editing/SelectionController.cpp:
              (khtml::SelectionController::adjustExtentForEditableContent):
              Added, ensures that a selection cannot cross an editable/non-editable boundry.
              (khtml::SelectionController::validate):
              * khtml/editing/SelectionController.h:
              * khtml/editing/visible_position.h:
              * khtml/khtml_part.cpp:
              (KHTMLPart::setSelection):
              (KHTMLPart::setFocusNodeIfNeeded):
              (KHTMLPart::selectAll):
              Select only the contents of the rootEditableElement, if it exists.  Also now calls the shouldChangeSelection delegate method.
              * khtml/xml/dom_nodeimpl.cpp:
              (DOM::ContainerNodeImpl::setFocus): Clicking on an editable element used to change the selection twice.
              * kwq/KWQKHTMLPart.mm:
              (KWQKHTMLPart::nextKeyViewInFrame): Select All when tabbing to an editable element, to match <textarea>s
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10781 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c268ef22
  29. 03 Oct, 2005 1 commit
    • mjs's avatar
      JavaScriptCore: · b64c50a2
      mjs authored
              Reviewed by Darin.
      
      	<rdar://problem/4283967> REGRESSION: 3% regression on PLT from new FastMalloc
      	http://bugzilla.opendarwin.org/show_bug.cgi?id=5243
      
      	A number of optimizations to the new threadsafe malloc that make it actually as fast
      	as dlmalloc (I measured wrong before) and as memory-efficient as the system malloc.
      
      	- use fastMalloc for everything - it now gets applied to all new/delete allocations
      	via a private inline operator new that is now included into every file via config.h.
      
      	- tweaked some of the numeric parameters for size classes and amount of wasted memory
      	allowed per allocation - this saves on memory use and consequently improves speed.
      
      	- so long as the allocator is not being used on background threads, get the per-thread
      	cache from a global variable instead of from pthread_getspecific, since the latter is slow.
      
      	- inline more functions, and force the ones GCC refuses to inline with
      	attribute(always_inline), nearly all of these have one call site so inlining them has
      	to be a win.
      
      	- use some tricks to calculate allocation size more efficiently and fewer times for small
      	allocations, to avoid hitting the huge size table array.
      
      	- avoid hitting the per-thread cache on code paths that don't need it.
      
      	- implement inline assembly version of spinlock for PowerPC (was already done for x86)
      
              * bindings/NP_jsobject.cpp:
              * bindings/c/c_class.cpp:
              * bindings/c/c_instance.cpp:
              * bindings/c/c_runtime.cpp:
              * bindings/c/c_utility.cpp:
              * bindings/jni/jni_class.cpp:
              * bindings/jni/jni_instance.cpp:
              * bindings/jni/jni_jsobject.cpp:
              * bindings/jni/jni_objc.mm:
              * bindings/jni/jni_runtime.cpp:
              * bindings/jni/jni_utility.cpp:
              * bindings/npruntime.cpp:
              * bindings/objc/WebScriptObject.mm:
              * bindings/objc/objc_class.mm:
              * bindings/objc/objc_instance.mm:
              * bindings/objc/objc_runtime.mm:
              * bindings/objc/objc_utility.mm:
              * bindings/runtime.cpp:
              * bindings/runtime_array.cpp:
              * bindings/runtime_method.cpp:
              * bindings/runtime_object.cpp:
              * bindings/runtime_root.cpp:
              * bindings/testbindings.cpp:
              * bindings/testbindings.mm:
              * kjs/array_object.cpp:
              (ArrayInstanceImp::ArrayInstanceImp):
              (ArrayInstanceImp::~ArrayInstanceImp):
              (ArrayInstanceImp::resizeStorage):
              * kjs/bool_object.cpp:
              * kjs/collector.cpp:
              (KJS::Collector::registerThread):
              * kjs/config.h:
              * kjs/debugger.cpp:
              * kjs/error_object.cpp:
              * kjs/function.cpp:
              * kjs/function_object.cpp:
              * kjs/identifier.cpp:
              (KJS::Identifier::rehash):
              * kjs/internal.cpp:
              (KJS::Parser::saveNewNode):
              (KJS::clearNewNodes):
              * kjs/interpreter.cpp:
              * kjs/lexer.cpp:
              (Lexer::doneParsing):
              (Lexer::makeIdentifier):
              (Lexer::makeUString):
              * kjs/list.cpp:
              * kjs/math_object.cpp:
              * kjs/nodes.cpp:
              * kjs/nodes.h:
              * kjs/nodes2string.cpp:
              * kjs/number_object.cpp:
              (integer_part_noexp):
              (char_sequence):
              * kjs/object.cpp:
              * kjs/object_object.cpp:
              * kjs/property_map.cpp:
              * kjs/property_slot.cpp:
              * kjs/protected_values.cpp:
              (KJS::ProtectedValues::rehash):
              * kjs/reference.cpp:
              * kjs/reference_list.cpp:
              * kjs/regexp.cpp:
              * kjs/regexp_object.cpp:
              * kjs/scope_chain.cpp:
              * kjs/scope_chain.h:
              * kjs/string_object.cpp:
              * kjs/testkjs.cpp:
              * kjs/ustring.h:
              * kjs/value.cpp:
              * kxmlcore/Assertions.mm:
              * kxmlcore/FastMalloc.cpp:
              (KXMLCore::InitSizeClasses):
              (KXMLCore::DLL_IsEmpty):
              (KXMLCore::DLL_Prepend):
              (KXMLCore::TCMalloc_Central_FreeList::Insert):
              (KXMLCore::TCMalloc_Central_FreeList::Remove):
              (KXMLCore::TCMalloc_Central_FreeList::Populate):
              (KXMLCore::TCMalloc_ThreadCache::Allocate):
              (KXMLCore::TCMalloc_ThreadCache::FetchFromCentralCache):
              (KXMLCore::fastMallocRegisterThread):
              (KXMLCore::TCMalloc_ThreadCache::GetCache):
              (KXMLCore::TCMalloc_ThreadCache::GetCacheIfPresent):
              (KXMLCore::TCMalloc_ThreadCache::CreateCacheIfNecessary):
              (KXMLCore::do_malloc):
              (KXMLCore::do_free):
              (KXMLCore::realloc):
              * kxmlcore/FastMalloc.h:
              (operator new):
              (operator delete):
              (operator new[]):
              (operator delete[]):
              * kxmlcore/HashTable.cpp:
              * kxmlcore/TCSpinLock.h:
              (TCMalloc_SpinLock::Lock):
              (TCMalloc_SpinLock::Unlock):
              (TCMalloc_SlowLock):
              * kxmlcore/TCSystemAlloc.cpp:
      
      WebCore:
      
              Reviewed by Darin.
      
      	<rdar://problem/4283967> REGRESSION: 3% regression on PLT from new FastMalloc
      	http://bugzilla.opendarwin.org/show_bug.cgi?id=5243
      
      	- use fastMalloc for everything - it now gets applied to all new/delete allocations
              via a private inline operator new that is now included into every file via config.h
      
              * WebCore.xcodeproj/project.pbxproj:
              * WebCorePrefix.h:
              * khtml/css/css_base.cpp:
              * khtml/css/css_base.h:
              * khtml/css/css_computedstyle.cpp:
              * khtml/css/css_ruleimpl.cpp:
              * khtml/css/css_stylesheetimpl.cpp:
              * khtml/css/css_valueimpl.cpp:
              * khtml/css/css_valueimpl.h:
              * khtml/css/csshelper.cpp:
              * khtml/css/cssparser.cpp:
              (ValueList::ValueList):
              (ValueList::~ValueList):
              (ValueList::addValue):
              (CSSParser::CSSParser):
              (CSSParser::~CSSParser):
              (CSSParser::setupParser):
              (CSSParser::addProperty):
              * khtml/css/cssstyleselector.cpp:
              * khtml/css/cssstyleselector.h:
              * khtml/dom/dom2_events.cpp:
              * khtml/dom/dom2_traversal.cpp:
              * khtml/dom/dom_misc.cpp:
              * khtml/dom/dom_string.cpp:
              * khtml/ecma/domparser.cpp:
              * khtml/ecma/kjs_binding.cpp:
              * khtml/ecma/kjs_css.cpp:
              * khtml/ecma/kjs_dom.cpp:
              * khtml/ecma/kjs_events.cpp:
              * khtml/ecma/kjs_html.cpp:
              (KJS::KJS::Context2DFunction::callAsFunction):
              (KJS::Gradient::~Gradient):
              (KJS::Gradient::addColorStop):
              (KJS::Gradient::colorStops):
              * khtml/ecma/kjs_navigator.cpp:
              * khtml/ecma/kjs_proxy.cpp:
              * khtml/ecma/kjs_range.cpp:
              * khtml/ecma/kjs_traversal.cpp:
              * khtml/ecma/kjs_views.cpp:
              * khtml/ecma/kjs_window.cpp:
              * khtml/ecma/xmlhttprequest.cpp:
              * khtml/ecma/xmlserializer.cpp:
              * khtml/editing/SelectionController.cpp:
              * khtml/editing/append_node_command.cpp:
              * khtml/editing/apply_style_command.cpp:
              * khtml/editing/break_blockquote_command.cpp:
              * khtml/editing/composite_edit_command.cpp:
              * khtml/editing/delete_from_text_node_command.cpp:
              * khtml/editing/delete_selection_command.cpp:
              * khtml/editing/edit_command.cpp:
              * khtml/editing/html_interchange.cpp:
              * khtml/editing/htmlediting.cpp:
              * khtml/editing/insert_into_text_node_command.cpp:
              * khtml/editing/insert_line_break_command.cpp:
              * khtml/editing/insert_node_before_command.cpp:
              * khtml/editing/insert_paragraph_separator_command.cpp:
              * khtml/editing/insert_text_command.cpp:
              * khtml/editing/join_text_nodes_command.cpp:
              * khtml/editing/jsediting.cpp:
              * khtml/editing/markup.cpp:
              * khtml/editing/merge_identical_elements_command.cpp:
              * khtml/editing/move_selection_command.cpp:
              * khtml/editing/rebalance_whitespace_command.cpp:
              * khtml/editing/remove_css_property_command.cpp:
              * khtml/editing/remove_node_attribute_command.cpp:
              * khtml/editing/remove_node_command.cpp:
              * khtml/editing/remove_node_preserving_children_command.cpp:
              * khtml/editing/replace_selection_command.cpp:
              * khtml/editing/set_node_attribute_command.cpp:
              * khtml/editing/split_element_command.cpp:
              * khtml/editing/split_text_node_command.cpp:
              * khtml/editing/split_text_node_containing_element.cpp:
              * khtml/editing/typing_command.cpp:
              * khtml/editing/visible_position.cpp:
              * khtml/editing/visible_range.cpp:
              * khtml/editing/visible_text.cpp:
              (khtml::CircularSearchBuffer::~CircularSearchBuffer):
              (khtml::CircularSearchBuffer::CircularSearchBuffer):
              * khtml/editing/visible_units.cpp:
              * khtml/editing/wrap_contents_in_dummy_span_command.cpp:
              * khtml/html/html_baseimpl.cpp:
              * khtml/html/html_blockimpl.cpp:
              * khtml/html/html_canvasimpl.cpp:
              * khtml/html/html_documentimpl.cpp:
              * khtml/html/html_elementimpl.cpp:
              * khtml/html/html_formimpl.cpp:
              * khtml/html/html_headimpl.cpp:
              * khtml/html/html_imageimpl.cpp:
              * khtml/html/html_inlineimpl.cpp:
              * khtml/html/html_listimpl.cpp:
              * khtml/html/html_miscimpl.cpp:
              * khtml/html/html_objectimpl.cpp:
              * khtml/html/html_tableimpl.cpp:
              * khtml/html/htmlfactory.cpp:
              * khtml/html/htmlnames.cpp:
              * khtml/html/htmlparser.cpp:
              * khtml/html/htmltokenizer.cpp:
              (khtml::HTMLTokenizer::enlargeBuffer):
              (khtml::HTMLTokenizer::enlargeScriptBuffer):
              * khtml/khtml_events.cpp:
              * khtml/khtml_part.cpp:
              * khtml/khtmlview.cpp:
              * khtml/misc/arena.cpp:
              * khtml/misc/arena.h:
              * khtml/misc/decoder.cpp:
              * khtml/misc/formdata.cpp:
              * khtml/misc/helper.cpp:
              * khtml/misc/loader.cpp:
              * khtml/misc/stringit.cpp:
              * khtml/rendering/bidi.cpp:
              * khtml/rendering/break_lines.cpp:
              * khtml/rendering/font.cpp:
              * khtml/rendering/render_arena.cpp:
              * khtml/rendering/render_block.cpp:
              * khtml/rendering/render_box.cpp:
              * khtml/rendering/render_br.cpp:
              * khtml/rendering/render_canvas.cpp:
              * khtml/rendering/render_canvasimage.cpp:
              (RenderCanvasImage::~RenderCanvasImage):
              (RenderCanvasImage::createDrawingContext):
              * khtml/rendering/render_container.cpp:
              * khtml/rendering/render_flexbox.cpp:
              * khtml/rendering/render_flow.cpp:
              * khtml/rendering/render_form.cpp:
              * khtml/rendering/render_frames.cpp:
              * khtml/rendering/render_image.cpp:
              * khtml/rendering/render_inline.cpp:
              * khtml/rendering/render_layer.cpp:
              * khtml/rendering/render_line.cpp:
              * khtml/rendering/render_list.cpp:
              * khtml/rendering/render_object.cpp:
              * khtml/rendering/render_replaced.cpp:
              * khtml/rendering/render_style.cpp:
              * khtml/rendering/render_style.h:
              * khtml/rendering/render_table.cpp:
              * khtml/rendering/render_text.cpp:
              * khtml/rendering/render_theme.cpp:
              * khtml/rendering/render_theme_mac.mm:
              * khtml/rendering/table_layout.cpp:
              * khtml/xbl/xbl_binding.cpp:
              * khtml/xbl/xbl_binding_manager.cpp:
              * khtml/xbl/xbl_docimpl.cpp:
              * khtml/xbl/xbl_protobinding.cpp:
              * khtml/xbl/xbl_protohandler.cpp:
              * khtml/xbl/xbl_protoimplementation.cpp:
              * khtml/xbl/xbl_tokenizer.cpp:
              * khtml/xml/EventNames.cpp:
              * khtml/xml/dom2_eventsimpl.cpp:
              * khtml/xml/dom2_eventsimpl.h:
              * khtml/xml/dom2_rangeimpl.cpp:
              * khtml/xml/dom2_rangeimpl.h:
              * khtml/xml/dom2_traversalimpl.cpp:
              * khtml/xml/dom2_traversalimpl.h:
              * khtml/xml/dom2_viewsimpl.cpp:
              * khtml/xml/dom2_viewsimpl.h:
              * khtml/xml/dom_atomicstring.cpp:
              * khtml/xml/dom_docimpl.cpp:
              * khtml/xml/dom_docimpl.h:
              * khtml/xml/dom_elementimpl.cpp:
              * khtml/xml/dom_elementimpl.h:
              * khtml/xml/dom_nodeimpl.cpp:
              * khtml/xml/dom_nodeimpl.h:
              * khtml/xml/dom_position.cpp:
              * khtml/xml/dom_qname.cpp:
              * khtml/xml/dom_stringimpl.cpp:
              * khtml/xml/dom_stringimpl.h:
              * khtml/xml/dom_textimpl.cpp:
              * khtml/xml/dom_xmlimpl.cpp:
              * khtml/xml/xml_tokenizer.cpp:
              * khtml/xsl/xsl_stylesheetimpl.cpp:
              * khtml/xsl/xslt_processorimpl.cpp:
              * kwq/DOM-CSS.mm:
              * kwq/DOM.mm:
              * kwq/DOMEvents.mm:
              * kwq/DOMHTML.mm:
              * kwq/DOMInternal.mm:
              (DOMString::DOMString):
              * kwq/DOMUtility.mm:
              * kwq/DOMViews.mm:
              * kwq/KWQAccObject.mm:
              * kwq/KWQAccObjectCache.mm:
              * kwq/KWQApplication.mm:
              * kwq/KWQArrayImpl.h:
              * kwq/KWQArrayImpl.mm:
              * kwq/KWQBuffer.mm:
              * kwq/KWQButton.mm:
              * kwq/KWQCString.mm:
              * kwq/KWQCharsets.mm:
              * kwq/KWQClipboard.mm:
              * kwq/KWQCollection.mm:
              * kwq/KWQColor.mm:
              * kwq/KWQComboBox.mm:
              * kwq/KWQCursor.mm:
              * kwq/KWQDateTime.mm:
              * kwq/KWQDictImpl.mm:
              * kwq/KWQEditCommand.mm:
              * kwq/KWQEvent.mm:
              * kwq/KWQExceptions.mm:
              * kwq/KWQFile.mm:
              * kwq/KWQFileButton.mm:
              * kwq/KWQFont.mm:
              * kwq/KWQFontFamily.h:
              * kwq/KWQFontFamily.mm:
              * kwq/KWQFontMetrics.mm:
              * kwq/KWQFormData.mm:
              * kwq/KWQFrame.mm:
              * kwq/KWQGlobal.mm:
              * kwq/KWQGuardedPtr.mm:
              * kwq/KWQKCharsets.mm:
              * kwq/KWQKConfigBase.mm:
              * kwq/KWQKCookieJar.mm:
              * kwq/KWQKCursor.mm:
              * kwq/KWQKGlobal.mm:
              * kwq/KWQKGlobalSettings.mm:
              * kwq/KWQKHTMLFactory.mm:
              * kwq/KWQKHTMLPart.cpp:
              * kwq/KWQKHTMLPart.mm:
              * kwq/KWQKHTMLPartBrowserExtension.mm:
              * kwq/KWQKHTMLView.mm:
              * kwq/KWQKHistoryProvider.mm:
              * kwq/KWQKJavaAppletWidget.mm:
              * kwq/KWQKJob.mm:
              * kwq/KWQKJobClasses.mm:
              * kwq/KWQKLocale.mm:
              * kwq/KWQKPartsBrowserInterface.mm:
              * kwq/KWQKPartsEvent.mm:
              * kwq/KWQKPartsPart.mm:
              * kwq/KWQKSSLKeyGen.mm:
              * kwq/KWQKStandardDirs.mm:
              * kwq/KWQKStringHandler.mm:
              * kwq/KWQKURL.mm:
              (KURL::KURL):
              (KURL::decode_string):
              (KURL::parse):
              (KURL::encode_string):
              (encodeRelativeString):
              * kwq/KWQKWin.mm:
              * kwq/KWQKWinModule.mm:
              * kwq/KWQLabel.mm:
              * kwq/KWQLineEdit.mm:
              * kwq/KWQListBox.mm:
              * kwq/KWQListImpl.mm:
              * kwq/KWQLoader.mm:
              (KWQIsResponseURLEqualToURL):
              * kwq/KWQMapImpl.h:
              * kwq/KWQMapImpl.mm:
              * kwq/KWQMovie.mm:
              * kwq/KWQObject.mm:
              * kwq/KWQPageState.mm:
              * kwq/KWQPaintDeviceMetrics.mm:
              * kwq/KWQPainter.mm:
              * kwq/KWQPalette.mm:
              * kwq/KWQPen.mm:
              * kwq/KWQPixmap.mm:
              * kwq/KWQPoint.mm:
              * kwq/KWQPointArray.mm:
              * kwq/KWQPtrDictImpl.mm:
              * kwq/KWQPushButton.mm:
              * kwq/KWQRect.mm:
              * kwq/KWQRegExp.mm:
              * kwq/KWQRegion.mm:
              * kwq/KWQRenderTreeDebug.cpp:
              * kwq/KWQResourceLoader.mm:
              * kwq/KWQScrollBar.mm:
              * kwq/KWQScrollView.mm:
              * kwq/KWQSignal.mm:
              * kwq/KWQSignalStubs.mm:
              * kwq/KWQSize.mm:
              * kwq/KWQSlider.mm:
              * kwq/KWQSlot.mm:
              * kwq/KWQString.h:
              * kwq/KWQString.mm:
              (ALLOC_CHAR):
              (REALLOC_CHAR):
              (DELETE_CHAR):
              (ALLOC_QCHAR):
              (REALLOC_QCHAR):
              (DELETE_QCHAR):
              (_printQStringAllocationStatistics):
              (allocateHandle):
              (KWQStringData::operator new):
              (KWQStringData::operator delete):
              (freeHandle):
              * kwq/KWQStringList.mm:
              * kwq/KWQStyle.mm:
              * kwq/KWQTextArea.mm:
              * kwq/KWQTextCodec.mm:
              * kwq/KWQTextEdit.mm:
              * kwq/KWQTextField.mm:
              * kwq/KWQTextStream.mm:
              * kwq/KWQTextUtilities.mm:
              * kwq/KWQTimer.mm:
              * kwq/KWQValueListImpl.h:
              * kwq/KWQValueListImpl.mm:
              * kwq/KWQVariant.mm:
              * kwq/KWQVectorImpl.mm:
              (KWQVectorImpl::KWQVectorImpl):
              (KWQVectorImpl::~KWQVectorImpl):
              (KWQVectorImpl::clear):
              (KWQVectorImpl::resize):
              (KWQVectorImpl::assign):
              * kwq/KWQWMatrix.mm:
              * kwq/KWQWidget.mm:
              * kwq/KWQWindowWidget.mm:
              * kwq/WebCoreBridge.mm:
              * kwq/WebCoreCache.mm:
              * kwq/WebCoreEncodings.mm:
              * kwq/WebCoreJavaScript.mm:
              * kwq/WebCoreScriptDebugger.mm:
              * kwq/WebCoreSettings.mm:
              * kwq/WebCoreTextRendererFactory.mm:
              * kwq/can-convert.mm:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10701 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b64c50a2
  30. 29 Sep, 2005 1 commit
    • justing's avatar
      Reviewed by harrison · a4e338f2
      justing authored
              <rdar://problem/4278698> Adding a space inside whitespace:pre text collapses space
              <rdar://problem/4076267> Mail behaves oddly when pasting in text with leading/trailing whitespace
              <rdar://problem/4063751> Redo Typing can add extra space characters
              <rdar://problem/4120558> Mail/WebKit: Repeated capitalizeWord command deletes spaces and does not capitalize
      
              Reblance whitespace was finding the extent of surrounding whitespace incorrectly.
              createFragmentFromMarkup was not dealing with the special cases for spaces at the start/end
              of a line.  InsertTextCommand was removing collapsable whitespace without regard for the
              whitespace mode.  createFragmentFromMarkup and RebalanceWhitespace command now use one method
              to produce rebalanced sequences.  Removed special case whitespace handling from
              InsertTextCommand, that's RebalanceWhiteSpaceCommand's job.
      
              Test cases added:
              * layout-tests/editing/inserting/4278698.html: Added.
              * layout-tests/editing/pasteboard/4076267-2.html: Added.
              * layout-tests/editing/pasteboard/4076267-3.html: Added.
              * layout-tests/editing/pasteboard/4076267.html: Added.
              * layout-tests/editing/undo/4063751.html: Added.
      
              * khtml/editing/composite_edit_command.cpp:
              (khtml::CompositeEditCommand::rebalanceWhitespaceAt):
              Added.  The old convenience method, rebalanceWhitespace, can probably
              be removed, because there is never a non-caret selection after an editing command.
              * khtml/editing/composite_edit_command.h:
              * khtml/editing/htmlediting.cpp:
              (khtml::rebalanceWhitespaceInTextNode):
              * khtml/editing/htmlediting.h:
              * khtml/editing/insert_text_command.cpp:
              (khtml::InsertTextCommand::input):
              * khtml/editing/insert_text_command.h:
              * khtml/editing/markup.cpp:
              (khtml::createParagraphContentsFromString):
              (khtml::createFragmentFromText):
              * khtml/editing/rebalance_whitespace_command.cpp:
              (khtml::RebalanceWhitespaceCommand::RebalanceWhitespaceCommand):
              (khtml::isWhitespace): Changed from isNBSP to include all forms of whitespace, to aid readability.
              (khtml::RebalanceWhitespaceCommand::doApply):
              (khtml::RebalanceWhitespaceCommand::doUnapply): Removed the unused m_downstreamOffset
              * layout-tests/editing/editingStyle.css: Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10661 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a4e338f2
  31. 28 Sep, 2005 1 commit
    • mjs's avatar
      JavaScriptCore: · f025068f
      mjs authored
              Reviewed by Eric.
      
      	- move HashMap/HashSet code down to JavaScriptCore
      	http://bugzilla.opendarwin.org/show_bug.cgi?id=5161
      
              * JavaScriptCore.xcodeproj/project.pbxproj:
              * kjs/internal.cpp:
              (KJS::interpreterMap): Function that fetches the interpreter map on demand.
              (KJS::InterpreterImp::InterpreterImp): Replace use of InterpreterMap
      	class with an appropriate HashMap.
              (KJS::InterpreterImp::clear): ditto
              (KJS::InterpreterImp::interpreterWithGlobalObject): ditto
              * kjs/interpreter_map.cpp: Removed.
              * kjs/interpreter_map.h: Removed.
      
      	The HashMap/HashSet code (copied and slightly tweaked from WebCore)
      
      	* kxmlcore/HashFunctions.h: Added.
              (KXMLCore::4):
              (KXMLCore::8):
              (KXMLCore::):
              (KXMLCore::PointerHash::hash):
              (KXMLCore::PointerHash::equal):
              * kxmlcore/HashMap.h: Added.
              (KXMLCore::extractFirst):
              (KXMLCore::HashMap::HashMap):
              (KXMLCore::::size):
              (KXMLCore::::capacity):
              (KXMLCore::::isEmpty):
              (KXMLCore::::begin):
              (KXMLCore::::end):
              (KXMLCore::::find):
              (KXMLCore::::contains):
              (KXMLCore::::set):
              (KXMLCore::::get):
              (KXMLCore::::remove):
              (KXMLCore::::clear):
              (KXMLCore::deleteAllValues):
              * kxmlcore/HashMapPtrSpec.h: Added.
              (KXMLCore::PointerHashIteratorAdapter::PointerHashIteratorAdapter):
              (KXMLCore::PointerHashIteratorAdapter::operator*):
              (KXMLCore::PointerHashIteratorAdapter::operator->):
              (KXMLCore::PointerHashIteratorAdapter::operator++):
              (KXMLCore::PointerHashIteratorAdapter::operator==):
              (KXMLCore::PointerHashIteratorAdapter::operator!=):
              (KXMLCore::PointerHashConstIteratorAdapter::PointerHashConstIteratorAdapter):
              (KXMLCore::PointerHashConstIteratorAdapter::operator*):
              (KXMLCore::PointerHashConstIteratorAdapter::operator->):
              (KXMLCore::PointerHashConstIteratorAdapter::operator++):
              (KXMLCore::PointerHashConstIteratorAdapter::operator==):
              (KXMLCore::PointerHashConstIteratorAdapter::operator!=):
              (KXMLCore::):
              * kxmlcore/HashSet.h: Added.
              (KXMLCore::identityExtract):
              (KXMLCore::convertAdapter):
              (KXMLCore::HashSet::HashSet):
              (KXMLCore::::size):
              (KXMLCore::::capacity):
              (KXMLCore::::isEmpty):
              (KXMLCore::::begin):
              (KXMLCore::::end):
              (KXMLCore::::find):
              (KXMLCore::::contains):
              (KXMLCore::::insert):
              (KXMLCore::::remove):
              (KXMLCore::::clear):
              * kxmlcore/HashTable.cpp: Added.
              (KXMLCore::HashTableStats::~HashTableStats):
              (KXMLCore::HashTableStats::recordCollisionAtCount):
              * kxmlcore/HashTable.h: Added.
              (KXMLCore::HashTableIterator::skipEmptyBuckets):
              (KXMLCore::HashTableIterator::HashTableIterator):
              (KXMLCore::HashTableIterator::operator*):
              (KXMLCore::HashTableIterator::operator->):
              (KXMLCore::HashTableIterator::operator++):
              (KXMLCore::HashTableIterator::operator==):
              (KXMLCore::HashTableIterator::operator!=):
              (KXMLCore::HashTableConstIterator::HashTableConstIterator):
              (KXMLCore::HashTableConstIterator::operator*):
              (KXMLCore::HashTableConstIterator::operator->):
              (KXMLCore::HashTableConstIterator::skipEmptyBuckets):
              (KXMLCore::HashTableConstIterator::operator++):
              (KXMLCore::HashTableConstIterator::operator==):
              (KXMLCore::HashTableConstIterator::operator!=):
              (KXMLCore::HashTable::HashTable):
              (KXMLCore::HashTable::~HashTable):
              (KXMLCore::HashTable::begin):
              (KXMLCore::HashTable::end):
              (KXMLCore::HashTable::size):
              (KXMLCore::HashTable::capacity):
              (KXMLCore::HashTable::insert):
              (KXMLCore::HashTable::isEmptyBucket):
              (KXMLCore::HashTable::isDeletedBucket):
              (KXMLCore::HashTable::isEmptyOrDeletedBucket):
              (KXMLCore::HashTable::hash):
              (KXMLCore::HashTable::equal):
              (KXMLCore::HashTable::identityConvert):
              (KXMLCore::HashTable::extractKey):
              (KXMLCore::HashTable::lookup):
              (KXMLCore::HashTable::shouldExpand):
              (KXMLCore::HashTable::mustRehashInPlace):
              (KXMLCore::HashTable::shouldShrink):
              (KXMLCore::HashTable::shrink):
              (KXMLCore::HashTable::clearBucket):
              (KXMLCore::HashTable::deleteBucket):
              (KXMLCore::HashTable::makeLookupResult):
              (KXMLCore::HashTable::makeIterator):
              (KXMLCore::HashTable::makeConstIterator):
              (KXMLCore::::lookup):
              (KXMLCore::::insert):
              (KXMLCore::::reinsert):
              (KXMLCore::::find):
              (KXMLCore::::contains):
              (KXMLCore::::remove):
              (KXMLCore::::allocateTable):
              (KXMLCore::::expand):
              (KXMLCore::::rehash):
              (KXMLCore::::clear):
              (KXMLCore::::HashTable):
              (KXMLCore::::swap):
              (KXMLCore::::operator):
              (KXMLCore::::checkTableConsistency):
              (KXMLCore::::checkTableConsistencyExceptSize):
              * kxmlcore/HashTraits.h: Added.
              (KXMLCore::HashTraits::emptyValue):
              (KXMLCore::):
              (KXMLCore::PairHashTraits::emptyValue):
              (KXMLCore::PairHashTraits::deletedValue):
      
      WebCore:
      
              Reviewed by Eric.
      
      	- move HashMap/HashSet code down to JavaScriptCore; adapt usage to the new header location
      	http://bugzilla.opendarwin.org/show_bug.cgi?id=5161
      
              * ForwardingHeaders/kxmlcore/HashMap.h: Added.
              * ForwardingHeaders/kxmlcore/HashSet.h: Added.
              * ForwardingHeaders/misc/hashmap.h: Removed.
              * ForwardingHeaders/misc/hashset.h: Removed.
              * ForwardingHeaders/misc/pointerhash.h: Removed.
              * WebCore.xcodeproj/project.pbxproj:
              * khtml/css/cssstyleselector.cpp:
              (khtml::CSSRuleSet::getIDRules):
              (khtml::CSSRuleSet::getClassRules):
              (khtml::CSSRuleSet::getTagRules):
              (khtml::CSSRuleSet::getUniversalRules):
              (khtml::CSSRuleSet::addToRuleSet):
              * khtml/css/cssstyleselector.h:
              * khtml/ecma/kjs_binding.cpp:
              * khtml/editing/jsediting.cpp:
              * khtml/html/html_documentimpl.cpp:
              (DOM::addItemToMap):
              * khtml/html/html_documentimpl.h:
              * khtml/html/html_elementimpl.cpp:
              * khtml/html/html_formimpl.cpp:
              (DOM::HTMLFormElementImpl::radioButtonChecked):
              * khtml/html/html_formimpl.h:
              * khtml/html/htmlfactory.cpp:
              (DOM::HTMLElementFactory::createHTMLElement):
              * khtml/html/htmlparser.cpp:
              (HTMLParser::getNode):
              * khtml/xml/dom_atomicstring.cpp:
              * khtml/xml/dom_qname.cpp:
              * khtml/xml/dom_stringimpl.h:
              (KXMLCore::):
              (KXMLCore::CaseInsensitiveHash::hash):
              (KXMLCore::CaseInsensitiveHash::equal):
              * khtml/xml/xml_tokenizer.cpp:
              * kwq/DOM.mm:
              (ObjCEventListener::ObjCEventListener):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@10653 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f025068f