WebKit-https.git
16 years agoRevised layout test with image and float changes.
hyatt [Tue, 11 May 2004 21:45:39 +0000 (21:45 +0000)]
Revised layout test with image and float changes.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6578 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix makeChildrenNonInline so that it does not wrap floats unless an inline is actual...
hyatt [Tue, 11 May 2004 20:29:19 +0000 (20:29 +0000)]
Fix makeChildrenNonInline so that it does not wrap floats unless an inline is actually found.

        Fix block minmaxwidth to add together contiguous runs of floats.

Fix the content image loader to not destroy the image when removed from the document.

        Reviewed by darin

        * ChangeLog:
        * khtml/html/html_imageimpl.cpp:
        (HTMLImageLoader::~HTMLImageLoader):
        (HTMLImageElementImpl::detach):
        * khtml/html/html_imageimpl.h:
        (DOM::):
        * khtml/html/html_objectimpl.cpp:
        (HTMLObjectElementImpl::createRenderer):
        * khtml/html/html_objectimpl.h:
        * khtml/rendering/render_block.cpp:
        (khtml::getInlineRun):
        (khtml::RenderBlock::calcInlineMinMaxWidth):
        (khtml::RenderBlock::calcBlockMinMaxWidth):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6577 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agofix B&I build failure caused by case sensitivity
vicki [Tue, 11 May 2004 17:30:43 +0000 (17:30 +0000)]
fix B&I build failure caused by case sensitivity

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6575 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
mjs [Mon, 10 May 2004 23:47:08 +0000 (23:47 +0000)]
WebCore:

        Reviewed by Darin.

- avoid redecoding animated images that are only used once for
~2.5% iBench speedup (WebCore part of fix)

        * khtml/rendering/render_image.cpp:
        (RenderImage::setPixmap): Maintain use count for pixmap.
        (RenderImage::~RenderImage): Likewise.
        * kwq/KWQPixmap.h:
        * kwq/KWQPixmap.mm:
        (QPixmap::increaseUseCount): Call WebCoreImageRenderer
        (QPixmap::decreaseUseCount): Call WebCoreImageRenderer
        * kwq/WebCoreImageRenderer.h: Prototype new protocol methods.

WebKit:

        Reviewed by Darin.

- avoid redecoding animated images that are only used once for
~2.5% iBench speedup (WebCore part of fix)

        * WebCoreSupport.subproj/WebImageRenderer.h:
        * WebCoreSupport.subproj/WebImageRenderer.m:
        (-[WebImageRenderer increaseUseCount]):
        (-[WebImageRenderer decreaseUseCount]):
        (-[WebImageRenderer retainOrCopyIfNeeded]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6574 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoBack out the optimization since it will break the ibench cheat.
hyatt [Mon, 10 May 2004 23:42:12 +0000 (23:42 +0000)]
Back out the optimization since it will break the ibench cheat.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6573 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix build.
mjs [Mon, 10 May 2004 23:34:23 +0000 (23:34 +0000)]
    Fix build.

        * WebView.subproj/WebFrame.m:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6572 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoFix build failure
hyatt [Mon, 10 May 2004 23:28:59 +0000 (23:28 +0000)]
Fix build failure

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6571 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
mjs [Mon, 10 May 2004 23:21:17 +0000 (23:21 +0000)]
    Reviewed by Ken.

- avoid messing with undo manager needlessly for ~1% HTML iBench speedup

        * WebCoreSupport.subproj/WebBridge.h:
        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge registerCommandForUndo:]): mark undo/redo item flag
        (-[WebBridge registerCommandForRedo:]): ditto
        (-[WebBridge clearUndoRedoOperations]): check flag before removing items,
and clear it after removing them

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6570 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin.
mjs [Mon, 10 May 2004 23:20:12 +0000 (23:20 +0000)]
    Reviewed by Darin.

- -[WebFrame childFrames] is so hot that a special internal
version which avoids the copy and autorelease results in a .75%
performance improvement on HTML iBench.

        * WebView.subproj/WebFramePrivate.h: Prototype new method.
        * WebView.subproj/WebFrame.m:
(-[WebFrame _internalChildFrames]): New method, just returns
internal value instead of copying.

        (-[WebFrame _descendantFrameNamed:]): Use it
        (-[WebFrame _textSizeMultiplierChanged]): likewise
        (-[WebFrame _viewWillMoveToHostWindow:]): likewise
        (-[WebFrame _viewDidMoveToHostWindow]): likewise
        (-[WebFrame _saveDocumentAndScrollState]): likewise
        (-[WebFrame _numPendingOrLoadingRequests:]): likewise
        (-[WebFrame _checkLoadComplete]): Refactored this and it's two
helpers a little so we could get away with using
_internalChildFrames.
        (-[WebFrame _checkLoadCompleteForThisFrame]): Renamed from
_isLoadComplete
(-[WebFrame _recursiveCheckLoadComplete]): renamed from (class
method) _recursiveCheckCompleteFromFrame:
        * WebView.subproj/WebDataSource.m:
        (-[WebDataSource _defersCallbacksChanged]): Use it
        (-[WebDataSource isLoading]): likewise
        * WebView.subproj/WebView.m:
        (-[WebView _frameForDataSource:fromFrame:]): likewise
        (-[WebView _frameForView:fromFrame:]): likewise

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6569 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Make sure that when finished parsing if all the right conditions are met, we just...
hyatt [Mon, 10 May 2004 23:19:27 +0000 (23:19 +0000)]
Make sure that when finished parsing if all the right conditions are met, we just go ahead and updateRendering and
layout.

        Reviewed by rjw

        * khtml/khtmlview.cpp:
        (KHTMLView::scheduleRelayout):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6568 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
mjs [Mon, 10 May 2004 21:47:37 +0000 (21:47 +0000)]
    Reviewed by Dave.

- some minor performance tweaks that together give .5% or so on
the HTML iBench

        * khtml/css/css_valueimpl.h: don't use a bitfield for id and important,
unpacking the bitfield is too expensive
        * kwq/KWQArrayImpl.h:
        * kwq/KWQArrayImpl.mm:
        (KWQArrayImpl::at): inline this method because it's so hot
        * kwq/KWQString.mm:
        (allocateHandle): inline this function because it's so hot
        (initializeHandleNodes): move this in the file so above can be inlined
        (allocateNode): ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6567 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Move image loading to content.
hyatt [Mon, 10 May 2004 21:29:42 +0000 (21:29 +0000)]
Move image loading to content.

        Reviewed by kocienda

        * khtml/html/html_imageimpl.cpp:
        (m_imageComplete):
        (HTMLImageLoader::~HTMLImageLoader):
        (HTMLImageLoader::updateFromElement):
        (HTMLImageLoader::removedFromDocument):
        (HTMLImageLoader::dispatchLoadEvent):
        (HTMLImageLoader::notifyFinished):
        (HTMLImageElementImpl::HTMLImageElementImpl):
        (HTMLImageElementImpl::parseHTMLAttribute):
        (HTMLImageElementImpl::attach):
        (HTMLImageElementImpl::detach):
        (HTMLImageElementImpl::removedFromDocument):
        (HTMLImageElementImpl::currentImage):
        * khtml/html/html_imageimpl.h:
        (DOM::):
        * khtml/html/html_objectimpl.cpp:
        (HTMLObjectElementImpl::HTMLObjectElementImpl):
        (HTMLObjectElementImpl::removedFromDocument):
        (HTMLObjectElementImpl::attach):
        * khtml/html/html_objectimpl.h:
        * khtml/misc/loader.cpp:
        (CachedImage::ref):
        * khtml/rendering/render_image.cpp:
        (RenderImage::RenderImage):
        (RenderImage::setImage):
        (RenderImage::updateAltText):
        * khtml/rendering/render_image.h:
        (khtml::RenderImage::getImage):
        * khtml/rendering/render_object.cpp:
        (RenderObject::canvas):
        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::dispatchImageLoadEventSoon):
        (DocumentImpl::removeImage):
        (DocumentImpl::dispatchImageLoadEventsNow):
        * khtml/xml/dom_docimpl.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6566 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Forgot to commit this copied header.
cblu [Mon, 10 May 2004 18:05:03 +0000 (18:05 +0000)]
Forgot to commit this copied header.

        * DOM.subproj/DOMExtensions.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6565 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Vicki.
darin [Mon, 10 May 2004 16:47:45 +0000 (16:47 +0000)]
    Reviewed by Vicki.

        - fixed build failure seen in B&I log (due to case sensitive file system?)

        * kwq/KWQLoader.h: Include "KWQCString.h" rather than "QCString.h". The latter was
        failing because the forwarding header is called "qcstring.h" and I guess B&I started
        building with a case sensitive file system. I could have changed this to "qcstring.h",
        but it seemed better to use the header's real name since we're inside KWQ here.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6563 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
mjs [Sun, 9 May 2004 04:55:11 +0000 (04:55 +0000)]
    Reviewed by Dave.

- change things around so extremely hot TokenizerString::current()
method doesn't have to do any work. It's cheaper to maintain the
relevant state than to always compute it.

        * khtml/misc/stringit.h:
        (khtml::TokenizerString::TokenizerString): Initialize m_currentChar
        (khtml::TokenizerString::push): update m_currentChar
        (khtml::TokenizerString::advance): ditto
        (khtml::TokenizerString::current): return m_currentChar
        * khtml/misc/stringit.cpp:
        (khtml::TokenizerString::clear): update m_currentChar
        (khtml::TokenizerString::append): update m_currentChar
        (khtml::TokenizerString::prepend): update m_currentChar

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6562 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
gramps [Sat, 8 May 2004 02:38:58 +0000 (02:38 +0000)]
    Reviewed by Dave.

Fixed minor, edge-case regression in KEYGEN RSA logic caused by Dave's
"atomic string" patch back in January.

        * khtml/html/html_formimpl.cpp:
        (HTMLKeygenElementImpl::encoding):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6561 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by darin.
vicki [Fri, 7 May 2004 22:31:01 +0000 (22:31 +0000)]
    Reviewed by darin.

Turn off GC since it uses ppc only instructions (which breaks
the B&I build).

        * kjs/value.h: set USE_CONSERVATIVE_GC to 0

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6559 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoset version number to 140u. the tree is open!
vicki [Fri, 7 May 2004 18:10:18 +0000 (18:10 +0000)]
set version number to 140u.  the tree is open!

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6558 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoSafari-139 stamp
vicki [Fri, 7 May 2004 18:03:16 +0000 (18:03 +0000)]
Safari-139 stamp

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6556 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin.
mjs [Fri, 7 May 2004 16:51:56 +0000 (16:51 +0000)]
    Reviewed by Darin.

- two trivial changes for a 1% speedup, thanks to Shark

        * khtml/dom/dom_string.cpp:
        * khtml/dom/dom_string.h:
        (DOM::DOMString::~DOMString): inline this method because it's hot and the
function call overhead was very costly.
        * WebCore.pbproj/project.pbxproj: Add -falign-loops=16
optimization flag, as suggested by Shark.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6555 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin.
mjs [Fri, 7 May 2004 16:50:16 +0000 (16:50 +0000)]
    Reviewed by Darin.

- add -funroll-loops=16 compiler option for approx .5% speedup on
HTML iBench and .5-1% speedup on JS iBench.

        * JavaScriptCore.pbproj/project.pbxproj:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6554 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Added alpha to DOMRGBColor as an extension.
