18 years ago Reviewed by Maciej.
darin [Mon, 13 Sep 2004 06:05:36 +0000 (06:05 +0000)]
    Reviewed by Maciej.

        - fixed <rdar://problem/3792082> zero character codes in UTF-16 input cause crash

        * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertUTF16): Fixed code that was using the wrong variable
        to decrement the input length, causing buffer overrun.

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

18 years ago Reviewed by Maciej.
darin [Mon, 13 Sep 2004 06:04:12 +0000 (06:04 +0000)]
    Reviewed by Maciej.

        - fixed <rdar://problem/3798240> computed style error log messages seen with numbers in the range 74-77

        * khtml/css/css_computedstyle.cpp: (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):

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

18 years ago * layout-tests/css1/text_properties/text-transform-expected.txt: Removed...
darin [Mon, 13 Sep 2004 06:03:25 +0000 (06:03 +0000)]
    * layout-tests/css1/text_properties/text-transform-expected.txt: Removed unused test result.

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

18 years ago Reviewed by Darin.
mjs [Sat, 11 Sep 2004 08:22:27 +0000 (08:22 +0000)]
    Reviewed by Darin.

<rdar://problem/3787208> can't log in to SAP SDN site (JS parse error)

        * kwq/KWQKURL.mm:
        (KURL::decode_string): Check for find result >= 0 instead of >0,
to handle case of first character in a string being encoded.

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

18 years ago Fixed <rdar://problem/3782533> CrashTracer: .1459 crashes at com.apple.WebKit...
rjw [Fri, 10 Sep 2004 23:26:36 +0000 (23:26 +0000)]
    Fixed <rdar://problem/3782533> CrashTracer: .1459 crashes at com.apple.WebKit: -[WebTextRenderer initWithFont:usingPrinterFont:] + 0x138

        We were explicitly failing when we encountered deprecated fonts.
        (Those with unsupported glyph packings).
        Deprecated fonts should only appear on a system that have
        stuff migrated from OS 9.  Ugh, thats probably why we've never seen
        the problem here.

        Reviewed by John.

        * WebCoreSupport.subproj/WebTextRenderer.m:
        (-[WebTextRenderer initWithFont:usingPrinterFont:]):

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

18 years agoWebKit:
sullivan [Fri, 10 Sep 2004 22:21:11 +0000 (22:21 +0000)]

        Reviewed by Chris.

        - added _isFrameSet as a private method, so it can be used in WebBrowser.
        This is needed to merge the fix for 3123987 to SUPanNavy.

        * WebView.subproj/WebFrame.m:
        (-[WebFrame _isFrameSet]):
        new method

        * WebView.subproj/WebFramePrivate.h:
        declare new method


        Reviewed by Chris.

        - changed implementation of -[WebFrameView isFrameset] so that it's more easily
        mergeable back to 10.3.5. This is needed to merge 3123987 to SUPanNavy.

        * BrowserWebViewExtras.m:
        (-[WebFrameView isFrameset]):
        Call private WebFrame method instead of using DOM.

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

18 years ago Fixed previous "Reviewed by" line.
cblu [Fri, 10 Sep 2004 16:18:50 +0000 (16:18 +0000)]
Fixed previous "Reviewed by" line.

        * ChangeLog:

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

18 years agoWebCore:
cblu [Fri, 10 Sep 2004 15:58:39 +0000 (15:58 +0000)]

Support for: <rdar://problem/3795485> debug menu item to enable RSS animation on first layout

        Reviewed by rjw.

        * khtml/khtml_part.h:
        (KHTMLPart::didFirstLayout): new
        * khtml/khtmlview.cpp:
        (KHTMLView::layout): call didFirstLayout
        * kwq/KWQKHTMLPart.h:
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::didFirstLayout): new
        * kwq/WebCoreBridge.h:


Support for: <rdar://problem/3795485> debug menu item to enable RSS animation on first layout

        Reviewed by NOBODY (OOPS!).

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge didFirstLayout]): new
        * WebView.subproj/WebDefaultFrameLoadDelegate.m:
        (-[WebDefaultFrameLoadDelegate webView:didFirstLayoutInFrame:]): new
        * WebView.subproj/WebViewPrivate.h:


Fixed: <rdar://problem/3795485> debug menu item to enable RSS animation on first layout

        Reviewed by rjw.

        * BrowserWindowController.h:
        * BrowserWindowController.m:
        (-[BrowserWindowController startRSSAnimationForFrame:error:]): new
        (-[BrowserWindowController webFrameLoadDidFirstLayout:]): new
        (-[BrowserWindowController webFrameLoadFinished:withError:]): call startRSSAnimationForFrame:error:
        * Debug/DebugUtilities.m:
        (-[DebugUtilities createDebugMenu]): added toggle for RSS animation
        (-[BrowserDocument toggleRSSAnimateAfterFirstLayout:]): new
        (-[BrowserDocument validate_toggleRSSAnimateAfterFirstLayout:]): new
        * LocationChangeHandler.m:
        (-[LocationChangeHandler webView:didFirstLayoutInFrame:]): new
        * PreferenceKeys.h:

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

18 years ago Alternate implementation of image rendering. Use CGImageRefs instead
rjw [Fri, 10 Sep 2004 02:31:28 +0000 (02:31 +0000)]
    Alternate implementation of image rendering.  Use CGImageRefs instead
        of NSImages.

        Mostly works, but currently disabled because of issues w/ CG.

        Reviewed by Chris.

        * ChangeLog:
        * WebCoreSupport.subproj/WebImageData.h: Added.
        * WebCoreSupport.subproj/WebImageData.m: Added.
        (-[WebImageData _commonTermination]):
        (-[WebImageData dealloc]):
        (-[WebImageData finalize]):
        (-[WebImageData copyWithZone:]):
        (-[WebImageData numberOfImages]):
        (-[WebImageData currentFrame]):
        (-[WebImageData _invalidateImages]):
        (-[WebImageData imageAtIndex:]):
        (-[WebImageData incrementalLoadWithBytes:length:complete:]):
        (-[WebImageData tileInRect:fromPoint:context:]):
        (-[WebImageData isNull]):
        (-[WebImageData size]):
        (-[WebImageData _frameDuration]):
        (-[WebImageData _repetitionCount]):
        (-[WebImageData isAnimationFinished]):
        (+[WebImageData stopAnimationsInView:]):
        (-[WebImageData addAnimatingRenderer:inView:]):
        (-[WebImageData removeAnimatingRenderer:]):
        (-[WebImageData _stopAnimation]):
        (-[WebImageData _nextFrame:]):
        (-[WebImageData animate]):
        * WebCoreSupport.subproj/WebImageRenderer.h:
        * WebCoreSupport.subproj/WebImageRenderer.m:
        (-[WebImageRenderer initWithMIMEType:]):
        (-[WebImageRenderer initWithData:MIMEType:]):
        (-[WebImageRenderer initWithContentsOfFile:]):
        (-[WebImageRenderer dealloc]):
        (-[WebImageRenderer copyWithZone:]):
        (-[WebImageRenderer retainOrCopyIfNeeded]):
        (-[WebImageRenderer resize:]):
        (-[WebImageRenderer size]):
        (-[WebImageRenderer MIMEType]):
        (-[WebImageRenderer frameCount]):
        (-[WebImageRenderer isNull]):
        (-[WebImageRenderer incrementalLoadWithBytes:length:complete:]):
        (-[WebImageRenderer drawImageInRect:fromRect:]):
        (-[WebImageRenderer drawImageInRect:fromRect:compositeOperator:context:]):
        (-[WebImageRenderer tileInRect:fromPoint:context:]):
        (-[WebImageRenderer _startOrContinueAnimationIfNecessary]):
        (+[WebImageRenderer stopAnimationsInView:]):
        (-[WebImageRenderer stopAnimation]):
        (-[WebImageRenderer targetAnimationRect]):
        (-[WebImageRenderer increaseUseCount]):
        (-[WebImageRenderer decreaseUseCount]):
        (-[WebImageRenderer flushRasterCache]):
        (-[WebImageRenderer imageRef]):
        (-[WebImageRenderer TIFFRepresentation]):
        (-[WebImageRenderer image]):
        * WebCoreSupport.subproj/WebImageRendererFactory.m:
        (-[WebImageRendererFactory imageRendererWithMIMEType:]):
        (-[WebImageRendererFactory imageRendererWithData:MIMEType:]):
        (-[WebImageRendererFactory imageRendererWithSize:]):
        (-[WebImageRendererFactory imageRendererWithName:]):
        * WebKit.pbproj/project.pbxproj:
        * WebView.subproj/WebImageView.m:
        (-[WebImageView image]):

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

18 years ago Reviewed by Richard.
mjs [Fri, 10 Sep 2004 01:52:24 +0000 (01:52 +0000)]
    Reviewed by Richard.

<rdar://problem/3493140> REGRESSION (85-100): cedille displays %-escaped in JavaScript message at hotmail.com

* kjs/function.cpp:
        (KJS::GlobalFuncImp::call): Replace our escape() and unescape() implementations with
ones from KDE KJS, which have the proper latin-1 behavior to match Win IE.
        * kjs/lexer.cpp:
        (Lexer::isHexDigit): Made static and non-const.
        * kjs/lexer.h:

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

18 years agochange version number to 2.0, 164u for TOT
vicki [Fri, 10 Sep 2004 01:41:44 +0000 (01:41 +0000)]
change version number to 2.0, 164u for TOT

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

18 years agoSafari-163 stamp for everything except WebBrowser. In these projects, CFBundleShortV...
vicki [Fri, 10 Sep 2004 01:29:52 +0000 (01:29 +0000)]
Safari-163 stamp for everything except WebBrowser.  In these projects, CFBundleShortVersionString matches CFBundleVersion (163 in both cases).

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

18 years ago - roll out the last change, it appears to cause a performance regression
mjs [Fri, 10 Sep 2004 01:02:20 +0000 (01:02 +0000)]
    - roll out the last change, it appears to cause a performance regression

        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_box.h:
        * khtml/rendering/render_br.cpp:
        * khtml/rendering/render_br.h:
        * khtml/rendering/render_flow.cpp:
        * khtml/rendering/render_flow.h:
        * khtml/rendering/render_object.cpp:
        * khtml/rendering/render_object.h:
        * khtml/rendering/render_text.cpp:
        * khtml/rendering/render_text.h:
        * kwq/WebCoreBridge.h:
        * kwq/WebCoreBridge.mm:

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

18 years ago - rolled out last two changes, they seem to cause a performance regression
mjs [Fri, 10 Sep 2004 01:01:54 +0000 (01:01 +0000)]
    - rolled out last two changes, they seem to cause a performance regression

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView firstRectForCharacterRange:]):

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

18 years ago - fixed build
mjs [Thu, 9 Sep 2004 22:25:20 +0000 (22:25 +0000)]
    - fixed build

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView firstRectForCharacterRange:]):

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

18 years agoWebCore:
mjs [Thu, 9 Sep 2004 21:02:08 +0000 (21:02 +0000)]

        Reviewed by Dave.

WebCore part of fix for:

<rdar://problem/3759187> REGRESSION (Mail): implement firstRectForCharacterRange:

        * kwq/WebCoreBridge.h:
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge firstRectForDOMRange:]): New method to compute the rect for a
DOMRange, or if the range is split into multiple lines, the rect for the part on
the first line only.

        * khtml/rendering/render_object.cpp:
        (RenderObject::caretRect): Added extraWidthToEndOfLine parameter and ditto
