Summary: | www.sport1.de element positioning wrong | ||
---|---|---|---|
Product: | [Applications] konqueror | Reporter: | Christoph Bartoschek <bartoschek> |
Component: | khtml | Assignee: | Konqueror Developers <konq-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | unspecified | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: |
Description
Christoph Bartoschek
2003-11-23 13:27:32 UTC
they changed their layout recently - sadly not to the easier ;( But we need test cases for these problems - fortunatly for you I'm a big sport1.de fan - but everyone tells me the site isn't worth it :) I've just read, that you want small testcases instead of a link to a full page. Here are two: For Bug 1 and 2: http://www.pontohonk.de/bugs/sport1-1.html It took hours to strip that horrible Page down to this example. You should compare the mozilla rendering to konqueror's rendering. It seems to be a JavaScript issue. The error also occurs if you replace css.top = css.top + 0; with css.top += 0; For Bug 4: http://www.pontohonk.de/bugs/sport1-4.html deleting nowrap or width="10pt" causes the bug to disapear. Bug 3: This bug appears because the space between the "SUCHEN" label and the grey vertical bar is to high, such that it is pushed to far down. Should I fill two separate bug reports? Subject: Re: www.sport1.de element positioning wrong > For Bug 1 and 2: > http://www.pontohonk.de/bugs/sport1-1.html > It took hours to strip that horrible Page down to this example. Wow, I tried for hours to strip it down and even wrote the (wrong) webmaster. > You should compare the mozilla rendering to konqueror's rendering. > It seems to be a JavaScript issue. The error also occurs if you replace > css.top = css.top + 0; with css.top += 0; > > For Bug 4: > http://www.pontohonk.de/bugs/sport1-4.html > deleting nowrap or width="10pt" causes the bug to disapear. > > Bug 3: This bug appears because the space between the "SUCHEN" label and the > grey vertical bar is to high, such that it is pushed to far down. > > Should I fill two separate bug reports? Yes, please file a bug report for the test cases and I'll close this one as duplicate of one of those. That would be perfect. Thanks for your work. Greetings, Stephan *** Bug 71897 has been marked as a duplicate of this bug. *** Subject: kdelibs/khtml/rendering CVS commit by mueller: fix for testcase 4 in bugreport #68855 CCMAIL: 68855@bugs.kde.org M +2 -1 render_table.cpp 1.252 --- kdelibs/khtml/rendering/render_table.cpp #1.251:1.252 @@ -1591,5 +1591,6 @@ void RenderTableCell::calcMinMaxWidth() // See if nowrap was set. DOMString nowrap = static_cast<ElementImpl*>(element())->getAttribute(ATTR_NOWRAP); - if (!nowrap.isNull() && style()->width().isFixed()) + if (!nowrap.isNull() && style()->width().isFixed() && + m_minWidth < style()->width().value() ) // Nowrap is set, but we didn't actually use it because of the // fixed width set on the cell. Even so, it is a WinIE/Moz trait the other bug got an entry on it's own. This one was just for the nowrap and that's fixed now CVS commit by coolo: merged the DOMNode::getValueProperty code with WebCore and now the updateLayout() works - and with it sport1.de CCMAIL: 68855@bugs.kde.org M +24 -48 kjs_dom.cpp 1.173 --- kdelibs/khtml/ecma/kjs_dom.cpp #1.172:1.173 @@ -166,6 +166,4 @@ Value DOMNode::tryGet(ExecState *exec, c Value DOMNode::getValueProperty(ExecState *exec, int token) const { - khtml::RenderObject *rend = node.handle() ? node.handle()->renderer() : 0L; - switch (token) { case NodeName: @@ -245,34 +243,29 @@ Value DOMNode::getValueProperty(ExecStat case OnUnload: return getListener(DOM::EventImpl::UNLOAD_EVENT); - case OffsetLeft: - case OffsetTop: - case OffsetWidth: - case OffsetHeight: - case OffsetParent: - case ClientWidth: - case ClientHeight: - case ScrollWidth: - case ScrollHeight: - case ScrollLeft: - case ScrollTop: - { + case SourceIndex: { + // Retrieves the ordinal position of the object, in source order, as the object + // appears in the document's all collection + // i.e. document.all[n.sourceIndex] == n + DOM::Document doc = node.ownerDocument(); + if (doc.isHTMLDocument()) { + DOM::HTMLCollection all = static_cast<DOM::HTMLDocument>(doc).all(); + unsigned long i = 0; + DOM::Node n = all.firstItem(); + for ( ; !n.isNull() && n != node; n = all.nextItem() ) + ++i; + Q_ASSERT( !n.isNull() ); // node not in document.all !? + return Number(i); + } + } + default: // no DOM standard, found in IE only - // make sure our rendering is up to date before - // we allow a query on these attributes. + // Make sure our layout is up to date before we allow a query on these attributes. DOM::DocumentImpl* docimpl = node.handle()->getDocument(); - KHTMLView* v = 0; - if ( docimpl ) { - v = docimpl->view(); - // Only do a layout if changes have occurred that make it necessary. - if ( v && docimpl->renderer() && !docimpl->renderer()->layouted() ) - { - docimpl->updateRendering(); - docimpl->view()->layout(); + if (docimpl) { + docimpl->updateLayout(); } - // refetch in case the renderer changed - rend = node.handle() ? node.handle()->renderer() : 0L; - } + khtml::RenderObject *rend = node.handle()->renderer(); switch (token) { @@ -302,26 +295,9 @@ Value DOMNode::getValueProperty(ExecStat case ScrollTop: return Number( rend && rend->layer() ? rend->layer()->scrollYOffset() : 0 ); - } - } - case SourceIndex: { - // Retrieves the ordinal position of the object, in source order, as the object - // appears in the document's all collection - // i.e. document.all[n.sourceIndex] == n - DOM::Document doc = node.ownerDocument(); - if (doc.isHTMLDocument()) { - DOM::HTMLCollection all = static_cast<DOM::HTMLDocument>(doc).all(); - unsigned long i = 0; - DOM::Node n = all.firstItem(); - for ( ; !n.isNull() && n != node; n = all.nextItem() ) - ++i; - Q_ASSERT( !n.isNull() ); // node not in document.all !? - return Number(i); - } - } default: kdDebug(6070) << "WARNING: Unhandled token in DOMNode::getValueProperty : " << token << endl; break; } - + } return Undefined(); } |