cblu [Thu, 6 May 2004 22:50:17 +0000 (22:50 +0000)]
Added alpha to DOMRGBColor as an extension.

        Reviewed by dave.

        * kwq/DOM-CSS.mm:
        (-[DOMRGBColor alpha]): new
        * kwq/DOMExtensions.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6553 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoAdd layout test for pres and brs.
hyatt [Thu, 6 May 2004 22:04:23 +0000 (22:04 +0000)]
Add layout test for pres and brs.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6552 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix whitespace rendering for brs inside pres. The bug is 3640711.
hyatt [Thu, 6 May 2004 22:01:33 +0000 (22:01 +0000)]
Fix whitespace rendering for brs inside pres. The bug is 3640711.

        Reviewed by kocienda

        * khtml/rendering/bidi.cpp:
        (khtml::RenderBlock::layoutInlineChildren):
        (khtml::RenderBlock::findNextLineBreak):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6551 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago * DOM.subproj/WebDOMOperations.h: improved a header doc comment
cblu [Thu, 6 May 2004 21:41:14 +0000 (21:41 +0000)]
    * DOM.subproj/WebDOMOperations.h: improved a header doc comment

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6550 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoJavaScriptCore:
mjs [Thu, 6 May 2004 06:41:06 +0000 (06:41 +0000)]
JavaScriptCore:

        Reviewed by Darin.

Enable full conservative GC mode in addition to test mode. When
conservative GC is enabled, we now get an 11% speed improvement on
the iBench. Also fix some spots I missed before.

Specific noteworth changes:

        * kjs/collector.cpp:
(KJS::Collector::markStackObjectsConservatively): Check possible
cell pointers for 8-byte aligment and verify they are not 0.

        * kjs/protected_values.cpp:
        (KJS::ProtectedValues::increaseProtectCount): Move null-tolerance from here...
        (KJS::ProtectedValues::decreaseProtectCount): ...and here...
        * kjs/protect.h:
        (KJS::gcProtectNullTolerant): ...to here...
        (KJS::gcUnprotectNullTolerant): ...and here, because not all callers need the null
tolerance, and doing the check is expensive.

        * kjs/protected_values.cpp:
        (KJS::ProtectedValues::computeHash): Replace hash function with a much faster one
that is still very good.

        * kjs/protect.h:
        (KJS::gcProtect):
        (KJS::gcUnprotect):
        (KJS::ProtectedValue::ProtectedValue):
        (KJS::ProtectedValue::~ProtectedValue):
        (KJS::ProtectedValue::operator=):
        (KJS::ProtectedObject::ProtectedObject):
        (KJS::ProtectedObject::~ProtectedObject):
        (KJS::ProtectedObject::operator=):
        (KJS::ProtectedReference::ProtectedReference):
        (KJS::ProtectedReference::~ProtectedReference):
        (KJS::ProtectedReference::operator=):
        * kjs/protected_values.cpp:
        (KJS::ProtectedValues::getProtectCount):
        (KJS::ProtectedValues::increaseProtectCount):
        (KJS::ProtectedValues::decreaseProtectCount):
        (KJS::ProtectedValues::computeHash):
        * bindings/runtime_root.cpp:
        (KJS::Bindings::addNativeReference):
        (KJS::Bindings::removeNativeReference):
        (RootObject::removeAllNativeReferences):
        * bindings/runtime_root.h:
        (KJS::Bindings::RootObject::~RootObject):
        (KJS::Bindings::RootObject::setRootObjectImp):
        * kjs/collector.cpp:
        (KJS::Collector::allocate):
        (KJS::Collector::collect):
        * kjs/collector.h:
        * kjs/internal.cpp:
        (NumberImp::create):
        (InterpreterImp::globalInit):
        (InterpreterImp::globalClear):
        (InterpreterImp::mark):
        * kjs/list.cpp:
        (KJS::List::derefValues):
        (KJS::List::refValues):
        (KJS::List::append):
        * kjs/object.cpp:
        (KJS::ObjectImp::setInternalValue):
        (KJS::ObjectImp::putDirect):
        * kjs/value.cpp:
        (ValueImp::mark):
        (ValueImp::marked):
        * kjs/value.h:
        (KJS::ValueImp::ValueImp):
        (KJS::ValueImp::~ValueImp):
        (KJS::ValueImp::):
        (KJS::Value::Value):
        (KJS::Value::~Value):
        (KJS::Value::operator=):

WebCore:

        Reviewed by Darin.

        * khtml/ecma/kjs_events.cpp:
        (JSLazyEventListener::parseCode): Make sure to protect the
permanent "event" string object.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6549 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fixes for 3637924, 3643356, and 3558513, all crashes in recalcStyle. Make sure...
hyatt [Wed, 5 May 2004 20:50:21 +0000 (20:50 +0000)]
Fixes for 3637924, 3643356, and 3558513, all crashes in recalcStyle.  Make sure the tree is always in a
sane state when removing children while changing .innerHTML.

        Reviewed by darin

        * khtml/xml/dom_nodeimpl.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6545 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoAdd quirk body height test.
hyatt [Wed, 5 May 2004 20:24:33 +0000 (20:24 +0000)]
Add quirk body height test.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6544 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoFixed layout tests plus added a new test.
hyatt [Wed, 5 May 2004 20:23:48 +0000 (20:23 +0000)]
Fixed layout tests plus added a new test.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6543 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago A collection of fixes.
hyatt [Wed, 5 May 2004 20:21:09 +0000 (20:21 +0000)]
A collection of fixes.

(1) Fix a regression from the style sharing landing that made visited and unvisited links accidentally share.
(2) Make sure 100% height divs fill the <body> in quirks mode, even if the body has no height specified.
(3) Make sure table cell percentage heights exclude border/padding.
(4) Make sure that before flexing auto height is used for the contents of the cells.

        Reviewed by darin

        * khtml/css/cssstyleselector.cpp:
        (khtml::CSSStyleSelector::canShareStyleWithElement):
        (khtml::CSSStyleSelector::locateSharedStyle):
        * khtml/rendering/render_box.cpp:
        (RenderBox::calcPercentageHeight):
        * khtml/rendering/render_table.cpp:
        (RenderTable::layout):
        (RenderTableSection::layoutRows):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6542 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoTests:
cblu [Wed, 5 May 2004 18:37:31 +0000 (18:37 +0000)]
Tests:

        Reviewed by kocienda.

        * Blot/BlotDocument.m:
        (-[BlotDocument dataRepresentationOfType:]): updated to use outerHTML

WebCore:

- DOM Extensions API tweaks
- Implemented outerHTML

        Reviewed by kocienda.

        * WebCore-combined.exp:
        * khtml/html/html_elementimpl.cpp:
        (HTMLElementImpl::outerHTML): new
        (HTMLElementImpl::setOuterHTML): mew
        * khtml/html/html_elementimpl.h:
        * kwq/DOMExtensions.h: removed background methods on table and table cell since these are unnecessary conveniences
        * kwq/DOMHTML.mm:
        (-[DOMHTMLElement outerHTML]): new
        (-[DOMHTMLElement setOuterHTML:]): mew

WebKit:

- DOM Extensions API tweaks

        Reviewed by kocienda.

        * DOM.subproj/DOMExtensions.h: copied from WebCore
        * DOM.subproj/WebDOMOperations.h: added header doc comments
        * DOM.subproj/WebDOMOperations.m:
        (-[DOMNode _URLsFromSelectors:]): use renamed URLWithAttributeString
        (-[DOMDocument URLWithAttributeString:]): renamed
        (-[DOMHTMLTableElement _web_background]): new private method
        (-[DOMHTMLTableElement _subresourceURLs]): use new private method
        (-[DOMHTMLTableCellElement _web_background]): new private method
        (-[DOMHTMLTableCellElement _subresourceURLs]): use new private method

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6541 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix for 3641331, make sure <th> elements don't reset text-align to center if they...
hyatt [Wed, 5 May 2004 00:16:21 +0000 (00:16 +0000)]
Fix for 3641331, make sure <th> elements don't reset text-align to center if they inherit a specified
value.

Also remove the styles from <abbr> and <acronym>.

        Reviewed by darin

        * khtml/css/cssstyleselector.cpp:
        (khtml::CSSStyleSelector::adjustRenderStyle):
        * khtml/css/html4.css:
        * khtml/css/quirks.css:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6540 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Hyatt
kocienda [Tue, 4 May 2004 23:43:16 +0000 (23:43 +0000)]
    Reviewed by Hyatt

        Fix for behavior which extends selection drawing to beginning and end of blocks.
        I added this feature a few days ago, but my checks to see if the extension should
        be done was naive: Is first or last item in root line box selected? Clearly this
        needs to be "selection is *beyond* first or last item in root line box. Done.

        * khtml/rendering/render_image.cpp:
        (RenderImage::paint): Add selectionState() == SelectionInside check.
        * khtml/rendering/render_text.cpp:
        (InlineTextBox::paintSelection): Constrain passed-in offsets to be relative to box.
        Use passed-in offsets to check whether selection extends beyond this box. Also, now
        passes in flag to tell whether the whole RenderText has selectionState() == SelectionInside
        (in which case you always want to extend).
        (RenderText::paint): Remove box offset constraining from here. Now done in above function.
        * khtml/rendering/render_text.h: Modify paintSelection interface to add
        selectionState() == SelectionInside flag.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6539 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by me
kocienda [Tue, 4 May 2004 23:31:42 +0000 (23:31 +0000)]
    Reviewed by me

        Added layout tests for DOM traversal objects.

        * layout-tests/traversal/node-iterator-001-expected.txt: Added.
        * layout-tests/traversal/node-iterator-001.html: Added.
        * layout-tests/traversal/node-iterator-002-expected.txt: Added.
        * layout-tests/traversal/node-iterator-002.html: Added.
        * layout-tests/traversal/node-iterator-003-expected.txt: Added.
        * layout-tests/traversal/node-iterator-003.html: Added.
        * layout-tests/traversal/node-iterator-004-expected.txt: Added.
        * layout-tests/traversal/node-iterator-004.html: Added.
        * layout-tests/traversal/node-iterator-005-expected.txt: Added.
        * layout-tests/traversal/node-iterator-005.html: Added.
        * layout-tests/traversal/node-iterator-006-expected.txt: Added.
        * layout-tests/traversal/node-iterator-006.html: Added.
        * layout-tests/traversal/node-iterator-007-expected.txt: Added.
        * layout-tests/traversal/node-iterator-007.html: Added.
        * layout-tests/traversal/traversal.js: Added.
        * layout-tests/traversal/tree-walker-001-expected.txt: Added.
        * layout-tests/traversal/tree-walker-001.html: Added.
        * layout-tests/traversal/tree-walker-002-expected.txt: Added.
        * layout-tests/traversal/tree-walker-002.html: Added.
        * layout-tests/traversal/tree-walker-003-expected.txt: Added.
        * layout-tests/traversal/tree-walker-003.html: Added.
        * layout-tests/traversal/tree-walker-004-expected.txt: Added.
        * layout-tests/traversal/tree-walker-004.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6538 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Hyatt
kocienda [Tue, 4 May 2004 23:30:30 +0000 (23:30 +0000)]
    Reviewed by Hyatt

        * khtml/xml/dom2_traversalimpl.cpp:
        (DOM::NodeIteratorImpl::nextNode): Change to make NodeIterators behave like the spec in that
        reference node is null until you iterate the first time.
        (DOM::NodeIteratorImpl::previousNode): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6537 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by me