for the overrides below.
        * khtml/rendering/render_object.h:
        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_box.h:
        * khtml/rendering/render_br.cpp:
        * khtml/rendering/render_br.h:
        * khtml/rendering/render_flow.cpp:
        * khtml/rendering/render_flow.h:
        * khtml/rendering/render_text.cpp:


        Reviewed by Dave.

WebKit part of fix for:

<rdar://problem/3759187> REGRESSION (Mail): implement firstRectForCharacterRange:

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView firstRectForCharacterRange:]): Call the appropriate new bridge method,
and translate to screen coordinates.

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

18 years agoWebCore:
darin [Thu, 9 Sep 2004 15:00:12 +0000 (15:00 +0000)]

        Reviewed by Ken.

        - fixed <rdar://problem/3790526> mark-related methods not implemented (needed for people with them in their key bindings files)

        * khtml/khtml_part.h: Added mark and setMark.
        * khtml/khtmlpart_p.h: Added m_mark.
        * khtml/khtml_part.cpp:
        (KHTMLPart::mark): Added.
        (KHTMLPart::setMark): Added.

        * kwq/KWQKHTMLPart.h: Change name of markedRange to markedTextRange to decrease
        the change it will be confused with the mark.
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::clear): Update for name change.
        (KWQKHTMLPart::markedTextRange): Ditto.
        (KWQKHTMLPart::setMarkedTextRange): Ditto.

        * khtml/rendering/render_text.cpp: (RenderText::paint): Update for name change.

        * kwq/WebCoreBridge.h: Remove setSelectionFrom, selectionStart, selectionStartOffset,
        selectionEnd, selectionEndOffset, and clearMarkedDOMRange. Renamed setMarkedDOMRange
        to setMarkedTextDOMRange and markedDOMRange to markedTextDOMRange. Added setMarkDOMRange
        and markDOMRange for the Emacs "mark".
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge setMarkDOMRange:]): Added.
        (-[WebCoreBridge markDOMRange]): Added.
        (-[WebCoreBridge setMarkedTextDOMRange:]): Renamed.
        (-[WebCoreBridge markedTextDOMRange]): Renamed.

        * khtml/xml/dom_selection.cpp: (DOM::Selection::validate): Make paragraph positions
        canonical by using deep rendered positions. Maybe someday this won't be an ad hoc
        decision any more.

        * khtml/xml/dom_nodeimpl.cpp: (NodeBaseImpl::removeChildren): Use ref and deref
        rather than the unconventional check for 0 refCount. This makes us a bit more
        robust against a node going away partway through the removal process.

        * WebCore.pbproj/project.pbxproj: Update MACOSX_DEPLOYMENT_TARGET to 10.3.


        Reviewed by Ken.

        - fixed <rdar://problem/3790526> mark-related methods not implemented (needed for people with them in their key bindings files)

        * WebKit.pbproj/project.pbxproj: Update MACOSX_DEPLOYMENT_TARGET to 10.3 and add -fobjc-exceptions
        so we can use new exceptions.

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView setMark:]): Added.
        (unionDOMRanges): Added.
        (-[WebHTMLView deleteToMark:]): Added.
        (-[WebHTMLView selectToMark:]): Added.
        (-[WebHTMLView swapWithMark:]): Added.
        (-[WebHTMLView markedRange]): Updated for change to bridge method names.
        (-[WebHTMLView hasMarkedText]): Ditto.
        (-[WebHTMLView unmarkText]): Ditto.
        (-[WebHTMLView _selectMarkedText]): Ditto.
        (-[WebHTMLView _selectRangeInMarkedText:]): Ditto.
        (-[WebHTMLView setMarkedText:selectedRange:]): Ditto.
        (-[WebHTMLView _insertText:selectInsertedText:]): Removed check for empty string. An empty string
        should not be filtered out here. We need to allow inserting an empty string.
        (-[WebHTMLView _selectionIsInsideMarkedText]): Updated for change to bridge method names.
        (-[WebHTMLView _updateSelectionForInputManager]): Ditto.

        * WebView.subproj/WebView.m: (-[WebView searchFor:direction:caseSensitive:wrap:]):
        Changed to use selectionDOMRange instead of selectionStart.

        * WebView.subproj/WebHTMLRepresentation.h: Removed unused setSelectionFrom method.
        * WebView.subproj/WebHTMLRepresentation.m: Ditto.

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

18 years agoWebKit:
sullivan [Wed, 8 Sep 2004 23:53:13 +0000 (23:53 +0000)]

        Reviewed by Darin.

        - fixed the localization aspect of:
        <rdar://problem/3790011> undoable operations all say "Undo" in the menu, no specific action names

        We now have all the strings ready for localization; we just don't actually use them yet.

        * English.lproj/Localizable.strings:
        updated for this change

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge setUndoActionNamePlaceholder]):
        added this placeholder method whose purpose is to hold localizable strings for all the Undo
        action names that NSTextView uses. Later we will use some or all of these, but we can do
        that part after the localization freeze.


        Reviewed by Darin.

        * English.lproj/StringsNotToBeLocalized.txt:
        updated for my recent changes

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

18 years ago Fixed previous "Reviewed by" line.
cblu [Wed, 8 Sep 2004 23:13:25 +0000 (23:13 +0000)]
Fixed previous "Reviewed by" line.

        * ChangeLog:

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

18 years ago Fixed: <rdar://problem/3778785> REGRESSION (Mail): copying from MS word and pasting...
cblu [Wed, 8 Sep 2004 23:12:27 +0000 (23:12 +0000)]
Fixed: <rdar://problem/3778785> REGRESSION (Mail): copying from MS word and pasting into editable region leaves internal clipboard data

        Reviewed by NOBODY (OOPS!).

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:]): ignore Microsoft's header meta data

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

18 years ago Fixed: <rdar://problem/3792893> WebBaseResourceHandleDelegate always returns cached...
cblu [Wed, 8 Sep 2004 21:48:05 +0000 (21:48 +0000)]
Fixed: <rdar://problem/3792893> WebBaseResourceHandleDelegate always returns cached data for subresource loads

        Reviewed by rjw.

        * WebView.subproj/WebBaseResourceHandleDelegate.m:
        (-[WebBaseResourceHandleDelegate _canUseResourceForRequest:]): new
        (-[WebBaseResourceHandleDelegate loadWithRequest:]): call _canUseResourceForRequest:

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

18 years ago - fixed deployment build problems noticed by Grant
mjs [Wed, 8 Sep 2004 21:46:00 +0000 (21:46 +0000)]
    - fixed deployment build problems noticed by Grant

        * khtml/rendering/render_flow.cpp:
        * khtml/rendering/render_text.cpp:

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

18 years ago Fix XML so that elements with no namespace never make HTML elements (when their...
hyatt [Wed, 8 Sep 2004 20:26:33 +0000 (20:26 +0000)]
Fix XML so that elements with no namespace never make HTML elements (when their names coincidentally match).

        Reviewed by rjw

        * khtml/xml/dom_docimpl.cpp:

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

18 years ago Forgot to add this in previous check-in.
cblu [Wed, 8 Sep 2004 20:04:06 +0000 (20:04 +0000)]
Forgot to add this in previous check-in.

        * English.lproj/WebViewEditingContextMenu.nib: Added.

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

18 years ago Reviewed by John.
mjs [Wed, 8 Sep 2004 19:26:53 +0000 (19:26 +0000)]
    Reviewed by John.

- renamed caretPos to caretRect and made it return a QRect instead
of taking four out parameters by reference.

        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_box.h:
        * khtml/rendering/render_br.cpp:
        * khtml/rendering/render_br.h:
        * khtml/rendering/render_flow.cpp:
        * khtml/rendering/render_flow.h:
        * khtml/rendering/render_object.cpp:
        * khtml/rendering/render_object.h:
        * khtml/rendering/render_text.cpp:
        * khtml/rendering/render_text.h:
        * khtml/xml/dom_selection.cpp:
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge caretRectAtNode:offset:]):

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

18 years ago Fixed: <rdar://problem/3791240> WebKit uses the NSTextViewContextMenu nib from insid...
cblu [Wed, 8 Sep 2004 18:17:15 +0000 (18:17 +0000)]
Fixed: <rdar://problem/3791240> WebKit uses the NSTextViewContextMenu nib from inside AppKit

        Reviewed by john.

        * English.lproj/StringsNotToBeLocalized.txt:
        * WebKit.pbproj/project.pbxproj:
        * WebView.subproj/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate editingContextMenuItemsForElement:]): use our copy of the nib

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

18 years ago Reviewed by Kevin.
mjs [Wed, 8 Sep 2004 01:27:21 +0000 (01:27 +0000)]
    Reviewed by Kevin.

<rdar://problem/3759209> REGRESSION (Mail): assertion failure when all of marked text deleted at start of document

        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::setMarkedRange): Allow any empty range, even if
it's not in a text node, since in this case it won't matter and
weird things can happen when all marked text is removed, there
might not be any text nodes.

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

18 years ago Initial text-decoration CSS3 work for editing. Just gets the properties and values...
hyatt [Wed, 8 Sep 2004 01:08:35 +0000 (01:08 +0000)]
Initial text-decoration CSS3 work for editing.  Just gets the properties and values parsed.

        Reviewed by darin

        * khtml/css/css_computedstyle.cpp:
        * khtml/css/cssparser.cpp:
        * khtml/css/cssproperties.c:
        * khtml/css/cssproperties.h:
        * khtml/css/cssproperties.in:
        * khtml/css/cssstyleselector.cpp:
        * khtml/css/cssvalues.c:
        * khtml/css/cssvalues.h:
        * khtml/css/cssvalues.in:

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

18 years ago * English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.
darin [Tue, 7 Sep 2004 23:01:15 +0000 (23:01 +0000)]
    * English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.

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

18 years ago Fixed previous "Reviewed by" line.
cblu [Tue, 7 Sep 2004 21:34:08 +0000 (21:34 +0000)]
    Fixed previous "Reviewed by" line.

        * ChangeLog:

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

18 years ago Fixed: <rdar://problem/3790143> exception raised when dragging a URL with 2-byte...
cblu [Tue, 7 Sep 2004 21:28:48 +0000 (21:28 +0000)]
Fixed: <rdar://problem/3790143> exception raised when dragging a URL with 2-byte characters

(checked in with last check-in)

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

18 years ago Fixed:
cblu [Tue, 7 Sep 2004 21:26:06 +0000 (21:26 +0000)]
<rdar://problem/3080103> Need to pass cmd-modified keys to plug-ins
<rdar://problem/3751509> can't use safari edit menu to copy and paste with Vantage Learning's My Access

        Reviewed by NOBODY (OOPS!).

        * Plugins.subproj/WebBaseNetscapePluginView.m: fake up command-key events for cut, copy, paste and select all so these menu items work for plug-ins
        (-[WebBaseNetscapePluginView sendModifierEventWithKeyCode:character:]):
        (-[WebBaseNetscapePluginView cut:]):
        (-[WebBaseNetscapePluginView copy:]):
        (-[WebBaseNetscapePluginView paste:]):
        (-[WebBaseNetscapePluginView selectAll:]):

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

18 years agoAdd layout test results.
hyatt [Tue, 7 Sep 2004 21:19:26 +0000 (21:19 +0000)]
Add layout test results.

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

18 years ago - fixed deployment build
darin [Tue, 7 Sep 2004 18:58:07 +0000 (18:58 +0000)]
    - fixed deployment build

        * WebView.subproj/WebHTMLView.m: (-[WebHTMLView _deleteWithDirection:granularity:killRing:]):
        Initialize prepend variable.

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

