[Webkit-unassigned] [Bug 48415] New: [Qt] QML WebView has no way of jumping to an anchor
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Oct 27 04:52:45 PDT 2010
https://bugs.webkit.org/show_bug.cgi?id=48415
Summary: [Qt] QML WebView has no way of jumping to an anchor
Product: WebKit
Version: 528+ (Nightly build)
Platform: PC
OS/Version: Mac OS X 10.5
Status: UNCONFIRMED
Severity: Normal
Priority: P2
Component: WebKit Qt
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: henrik.hartz at nokia.com
I have a WebView embedded inside a Flickable, and I'm trying to move the
page appropriately when a user clicks on a link that's an anchor to the
same page, such as:
<pre>
<a href="#references">Jump to References</a>
</pre>
I looked at the source code in demos/declarative/webbrowser, but I fear
that they may have forgotten about the use of links for that purpose,
since the code in FlickableWebView looks like:
<pre>
(...)
onUrlChanged: {
// got to topleft
flickable.contentX = 0
flickable.contentY = 0
if (url != null) { header.editUrl = url.toString(); }
}
(...)
</pre>
contentY shouldn't typically be set to 0 if the url changes just by the
anchor part (i.e. from http://www.example.com#section1 to
http://www.example.com#section2). My question is: Does the QML WebView
element exposes enough of its state in its API so that we can actually
scroll to the right place on the page ? If not, shouldn't we submit a
bug report or feature request ?
Example:
Use the demos/declarative/webbrowser QML example and visit
http://en.wikipedia.org/wiki/Uniform_Resource_Locator
... and try any of the "Contents" link: Instead of scrolling to the
right place on the page, it will go back to the top of the document.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list