kocienda [Tue, 4 May 2004 22:38:51 +0000 (22:38 +0000)]
    Reviewed by me

        * WebCore.pbproj/project.pbxproj: Backed out unintentional
        change.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6536 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
kocienda [Tue, 4 May 2004 22:38:00 +0000 (22:38 +0000)]
WebCore:

        Reviewed by Hyatt

        Implemented DOM traversal objects, NodeIterator and TreeWalker.

        * WebCore-combined.exp: Regenerate
        * WebCore.exp: Export DOMNodeFilter protocol
        * khtml/dom/dom2_traversal.cpp: Completed half-done implementation pulled from KDE tree.
        * khtml/dom/dom2_traversal.h: Ditto.
        * khtml/dom/dom_doc.cpp:
        (DOM::Document::createNodeIterator): Ditto.
        (DOM::Document::createTreeWalker): Ditto.
        * khtml/dom/dom_doc.h: Ditto.
        * khtml/ecma/kjs_dom.cpp:
        (DOMDocumentProtoFunc::tryCall): Fix cases that create traversal objects.
        * khtml/ecma/kjs_traversal.cpp:
        (DOMNodeIterator::getValueProperty): Add referenceNode and pointerBeforeReferenceNode
        properties to node interator.
        (DOMTreeWalkerProtoFunc::tryCall): Fix typo where DOMTreeWalker::PreviousNode case called previousSibling function.
        (JSNodeFilterCondition::JSNodeFilterCondition): Implement JS glue class for node filter conditions.
        (JSNodeFilterCondition::acceptNode): Ditto.
        * khtml/ecma/kjs_traversal.h:
        (KJS::DOMNodeIterator::): Add ReferenceNode and PointerBeforeReferenceNode constants.
        * khtml/ecma/kjs_traversal.lut.h:
        (KJS::): Regenerated
        * khtml/xml/dom2_traversalimpl.cpp: Completed half-done implementation pulled from KDE tree.
        * khtml/xml/dom2_traversalimpl.h: Ditto.
        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::createNodeIterator): Ditto.
        (DocumentImpl::createTreeWalker): Ditto.
        * khtml/xml/dom_docimpl.h: Ditto.
        * khtml/xml/dom_nodeimpl.cpp:
        (NodeImpl::checkAddChild): Patched due to change in isAncestor function. This was the one pre-existing caller.
        (NodeImpl::isAncestor): Changed so that it does not return true for itself: node->isAncestor(node) now returns false.
        * khtml/xml/dom_nodeimpl.h: Made isAncestor const.
        * kwq/DOM.mm: Implemented obj-c glue for traversal objects.
        * kwq/DOMInternal.h: Ditto.
        * kwq/DOMTraversal.h: Ditto.

WebKit:

        Reviewed by Hyatt

        * DOM.subproj/DOMTraversal.h: File coppied from WebCore

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6535 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Tue, 4 May 2004 16:29:50 +0000 (16:29 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3642252>: "starting to drag a link and then releasing needs to activate the link if you are still over it"

        * khtml/khtmlview.cpp:
        (KHTMLView::viewportMouseMoveEvent): Put hysteresis check inside !APPLE_CHANGES because
        the Web Kit does our hysteresis checks.
        (KHTMLView::viewportMouseReleaseEvent): Ditto.

        * kwq/KWQApplication.h: Removed startDragDistance and globalStrut; unused.
        * kwq/KWQApplication.mm: Removed the implementations.
        * kwq/KWQPointArray.h: Removed manhattanLength; unused.
        * kwq/KWQPoint.mm:  Removed the implementation.

        * WebCore-tests.exp: Removed manhattanLength.
        * WebCore-combined.exp: Regenerated.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6534 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Hyatt
kocienda [Mon, 3 May 2004 22:54:25 +0000 (22:54 +0000)]
    Reviewed by Hyatt

Nifty hack to work around problem where BR's inserted at the end of a block do not
render. Since only the *last* BR has this quirk, insert two when at the end of a block.
Once done, you can't caret past the last one, so you never insert two again.

        * khtml/editing/htmlediting_impl.cpp:
        (InputNewlineCommandImpl::doApply)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6533 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken
darin [Mon, 3 May 2004 22:29:59 +0000 (22:29 +0000)]
    Reviewed by Ken

        - fixed <rdar://problem/3091531>: "should format copied tables with tabs between cells, spreadsheet-style, for pasting to Excel"
        - fixed <rdar://problem/3110002>: "Find doesn't match across formatting boundaries"
        - fixed <rdar://problem/3640340>: "REGRESSION (136-137): nil-deref in KHTMLPart::setFocusNodeIfNeeded inside triple click code after repeatedly click/drag selecting text"
        - fixed <rdar://problem/3640422>: "too many blank lines between paragraphs in copied text"

        * khtml/dom/dom2_range.h: Added == and != operators to DOMRange.
        * khtml/dom/dom2_range.cpp: (DOM::operator==): Added.

        * khtml/khtml_part.cpp:
        (KHTMLPart::init): Don't call findTextBegin any more; it's now not used at all
        in WebCore.
        (KHTMLPart::clear): Don't call findTextBegin any more. Also don't set up the
        load statistics variables.
        (KHTMLPart::findTextNext): Roll out APPLE_CHANGES; this function is no longer
        used in WebCore any more and instead the entire thing is compiled out.
        (KHTMLPart::text): Reimplement this by calling one of the new text operations. All the interesting
        parts were moved into the TextIterator class.
        (KHTMLPart::setFocusNodeIfNeeded): Add a check for nil; this is the fix for 364030.

        * khtml/khtmlpart_p.h: (KHTMLPartPrivate::KHTMLPartPrivate): Put m_findPos,
        m_findNode, m_overURL, m_overURLTarget, m_scrollTimer, m_loadedObjects,
        m_totalObjectCount, and m_jobPercent inside !APPLE_CHANGES.

        * khtml/xml/dom_selection.h: Replaced uses of 4-character tabs with spaces.
        (DOM::Selection::Selection): Added a constructor that takes a DOM range.
        (DOM::Selection::operator=): Overloaded operator= for DOM range and position.
        This is slightly more efficient than letting a second Selection object be constructed.
        * khtml/xml/dom_selection.cpp: Replaced uses of 4-character tabs with spaces.
        (DOM::Selection::Selection): Added a constructor that takes a DOM range.

        * kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::findString): Reimplement find so it uses
        the new text operations function for finding.

        * khtml/misc/khtml_text_operations.h:
        * khtml/misc/khtml_text_operations.cpp:
        * WebCore.pbproj/project.pbxproj:
        Added new text iterator classes that do the heavy lifting.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6532 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Make sure that XML processing instructions set themselves as the parent node of...
hyatt [Mon, 3 May 2004 17:53:06 +0000 (17:53 +0000)]
Make sure that XML processing instructions set themselves as the parent node of the stylesheets they load,
so that they will get stylesheetLoaded() notifications when @imported stylesheets are contained inside the
sheet.

        Reviewed by cblu

        * khtml/xml/dom_xmlimpl.cpp:
        (ProcessingInstructionImpl::setStyleSheet):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6531 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Sun, 2 May 2004 16:13:40 +0000 (16:13 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3640419>: "_webkit_stringByReplacingValidPercentEscapes does not handle %00 properly"

        * Misc.subproj/WebNSURLExtras.m: (-[NSString _webkit_stringByReplacingValidPercentEscapes]):
        Use the function in NSURL instead of implementing our own here.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6530 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Asking an NSInvocation for it's return value when return type
rjw [Fri, 30 Apr 2004 23:19:24 +0000 (23:19 +0000)]
Asking an NSInvocation for it's return value when return type
is void throws an exception.  Added check for void return types
to avoid this exception.

        Reviewed by Ken.

        * bindings/objc/objc_instance.mm:
        (ObjcInstance::invokeMethod):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6529 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fixed: <rdar://problem/3543662>: HITLIST-137: REGRESSION: reproducible hang copying...
cblu [Fri, 30 Apr 2004 23:16:59 +0000 (23:16 +0000)]
Fixed: <rdar://problem/3543662>: HITLIST-137: REGRESSION: reproducible hang copying all text at Dave's blog, and other pages

        Reviewed by dave.

        * khtml/xml/dom2_rangeimpl.cpp:
        (RangeImpl::toHTMLWithOptions): when looping with containingBlock, check the value to see if it is the same

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6528 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix for 3639530, regression on generated content pages. They crash because I forgot...
hyatt [Fri, 30 Apr 2004 19:19:52 +0000 (19:19 +0000)]
Fix for 3639530, regression on generated content pages.  They crash because I forgot to null-check the style
object.

        Reviewed by kocienda

        * khtml/css/cssstyleselector.cpp:
        (khtml::CSSStyleSelector::checkOneSelector):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6527 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago * WebView.subproj/WebView.m:
sullivan [Fri, 30 Apr 2004 17:59:26 +0000 (17:59 +0000)]
    * WebView.subproj/WebView.m:
        fixed deployment build breakage

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6526 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
sullivan [Fri, 30 Apr 2004 17:30:54 +0000 (17:30 +0000)]
WebCore:

        - added bridge method to get the NSFont used to render a node, to
        help with supporting the font panel

        Reviewed by Ken.

        * kwq/WebCoreBridge.h:
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge renderedFontForNode:]):
        return nil if no renderer, otherwise return NSFont