18 years ago * JavaScriptCore.pbproj/project.pbxproj: Bump MACOSX_DEPLOYMENT_TARGET to...
darin [Tue, 7 Sep 2004 06:37:57 +0000 (06:37 +0000)]
    * JavaScriptCore.pbproj/project.pbxproj: Bump MACOSX_DEPLOYMENT_TARGET to 10.3.

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

18 years ago Reviewed by Darin and Ken.
mjs [Tue, 7 Sep 2004 05:38:11 +0000 (05:38 +0000)]
    Reviewed by Darin and Ken.

<rdar://problem/3655568> window.open fails when URL contains trailing space

        * kwq/KWQKURL.mm:
        (KURL::KURL): Strip trailing and leading space when resolving relative URLs in all
cases, instead of just leading in the non-absolute case as before.

- refactored KURL constructor to put more work in separate
functions and also to change static methods to static functions,
to avoid having to change the header when only changing helper
functions that do not affect the KURL API (since KURL.h is widely

        * kwq/KWQKURL.mm:
* kwq/KWQKURL.h:

- add missing include of qvaluelist.h

        * khtml/ecma/kjs_dom.h:

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

18 years agoWebCore:
darin [Tue, 7 Sep 2004 00:25:38 +0000 (00:25 +0000)]

        Reviewed by John.

        - fixed <rdar://problem/3512066> REGRESSION (Mail): Select All highlights only part of the content, though all is copied
        - fixed <rdar://problem/3157025> REGRESSION (Mail): Should select paragraph instead of line on triple-click
        - fixed <rdar://problem/3735048> REGRESSION (Mail): HTML editing must select newline on triple click
        - fixed <rdar://problem/3788872> REGRESSION (Mail): ctrl-a emacs key binding does not work (move to start of paragraph)
        - fixed <rdar://problem/3788881> REGRESSION (Mail): ctrl-e emacs key binding does not work (move to end of paragraph)
        - fixed <rdar://problem/3789931> REGRESSION (Mail): typing style lost when you backspace
        - added code to select inserted text to help WebKit implement yankAndSelect:
        - did some clean-up on editing commands code

        * khtml/khtml_part.cpp:
        (KHTMLPart::handleMousePressEventTripleClick): Expand to a paragraph, not a line.
        (KHTMLPart::selectAll): Remove a lot of unneeded code and just expand to document using Selection.
        (KHTMLPart::selectionHasStyle): Remove check that limited us to only HTML elements, and add
        a check for nil. Together, these two changes fix a few cases I ran into during testing.

        * khtml/rendering/render_canvas.cpp: (RenderCanvas::setSelection): Fix test that was checking if
        the old selection spanned multiple objects when it really should have checked whether the new
        new selection spans multiple objects. This caused the select all redraw bug.

        * khtml/editing/htmlediting.h: Fixed indenting. Remove command IDs, replacing them with a couple
        of specific type checking methods, and SharedCommandImpl, using EditCommandImpl directly instead.
        Got rid of virtual functions, since the command objects have no data members other than the ones
        inherited from SharedPtr. Removed explicit copy constructors and destructors. Removed unneeded
        empty constructors. Removed inline directives that were having no effect. Added some boolean
        selectInsertedText parameter to some commands. Made almost all member functions const, because
        the const here applies to the command object which is a smart pointer, not the pointed-to
        command implementation object.
        * khtml/editing/htmlediting.cpp:
        (khtml::EditCommand::EditCommand): Changed since SharedPtr is now a pointer to EditCommandImpl.
        (khtml::EditCommand::operator=): Added. By defining this explicitly, we don't need the class
        that we are pointing to defined in the header, which lets us get rid of SharedCommandImpl.
        (khtml::EditCommand::isInputTextCommand): Added.
        (khtml::EditCommand::isTypingCommand): Added.
        (khtml::EditCommand::setParent): Updated since EditCommandImpl.setParent takes an impl pointer now.
        (khtml::EditCommand::handle): Removed, since it's identical to get().
        (khtml::InputTextCommand::input): Added selectInsertedText parameter.
        (khtml::TypingCommand::TypingCommand): Ditto.
        (khtml::TypingCommand::insertText): Ditto.
        (khtml::TypingCommand::isOpenForMoreTypingCommand): Use isTypingCommand instead of commandID.
        (khtml::TypingCommand::closeTyping): Change parameter type to const reference.

        * khtml/editing/htmlediting_impl.h: Made StyleChange functions be const member functions.
        Changed parent() and setParent() to take and return EditCommandImpl pointers and be inlined.
        Added virtual isInputTextCommand, isTypingCommand, and preservesTypingStyle functions.
        Removed commandID functions and unneeded explicit destructors. Removed unneeded doApply
        function declaration in CompositeEditCommandImpl. Changed type of applyTypingStyle to return
        a node, not necessarily an element. Removed private execute function from InputTextCommandImpl.
        Added selectInsertedText to InputTextCommandImpl's input function and TypingCommandImpl's constructor
        and insertText function.
        * khtml/editing/htmlediting_impl.cpp:
        (khtml::StyleChange::StyleChange): Don't bother initializing the booleans since init handles that.
        (khtml::StyleChange::init): Added code to strip whitespace, and tweaked how the function does its job.
        (khtml::StyleChange::currentlyHasStyle): Added a check for null value, which can happen for properties
        where we don't have computed style implemented yet.
        (khtml::EditCommandImpl::EditCommandImpl): Updated since there is no SharedCommandImpl any more.
        (khtml::EditCommandImpl::apply): Call new preservesTypingStyle function rather than checking
        the command ID. This preserves typing style when deleting with the keyboard.
        (khtml::EditCommandImpl::setStartingSelection): Changed since parent is now a EditCommandImpl.
        Also rewrote to use for loop so it's simpler-looking.
        (khtml::EditCommandImpl::setEndingSelection): Ditto.
        (khtml::EditCommandImpl::setTypingStyle): Ditto.
        (khtml::EditCommandImpl::preservesTypingStyle): Added. Returns false.
        (khtml::EditCommandImpl::isInputTextCommand): Added. Returns false.
        (khtml::EditCommandImpl::isTypingCommand): Added. Returns false.
        (khtml::CompositeEditCommandImpl::applyTypingStyle): Changed this function to return a node rather
        than an element. Also change it so it returns the child as-is if the style change has nothing in it.
        (khtml::AppendNodeCommandImpl::~AppendNodeCommandImpl): Removed unneeded null checks.
        (khtml::DeleteSelectionCommandImpl::preservesTypingStyle): Added. Returns true.
        (khtml::DeleteTextCommandImpl::~DeleteTextCommandImpl): Removed unneeded null checks.
        (khtml::InputTextCommandImpl::input): Renamed execute function to input and got rid of the additional
        level of indirection, since it was the only caller. Added selectInsertedText parameter and changed
        the code so it will respect it.
        (khtml::InputTextCommandImpl::isInputTextCommand): Added. Returns true.
        (khtml::InsertNodeBeforeCommandImpl::~InsertNodeBeforeCommandImpl): Removed unneeded null checks.
        (khtml::JoinTextNodesCommandImpl::~JoinTextNodesCommandImpl): Ditto.
        (khtml::MoveSelectionCommandImpl::MoveSelectionCommandImpl): Hold a reference to the fragment
        while the command exists.
        (khtml::MoveSelectionCommandImpl::~MoveSelectionCommandImpl): Release the fragment.
        (khtml::RemoveNodeCommandImpl::~RemoveNodeCommandImpl): Remove unneeded null checks.
        (khtml::RemoveNodeCommandImpl::doUnapply): Take advantage of defined behavior of insertBefore when
        the node to insert before is 0 (means the same thing as appendChild).
        Remove unneeded null check.
        (khtml::ReplaceSelectionCommandImpl::ReplaceSelectionCommandImpl): Hold a reference to the fragment
        while the command exists.
        (khtml::ReplaceSelectionCommandImpl::~ReplaceSelectionCommandImpl): Release the fragment.
        (khtml::SetNodeAttributeCommandImpl::~SetNodeAttributeCommandImpl): Remove unneeded null check.
        (khtml::SplitTextNodeCommandImpl::~SplitTextNodeCommandImpl): Remove unneeded null check.
        (khtml::TypingCommandImpl::TypingCommandImpl): Added selectInsertedText parameter.
        (khtml::TypingCommandImpl::doApply): Pass along selectInsertedText parameter.
        (khtml::TypingCommandImpl::insertText): Ditto.
        (khtml::TypingCommandImpl::preservesTypingStyle): Added. Returns true for DeleteKey.
        (khtml::TypingCommandImpl::isTypingCommand): Added. Returns true.

        * khtml/editing/jsediting.cpp: Add a cut at implementing the underline command. May not work
        perfectly yet because text-decoration is not inherited the way, say, font-weight is.

        * khtml/xml/dom_selection.h: Removed some unneeded friend declarations for comparison operators
        that use only public members. Added PARAGRAPH_BOUNDARY.
        * khtml/xml/dom_selection.cpp:
        (DOM::Selection::modifyExtendingRightForward): Implemented paragraph boundary case, simplified line
        boundary case (by changing parameter types and function names, not the algorithm), and made
        paragraph case fall into line case for now.
        (DOM::Selection::modifyMovingRightForward): Ditto.
        (DOM::Selection::modifyExtendingLeftBackward): Ditto.
        (DOM::Selection::modifyMovingLeftBackward): Ditto.
        (DOM::Selection::validate): Implemented paragraph case and paragraph boundary case, simplified the
        line case as above and also fixed the document case.
        (DOM::startOfFirstRunAt): Changed to use DOM::Position instead of node
        offset pairs. Also renamed and got rid of separate bool to indicate "not found".
        (DOM::endOfLastRunAt): Ditto.
        (DOM::selectionForLine): Ditto.

        * khtml/xml/dom_position.h: Added startParagraphBoundary and endParagraphBoundary.
        Also used enums instead of bools in a couple of places. Removed some unneeded friend
        declarations for comparison operators that use only public members.
        * khtml/xml/dom_position.cpp:
        (DOM::Position::Position): Coding style tweak.
        (DOM::Position::startParagraphBoundary): Added.
        (DOM::Position::endParagraphBoundary): Added.
        (DOM::Position::upstream): Use enum parameter instead of bool.
        (DOM::Position::downstream): Ditto.
        (DOM::Position::rendersOnSameLine): Removed unused function. Noticed some backwards logic
        here, and removed it rather than fixing it.

        * khtml/xml/dom_nodeimpl.h: Added traversePreviousNodePostOrder.
        * khtml/xml/dom_nodeimpl.cpp:
        (NodeImpl::traversePreviousNodePostOrder): Added. For some uses, this function is more analogous
        to traverseNextNode in reverse than traversePreviousNode, which does a backwards pre-order traversal.

        * kwq/WebCoreBridge.h: Replaced fontForCurrentPosition method with fontForSelection:, added
        selectInsertedText parameter to insertText method, and added selectionStartHasStyle: method.
        Add WebSelectToParagraphBoundary.
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge setSelectedDOMRange:affinity:]): Added workaround for bug where isRenderedContent
        returns false for <br> elements at the ends of lines.
        (-[WebCoreBridge insertText:selectInsertedText:]): Added selectInsertedText parameter, passing it
        along to TypingCommand::insertText.
        (-[WebCoreBridge selectionStartHasStyle:]): Added. Calls code in the part that does the real work.
        (-[WebCoreBridge fontForSelection:]): Ditto.

        * kwq/KWQKHTMLPart.h: Renamed fontForCurrentPosition to fontForSelection, and added a feature
        where it tells us whether there are multiple fonts in the selection or not.
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::fontForSelection): Rewrote this to be a bit simpler, and added code to detect
        whether there are multiple fonts in the selection.
        (KWQKHTMLPart::didTellBridgeAboutLoad): Use a global character rather than a bad pointer here.
        Better not to rely on undefined behavior.
        (KWQKHTMLPart::documentFragmentWithText): Use lowercase HTML. I believe this works better when
        the document is XML, and we should probably visit all callers and change them.
        (KWQKHTMLPart::registerCommandForUndo): Call get() instead of handle().
        (KWQKHTMLPart::registerCommandForRedo): Call get() instead of handle().

        * khtml/misc/shared.h: Added a private, non-implemented copy constructor and assignment
        operator to Shared<> and TreeShared<> to prevent copying reference counts by accident.
        * khtml/rendering/render_style.h: Get rid of Shared<BorderData>, since it's not used that way.
        This makes BorderData smaller, and allows it to compile with the change to Shared<>.
        * khtml/xml/dom_docimpl.h: Remove unneeded copy constructor on DocumentFragmentImpl,
        which ran afoul of the change to Shared<> and was unused.
        * khtml/xml/dom_docimpl.cpp: Ditto.
        * khtml/xml/dom_stringimpl.cpp:
        (DOM::DOMStringImpl::empty): Changed code around so it doesn't run afoul of the change to
        Shared<>. The old code was copying a DOMStringImpl.
        (DOM::DOMStringImpl::ascii): Added code to null-terminate the string buffer.


        Reviewed by John.

        - fixed <rdar://problem/3696542> REGRESSION (Mail): Editable WebKit doesn't support underline yet (in the iChat profile window, at least)
        - fixed <rdar://problem/3780249> REGRESSION (Mail): copy style/paste style doesn't work in HTML editing in Mail
        - fixed <rdar://problem/3788857> REGRESSION (Mail): Home and End keys don't work in message composer
        - fixed <rdar://problem/3788884> REGRESSION (Mail): ctrl-d emacs key binding does not work (delete forward)
        - fixed <rdar://problem/3788890> REGRESSION (Mail): ctrl-k emacs key binding does not work (delete to end of paragraph)
        - fixed <rdar://problem/3788899> REGRESSION (Mail): ctrl-y emacs key binding does not work (yank)
        - fixed <rdar://problem/3788901> REGRESSION (Mail): ctrl-o emacs key binding does not work (insert newline in front of insertion point)
        - fixed <rdar://problem/3788908> REGRESSION (Mail): ctrl-left-arrow emacs key binding does not work (move to beginning of line)
        - fixed <rdar://problem/3788913> REGRESSION (Mail): ctrl-right-arrow emacs key binding does not work (move to end of line)
        - implemented a first cut at other attribute changes from Text Panel besides underline (bugs?)
        - dealt with a couple of FIXMEs in WebHTMLView.m
        - updated list of not-yet-implemented methods in WebHTMLView.m
        - fixed many deletion operations to call the correct editing delegate methods

        * WebView.subproj/WebFrameViewPrivate.h: Remove _scrollToTopLeft and _scrollToBottomLeft.
        No one was calling them anyway, so they should really have been marked internal and not private.
        * WebView.subproj/WebFrameView.m:
        (-[WebFrameView scrollToBeginningOfDocument:]): Renamed _scrollToTopLeft to this, so the home key
        would start working with the key bindings machinery.
        (-[WebFrameView scrollToEndOfDocument:]): Same thing, for end key.
        (-[WebFrameView keyDown:]): Update for name changes, and also make sure we don't try to grab
        control-arrow keys here (probably not necessary, but good anyway).

        * WebView.subproj/WebHTMLViewInternal.h: Added keyDownEvent field, and startNewKillRingSequence
        and nextResponderDisabledOnce flags.
        * WebView.subproj/WebHTMLView.m:
        Rearrange declarations at the top of the file so that external things are up with
        the #import directives and things inside this file are declared below.
        (-[WebHTMLView _shouldReplaceSelectionWithText:givenAction:]): Ditto.
        (-[WebHTMLView _calculatePrintHeight]): Moved up into the "internal to file" category.
        (-[WebHTMLView _updateTextSizeMultiplier]): Ditto.
        (-[WebHTMLView _selectedRange]): Added.
        (-[WebHTMLView _openLinkFromMenu:]): Left this method lying around even though I deleted the
        other APPKIT_CODE_FOR_REFERENCE in case this shows up in the context menu we are now sharing
        with the AppKit. Chris will look at this later, and he can delete it then.
        (+[WebHTMLView initialize]): Call _NSInitializeKillRing.
        (-[WebHTMLView _documentRange]): Added.
        (-[WebHTMLView string]): Call the bridge to get the plain text rather than making an attributed
        string and then getting the text from there.
        (-[WebHTMLView becomeFirstResponder]): Set startNewKillRingSequence flag, so that new deletions
        will create a new kill ring entry.
        (-[WebHTMLView moveToBeginningOfDocument:]): Use backward direction instead of left direction.
        (-[WebHTMLView moveToBeginningOfDocumentAndModifySelection:]): Ditto.
        (-[WebHTMLView moveToBeginningOfLine:]): Ditto.
        (-[WebHTMLView moveToBeginningOfLineAndModifySelection:]): Ditto.
        (-[WebHTMLView moveToBeginningOfParagraph:]): Ditto, also use WebSelectToParagraphBoundary.
        (-[WebHTMLView moveToBeginningOfParagraphAndModifySelection:]): Ditto.
        (-[WebHTMLView moveToEndOfDocument:]): Use forward direction instead of right direction.
        (-[WebHTMLView moveToEndOfDocumentAndModifySelection:]): Ditto.
        (-[WebHTMLView moveToEndOfLine:]): Ditto.
        (-[WebHTMLView moveToEndOfLineAndModifySelection:]): Ditto.
        (-[WebHTMLView moveToEndOfParagraph:]): Ditto, also use WebSelectToParagraphBoundary.
        (-[WebHTMLView moveToEndOfParagraphAndModifySelection:]): Ditto.
        (-[WebHTMLView _shouldDeleteRange:]): Added.
        (-[WebHTMLView _deleteRange:preflight:killRing:prepend:]): Added.
        (-[WebHTMLView delete:]): Changed to call new _deleteRange method.
        (-[WebHTMLView cut:]): Changed to preflight property and call new _deleteRange method.
        (-[WebHTMLView _selectionFontAttributes]): Added.
        (-[WebHTMLView _selectionFontAttributesAsRTF]): Added.
        (-[WebHTMLView _fontAttributesFromFontPasteboard]): Added.
        (-[WebHTMLView _emptyStyle]): Added.
        (-[WebHTMLView _styleFromFontAttributes:]): Added.
        (-[WebHTMLView _applyStyleToSelection:]): Added.
        (-[WebHTMLView copyFont:]): Implemented.
        (-[WebHTMLView pasteFont:]): Implemented.
        (-[WebHTMLView _originalFontA]): Added.
        (-[WebHTMLView _originalFontB]): Added.
        (-[WebHTMLView _addToStyle:fontA:fontB:]): Added. Has code from the method that figures out
        what the font manager is doing for changeFont:, now needed for changeAttribute: too.
        (-[WebHTMLView _styleFromFontManagerOperation]): Renamed and now calls shared methods.
        (-[WebHTMLView changeFont:]): Call shared method, still does the same thing.
        (-[WebHTMLView _colorAsString:]): Added. Has code from the method we were using with the
        color panel before.
        (-[WebHTMLView _shadowAsString:]): Added.
        (-[WebHTMLView _styleForAttributeChange:]): Added.
        (-[WebHTMLView changeAttributes:]): Implemented.
        (-[WebHTMLView _styleFromColorPanelWithSelector:]): Renamed and now calls shared methods.
        (-[WebHTMLView _changeCSSColorUsingSelector:inRange:]): Call method by new name.
        (-[WebHTMLView changeDocumentBackgroundColor:]): Call method by new name.
        (-[WebHTMLView changeColor:]): Changed around a bit; still doesn't work yet.
        (-[WebHTMLView _alignSelectionUsingCSSValue:]): Call shared methods.
        (-[WebHTMLView indent:]): Removed, since NSTextView doesn't implement this method. Added to list
        of methods to possibly implement later in the file.
        (-[WebHTMLView insertTab:]): Call insertText: to save code and so we get WebViewInsertActionTyped
        instead of WebViewInsertActionPasted.
        (-[WebHTMLView changeCaseOfLetter:]): Removed, since NSTextView doesn't implement this method.
        Added to list of methods to possibly implement later in the file.
        (-[WebHTMLView _deleteWithDirection:granularity:killRing:]): Added.
        (-[WebHTMLView deleteForward:]): Implemented. This makes Control-D work.
        (-[WebHTMLView deleteBackwardByDecomposingPreviousCharacter:]): Implemented by just calling
        deleteBackward for now; probably better than doing nothing.
        (-[WebHTMLView deleteWordForward:]): Changed to call new _delete method above. Fixes things
        so that we delete the selection if there is one, get the appropriate delegate calls, handle
        the kill ring properly, and don't do any selection if we can't delete.
        (-[WebHTMLView deleteWordBackward:]): Ditto.
        (-[WebHTMLView deleteToBeginningOfLine:]): Ditto.
        (-[WebHTMLView deleteToEndOfLine:]): Ditto.
        (-[WebHTMLView deleteToBeginningOfParagraph:]): Ditto.
        (-[WebHTMLView deleteToEndOfParagraph:]): Ditto. Added additional behavior needed since this
        is bound to Control-K, so it's not really just delete to end of paragraph.
        (-[WebHTMLView insertNewlineIgnoringFieldEditor:]): Added. Calls insertNewline:.
        (-[WebHTMLView insertTabIgnoringFieldEditor:]): Added. Calls insertTab:.
        (-[WebHTMLView subscript:]): Added.
        (-[WebHTMLView superscript:]): Added.
        (-[WebHTMLView unscript:]): Added.
        (-[WebHTMLView underline:]): Added.
        (-[WebHTMLView yank:]): Added.
        (-[WebHTMLView yankAndSelect:]): Added. Calls _insertText.
        (-[WebHTMLView _arrowKeyDownEventSelectorIfPreprocessing:]): Added. Part of workaround for
        control-arrow key trouble.
        (-[WebHTMLView respondsToSelector:]): Added. More of workaround.
        (-[WebHTMLView nextResponder:]): Added. More of workaround.
        (-[WebHTMLView _selectionChanged]): Set startNewKillRingSequence flag, so that new deletions
        will create a new kill ring entry.
        (-[WebHTMLView _updateFontPanel]): Remove a bunch of code here that wasn't working very well
        because it walked a DOM range incorrectly, and instead use the new method that does all the
        right stuff on the other side of the bridge.
        (-[WebHTMLView _insertText:selectInsertedText:]): Added new helper method for use by both
        insertText and yankAndSelect, with most of the guts of insertText and one additional parameter.
        (-[WebHTMLView insertText:]): Call the new _insertText.

        * WebView.subproj/WebView.m: Use macros to make the forwarding from WebView more terse.
        Updated the list to include a few methods it didn't before.

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