WebKit:

        - more work on getting the font panel to work with editable HTML.
        The font panel in Blot now correctly reflects the first selected font when the
        selection is at least one character long.

        Reviewed by Ken.

        * WebView.subproj/WebView.m:
        removed unfinished plumbing to support reflecting selected attributes (e.g. text color,
        underline) in font panel, since this doesn't work in Mail or TextEdit either.
        (_fontFromStyle):
        removed assertion for now
        (-[WebView _updateFontPanel]):
        now uses new bridge method to get the NSFont from the node, instead of trying
        to create an NSFont from a DOMCSSStyleDeclaration

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6525 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fixed several bad problems with the ObjC bindings. In particular, conversion
rjw [Fri, 30 Apr 2004 01:44:16 +0000 (01:44 +0000)]
Fixed several bad problems with the ObjC bindings.  In particular, conversion
to/from JavaScriptObject (soon to be WebScriptObject) was completely broken.

        Reviewed by Chris.

        * bindings/objc/objc_jsobject.h:
        * bindings/objc/objc_jsobject.mm:
        (-[JavaScriptObject initWithObjectImp:KJS::root:Bindings::]):
        (-[JavaScriptObject KJS::]):
        (+[JavaScriptObject _convertValueToObjcValue:KJS::root:Bindings::]):
        (-[JavaScriptObject call:arguments:]):
        (-[JavaScriptObject evaluate:]):
        (-[JavaScriptObject getMember:]):
        (-[JavaScriptObject getSlot:]):
        * bindings/objc/objc_runtime.mm:
        (ObjcField::valueFromInstance):
        (ObjcField::setValueToInstance):
        * bindings/objc/objc_utility.mm:
        (KJS::Bindings::convertValueToObjcValue):
        (KJS::Bindings::convertObjcValueToValue):
        * bindings/runtime.h:
        * bindings/runtime_root.cpp:
        (KJS::Bindings::rootForInterpreter):
        (KJS::Bindings::addNativeReference):
        (KJS::Bindings::removeNativeReference):
        * bindings/runtime_root.h:
        * bindings/testbindings.mm:
        (-[MyFirstInterface logMessage:]):
        (-[MyFirstInterface setJSObject:]):
        (-[MyFirstInterface callJSObject::]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6524 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Expose summary on tables.
hyatt [Thu, 29 Apr 2004 23:26:02 +0000 (23:26 +0000)]
Expose summary on tables.

        Reviewed by darin

        * kwq/KWQAccObject.mm:
        (-[KWQAccObject helpText]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6523 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Implement image maps for accessibility.
hyatt [Thu, 29 Apr 2004 23:08:13 +0000 (23:08 +0000)]
Implement image maps for accessibility.

        Reviewed by darin

        * khtml/html/html_imageimpl.cpp:
        (HTMLAreaElementImpl::getRect):
        * khtml/html/html_imageimpl.h:
        * khtml/rendering/render_image.cpp:
        (RenderImage::imageMap):
        (RenderImage::nodeAtPoint):
        * khtml/rendering/render_image.h:
        * kwq/KWQAccObject.h:
        * kwq/KWQAccObject.mm:
        (-[KWQAccObject initWithRenderer:]):
        (-[KWQAccObject anchorElement]):
        (-[KWQAccObject parentObject]):
        (-[KWQAccObject parentObjectUnignored]):
        (-[KWQAccObject addChildrenToArray:]):
        (-[KWQAccObject role]):
        (-[KWQAccObject helpText]):
        (-[KWQAccObject value]):
        (-[KWQAccObject title]):
        (-[KWQAccObject position]):
        (-[KWQAccObject size]):
        (-[KWQAccObject accessibilityIsIgnored]):
        (-[KWQAccObject accessibilityAttributeNames]):
        (-[KWQAccObject accessibilityAttributeValue:]):
        * kwq/KWQRegion.mm:
        (QRegion::boundingRect):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6522 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fixed:
cblu [Thu, 29 Apr 2004 21:30:47 +0000 (21:30 +0000)]
Fixed:
<rdar://problem/3631431>: web archive of .Mac welcome page renders has gaps in layout
<rdar://problem/3631470>: news.google.com web archive has a different font than the live site

        Reviewed by kocienda.

        * khtml/html/html_documentimpl.cpp:
        (HTMLDocumentImpl::determineParseMode): don't set a name on the doc type when there is no doc type in the source
        * khtml/xml/dom_docimpl.cpp:
        (DocumentTypeImpl::toString): don't return "<!DOCTYPE>" when there is no doc type in the source
        * khtml/xml/dom_nodeimpl.cpp:
        (NodeImpl::recursive_toHTMLWithOptions): don't escape STYLE text, don't include the end tags for document nodes just as we don't for start tags

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6521 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
darin [Thu, 29 Apr 2004 20:49:34 +0000 (20:49 +0000)]
    Reviewed by Dave.

        - some tweaks on image

        * khtml/html/html_imageimpl.h: Remove unused noref bit and unneeded override of isURLAttribute.
        * khtml/html/html_imageimpl.cpp:
        (HTMLAreaElementImpl::HTMLAreaElementImpl): Remove unused noref bit.
        (HTMLAreaElementImpl::parseHTMLAttribute): Remove parsing of noref; no need to store the
        bit since it has no meaning.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6520 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago - more work on getting the font panel to work with editable HTML
sullivan [Thu, 29 Apr 2004 20:33:01 +0000 (20:33 +0000)]
    - more work on getting the font panel to work with editable HTML

        Reviewed by Ken.

        * WebView.subproj/WebView.m:
        (-[WebView computedStyleForElement:pseudoElement:]):
        convert nil pseudoElement to empty string because lower level chokes on nil
        (_fontFromStyle):
        I tried to implement this, but was thwarted by missing API, so I added a
        bunch of FIXMEs instead
        (_stylesRepresentSameFont):
        new function, not yet implementable
        (_stylesRepresentSameAttributes):
        new function, not yet implementable
        (-[WebView _updateFontPanel]):
        added code to get first and last element in selection, and to use
        NodeIterator to walk through the entire selection to see if more than one
        font or set of attributes is in use. However, createNodeIterator is declared
        in DOMTraversal.h but not actually defined anywhere, so I had to prevent this
        code from actually being called.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6519 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago 1. Change the role of links from AXButton to AXLink.
hyatt [Thu, 29 Apr 2004 18:52:06 +0000 (18:52 +0000)]
1. Change the role of links from AXButton to AXLink.
2. Add support for list markers using a new role, AXListMarker.

        Reviewed by kocienda

        * khtml/rendering/render_list.h:
        (khtml::RenderListMarker::text):
        * kwq/KWQAccObject.mm:
        (-[KWQAccObject role]):
        (-[KWQAccObject roleDescription]):
        (-[KWQAccObject value]):
        (-[KWQAccObject accessibilityIsIgnored]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6518 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Thu, 29 Apr 2004 16:20:36 +0000 (16:20 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3636566>: "space bar on a form button hits default button instead (autorestore.apple.com)"

        * khtml/html/html_formimpl.cpp: (HTMLInputElementImpl::defaultEventHandler):
        Remove special handling for space, falling back to default AppKit behavior. Change enter handling to
        click the form element itself in the case of elements other than text input ones.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6517 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Thu, 29 Apr 2004 15:24:22 +0000 (15:24 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3636673>: "unrepro nil-deref crash in KHTMLPart::frameDetached() (espn.com)"

        * kwq/KWQKHTMLPart.mm: (KHTMLPart::frameDetached): Check for nil.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6516 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago - Implemented DOMHTMLElementExtensions.
cblu [Thu, 29 Apr 2004 02:05:28 +0000 (02:05 +0000)]
- Implemented DOMHTMLElementExtensions.
- Added stubs for the rest of the DOM API.

        Reviewed by dave.

        * WebCore.pbproj/project.pbxproj:
        * khtml/dom/html_element.cpp:
        (HTMLElement::setContentEditable): moved implementation from here to HTMLElementImpl
        * khtml/html/html_elementimpl.cpp:
        (HTMLElementImpl::setContentEditable): new, moved from HTMLElement
        * khtml/html/html_elementimpl.h:
        * kwq/DOM-CSS.mm:
        (-[DOMObject sheet]):
        (-[DOMDocument getComputedStyle::]):
        * kwq/DOM.mm:
        (-[DOMAbstractView document]):
        (-[DOMDocumentView defaultView]):
        (-[DOMDocument createNodeIterator::::]):
        (-[DOMDocument createTreeWalker::::]):
        (-[DOMNodeFilter acceptNode:]):
        (-[DOMNodeIterator root]):
        (-[DOMNodeIterator whatToShow]):
        (-[DOMNodeIterator filter]):
        (-[DOMNodeIterator expandEntityReferences]):
        (-[DOMNodeIterator nextNode]):
        (-[DOMNodeIterator previousNode]):
        (-[DOMNodeIterator detach]):
        (-[DOMTreeWalker root]):
        (-[DOMTreeWalker whatToShow]):
        (-[DOMTreeWalker filter]):
        (-[DOMTreeWalker expandEntityReferences]):
        (-[DOMTreeWalker currentNode]):
        (-[DOMTreeWalker setCurrentNode:]):
        (-[DOMTreeWalker parentNode]):
        (-[DOMTreeWalker firstChild]):
        (-[DOMTreeWalker lastChild]):
        (-[DOMTreeWalker previousSibling]):
        (-[DOMTreeWalker nextSibling]):
        (-[DOMTreeWalker previousNode]):
        (-[DOMTreeWalker nextNode]):
        * kwq/DOMEvents.mm: Added.
        (-[DOMEvent type]):
        (-[DOMEvent target]):
        (-[DOMEvent currentTarget]):
        (-[DOMEvent eventPhase]):
        (-[DOMEvent bubbles]):
        (-[DOMEvent cancelable]):
        (-[DOMEvent timeStamp]):
        (-[DOMEvent stopPropagation]):
        (-[DOMEvent preventDefault]):
        (-[DOMEvent initEvent:::]):
        (-[DOMEventTarget addEventListener:::]):
        (-[DOMEventTarget removeEventListener:::]):
        (-[DOMEventTarget dispatchEvent:]):
        (-[DOMMouseEvent screenX]):
        (-[DOMMouseEvent screenY]):
        (-[DOMMouseEvent clientX]):
        (-[DOMMouseEvent clientY]):
        (-[DOMMouseEvent ctrlKey]):
        (-[DOMMouseEvent shiftKey]):
        (-[DOMMouseEvent altKey]):
        (-[DOMMouseEvent metaKey]):
        (-[DOMMouseEvent button]):
        (-[DOMMouseEvent relatedTarget]):
        (-[DOMMouseEvent initMouseEvent:::::::::::::::]):
        (-[DOMMutationEvent relatedNode]):
        (-[DOMMutationEvent prevValue]):
        (-[DOMMutationEvent newValue]):
        (-[DOMMutationEvent attrName]):
        (-[DOMMutationEvent attrChange]):
        (-[DOMMutationEvent initMutationEvent::::::::]):
        (-[DOMUIEvent view]):
        (-[DOMUIEvent detail]):
        (-[DOMUIEvent initUIEvent:::::]):
        (-[DOMDocument createEvent:]):
        * kwq/DOMHTML.mm:
        (-[DOMHTMLElement innerHTML]): implemented
        (-[DOMHTMLElement setInnerHTML:]): implemented
        (-[DOMHTMLElement innerText]): implemented
        (-[DOMHTMLElement setInnerText:]): implemented
        (-[DOMHTMLElement children]): implemented
        (-[DOMHTMLElement contentEditable]): implemented
        (-[DOMHTMLElement setContentEditable:]): implemented
        (-[DOMHTMLElement isContentEditable]): implemented

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6515 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Implement sharing of similar style objects. Cuts the # of style objects allocated...
hyatt [Thu, 29 Apr 2004 01:19:04 +0000 (01:19 +0000)]
Implement sharing of similar style objects. Cuts the # of style objects allocated on the PLT by more
than half.

        Reviewed by kocienda

        * khtml/css/cssstyleselector.cpp:
        (khtml::CSSStyleSelector::initElementAndPseudoState):
        (khtml::CSSStyleSelector::initForStyleResolve):
        (khtml::cleanpath):
        (khtml::checkPseudoState):
        (khtml::CSSStyleSelector::locateSiblingList):
        (khtml::CSSStyleSelector::canShareStyleWithElement):
        (khtml::CSSStyleSelector::locateSharedStyle):
        (khtml::CSSStyleSelector::styleForElement):
        (khtml::CSSStyleSelector::pseudoStyleForElement):
        (khtml::CSSStyleSelector::checkOneSelector):
        * khtml/css/cssstyleselector.h:
        * khtml/css/html4.css:
        * khtml/css/parser.cpp:
        * khtml/css/parser.y:
        * khtml/html/html_baseimpl.cpp:
        (HTMLBodyElementImpl::mapToEntry):
        (HTMLIFrameElementImpl::mapToEntry):
        * khtml/html/html_baseimpl.h:
        * khtml/html/html_blockimpl.cpp:
        (HTMLDivElementImpl::mapToEntry):
        (HTMLHRElementImpl::mapToEntry):
        (HTMLParagraphElementImpl::mapToEntry):
        (HTMLMarqueeElementImpl::mapToEntry):
        * khtml/html/html_blockimpl.h:
        * khtml/html/html_elementimpl.cpp:
        (HTMLNamedAttrMapImpl::declCount):
        (HTMLNamedAttrMapImpl::mapsEquivalent):
        (HTMLElementImpl::attributeChanged):
        (HTMLElementImpl::mapToEntry):
        * khtml/html/html_elementimpl.h:
        (DOM::HTMLElementImpl::isMappedAttribute):
        * khtml/html/html_formimpl.cpp:
        (HTMLInputElementImpl::mapToEntry):
        * khtml/html/html_formimpl.h:
        * khtml/html/html_imageimpl.cpp:
        (HTMLImageElementImpl::mapToEntry):
        * khtml/html/html_imageimpl.h:
        * khtml/html/html_inlineimpl.cpp:
        (HTMLBRElementImpl::mapToEntry):
        (HTMLFontElementImpl::mapToEntry):
        * khtml/html/html_inlineimpl.h:
        * khtml/html/html_listimpl.cpp:
        (HTMLUListElementImpl::mapToEntry):
        (HTMLOListElementImpl::mapToEntry):
        (HTMLLIElementImpl::mapToEntry):
        * khtml/html/html_listimpl.h:
        * khtml/html/html_objectimpl.cpp:
        (HTMLAppletElementImpl::mapToEntry):
        (HTMLEmbedElementImpl::mapToEntry):
        (HTMLObjectElementImpl::mapToEntry):
        * khtml/html/html_objectimpl.h:
        * khtml/html/html_tableimpl.cpp:
        (HTMLTableElementImpl::mapToEntry):
        (HTMLTablePartElementImpl::mapToEntry):
        (HTMLTableCellElementImpl::mapToEntry):
        (HTMLTableColElementImpl::mapToEntry):
        (HTMLTableCaptionElementImpl::mapToEntry):
        * khtml/html/html_tableimpl.h:
        * khtml/rendering/render_object.cpp:
        (RenderObject::setStyle):
        * khtml/rendering/render_style.cpp:
        (m_affectedByAttributeSelectors):
        (RenderStyle::RenderStyle):
        * khtml/rendering/render_style.h:
        (khtml::):
        (khtml::RenderStyle::pseudoState):
        (khtml::RenderStyle::setPseudoState):
        (khtml::RenderStyle::affectedByAttributeSelectors):
        (khtml::RenderStyle::setAffectedByAttributeSelectors):
        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::DocumentImpl):
        * khtml/xml/dom_docimpl.h:
        (DOM::DocumentImpl::usesSiblingRules):
        (DOM::DocumentImpl::setUsesSiblingRules):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6514 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago - Made WebArchive and WebResource conform to NSCoding and NSCopying.
cblu [Thu, 29 Apr 2004 00:56:23 +0000 (00:56 +0000)]
- Made WebArchive and WebResource conform to NSCoding and NSCopying.

        Reviewed by rjw.

        * DOM.subproj/WebDOMOperations.h: added header doc comment for WebArchive methods
        * WebView.subproj/WebArchive.h:
        * WebView.subproj/WebArchive.m:
        (-[WebArchive initWithCoder:]): new
        (-[WebArchive encodeWithCoder:]): new
        (-[WebArchive copyWithZone:]): new
        * WebView.subproj/WebResource.h:
        * WebView.subproj/WebResource.m:
        (-[WebResource init]): new
        (-[WebResource initWithData:URL:MIMEType:textEncodingName:frameName:]): call [self init]
        (-[WebResource initWithCoder:]): new
        (-[WebResource encodeWithCoder:]): new
        (-[WebResource copyWithZone:]): new

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6513 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Chris.
darin [Wed, 28 Apr 2004 22:49:49 +0000 (22:49 +0000)]
    Reviewed by Chris.

        - another step of refinement on the reinterpret_cast stuff; now it's a compile-time
          error if you do it wrong
        - fixed a couple of storage leaks

        * kwq/DOMInternal.h: Added new DOM_cast template function. Like reinterpret_cast, but a
        compile-time error if you use it with the wrong parameters. Also added type-safe versions
        of the wrapper functions that do the DOM_cast automatically.
        * kwq/DOMInternal.mm:
        (getDOMWrapperImpl): Changed name and parameter type as part of above change.
        (addDOMWrapperImpl): Ditto.
        (removeDOMWrapper): Ditto.

        * kwq/DOM.mm: Use the new DOM_cast instead of reinterpret_cast, and the new
        DOM wrapper calls that do the cast automatically.
        * kwq/DOM-CSS.mm: More of the same.
        (-[DOMCSSStyleSheet dealloc]): Added override to deref, fixes leak.
        * kwq/DOMHTML.mm: More of the same.
        (-[DOMHTMLCollection dealloc]): Added override to deref, fixes leak.
        (-[DOMHTMLOptionsCollection dealloc]): Added override to deref, fixes theoretical leak.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6512 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago A little bit more progress in wiring up the font panel.
sullivan [Wed, 28 Apr 2004 21:44:51 +0000 (21:44 +0000)]
    A little bit more progress in wiring up the font panel.

        Reviewed by Ken.

        * WebView.subproj/WebViewInternal.h:
        put _updateFontPanel here. Also moved _isLoading here, since it was
        already in a category named WebInternal

        * WebView.subproj/WebView.m:
        (-[WebView _isLoading]):
        moved into WebInternal category implementation
        (_textAttributesFromStyle):
        changed from method to function
        (_fontFromStyle):
        added, guts not filled in yet
        (-[WebView _updateFontPanel]):
        now calls these two functions (but results are always nil)
        (-[WebView setSelectedDOMRange:affinity:]):
        remove call to _updateFontPanel here since it's now called in
        the proper bottleneck

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge postDidChangeNotification]):
        call -[WebView _updateFontPanel] in addition to sending notification
        (-[WebBridge postDidChangeSelectionNotification]):
        ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6507 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebKit:
sullivan [Wed, 28 Apr 2004 20:05:38 +0000 (20:05 +0000)]
WebKit:

        - fixed these bugs:
        <rdar://problem/3636570>: "API: [WebPreferences tabsToLinks] should be public API"
        <rdar://problem/3610597>: "API: could turn "stealth browsing" preference into API"

        Reviewed by Darin.

        I just moved the declarations and implementations from one place to another.
        (No clients in WebKit needed their #imports updated.) This confused cvs diff quite a bit.

        * WebView.subproj/WebPreferences.h:
        * WebView.subproj/WebPreferences.m:
        (-[WebPreferences setTabsToLinks:]):
        (-[WebPreferences tabsToLinks]):
        (-[WebPreferences setPrivateBrowsingEnabled:]):
        (-[WebPreferences privateBrowsingEnabled]):
        (-[WebPreferences _pageCacheSize]):
        (-[WebPreferences _objectCacheSize]):
        (-[WebPreferences _backForwardCacheExpirationInterval]):
        * WebView.subproj/WebPreferencesPrivate.h:

WebBrowser:

        - fixed up #imports for WebPreferencesPrivate

        Reviewed by Darin.

        * AppController.m:
        removed #import <WebKit/WebPreferencesPrivate.h>
        * BrowserWindowController.m:
        replaced #import <WebKit/WebPreferencesPrivate.h> with #import <WebKit/WebPreferences.h>
        * DownloadProgressEntry.m:
        ditto
        * FormCompletionController.m:
        ditto
        * Preferences.subproj/AdvancedPreferences.m:
        removed #import <WebKit/WebPreferencesPrivate.h>

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6506 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Cut the time spent on an operation inside widthForNextCharacter from 17% of the...
hyatt [Wed, 28 Apr 2004 19:52:35 +0000 (19:52 +0000)]
Cut the time spent on an operation inside widthForNextCharacter from 17% of the function time down to less than
5% merely by adding a check for non-zero letter-spacing (thus avoiding double precision math in the
common case where we just add 0 between letters).

        Reviewed by rjw

        * WebCoreSupport.subproj/WebTextRenderer.m:
        (widthForNextCharacter):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6505 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Initial plumbing to get the font panel to be updated from an editable
sullivan [Wed, 28 Apr 2004 18:45:45 +0000 (18:45 +0000)]
    Initial plumbing to get the font panel to be updated from an editable
        WebView.

        Reviewed by Ken.

        * WebView.subproj/WebView.m:
        (-[WebView _textAttributesFromStyle:]):
        new dummy method, will need implementation
        (-[WebView _updateFontPanel]):
        new method, sets the font shown in the font panel from the current
        selection. Lots of placeholder stuff.
        (-[WebView setSelectedDOMRange:affinity:]):
        call _updateFontPanel here for now.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6504 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Chris.
darin [Wed, 28 Apr 2004 18:12:01 +0000 (18:12 +0000)]
    Reviewed by Chris.

        - fixed reinterpret_cast mistakes and some style issues in DOM implementation

        * kwq/DOM-CSS.mm:
        (-[DOMCSSStyleRule _styleRuleImpl]): Fix broken reinterpret_cast; you must reinterpret_cast back
        to the class you reinterpret_casted from, not to a derived class.
        (-[DOMCSSMediaRule _mediaRuleImpl]): Ditto.
        (-[DOMCSSFontFaceRule _fontFaceRuleImpl]): Ditto.
        (-[DOMCSSPageRule _pageRuleImpl]): Ditto.
        (-[DOMCSSImportRule _importRuleImpl]): Ditto.
        (-[DOMCSSCharsetRule _importRuleImpl]): Ditto.
        * kwq/DOMHTML.mm:
        (-[DOMHTMLOptionsCollection length]): Put in an "unimplemented" version instead of leaving out
        the class implementation altogether.
        (-[DOMHTMLOptionsCollection setLength:]): Ditto.
        (-[DOMHTMLOptionsCollection item:]): Ditto.
        (-[DOMHTMLOptionsCollection namedItem:]): Ditto.
        (+[DOMHTMLElement _elementWithImpl:]): Corrected this implementation. The wrapper must use a
        standard node wrapper, since this is a subclass of DOMNode. Also moved into a separate category
        so it gets checked against the declarations above.
        (-[DOMHTMLElement _HTMLElementImpl]): Fix broken reinterpret_cast.
        (-[DOMHTMLHtmlElement _HTMLHtmlElementImpl]): Ditto.
        (-[DOMHTMLHeadElement _headElementImpl]): Ditto.
        (-[DOMHTMLLinkElement _linkElementImpl]): Ditto.
        (-[DOMHTMLTitleElement _titleElementImpl]): Ditto.
        (-[DOMHTMLMetaElement _metaElementImpl]): Ditto.
        (-[DOMHTMLBaseElement _baseElementImpl]): Ditto.
        (-[DOMHTMLStyleElement _styleElementImpl]): Ditto.
        (-[DOMHTMLBodyElement _bodyElementImpl]): Ditto.
        (-[DOMHTMLFormElement _formElementImpl]): Ditto.
        (+[DOMHTMLFormElement _formElementWithImpl:]): Another DOMNode subclass wrapper fix.
        (-[DOMHTMLIsIndexElement _isIndexElementImpl]): Fix broken reinterpret_cast.
        (-[DOMHTMLSelectElement _selectElementImpl]): Ditto.
        (-[DOMHTMLOptGroupElement _optGroupElementImpl]): Ditto.
        (-[DOMHTMLOptionElement _optionElementImpl]): Ditto.
        (-[DOMHTMLInputElement _inputElementImpl]): Ditto.
        (-[DOMHTMLTextAreaElement _textAreaElementImpl]): Ditto.
        (-[DOMHTMLButtonElement _buttonElementImpl]): Ditto.
        (-[DOMHTMLLabelElement _labelElementImpl]): Ditto.
        (-[DOMHTMLFieldSetElement _fieldSetElementImpl]): Ditto.
        (-[DOMHTMLLegendElement _legendElementImpl]): Ditto.
        (-[DOMHTMLUListElement _uListElementImpl]): Ditto.
        (-[DOMHTMLOListElement _oListElementImpl]): Ditto.
        (-[DOMHTMLDListElement _dListElementImpl]): Ditto.
        (-[DOMHTMLDirectoryElement _directoryListElementImpl]): Ditto.
        (-[DOMHTMLMenuElement _menuListElementImpl]): Ditto.
        (-[DOMHTMLLIElement _liElementImpl]): Ditto.
        (-[DOMHTMLQuoteElement _quoteElementImpl]): Ditto.
        (-[DOMHTMLDivElement _divElementImpl]): Ditto.
        (-[DOMHTMLParagraphElement _paragraphElementImpl]): Ditto.
        (-[DOMHTMLHeadingElement _headingElementImpl]): Ditto.
        (-[DOMHTMLPreElement _preElementImpl]): Ditto.
        (-[DOMHTMLBRElement _BRElementImpl]): Ditto.
        (-[DOMHTMLBaseFontElement _baseFontElementImpl]): Ditto.
        (-[DOMHTMLFontElement _fontElementImpl]): Ditto.
        (-[DOMHTMLHRElement _HRElementImpl]): Ditto.
        (-[DOMHTMLModElement _modElementImpl]): Ditto.
        (-[DOMHTMLAnchorElement _anchorElementImpl]): Ditto.
        (-[DOMHTMLImageElement _imageElementImpl]): Ditto.
        (-[DOMHTMLObjectElement _objectElementImpl]): Ditto.
        (-[DOMHTMLParamElement _paramElementImpl]): Ditto.
        (-[DOMHTMLAppletElement _appletElementImpl]): Ditto.
        (-[DOMHTMLMapElement _mapElementImpl]): Ditto.
        (-[DOMHTMLAreaElement _areaElementImpl]): Ditto.
        (-[DOMHTMLScriptElement _scriptElementImpl]): Ditto.
        (+[DOMHTMLTableCaptionElement _tableCaptionElementWithImpl:]): Another DOMNode subclass wrapper fix.
        (-[DOMHTMLTableCaptionElement _tableCaptionElementImpl]): Fix broken reinterpret_cast.
        (+[DOMHTMLTableSectionElement _tableSectionElementWithImpl:]): Another DOMNode subclass wrapper fix.
        (-[DOMHTMLTableSectionElement _tableSectionElementImpl]): Fix broken reinterpret_cast.
        (+[DOMHTMLTableElement _tableElementWithImpl:]): Another DOMNode subclass wrapper fix.
        (-[DOMHTMLTableElement _tableElementImpl]): Fix broken reinterpret_cast.
        (-[DOMHTMLTableColElement _tableColElementImpl]): Ditto.
        (-[DOMHTMLTableRowElement _tableRowElementImpl]): Ditto.
        (+[DOMHTMLTableCellElement _tableCellElementWithImpl:]): Another DOMNode subclass wrapper fix.
        (-[DOMHTMLTableCellElement _tableCellElementImpl]): Fix broken reinterpret_cast.
        (-[DOMHTMLFrameSetElement _frameSetElementImpl]): Ditto.
        (-[DOMHTMLFrameElement _frameElementImpl]): Ditto.
        (-[DOMHTMLIFrameElement _IFrameElementImpl]): Ditto.
        (-[DOMHTMLEmbedElement _embedElementImpl]): Ditto.

        * kwq/HTMLDOM.mm: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6503 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
kocienda [Wed, 28 Apr 2004 16:55:28 +0000 (16:55 +0000)]
WebCore:

        Reviewed by Darin

        * khtml/khtml_part.cpp:
        (KHTMLPart::notifySelectionChanged): Call new postDidChangeSelectionNotification function
        to send Cocoa notification when the selection changes.
        (KHTMLPart::appliedEditing): Call postDidChangeNotification to send Cocoa notification when the document changes
        due to editing.
        (KHTMLPart::unappliedEditing): Ditto.
        (KHTMLPart::reappliedEditing): Ditto.
        * kwq/DOMHTML.mm:
        (-[DOMHTMLDocument _HTMLDocumentImpl]): Fix cast to account for multiple inheritance used by the impl class.
        * kwq/KWQKHTMLPart.h:
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::postDidChangeSelectionNotification): New function. Call the bridge to post the notification.
        (KWQKHTMLPart::postDidChangeNotification): Ditto.
        * kwq/WebCoreBridge.h: Declare new -postDidChangeSelectionNotification and -postDidChangeNotification methods.

WebKit:

        Reviewed by Darin

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge postDidChangeNotification]): Posts Cocoa notification when the document changes
        due to editing.
        (-[WebBridge postDidChangeSelectionNotification]): Posts Cocoa notification when the document selection
        changes.
        * WebKit.exp: Export editing notification string constants.
        * WebView.subproj/WebView.m: Define editing notification string constants.
        (-[WebView computedStyleForElement:pseudoElement:]): Add implementation.
        (-[WebView setEditingDelegate:]): Do work to set up delegate to receive notification callbacks.
        (-[WebView DOMDocument]): Simplify to just call the bridge DOMDocument. No need to jump through hoops here.
        (-[WebView insertNewline:]): Consult delegate before taking action.
        (-[WebView deleteBackward:]): Ditto.
        (-[WebView insertText:]): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6502 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Wed, 28 Apr 2004 16:21:56 +0000 (16:21 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3636261>: "nil-deref in selectedStylesheetSet iterating through properties in a non-view document"

        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::selectedStylesheetSet): Add nil check.
        (DocumentImpl::setSelectedStylesheetSet): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6501 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fixed broken development build.