18 years ago Reviewed by John.
darin [Mon, 6 Sep 2004 23:30:27 +0000 (23:30 +0000)]
    Reviewed by John.

        - improved computed style code and implemented text-decoration and text-shadow (needed for, e.g., underline)

        * khtml/css/css_computedstyle.cpp:
        Added CSS_PROP_TEXT_DECORATION to the InheritableProperties array for now even though it's
        not inheritable. This makes underline work in some cases for typing style. We may decide to
        take it back out again after further consideration.
        (DOM::valueForLength): Use IDs in primitive values rather than strings.
        (DOM::valueForBorderStyle): Ditto, also renamed this.
        (DOM::valueForTextAlign): More of the same.
        (DOM::valueForShadow): Added this function.
        (DOM::CSSComputedStyleDeclarationImpl::getPositionOffsetValue): More IDs in primitive values.
        (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue): Changed all the cases to use
        IDs instead of strings in primitive values. Also put the style in a local variable for
        better code size and smaller source code too. Added implementation for CSS_PROP_TEXT_DECORATION

        * khtml/css/css_valueimpl.cpp:
        (CSSValueListImpl::cssText): Put commas between list elements.
        (CSSPrimitiveValueImpl::cssText): Fixed some messed up indenting and removed an unneeded
        default case that would just prevent a warning if we ever have an unhandled enum value.

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

18 years ago Reviewed by John.
darin [Mon, 6 Sep 2004 23:23:15 +0000 (23:23 +0000)]
    Reviewed by John.

        - did some clean-up on form data code

        * khtml/misc/formdata.h: Added more public functions as suggested by Chris when he reviewed
        this class.
        * khtml/misc/formdata.cpp: (khtml::FormData::appendFile): Added. Will be needed soon.
        * kwq/KWQFormData.mm: (arrayFromFormData): Use new cleaned-up FormData API.

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

18 years ago Reviewed by John.
darin [Mon, 6 Sep 2004 23:22:15 +0000 (23:22 +0000)]
    Reviewed by John.

        * kwq/DOM-CSS.mm: (-[DOMCSSStyleDeclaration description]): Use cssText in the description
        so it's easier to see in the debugger.

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

18 years ago Reviewed by John.
darin [Mon, 6 Sep 2004 23:21:48 +0000 (23:21 +0000)]
    Reviewed by John.

        * khtml/ecma/xmlhttprequest.cpp: (KJS::XMLHttpRequest::send): Remove uneeded QCString copy.

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

18 years agoWebKit:
sullivan [Mon, 6 Sep 2004 21:13:50 +0000 (21:13 +0000)]

        Reviewed by Darin.

        - put preference keys in a private header file so Safari can use them for Managed Preferences

        * WebView.subproj/WebPreferenceKeysPrivate.h:
        new Private header file, includes the #defines for NSUserDefaults preference keys

        * WebView.subproj/WebPreferences.m:
        moved the preference key #defines out of here; now imports WebPreferenceKeysPrivate.h

        * WebKit.pbproj/project.pbxproj:
        updated for new file


        Reviewed by Darin.

        - fixed these bugs:
        <rdar://problem/3786507> Safari's managed preferences manifest needs to be
        brought up to date and made localizable
        <rdar://problem/3550533> Would like Safari to make more preferences "managed"
        in the Managed Preferences sense

        * Preferences.subproj/AdvancedPreferences.m:
        (-[AdvancedPreferences updateStyleSheetMenu]):
        disable popup button if style sheet enabled-ness or location is forced
        (-[AdvancedPreferences updateMinFontSizeViews]):
        disable checkbox and combo box if min font size value is forced
        (-[AdvancedPreferences updateTabToAllViews]):
        disable checkbox if tab-to-links value is forced

        * Preferences.subproj/AppearancePreferences.h:
        new outlets for "Select" buttons
        * Preferences.subproj/English.lproj/AppearancePreferences.nib:
        wire up "Select" button outlets
        * Preferences.subproj/AppearancePreferences.m:
        (-[AppearancePreferences updateDefaultCharacterSetPopup]):
        disable popup if text encoding value is forced
        (-[AppearancePreferences initializeFromDefaults]):
        disable each "Select" button if the font or font size is forced

        * Preferences.subproj/AutoFillPreferences.m:
        (-[AutoFillPreferences updateViews]):
        disable each checkbox if its value is forced

        * Preferences.subproj/BookmarkPreferences.m:
        (-[BookmarkPreferences setUpCheckbox:fromPreferenceKey:]):
        renamed from "setStateOfCheckbox:..."; now disables checkbox
        if the preference key value is forced
        (-[BookmarkPreferences updateBookmarksViews]):
        updated for name change

        * Preferences.subproj/GeneralPreferences.m:
        (-[GeneralPreferences updateExternalLinkPolicyViews]):
        disable radio buttons if value is forced
        (-[GeneralPreferences initializeFromDefaults]):
        disable new window policy popup, downloads clearing policy popup, and/or
        auto-open downloads checkbox if its value is forced

        * Preferences.subproj/SecurityPreferences.m:
        (-[SecurityPreferences updateJavaScriptViews]):
        disable javascript and/or block popups checkbox if its value is forced
        (-[SecurityPreferences updateMiscellaneousSecurityViews]):
        disable insecure forms checkbox if its value is forced
        (-[SecurityPreferences initializeFromDefaults]):
        disable java checkbox and/or plugins checkbox if its value is forced

        * Preferences.subproj/TabsPreferences.m:
        (-[TabsPreferences updateViews]):
        disable each checkbox if its value is forced

        * PrintingAccessoryViewController.m:
        (-[PrintingAccessoryViewController accessoryView]):
        disable each checkbox if its value is forced

        * Resources/com.apple.Safari.manifest/Contents/Resources/com.apple.Safari.manifest:
        updated key names to match latest spec; removed keys that have been removed in latest
        spec (pfm_print_string and pfm_ui_category); added pfm_titles; removed periods from
        pfm_descriptions since they aren't sentences; made all keys user-managed

        * Resources/com.apple.Safari.manifest/Contents/Resources/English.lproj/Localizable.strings:
        created contents from com.apple.Safari.manifest. I did this by hand this time, but wrote
        bug 3789768 about automating it later.

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

18 years agoRemoved this test, since it doesn't work reliably.
darin [Mon, 6 Sep 2004 17:15:20 +0000 (17:15 +0000)]
Removed this test, since it doesn't work reliably.
We can bring it back some day if we like.

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

18 years ago Fix build problem on panther.
rjw [Sat, 4 Sep 2004 19:59:58 +0000 (19:59 +0000)]
    Fix build problem on panther.

        * khtml/ecma/kjs_html.cpp:
        * khtml/rendering/render_canvasimage.h:

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

18 years ago Simple tweak to background-attachment. Don't apply the slow repaint flag until...
hyatt [Sat, 4 Sep 2004 03:58:13 +0000 (03:58 +0000)]
Simple tweak to background-attachment.  Don't apply the slow repaint flag until after the whole style has been
resolved, since while cascading someone may set the attachment to fixed but later override with scroll.

        * khtml/css/cssstyleselector.cpp:

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

18 years ago Fixed <rdar://problem/3781001>: redirection of URL via resource load delegate does...
rjw [Sat, 4 Sep 2004 01:38:09 +0000 (01:38 +0000)]
Fixed <rdar://problem/3781001>: redirection of URL via resource load delegate does not correctly set base URL for subsequent loads

Ensure that stylesheets have the correct URL when request
is redirected.

        Reviewed by Maciej.

        * khtml/misc/loader.cpp:
        * kwq/KWQLoader.h:
        * kwq/KWQLoader.mm:

        * khtml/ecma/kjs_html.cpp:
Compare parameter count with == instead of <=.

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

18 years ago Fix for 3779083, deleting large amount of text is really slow. Don't use NodeLists...
hyatt [Sat, 4 Sep 2004 00:21:49 +0000 (00:21 +0000)]
Fix for 3779083, deleting large amount of text is really slow.  Don't use NodeLists in editing remove commands.

        Reviewed by darin

        * khtml/editing/htmlediting_impl.cpp:

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

18 years ago Fixed: <rdar://problem/3782543> CrashTracer: ...87 crashes at com.apple.WebKit:...
cblu [Sat, 4 Sep 2004 00:04:26 +0000 (00:04 +0000)]
Fixed: <rdar://problem/3782543> CrashTracer: ...87 crashes at com.apple.WebKit: -[WebNetscapePluginPackage initWithPath:] + 0x18c

        Reviewed by john.

        * Plugins.subproj/WebNetscapePluginPackage.m:
        (-[WebNetscapePluginPackage initWithPath:]): make sure the file is at least 8 bytes long before calling memcmp

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

18 years ago Fixed:
cblu [Fri, 3 Sep 2004 23:02:12 +0000 (23:02 +0000)]
<rdar://problem/3788328> assertion failure when moving an image
<rdar://problem/3783628> REGRESSION (Mail): when I try to reorder an image, the image is duplicated

        Reviewed by NOBODY (OOPS!).

        * DOM.subproj/WebDOMOperations.m:
        (-[DOMDocument _createRangeWithNode:]): new, convenience
        (-[DOMDocument _documentRange]): use _ createRangeWithNode:
        * DOM.subproj/WebDOMOperationsPrivate.h:
        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]): set the selection to the image when starting the drag. This allows "move selection" to work and this matches NSText's behavior

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