sullivan [Wed, 28 Apr 2004 01:32:55 +0000 (01:32 +0000)]
    Fixed broken development build.

        * WebView.subproj/WebFrame.m:
        (-[WebFrame _transitionToLayoutAcceptable]):
        updated bad variable name used only in LOG statement to match
        recent change.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6499 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
rjw [Wed, 28 Apr 2004 01:00:47 +0000 (01:00 +0000)]
WebCore:
<rdar://problem/3564519>: API: please add a way to set the media type for a WebView

        Reviewed by Chris.

        * khtml/khtmlview.cpp:
        (KHTMLView::mediaType):
        * kwq/KWQKHTMLPart.h:
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::overrideMediaType):
        * kwq/WebCoreBridge.h:

WebKit:
<rdar://problem/3279301>: API: WebKitErrorCannotFindPlugin and WebKitErrorCannotLoadPlugin should use PlugIn

<rdar://problem/3278513>: API: Need API to control the size of WebHistory

<rdar://problem/3564519>: API: please add a way to set the media type for a WebView
<rdar://problem/3565642>: API: allow a way to extend the MIME types that a WebView will display
<rdar://problem/3577693>: API: add ability to subclass WebView but still use it with Carbon

Reviewed by Chris.

        * Carbon.subproj/HIWebView.h:
        * Carbon.subproj/HIWebView.m:
        (HIWebViewCreate):
        (HIWebViewCreateWithClass):
        (HIWebViewConstructor):
        * History.subproj/WebHistory.h:
        * History.subproj/WebHistory.m:
        (-[WebHistoryPrivate setHistoryAgeInDaysLimit:]):
        (-[WebHistoryPrivate historyAgeInDaysLimit]):
        (-[WebHistoryPrivate setHistoryItemLimit:]):
        (-[WebHistoryPrivate historyItemLimit]):
        (-[WebHistoryPrivate _ageLimitDate]):
        (-[WebHistoryPrivate arrayRepresentation]):
        (-[WebHistory setHistoryItemLimit:]):
        (-[WebHistory historyItemLimit]):
        (-[WebHistory setHistoryAgeInDaysLimit:]):
        (-[WebHistory historyAgeInDaysLimit]):
        * History.subproj/WebHistoryPrivate.h:
        * Misc.subproj/WebKitErrors.h:
        * Misc.subproj/WebKitErrors.m:
        (registerErrors):
        * Plugins.subproj/WebNetscapePluginDocumentView.m:
        (-[WebNetscapePluginDocumentView setDataSource:]):
        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge isViewSelected:]):
        (-[WebBridge overrideMediaType]):
        * WebView.subproj/WebView.h:
        * WebView.subproj/WebView.m:
        (-[WebViewPrivate dealloc]):
        (+[WebView MIMETypesShownAsHTML]):
        (+[WebView setMIMETypesShownAsHTML:]):
        (-[WebView customUserAgent]):
        (-[WebView setMediaStyle:]):
        (-[WebView mediaStyle]):
        * WebView.subproj/WebViewPrivate.h:

WebBrowser:
<rdar://problem/3279301>: API: WebKitErrorCannotFindPlugin and WebKitErrorCannotLoadPlugin should use PlugIn

        Reviewed by Chris.

        * LoadProgressMonitor.m:
        (-[LoadProgressMonitor webView:plugInFailedWithError:dataSource:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6498 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Eliminate the preferences for timed/resource layouts. Accessing them is now taking...
hyatt [Tue, 27 Apr 2004 23:29:05 +0000 (23:29 +0000)]
Eliminate the preferences for timed/resource layouts.  Accessing them is now taking 0.5% on the cvs-base
test, so we're just going to hardcode the values instead.

        Reviewed by mjs

        * WebView.subproj/WebFrame.m:
        (-[WebFrame _transitionToLayoutAcceptable]):
        (-[WebFrame _isLoadComplete]):
        * WebView.subproj/WebPreferences.m:
        (+[WebPreferences initialize]):
        (-[WebPreferences _objectCacheSize]):
        * WebView.subproj/WebPreferencesPrivate.h:
        * WebView.subproj/WebView.m:
        (-[WebView _mainReceivedBytesSoFar:fromDataSource:complete:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6497 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
kocienda [Tue, 27 Apr 2004 22:57:31 +0000 (22:57 +0000)]
WebCore:

        Reviewed by Hyatt

        Make selections draw in a more Cocoa-like way, where
        fully-selected lines draw out to the ends of lines, and
        spaces between lines are drawn with the selection color as well.

        * WebCore-combined.exp: Add _WebCoreInitializeEmptyTextGeometry symbol
        * WebCore.exp: Ditto.
        * khtml/khtml_part.cpp:
        (KHTMLPart::isPointInsideSelection): Marginally-related change. Fix up this function
        so that it works right, given my recent changes to positionForCoordinates. This fix
        "really" fixes the problem. Unlike my attempt to fix yesterday.
        * khtml/rendering/font.cpp:
        (Font::drawHighlightForText): New drawHighlightForText interface which includes extra
        information to draw the selection.
        * khtml/rendering/font.h: Ditto.
        * khtml/rendering/render_block.cpp:
        (khtml::RenderBlock::positionForCoordinates): Some minor improvements and cleanups to
        make this code work correctly in more cases.
        * khtml/rendering/render_block.h: Remove spurious semi-colon after namespace block.
        * khtml/rendering/render_container.cpp:
        (RenderContainer::positionForCoordinates): Fix typo in comment. Also, clean up
        one unnecessary call to absolutePosition.
        * khtml/rendering/render_image.cpp:
        (RenderImage::paint): Many changes to add the new selection drawing behavior.
        * khtml/rendering/render_inline.cpp:
        (RenderInline::positionForCoordinates): Added to help make selections work right
        with continuations.
        * khtml/rendering/render_inline.h: Ditto.
        * khtml/rendering/render_object.h: Give zero default argument to inlineBox() helper.
        * khtml/rendering/render_text.cpp:
        (InlineTextBox::paintSelection): Many changes to add the new selection drawing behavior.
        * kwq/KWQListBox.mm:
        (-[KWQTableView drawRow:clipRect:]): Use new WebCoreTextGeometry struct.
        * kwq/KWQPainter.h: New drawHighlightForText interface which includes extra
        information to draw the selection.
        * kwq/KWQPainter.mm:
        (QPainter::drawText): Use new WebCoreInitializeEmptyTextGeometry struct.
        (QPainter::drawHighlightForText): Use new WebCoreTextGeometry struct.
        * kwq/WebCoreTextRenderer.h: Declare new WebCoreTextGeometry struct.
        * kwq/WebCoreTextRendererFactory.m:
        (WebCoreInitializeEmptyTextGeometry): Initializer for WebCoreTextGeometry struct.

WebKit:

        Reviewed by Hyatt

        Make selections draw in a more Cocoa-like way, where
        fully-selected lines draw out to the ends of lines, and
        spaces between lines are drawn with the selection color as well.

        * Misc.subproj/WebKitNSStringExtras.m: Use new WebCoreTextGeometry struct. No change in functionality.
        * WebCoreSupport.subproj/WebTextRenderer.m:
        (-[WebTextRenderer drawRun:style:geometry:]): Use new WebCoreTextGeometry struct. No change in functionality.
        (-[WebTextRenderer drawHighlightForRun:style:geometry:]): Ditto.
        (-[WebTextRenderer _CG_drawHighlightForRun:style:geometry:]): Many changes to add the new selection drawing behavior.
        (-[WebTextRenderer _CG_drawRun:style:geometry:]):  Use new WebCoreTextGeometry struct. No change in functionality.
        (-[WebTextRenderer _ATSU_drawHighlightForRun:style:geometry:]): Many changes to add the new selection drawing behavior.
        (-[WebTextRenderer _ATSU_drawRun:style:geometry:]):  Use new WebCoreTextGeometry struct. No change in functionality.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6496 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Don't do unnecessary string comparisons when no composite operator is
rjw [Tue, 27 Apr 2004 19:54:04 +0000 (19:54 +0000)]
Don't do unnecessary string comparisons when no composite operator is
specified.

        Reviewed by Hyatt.

        * kwq/KWQPainter.mm:
        (compositeOperatorFromString):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6495 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Ken.
darin [Tue, 27 Apr 2004 17:38:07 +0000 (17:38 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3623694>: "top level <option> and <optgroup> labels look identical in pop-up menus; should not"

        * khtml/rendering/render_form.cpp: (RenderSelect::updateFromElement):
        Call appendGroupLabel instead of appendItem for group labels.

        * kwq/KWQComboBox.h: Added appendGroupLabel, private setControlSize, labelFont, setTitle, _labelFont,
        and make _items a QValueList<KWQListBoxItem> instead of QStringList.
        * kwq/KWQComboBox.mm:
        (QComboBox::QComboBox): Initializes _labelFont to nil.
        (QComboBox::~QComboBox): Release _labelFont.
        (QComboBox::setTitle): Added helper function. Uses an attributed string for group labels, and also sets
        the action to NULL so they are disabled.
        (QComboBox::appendItem): Added isLabel boolean parameter, make KWQListBoxItem, call setTitle.
        (QComboBox::sizeHint): Changed to handle group labels with a separate renderer to measure bolded text.
        (QComboBox::setCurrentItem): Changed to use setTitle helper.
        (QComboBox::setFont): Release _labelFont if control size changed.
        (QComboBox::labelFont): Compute label font lazily.
        (QComboBox::populateMenu): Changed to use setTitle helper.

        * kwq/KWQListBox.h: Removed excess includes, fixed comment.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6494 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Maciej.
darin [Tue, 27 Apr 2004 04:20:09 +0000 (04:20 +0000)]
    Reviewed by Maciej.

        - follow-on to fix for <rdar://problem/3488892>: "anchor names with non-ASCII characters in them do not work"
        This part fixes anchor names with non-ASCII characters in local files.

        * kwq/KWQKURL.mm: (KURL::KURL): For file and help URLs, force UTF-8 only for the path part of the URL.
        Use the document encoding for the rest of the URL.
        * kwq/KWQTextCodec.h: (operator!=): Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6493 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix for Emerson truncation problem using apple-line-clamp. Always dirty positioned...
hyatt [Tue, 27 Apr 2004 01:24:47 +0000 (01:24 +0000)]
Fix for Emerson truncation problem using apple-line-clamp.  Always dirty positioned objects so that they
will move when the height changes.

        Reviewed by darin

        * khtml/rendering/render_block.cpp:
        (khtml::RenderBlock::markPositionedObjectsForLayout):
        * khtml/rendering/render_block.h:
        * khtml/rendering/render_flexbox.cpp:
        (khtml::RenderFlexibleBox::layoutVerticalBox):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6492 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
rjw [Mon, 26 Apr 2004 23:10:44 +0000 (23:10 +0000)]
WebCore:
Added support for specifying composite operation on an
image element.  Attribute name is "composite", possible values
are:

clear,
copy
source-over
source-in
source-out
source-atop
destination-over
destination-in
destination-out
destination-atop
xor
darker
highlight
lighter

<img composite="source-over" src="triangle.png">
<img style="position:relative; left:-200px;" composite="destination-in" src="circle.png">

        Reviewed by Ken.

        * khtml/html/html_imageimpl.cpp:
        (HTMLImageElementImpl::parseHTMLAttribute):
        * khtml/html/html_imageimpl.h:
        (DOM::HTMLImageElementImpl::compositeOperator):
        * khtml/misc/htmlattrs.c:
        (findAttr):
        * khtml/misc/htmlattrs.h:
        * khtml/misc/htmlattrs.in:
        * khtml/rendering/render_image.cpp:
        (RenderImage::paint):
        * kwq/KWQPainter.h:
        * kwq/KWQPainter.mm:
        (compositeOperatorFromString):
        (QPainter::drawPixmap):
        * kwq/WebCoreImageRenderer.h:

WebKit:
Added support for specifying composite operation on an
image element, i.e.:

<img composite="source-over" src="triangle.png">
<img style="position:relative; left:-200px;" composite="destination-in" src="circle.png">

This feature was requested by the dashboard guys.  They can use it to apply
transparency masks to widgies.

        Reviewed by Ken.

        * WebCoreSupport.subproj/WebImageRenderer.h:
        * WebCoreSupport.subproj/WebImageRenderer.m:
        (-[WebImageRenderer initWithMIMEType:]):
        (-[WebImageRenderer initWithData:MIMEType:]):
        (-[WebImageRenderer initWithContentsOfFile:]):
        (-[WebImageRenderer copyWithZone:]):
        (-[WebImageRenderer drawClippedToValidInRect:fromRect:]):
        (-[WebImageRenderer drawImageInRect:fromRect:]):
        (-[WebImageRenderer drawImageInRect:fromRect:compositeOperator:]):

WebBrowser:
        Added debug menu to make browser window transparent.  Useful
        for testing widgies.

        * Debug/DebugUtilities.m:
        (-[DebugUtilities createDebugMenu]):
        (-[BrowserDocument toggleBackForwardEnabled:]):
        (-[BrowserDocument toggleTransparentWindow:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6491 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago More header doc changes after John's review.
cblu [Mon, 26 Apr 2004 22:19:24 +0000 (22:19 +0000)]
More header doc changes after John's review.

        * WebView.subproj/WebDataSourcePrivate.h:
        * WebView.subproj/WebResource.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6490 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoFix semicolon.
darin [Mon, 26 Apr 2004 22:03:14 +0000 (22:03 +0000)]
Fix semicolon.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6489 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago - fixed <rdar://problem/3634145>: "REGRESSION: nil-deref in QTextCodec::toUni...
darin [Mon, 26 Apr 2004 22:01:49 +0000 (22:01 +0000)]
    - fixed <rdar://problem/3634145>: "REGRESSION: nil-deref in QTextCodec::toUnicode every time loading page at wiki.wordpress.org"

        * kwq/KWQKURL.mm:
        (KURL::KURL): Simplify check for nil that defaults to UTF-8.
        (KURL::decode_string): Add a similar test here.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6488 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoUpdate layout tests to reflect WinIE body-height quirk.
hyatt [Mon, 26 Apr 2004 21:19:03 +0000 (21:19 +0000)]
Update layout tests to reflect WinIE body-height quirk.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6487 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Implement the quirk that makes the <body> and <html> size to fill the viewport in...
hyatt [Mon, 26 Apr 2004 21:16:21 +0000 (21:16 +0000)]
Implement the quirk that makes the <body> and <html> size to fill the viewport in quirks mode.  This
matches WinIE.

        Reviewed by john

        * khtml/rendering/render_box.cpp:
        (RenderBox::calcHeight):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6486 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago * WebView.subproj/WebDataSourcePrivate.h: added some header doc comments
cblu [Mon, 26 Apr 2004 18:52:12 +0000 (18:52 +0000)]
    * WebView.subproj/WebDataSourcePrivate.h: added some header doc comments
        * WebView.subproj/WebFramePrivate.h: fixed header doc typo

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6485 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by John
kocienda [Mon, 26 Apr 2004 18:34:18 +0000 (18:34 +0000)]
    Reviewed by John

        Fix for this bug:

        <rdar://problem/3633458>: "REGRESSION (125-137): Can't drag a selection unless it starts at beginning of line"

        * khtml/khtml_part.cpp:
        (KHTMLPart::isPointInsideSelection): I flubbed when I converted this
        code to use my new positionForCoordinates helper. I failed to add in
        the passed in values for x and y to the absolute coordinates for the
        clicked node. So, the "unless it starts at beginning of line" behavior
        is exactly as one would expect.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6484 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Eliminate overhangingContents. This concept was redundant with the overflowHeight...
hyatt [Mon, 26 Apr 2004 08:58:45 +0000 (08:58 +0000)]
Eliminate overhangingContents.  This concept was redundant with the overflowHeight mechanism that I
implemented some time ago, and in fact, it causes us to grovel through much more of the render tree
than we should when painting.  It turns out that none of the places that used this boolean needed
to any longer, and so the entire implementation can now be removed from the tree.

        Reviewed by mjs, darin

        * khtml/rendering/render_block.cpp:
        (khtml::RenderBlock::addChildToFlow):
        (khtml::RenderBlock::layoutBlock):
        (khtml::RenderBlock::paint):
        (khtml::RenderBlock::insertPositionedObject):
        * khtml/rendering/render_box.cpp:
        (RenderBox::calcHeight):
        * khtml/rendering/render_image.cpp:
        (RenderImage::setStyle):
        * khtml/rendering/render_inline.cpp:
        (RenderInline::addChildToFlow):
        * khtml/rendering/render_object.cpp:
        (RenderObject::RenderObject):
        (RenderObject::containingBlock):
        (RenderObject::information):
        (RenderObject::dump):
        (RenderObject::nodeAtPoint):
        * khtml/rendering/render_object.h:
        (khtml::RenderObject::minMaxKnown):
        * khtml/rendering/render_table.cpp:
        (RenderTable::layout):
        (RenderTable::paint):
        (RenderTableCell::paint):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6483 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix for 3258403, implement support for min-height and max-height on normal flow...
hyatt [Mon, 26 Apr 2004 06:38:10 +0000 (06:38 +0000)]
Fix for 3258403, implement support for min-height and max-height on normal flow elements.  With this patch the
only min-height/max-height work that remains to be done is for table cells and positioned elements.

        Reviewed by darin

        * khtml/rendering/render_box.cpp:
        (RenderBox::calcHeight):
        (RenderBox::calcHeightUsing):
        (RenderBox::calcPercentageHeight):
        * khtml/rendering/render_box.h:
        * layout-tests/fast/block/basic/minheight-expected.txt: Added.
        * layout-tests/fast/block/basic/minheight.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6482 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
darin [Mon, 26 Apr 2004 02:33:32 +0000 (02:33 +0000)]
    Reviewed by Dave.

        - fixed <rdar://problem/3633091>: "add overrideMimeType function to XMLHttpRequest"

        * khtml/ecma/xmlhttprequest.cpp:
        (KJS::XMLHttpRequest::getValueProperty): Add logic to override MIME type if
        OverrideMIMEType was called.
        (KJS::XMLHttpRequestProtoFunc::tryCall): Store the MIME type when overrideMimeType is called.
        * khtml/ecma/xmlhttprequest.h: Add OverrideMIMEType to the XMLHttpRequest property enum,
        and also add a MIMETypeOverride data member to the class.
        * khtml/ecma/xmlhttprequest.lut.h: Regenerated.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6481 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin.
mjs [Mon, 26 Apr 2004 00:08:34 +0000 (00:08 +0000)]
    Reviewed by Darin.

<rdar://problem/3628309>: Fedex tracking page so slow it seems like a hang (site change?)
<rdar://problem/3608061>: "ATI Developer site so slow it seems like a hang"
<rdar://problem/3612130>: "Reproducible hang in JavaScript at www.tfl.gov.uk"
<rdar://problem/3626022>: "Safari was consuming > 100% CPU on dual-G5 Mac, sample shows JavaScript"
<rdar://problem/3632348>: "www.whatis.com search for "pivot table" leads to JavaScript hang"

        * khtml/ecma/kjs_html.cpp:
        (KJS::HTMLElement::getValueProperty): The "text" property for anchors should be
innerText, not innerHTML.
        * khtml/html/html_elementimpl.cpp:
        (HTMLElementImpl::innerText): Make sure not to include all the text after an
element if it has no children.
        * layout-tests/fast/dom/anchor-text-expected.txt: Added.
        * layout-tests/fast/dom/anchor-text.html: Added.
        * layout-tests/fast/dom/inner-text-expected.txt: Added.
        * layout-tests/fast/dom/inner-text.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6480 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
darin [Sun, 25 Apr 2004 15:10:57 +0000 (15:10 +0000)]
    Reviewed by Dave.

        - fixed <rdar://problem/3488892>: "anchor names with non-ASCII characters in them do not work"

        * khtml/khtml_part.h: Add new gotoAnchor helper function, private.
        * khtml/khtml_part.cpp:
        (KHTMLPart::openURL): Call new gotoAnchor helper, since the code is now complex enough
        that I don't want to copy and paste.
        (KHTMLPart::gotoAnchor): Use the pages own encoding when decoding the string for an
        anchor reference when going to an anchor. This matches the behavior of other browsers.
        (KHTMLPart::slotFinishedParsing): Call new gotoAnchor helper.
        * kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::scrollToAnchor): Call new gotoAnchor helper.

        * kwq/KWQKURL.h: Removed htmlRef function, and made encodedHtmlRef an inline.
        Removed unused encoding hint parameter from setQuery (it's not a "hint" at all, but we
        don't use it). Added a codec parameter to decode_string.
        * kwq/KWQKURL.mm:
        (hexDigitValue): Added. Helper function.
        (KURL::setQuery): Removed unused parameter.
        (KURL::decode_string): Implemented this function. It needs to use an encoding specified
        by the web page. Also, we wanted to make a version that did not use the
        CFURLCreateStringByReplacingPercentEscapes function anyway.

        * kwq/KWQString.h: Added parameters to copyLatin1. Now you can copy an arbitrary substring.
        * kwq/KWQString.mm: (QString::copyLatin1): Updated implementation to handle the two
        new parameters.

        * WebCore-tests.exp: Updated for change in signature of setQuery and decode_string.
        * WebCore-combined.exp: Regenerated.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6479 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
darin [Sun, 25 Apr 2004 15:10:32 +0000 (15:10 +0000)]
    Reviewed by Dave.

        * kjs/ustring.cpp: (KJS::UString::append): Fix one case that was allocating a buffer
        that is 2x too big.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6478 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Dave.
darin [Sun, 25 Apr 2004 15:10:24 +0000 (15:10 +0000)]
    Reviewed by Dave.

        * Misc.subproj/WebNSURLExtras.m: (hexDigit): Use capitalized hex, not lowercase, for consistency
        with similar functions in WebCore and what other web browsers do.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6477 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years agoWebCore:
darin [Sun, 25 Apr 2004 02:46:09 +0000 (02:46 +0000)]
WebCore:

        - fixed <rdar://problem/3570953>: "Update "Acknowledgements" to remove expat and possibly include libxml"

        * WebCore.pbproj/project.pbxproj: Removed the part of the copyright notice that was for expat contributors.

WebBrowser:

        - fixed <rdar://problem/3570953>: "Update "Acknowledgements" to remove expat and possibly include libxml"

        * Help/Acknowledgments.rtf: New version of the file from legal, removing expat-related section.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6476 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Maciej.
darin [Sat, 24 Apr 2004 02:50:22 +0000 (02:50 +0000)]
    Reviewed by Maciej.

        - fixed <rdar://problem/3627362>: "bad access with libgmalloc in -[_WebCoreHistoryProvider containsItemForURLUnicode:length:]"

        * History.subproj/WebHistory.m:
        (-[_WebCoreHistoryProvider containsItemForURLUnicode:length:]): Add range checks so we
        don't overrun the buffer while looking for slashes.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6475 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix the apple-line-clamp values to more closely match what is needed, an even split...
hyatt [Fri, 23 Apr 2004 23:57:49 +0000 (23:57 +0000)]
Fix the apple-line-clamp values to more closely match what is needed, an even split of the max lines between the possible
values.

        * khtml/rendering/render_flexbox.cpp:
        (khtml::RenderFlexibleBox::layoutVerticalBox):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6474 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix to make the containing block percentage height calculation actually work accordi...
hyatt [Fri, 23 Apr 2004 23:43:33 +0000 (23:43 +0000)]
Fix to make the containing block percentage height calculation actually work according to the CSS2 spec.
Percentages other than 100% are now supported, and flexing percentage height blocks inside table cells
are now supported.

        Reviewed by kocienda

        * khtml/rendering/render_box.cpp:
        (RenderBox::calcHeight):
        (RenderBox::calcPercentageHeight):
        * khtml/rendering/render_box.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6473 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin.
mjs [Fri, 23 Apr 2004 22:40:31 +0000 (22:40 +0000)]
    Reviewed by Darin.

Implementation of conservative GC, based partly on code from
Darin. It's turned off for now, so it shouldn't have any effect on
the normal build.

        * JavaScriptCore.pbproj/project.pbxproj:
        * kjs/collector.cpp:
        (KJS::Collector::markStackObjectsConservatively):
        (KJS::Collector::markProtectedObjects):
        (KJS::Collector::collect):
        * kjs/collector.h:
        * kjs/protect.h:
        (KJS::gcProtect):
        (KJS::gcUnprotect):
        * kjs/protected_values.cpp: Added.
        (KJS::ProtectedValues::getProtectCount):
        (KJS::ProtectedValues::increaseProtectCount):
        (KJS::ProtectedValues::insert):
        (KJS::ProtectedValues::decreaseProtectCount):
        (KJS::ProtectedValues::expand):
        (KJS::ProtectedValues::shrink):
        (KJS::ProtectedValues::rehash):
        (KJS::ProtectedValues::computeHash):
        * kjs/protected_values.h: Added.
        * kjs/value.cpp:
        (ValueImp::useConservativeMark):
        (ValueImp::mark):
        (ValueImp::marked):
        * kjs/value.h:
        (KJS::ValueImp::):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6472 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by John
kocienda [Fri, 23 Apr 2004 21:20:50 +0000 (21:20 +0000)]
    Reviewed by John

        Fix for this bug:
        <rdar://problem/3632163>: "REGRESSSION: crash on css home page"

        * khtml/rendering/render_block.cpp:
        (khtml::RenderBlock::positionForRenderer): Add null check.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6471 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by John
cblu [Fri, 23 Apr 2004 21:17:54 +0000 (21:17 +0000)]
Reviewed by John

Added header doc comments to proposed API's.

        * WebView.subproj/WebArchive.h:
        * WebView.subproj/WebFramePrivate.h:
        * WebView.subproj/WebResource.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6470 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Fix hiermenu opacity bug. Make sure to save/restore the graphics state before pushi...
hyatt [Fri, 23 Apr 2004 19:01:51 +0000 (19:01 +0000)]
Fix hiermenu opacity bug.  Make sure to save/restore the graphics state before pushing and popping
transparency layers, so that alterations to alpha don't accidentally persist.

        Reviewed by kocienda

        * kwq/KWQPainter.mm:
        (QPainter::beginTransparencyLayer):
        (QPainter::endTransparencyLayer):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6469 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin
kocienda [Fri, 23 Apr 2004 17:18:08 +0000 (17:18 +0000)]
    Reviewed by Darin

        Changed inlineBoxForRenderer(RenderObject *, int) helper that was static
        in dom_position.cpp into a virtual method on RenderObjects. Function is
        now called inlineBox(int). Functionality unchanged.

        * khtml/rendering/render_br.cpp:
        (RenderBR::inlineBox)
        * khtml/rendering/render_br.h:
        * khtml/rendering/render_object.cpp:
        (RenderObject::caretMaxRenderedOffset)
        (RenderObject::inlineBox)
        * khtml/rendering/render_object.h:
        * khtml/rendering/render_text.cpp:
        (RenderText::inlineBox)
        * khtml/rendering/render_text.h:
        * khtml/xml/dom_position.cpp:
        (DOM::renderersOnDifferentLine):
        (DOM::nextRenderedEditable)
        (DOM::previousRenderedEditable)
        (DOM::Position::previousLinePosition)
        (DOM::Position::nextLinePosition)
        (DOM::Position::rendersInDifferentPosition)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6468 268f45cc-cd09-0410-ab3c-d52691b4dbfc

16 years ago Reviewed by Darin
kocienda [Fri, 23 Apr 2004 17:02:31 +0000 (17:02 +0000)]
    Reviewed by Darin

        * khtml/editing/htmlediting_impl.cpp:
        (DeleteSelectionCommandImpl::doApply): Fix editing test
        regression with deleting whitespace at the end of the line.
        I just made this "improvement" yesterday, and the concept
        of the change is a good one, but instead of short-circuiting
        if the selection after deleting collapsible whitespace is a
        range (which can be confused by "significant" collapsed
        whitespace at the end of a line), short-circuit if the
        upstream start position equals the downstream end position.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6467 268f45cc-cd09-0410-ab3c-d52691b4dbfc