18 years ago Reviewed by John.
darin [Fri, 3 Sep 2004 22:12:19 +0000 (22:12 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/3714501> REGRESSION (125.8-8A162): Chinese words display as garbage in search results (www.sz.net.cn)

        * khtml/ecma/kjs_html.cpp: (KJS::HTMLDocument::putValue): Resolve URL using the document method
        that passes the codec rather than calling the KURL constructor directly.

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

18 years ago Fixed: <rdar://problem/3788409> can't create or clone an embed element
cblu [Fri, 3 Sep 2004 21:51:14 +0000 (21:51 +0000)]
Fixed: <rdar://problem/3788409> can't create or clone an embed element

        Reviewed by rjw.

        * khtml/html/htmlparser.cpp: added fixme about sharing code
        * khtml/xml/dom_docimpl.cpp: ditto
        (DocumentImpl::createHTMLElement): create and return a HTMLEmbedElementImpl

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

18 years agore-jigger these ChangeLogs so that they actually reflect what went into Safari-162
vicki [Fri, 3 Sep 2004 21:33:22 +0000 (21:33 +0000)]
re-jigger these ChangeLogs so that they actually reflect what went into Safari-162

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

18 years agochange versions for TOT, Safari 2.0 (v163u)
vicki [Fri, 3 Sep 2004 21:25:44 +0000 (21:25 +0000)]
change versions for TOT, Safari 2.0 (v163u)

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

18 years ago Reviewed by Chris.
darin [Fri, 3 Sep 2004 20:41:23 +0000 (20:41 +0000)]
    Reviewed by Chris.

        - fixed <rdar://problem/3410112> filename with non-ASCII name for <input type=file> should be sent in the page's encoding

        * khtml/html/html_formimpl.cpp: (DOM::HTMLFormElementImpl::formData):
        Encode filename using the codec rather than doing the &# dance. It turns out that Mozilla
        only does the &# thing under certain circumstances that are not important. Always encoding
        the filename is almost certainly better behavior, and will fix many serious problems for
        Japanese and Korean users and websites.

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

18 years ago Reviewed by John.
darin [Fri, 3 Sep 2004 19:23:07 +0000 (19:23 +0000)]
    Reviewed by John.

        - <rdar://problem/3788040> REGRESSION: text that i type into a textarea disappears when i tab out of the textarea

        * kwq/KWQTextArea.mm: (-[KWQTextArea textDidChange:]): Bring back an unconditional version of
        this method. Earlier, we deleted this method, but we should have instead removed the check.

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

18 years ago Made drawImage() in <canvas> compliant with whatwg spec.
rjw [Fri, 3 Sep 2004 17:35:22 +0000 (17:35 +0000)]
Made drawImage() in <canvas> compliant with whatwg spec.

        Reviewed by John.

        * khtml/ecma/kjs_html.cpp:
        * khtml/html/html_imageimpl.h:

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

18 years ago Fix for 3787686, CSS parser should do case-sensitive matching of ids and attributes...
hyatt [Fri, 3 Sep 2004 17:28:02 +0000 (17:28 +0000)]
Fix for 3787686, CSS parser should do case-sensitive matching of ids and attributes only in strict mode
(and not whenever you have an HTML document).

        Reviewed by john

        * khtml/css/parser.cpp:
        * khtml/css/parser.y:

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

18 years agoLand updated layout tests after box/container swap
hyatt [Fri, 3 Sep 2004 17:14:06 +0000 (17:14 +0000)]
Land updated layout tests after box/container swap

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

18 years agoSafari-162 stamp for everything except WebBrowser. In these project, CFBundleShortVe...
vicki [Fri, 3 Sep 2004 02:03:16 +0000 (02:03 +0000)]
Safari-162 stamp for everything except WebBrowser.  In these project, CFBundleShortVersionString matches CFBundleVersion (162 in both cases).

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

18 years ago Swap RenderBox and RenderContainer. Make leaf RenderObjects actually derive off...
hyatt [Fri, 3 Sep 2004 00:10:41 +0000 (00:10 +0000)]
Swap RenderBox and RenderContainer.  Make leaf RenderObjects actually derive off of RenderBox instead.

        Reviewed by kocienda

        * khtml/rendering/render_block.cpp:
        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_box.h:
        * khtml/rendering/render_container.cpp:
        * khtml/rendering/render_container.h:
        * khtml/rendering/render_flow.cpp:
        * khtml/rendering/render_flow.h:
        * khtml/rendering/render_frames.cpp:
        * khtml/rendering/render_frames.h:
        * khtml/rendering/render_inline.cpp:
        * khtml/rendering/render_replaced.cpp:
        * khtml/rendering/render_replaced.h:
        * khtml/rendering/render_table.cpp:
        * khtml/rendering/render_table.h:

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

18 years ago Reviewed by me
kocienda [Thu, 2 Sep 2004 23:41:16 +0000 (23:41 +0000)]
    Reviewed by me

        * khtml/editing/htmlediting_impl.h: Fix some inconsistent use of whitespace. No code change.

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

18 years ago Reviewed by Hyatt
kocienda [Thu, 2 Sep 2004 23:25:09 +0000 (23:25 +0000)]
    Reviewed by Hyatt

        Fix for this bug:

        <rdar://problem/3786848> REGRESSION (Mail): Typing styles and font panel updates broken

        * khtml/xml/dom_position.cpp:
        (DOM::Position::inRenderedContent): Check for inlines that can have kids is wrong.
        I busted this the other day when making the PositionIterator class iterate over
        all nodes and not just leaves of the DOM tree.

        Update all the following functions. These use the PositionIterator class, but still
        only want to consider leaf nodes.


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

18 years agoWebCore:
rjw [Thu, 2 Sep 2004 20:53:54 +0000 (20:53 +0000)]
Support for patterns in <canvas>

        Reviewed by Hyatt.

        * khtml/ecma/kjs_html.cpp:
        * khtml/ecma/kjs_html.h:
        * kwq/KWQPixmap.h:
        * kwq/KWQPixmap.mm:
        * kwq/WebCoreImageRenderer.h:

        Support for patterns in <canvas>.
        (These changes attempt to create a CGImageRef from a WebImageRenderer that
        is used by the pattern drawing function.)

        Reviewed by Hyatt.

        * WebCoreSupport.subproj/WebImageRenderer.h:
        * WebCoreSupport.subproj/WebImageRenderer.m:
        (-[WebImageRenderer dealloc]):
        (-[WebImageRenderer finalize]):
        (-[WebImageRenderer imageRef]):
        * WebView.subproj/WebPDFView.h:
        * WebView.subproj/WebPDFView.m:

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

18 years ago Fix for 3769409, a regression from 10.3.4 to 10.3.5 involving <colgroup>s in malform...
hyatt [Thu, 2 Sep 2004 20:50:48 +0000 (20:50 +0000)]
Fix for 3769409, a regression from 10.3.4 to 10.3.5 involving <colgroup>s in malformed HTML.

        Reviewed by mjs

        * khtml/html/htmlparser.cpp:

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

18 years agoAdd layout test for crashing colgroup
hyatt [Thu, 2 Sep 2004 20:39:24 +0000 (20:39 +0000)]
Add layout test for crashing colgroup

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

18 years ago Fix for the <colgroup> crasher. Make sure adding to an anonymous box just returns...
hyatt [Thu, 2 Sep 2004 20:38:22 +0000 (20:38 +0000)]
Fix for the <colgroup> crasher.  Make sure adding to an anonymous box just returns immediately. Also eliminate
all the redundant setPos -500000 calls, since we don't need those at all.

        Reviewed by john

        * khtml/rendering/render_block.cpp:
        * khtml/rendering/render_inline.cpp:

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

18 years ago Reviewed by John
kocienda [Thu, 2 Sep 2004 17:06:05 +0000 (17:06 +0000)]
    Reviewed by John

        Fix for these bugs:

        <rdar://problem/3729219> REGRESSION (Mail): Caret placement and navigation not working correctly at yahoo.com
        <rdar://problem/3758606> REGRESSION (Mail): Deletions across DIV elements is broken
        <rdar://problem/3784810> REGRESSION (Mail): delete at beginning of line instead deletes to the end of the document (simple reduced test)

        I made some very big improvements to the code which handles deletions of selections
        which span more than one block.

        * khtml/editing/htmlediting_impl.cpp:
        (khtml::CompositeEditCommandImpl::deleteUnrenderedText): An new, overloaded version of this
        function which works on a NodeImpl. The code in this function fell out of some refactoring
        I did in the function with the same name which takes a Position as an argument.
        (khtml::DeleteSelectionCommandImpl::moveNodesToBlock): New function. This new logic provides
        the smarts to fix the bugs listed above and greatly improves the code to perform deleting
        selections which span more than one block.
        (khtml::DeleteSelectionCommandImpl::doApply): Several changes. Constrain downstream positions
        so that they stay in the current block. This was a mistake before I think. Add code to detect
        when the insertion point is a caret at the start of a block. This is a special-case of a
        cross-block selection. Change the end-of-deletion-fixup case to operate on the downstreamEnd
        position of the selection rather than the upstream. This is more logical. Refine the block
        merge logic to handle more cases, like dealing with whitespace.
        * khtml/editing/htmlediting_impl.h: Associated header file changes.
        * khtml/xml/dom_nodeimpl.cpp:
        (NodeImpl::rootEditableElement): Add code to clamp the return value to the body element.
        * khtml/xml/dom_selection.cpp:
        (DOM::Selection::validate): Make selection canonicalizations stay in the current block.
        * layout-tests/editing/deleting/delete-block-merge-contents-001-expected.txt:
        * layout-tests/editing/deleting/delete-block-merge-contents-001.html:
        * layout-tests/editing/deleting/delete-block-merge-contents-002-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-002.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-003-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-003.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-004-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-004.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-005-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-005.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-006-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-006.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-007-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-007.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-008-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-008.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-009-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-009.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-010-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-010.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-011-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-011.html: Added.
        * layout-tests/editing/inserting/insert-3654864-fix-expected.txt: Updated with new results.
        * layout-tests/editing/inserting/insert-3654864-fix.html: Updated test to deal better with
        improved select all behavior.
        * layout-tests/editing/selection/select-all-003-expected.txt: Updated with new results.

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

18 years agoAdding layout test for contentWindow for frames
adele [Thu, 2 Sep 2004 00:58:02 +0000 (00:58 +0000)]
Adding layout test for contentWindow for frames

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

18 years ago Add pid to exception messages (to help debug dashboard clients).
rjw [Wed, 1 Sep 2004 23:49:16 +0000 (23:49 +0000)]
Add pid to exception messages (to help debug dashboard clients).

        Reviewed by Chris.

        * kjs/interpreter.cpp:

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

18 years ago Fixed panther build glitch.
rjw [Wed, 1 Sep 2004 22:53:29 +0000 (22:53 +0000)]
Fixed panther build glitch.

        Reviewed by Ken.

        * khtml/ecma/kjs_html.cpp:

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

18 years ago Fixed deployment build failure.
cblu [Wed, 1 Sep 2004 22:17:57 +0000 (22:17 +0000)]
Fixed deployment build failure.

        * WebView.subproj/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate menuItemWithTag:]):

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

18 years agoWebCore:
rjw [Wed, 1 Sep 2004 19:38:22 +0000 (19:38 +0000)]
Finished implementation of gradient support in <canvas>.

        Reviewed by John.

        * khtml/ecma/kjs_html.cpp:
        * khtml/ecma/kjs_html.h:
        * khtml/ecma/kjs_html.lut.h:

        Test page for gradients usage in the <canvas>.

        Reviewed by John.

        * html/canvas_gradient.html: Added.
        * html/gibson.jpg: Added.

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

18 years ago Fix for 3784686, hidden links still active. Make sure text nodes exclude themselves...
hyatt [Wed, 1 Sep 2004 18:22:56 +0000 (18:22 +0000)]
Fix for 3784686, hidden links still active.  Make sure text nodes exclude themselves from nodeAtPoint checks
when hidden.

        * khtml/rendering/render_text.cpp:

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

18 years agoAdd layout tests.
hyatt [Wed, 1 Sep 2004 17:29:37 +0000 (17:29 +0000)]
Add layout tests.

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

18 years ago Fixes for 3761411 and 3782201. This patch makes two changes to percentage heights...
hyatt [Wed, 1 Sep 2004 17:19:26 +0000 (17:19 +0000)]
Fixes for 3761411 and 3782201.  This patch makes two changes to percentage heights.  First it makes sure that
replaced elements always flex inside a cell (unlike blocks and tables, which do so only sometimes under bizarre
conditions that are still being guessed at by me).  The second fix is a recognition that empty tables do not
actually honor their heights, and so it is a mistake to try to flex them.

        Reviewed by mjs

        * khtml/rendering/render_table.cpp:
        * khtml/rendering/render_table.h:

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

18 years ago Fixed:
cblu [Tue, 31 Aug 2004 22:12:12 +0000 (22:12 +0000)]
<rdar://problem/3699498> Context menu for editable WebViews should provide items like Cut and Paste
<rdar://problem/3781535> REGRESSION (Mail): no context menu after ctrl-clicking a misspelled word

        Reviewed by kocienda.

        * English.lproj/Localizable.strings:
        * WebView.subproj/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate menuItemWithTag:]): updated to handle new menu items
        (-[WebDefaultUIDelegate contextMenuItemsForElement:]): renamed from webView:contextMenuItemsForElement:defaultMenuItems:
        (-[WebDefaultUIDelegate editingContextMenuItemsForElement:]): new
        (-[WebDefaultUIDelegate webView:contextMenuItemsForElement:defaultMenuItems:]): moved, now call contextMenuItemsForElement: or editingContextMenuItemsForElement:
        * WebView.subproj/WebDefaultUIDelegate.h:
        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView _isSelectionMisspelled]): new
        (-[WebHTMLView _guessesForMisspelledSelection]): new
        (-[WebHTMLView _changeSpellingFromMenu:]): new
        (-[WebHTMLView _ignoreSpellingFromMenu:]): new
        (-[WebHTMLView _learnSpellingFromMenu:]): new
        * WebView.subproj/WebHTMLViewPrivate.h:
        * WebView.subproj/WebUIDelegate.h:

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

18 years ago - fixed B&I build failure
darin [Tue, 31 Aug 2004 21:58:44 +0000 (21:58 +0000)]
    - fixed B&I build failure

        * WebView.subproj/WebHTMLView.m: (-[WebTextCompleteController _buildUI]):
        Work around unwanted warning by adding a cast.

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

18 years ago Reviewed by Hyatt
kocienda [Tue, 31 Aug 2004 21:31:31 +0000 (21:31 +0000)]
    Reviewed by Hyatt

        Fix for this bug:

        <rdar://problem/3781572> can't paste text in replied message view

        * khtml/xml/dom2_rangeimpl.cpp:
        (DOM::RangeImpl::toHTML): Copying text placed in an anonymous block was failing
        since the code in here depending on the text node's containing block having an
        element, which it won't. In fact, using containing block is wrong anyway, since
        positioned elements can have containing blocks far from where they live in the
        tree. This "move up to block check" should use the more DOM-wise enclosingBlockFlowElement()
        in NodeImpl.

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

18 years ago Reviewed by John.
mjs [Tue, 31 Aug 2004 20:18:38 +0000 (20:18 +0000)]
    Reviewed by John.

<rdar://problem/3778314> REGRESSION: Can't proceed to survey questions on Lominger's Apple website

Because we will stop parsing when there is a pending redirection,
avoid setting one if no navigation would actually take place
because the number of steps is out of range.

* WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge canGoBackOrForward:]):

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

18 years ago*** empty log message ***
hyatt [Tue, 31 Aug 2004 16:58:06 +0000 (16:58 +0000)]
*** empty log message ***

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

18 years ago Fix for 3742585, sony dhtml menus wrong size. The percentage table height algorithm...
hyatt [Tue, 31 Aug 2004 16:49:33 +0000 (16:49 +0000)]
Fix for 3742585, sony dhtml menus wrong size.  The percentage table height algorithm was wrong.  This patch
unifies the table percentage height algorithm with the block percentage height algorithm and fixes bugs in

        Reviewed by john

        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_table.cpp:

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

18 years ago Reviewed by me
kocienda [Tue, 31 Aug 2004 16:39:10 +0000 (16:39 +0000)]
    Reviewed by me

        Added more editing layout tests.

        * layout-tests/editing/deleting/delete-tab-001-expected.txt: Added.
        * layout-tests/editing/deleting/delete-tab-001.html: Added.
        * layout-tests/editing/deleting/delete-tab-002-expected.txt: Added.
        * layout-tests/editing/deleting/delete-tab-002.html: Added.
        * layout-tests/editing/deleting/delete-tab-003-expected.txt: Added.
        * layout-tests/editing/deleting/delete-tab-003.html: Added.
        * layout-tests/editing/deleting/delete-tab-004-expected.txt: Added.
        * layout-tests/editing/deleting/delete-tab-004.html: Added.
        * layout-tests/editing/editing.js: Fixed a little bug in one of the "delayed" commands.
        * layout-tests/editing/inserting/insert-tab-001-expected.txt: Added.
        * layout-tests/editing/inserting/insert-tab-001.html: Added.
        * layout-tests/editing/inserting/insert-tab-002-expected.txt: Added.
        * layout-tests/editing/inserting/insert-tab-002.html: Added.
        * layout-tests/editing/inserting/insert-tab-003-expected.txt: Added.
        * layout-tests/editing/inserting/insert-tab-003.html: Added.
        * layout-tests/editing/inserting/insert-tab-004-expected.txt: Added.
        * layout-tests/editing/inserting/insert-tab-004.html: Added.

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

18 years ago Reviewed by John
kocienda [Tue, 31 Aug 2004 16:29:26 +0000 (16:29 +0000)]
    Reviewed by John

        Fix for this bug:

        <rdar://problem/3782521> Typing newline at start of block does not work

        * khtml/editing/htmlediting_impl.cpp:
        (khtml::InputNewlineCommandImpl::doApply): Change handling of case to insert
        newline at the start of a block.
        * layout-tests/editing/inserting/insert-br-006-expected.txt: Updated layout test with
        new results.

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

18 years agoChecked this in by mistake, rolling back
kocienda [Tue, 31 Aug 2004 16:04:14 +0000 (16:04 +0000)]
Checked this in by mistake, rolling back

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

18 years agoChangeLog
kocienda [Tue, 31 Aug 2004 15:57:09 +0000 (15:57 +0000)]

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

18 years ago Reviewed by NOBODY (OOPS!).
kocienda [Tue, 31 Aug 2004 15:56:53 +0000 (15:56 +0000)]
    Reviewed by NOBODY (OOPS!).

        * khtml/editing/htmlediting_impl.cpp:
        * layout-tests/editing/deleting/collapse-whitespace-3587601-fix-expected.txt:
        * layout-tests/editing/selection/move-by-line-001-expected.txt:

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

18 years ago Reviewed by me
kocienda [Tue, 31 Aug 2004 15:41:34 +0000 (15:41 +0000)]
    Reviewed by me

        Added more editing layout tests.

        * layout-tests/editing/deleting/collapse-whitespace-3587601-fix-expected.txt: Added.
        * layout-tests/editing/deleting/collapse-whitespace-3587601-fix.html: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-001-expected.txt: Added.
        * layout-tests/editing/deleting/delete-block-merge-contents-001.html: Added.
        * layout-tests/editing/editing.js: Added some more navigation commands.
        * layout-tests/editing/inserting/insert-3778059-fix-expected.txt: Added.
        * layout-tests/editing/inserting/insert-3778059-fix.html: Added.
        * layout-tests/editing/selection/move-by-line-001-expected.txt: Added.
        * layout-tests/editing/selection/move-by-line-001.html: Added.
        * layout-tests/editing/style/typing-style-003-expected.txt: Added.
        * layout-tests/editing/style/typing-style-003.html: Added.

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

18 years ago Reviewed by me
kocienda [Tue, 31 Aug 2004 15:27:18 +0000 (15:27 +0000)]
    Reviewed by me

        Added more editing layout tests. Renamed some others.

        * layout-tests/editing/inserting/insert-br-001-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-001.html: Added.
        * layout-tests/editing/inserting/insert-br-002-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-002.html: Added.
        * layout-tests/editing/inserting/insert-br-003-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-003.html: Added.
        * layout-tests/editing/inserting/insert-br-004-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-004.html: Added.
        * layout-tests/editing/inserting/insert-br-005-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-005.html: Added.
        * layout-tests/editing/inserting/insert-br-006-expected.txt: Added.
        * layout-tests/editing/inserting/insert-br-006.html: Added.
        * layout-tests/editing/inserting/insert-br-case1-expected.txt: Removed.
        * layout-tests/editing/inserting/insert-br-case1.html: Removed.
        * layout-tests/editing/inserting/insert-br-case2-expected.txt: Removed.
        * layout-tests/editing/inserting/insert-br-case2.html: Removed.
        * layout-tests/editing/inserting/insert-br-case3-expected.txt: Removed.
        * layout-tests/editing/inserting/insert-br-case3.html: Removed.
        * layout-tests/editing/inserting/insert-br-case6-expected.txt: Removed.
        * layout-tests/editing/inserting/insert-br-case6.html: Removed.
        * layout-tests/editing/inserting/insert-text-with-newlines-expected.txt: Added.
        * layout-tests/editing/inserting/insert-text-with-newlines.html: Added.

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

18 years ago Reviewed by me
kocienda [Tue, 31 Aug 2004 15:14:57 +0000 (15:14 +0000)]
    Reviewed by me

        * layout-tests/editing/editing.js: Modified typeCharacterCommand so it can accept a character
        as an argument.

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

18 years ago Reviewed by Hyatt
kocienda [Tue, 31 Aug 2004 15:02:27 +0000 (15:02 +0000)]
    Reviewed by Hyatt

        Fix for these bugs:

        <rdar://problem/3777629> REGRESSION (Mail): can't delete blank lines in quoted text in HTML mail replies
        <rdar://problem/3780309> REGRESSION (Mail): can't delete past an empty span in a particular test case
        <rdar://problem/3780315> REGRESSION (Mail): right arrow works incorrectly in a particular test case with an empty span
        <rdar://problem/3780320> REGRESSION (Mail): left arrow works incorrectly in a particular test case with an empty span
        <rdar://problem/3780336> REGRESSION (Mail): down arrow fails in a reduction of a Mail reply test case (seems to be inside a span)

        * khtml/xml/dom_position.cpp:
        (DOM::Position::upstream): If this position's node is a block, use it for the StayInBlock case, not the block's
        enclosing block.
        (DOM::Position::downstream): Ditto.
        (DOM::Position::inRenderedContent): Refine the case for non-text nodes. This was erroneously returning true
        for any empty element (like <span></span>).
        * khtml/xml/dom_positioniterator.cpp: Change the following four functions to consider all nodes, not just
        leaves of the DOM tree. This is a step towards making this iteration less cranky and unpredictable, and
        was necessary to do now to keep the inRenderedContent() change above from breaking editign layout tests.
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::fontForCurrentPosition): Check that the position being checked is an element and that the
        element is in rendered content. I ran across some null-check failures while I was coding this fix, and
        the additions seem prudent.

        Updated these layout tests with new results.

        * layout-tests/editing/deleting/delete-3608430-fix-expected.txt:
        * layout-tests/editing/deleting/delete-3775172-fix-expected.txt:
        * layout-tests/editing/deleting/delete-block-contents-001-expected.txt:
        * layout-tests/editing/deleting/delete-block-contents-002-expected.txt:
        * layout-tests/editing/deleting/delete-block-contents-003-expected.txt:
        * layout-tests/editing/deleting/delete-image-004-expected.txt:
        * layout-tests/editing/deleting/delete-trailing-ws-001-expected.txt:
        * layout-tests/editing/editing.js:
        * layout-tests/editing/execCommand/boldSelection-expected.txt:
        * layout-tests/editing/execCommand/italicizeByCharacter-expected.txt:
        * layout-tests/editing/execCommand/modifyForeColorByCharacter-expected.txt:
        * layout-tests/editing/execCommand/print-expected.txt:
        * layout-tests/editing/execCommand/selectAll-expected.txt:
        * layout-tests/editing/selection/extend-by-character-002-expected.txt:
        * layout-tests/editing/selection/extend-by-character-004-expected.txt:
        * layout-tests/editing/selection/extend-by-character-005-expected.txt:
        * layout-tests/editing/selection/extend-by-character-006-expected.txt:
        * layout-tests/editing/selection/select-all-001-expected.txt:
        * layout-tests/editing/selection/select-all-002-expected.txt:
        * layout-tests/editing/selection/select-all-003-expected.txt:

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

18 years agoWebCore:
darin [Tue, 31 Aug 2004 00:49:18 +0000 (00:49 +0000)]

        Reviewed by John.

        - fixed <rdar://problem/3637519> REGRESSION (125-128): unrepro crash in QListBox::sizeForNumberOfLines at istweb.apple.com

        * kwq/KWQListBox.h: Added a clearCachedTextRenderers function.
        * kwq/KWQListBox.mm:
        (itemTextRenderer): Change to use globals that are outside the function, and added retain calls.
        (groupLabelTextRenderer): Ditto.
        (QListBox::clearCachedTextRenderers): Release global text renderers and nil out the globals.

        * kwq/WebCoreBridge.h: Removed updateAllViews; not needed any more.
        * kwq/WebCoreBridge.mm: Ditto.

        * kwq/WebCoreTextRendererFactory.h: Added a clearCaches method.
        * kwq/WebCoreTextRendererFactory.mm:
        (-[WebCoreTextRendererFactory clearCaches]): Added. Tells all the views to repaint after clearing the cached
        text renderers from KWQListBox. To be more elegant, we could generalize the KWQListBox trick, but for now why bother?

        * kwq/WebCoreTextRendererFactory.m: Removed. I needed to put some C++ code in here, so changed the extension to .mm.
        * WebCore.pbproj/project.pbxproj: Removed WebCoreTextRendererFactory.m, and added WebCoreTextRendererFactory.mm.


        Reviewed by John.

        - part of fix for <rdar://problem/3637519> REGRESSION (125-128): unrepro crash in QListBox::sizeForNumberOfLines at istweb.apple.com

        * WebCoreSupport.subproj/WebTextRendererFactory.m: (-[WebTextRendererFactory clearCaches]):
        Call [super clearCaches].

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

18 years ago Reviewed by John.
darin [Mon, 30 Aug 2004 22:58:27 +0000 (22:58 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/3528538> can paste a Return character into the Search field at amazon.com, other browsers won't

        * kwq/KWQTextField.mm: (-[KWQTextFieldController controlTextDidChange:]):
        Truncate text before the first line break.

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

18 years ago * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertOneChunkUsingTEC):
darin [Mon, 30 Aug 2004 22:44:45 +0000 (22:44 +0000)]
    * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertOneChunkUsingTEC):
        Added some more assertions I used to track down what looks like a TEC bug.

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

18 years ago Reviewed by Ken.
darin [Mon, 30 Aug 2004 22:36:16 +0000 (22:36 +0000)]
    Reviewed by Ken.

        - fixed <rdar://problem/3779122> No accesskey support on LABEL element

        * khtml/html/html_formimpl.h: Change type of m_currValue to DOMString. Should have been done
        as part of my form data check-in, but harmless to do now. Add accessKeyAction function for
        * khtml/html/html_formimpl.cpp:
        (DOM::HTMLButtonElementImpl::parseHTMLAttribute): Remove conversion of DOMString to QString
        for m_currValue.
        (DOM::HTMLLabelElementImpl::formElement): If there's no "for" attribute, search children for
        the first control.
        (DOM::HTMLLabelElementImpl::accessKeyAction): Forward the accesskey action to the formElement.

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

18 years ago Reviewed by Dave.
darin [Mon, 30 Aug 2004 21:50:53 +0000 (21:50 +0000)]
    Reviewed by Dave.

        - fixed <rdar://problem/3303968> final newline character omitted from <textarea> when parsing a new page

        * khtml/html/htmltokenizer.cpp: (khtml::HTMLTokenizer::processListing): Handle newline pending
        cases as well as space and tab pending spaces at the end of this function. This seems right for
        both scripts and text areas; it's not clear why omittiing the LF is ever needed. Tested by running
        all the layout tests; no regressions.

        - fixed <rdar://problem/3552736> word wrapped text fields that blur/focus when you type move the insertion point strangely (vtext.com)

        * khtml/rendering/render_form.cpp: (RenderTextArea::updateFromElement): Call text() instead of
        calling widget->text() directly. This prevents this function from running in cases where the
        text didn't really change for text areas in wrap mode.

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

18 years ago Reviewed by Dave.
darin [Mon, 30 Aug 2004 21:28:49 +0000 (21:28 +0000)]
    Reviewed by Dave.

        - got rid of ERROR message when running layout tests by implementing text-transform in computed style

        * khtml/css/css_computedstyle.cpp:
        (DOM::numberAsString): Added. Helper that returns "1" rather then "1.0" for integer values.
        (DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue): Fixed use of tabs instead of
        spaces. Fixed switch statements so they don't use default so we get errors if we leave
        a case out. Changed callers to use numberAsString instead of QString::number. Added implementation
        of CSS_PROP_TEXT_TRANSFORM. Added code to prevent falling through to next property when no item
        in a switch statement matches.

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

18 years agoWebCore:
darin [Mon, 30 Aug 2004 20:35:41 +0000 (20:35 +0000)]

        Reviewed by Chris.

        - did work to prepare for uploading files incrementally when submitting forms

        * khtml/misc/formdata.h: Added. Class for holding form data inside WebCore.
        * khtml/misc/formdata.cpp: Added.

        * khtml/html/html_formimpl.h: Added the FormDataList type, changed the formData function parameters
        and made it private, renamed the encoding method to appendFormData and changed the parameters around.
        * khtml/html/html_formimpl.cpp:
        (DOM::FormDataList): Added. Class that replaces the old use of QValueList<QCString> for form data.
        Later we'll change it to accomodate filenames too.
        (DOM::HTMLFormElementImpl::formData): Changed code to use FormDataList intsead of the old encodingList.
        Also changed to return the "OK" result as the function result and put the form data into something
        passed as an "out" parameter; the old way was the other way around.
        (DOM::HTMLFormElementImpl::submit): Change to use FormData rather than a QByteArray when getting the
        form data to submit.
        (DOM::HTMLButtonElementImpl::appendFormData): Rename from encoding, and use the new appendData function
        instead of the old way of doing += to put data on the list.
        (DOM::HTMLInputElementImpl::appendFormData): Ditto.
        (DOM::HTMLSelectElementImpl::appendFormData): Ditto.
        (DOM::HTMLKeygenElementImpl::appendFormData): Ditto.
        (DOM::HTMLTextAreaElementImpl::appendFormData): Ditto.
        (DOM::FormDataList::FormDataList): Added.
        (DOM::FormDataList::appendString): Added.
        (DOM::FormDataList::begin): Added.
        (DOM::FormDataList::end): Added.

        * khtml/khtml_part.h: Changed the type of the submitForm parameter to FormData instead of QByteArray.
        * khtml/khtmlpart_p.h: Changed the type of the submitFormData data member to FormData instead of QByteArray.
        * khtml/khtml_part.cpp: (KHTMLPart::submitForm): Called the new flattenToString function in all the
        code that handles mailto forms. Called the new flatten function in the non-Apple code path.

        * kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::submitForm): Pass NSArray for form data instead of NSData.

        * kwq/KWQKJob.h: Use FormData instead of QByteArray. A couple other small cleanups.
        * kwq/KWQKJobClasses.h: Ditto.
        * kwq/KWQKJobClasses.mm:
        (KIO::TransferJobPrivate::TransferJobPrivate): Ditto.
        (KIO::TransferJob::TransferJob): Ditto.
        (KIO::TransferJob::postData): Ditto.
        * kwq/KWQKPartsBrowserExtension.h: Ditto.
        * kwq/KWQLoader.mm:
        (KWQServeRequest): Ditto.
        (KWQServeSynchronousRequest): Ditto.

        * kwq/KWQFormData.h: Added. A function to convert KHTML form data into an NSArray for communication
        with the WebKit side.
        * kwq/KWQFormData.mm: Added.

        * kwq/WebCoreBridge.h: Pass NSArray instead of NSData for form data.

        * kwq/KWQArrayImpl.h: Added a detach member function. The old version would do unnecessary work when
        detach was called on an array that had exactly one reference.
        * kwq/KWQArrayImpl.mm: (KWQArrayImpl::detach): Added.
        * kwq/KWQMemArray.h: (QMemArray::detach): Call through to KWQArrayImpl.

        * kwq/KWQValueList.h:
        (QValueList::first): Added overload for non-const.
        (QValueList::last): Ditto.

        * ForwardingHeaders/misc/formdata.h: Added.
        * WebCore.pbproj/project.pbxproj: Added formdata.h, formdata.cpp, KWQFormData.h, and KWQFormData.cpp.

        * WebCore-tests.exp: Updated for changes to QValueList, and re-sorted.
        * WebCore-combined.exp: Regenerated.


        Reviewed by Chris.

        - did work to prepare for uploading files incrementally when submitting forms

        * History.subproj/WebHistoryItem.m:
        (-[WebHistoryItem _setFormInfoFromRequest:]): Use NSArray instead of NSData for form data.
        (-[WebHistoryItem formData]): Ditto.
        * History.subproj/WebHistoryItemPrivate.h: Ditto.
        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge startLoadingResource:withURL:customHeaders:postData:]): Ditto.
        (-[WebBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]): Ditto.
        (-[WebBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]): Ditto.
        * WebCoreSupport.subproj/WebSubresourceClient.h: Ditto.
        * WebCoreSupport.subproj/WebSubresourceClient.m:
        (+[WebSubresourceClient startLoadingResource:withURL:customHeaders:postData:referrer:forDataSource:]): Ditto.
        * WebView.subproj/WebFrame.m:
        (-[WebFrame _loadItem:withLoadType:]): Ditto.
        (-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]): Ditto.
        * WebView.subproj/WebFramePrivate.h: Ditto.

        * WebView.subproj/WebFormDataStream.h: Added.
        * WebView.subproj/WebFormDataStream.m:
        (-[WebFormDataStream initWithFormDataArray:]): Placeholder; not done yet.
        (-[WebFormDataStream formDataArray]): Ditto.
        * WebKit.pbproj/project.pbxproj: Added WebFormDataStream files.

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

18 years ago Reviewed by Ken.
darin [Mon, 30 Aug 2004 18:00:15 +0000 (18:00 +0000)]
    Reviewed by Ken.

        - improved multiple submit logic in preparation for making command-click on a form
          button load a form in another frame

        * kwq/KWQKHTMLPart.h: Added const to a bunch of member functions for cleanup.
        Added prepareForUserAction member function.
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::submitForm): Simplified logic and removed special case for "http" and "https".
        (KWQKHTMLPart::renderer): Added const.
        (KWQKHTMLPart::keyEvent): Added call to prepareForUserAction.
        (KWQKHTMLPart::lastEventIsMouseUp): Added const.
        (KWQKHTMLPart::eventMayStartDrag): Added const.
        (KWQKHTMLPart::mouseDown): Added call to prepareForUserAction.
        (KWQKHTMLPart::overrideMediaType): Added const.
        (KWQKHTMLPart::canGoBackOrForward): Added const.
        (KWQKHTMLPart::prepareForUserAction): Added. Clears _submittedFormURL.
        * kwq/KWQAccObject.mm: (-[KWQAccObject accessibilityPerformAction:]): Added call to prepareForUserAction.

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

18 years ago Reviewed by John
kocienda [Mon, 30 Aug 2004 17:43:00 +0000 (17:43 +0000)]
    Reviewed by John

        Fix for this bug:

        <rdar://problem/3762231> REGRESSION (Mail): tab key inserts a single space

        * khtml/editing/htmlediting_impl.cpp:
        (khtml::isTab): New helper. Checks a DOMString to see if it is one character and
        that character is a tab.
        (khtml::InputTextCommandImpl::execute): Trap tabs before handling insertion of
        other kinds of whitespace. Treat a tab like four spaces. Rearrange the code to
        update the ending position after the text insertion to cover the new tab case
        where the amount of advance is not the same as the number of character in the
        passed-in DOMString (i.e. tabs expand to four characters).

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

18 years ago Reviewed by Ken.
sullivan [Mon, 30 Aug 2004 17:39:40 +0000 (17:39 +0000)]
    Reviewed by Ken.

        - WebKit part of fix for <rdar://problem/3607720> myFrame.print() prints the window
        but should only print the frame

        * WebView.subproj/WebUIDelegatePrivate.h:
        declare new delegate method that includes which frame to print

        * WebView.subproj/WebDefaultUIDelegate.m:
        (-[WebDefaultUIDelegate webView:printFrameView:]):
        implement default (no-op) version of new delegate method

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge print]):
        call new delegate method if available, otherwise call old delegate method, for
        backward compatibility.

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