Bug 29856

Summary: [Qt] gotoAnchor in QtWebKit
Product: WebKit Reporter: Tor Arne Vestbø <vestbo>
Component: WebKit QtAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Enhancement CC: ariya.hidayat, tonikitoo
Priority: P2 Keywords: Qt
Version: 528+ (Nightly build)   
Hardware: Other   
OS: OS X 10.5   
Bug Depends on:    
Bug Blocks: 31552    
Attachments:
Description Flags
Patch hausmann: review+

Description Tor Arne Vestbø 2009-09-29 05:34:18 PDT
This bug report originated from issue QTBUG-3390
http://bugreports.qt.nokia.com/browse/QTBUG-3390

--- Description ---

The gotoAnchor function is available in webkit, but it does not have a Qt wrapper function so that it is available to use. It is the function that scrolls the web page to an html anchor on that page. I am using setHtml to load locally generated html and I want to be able to scroll to a specified point in that html. 

This should be very easy to fix since only a Qt wrapper function is needed to access an existing function in webkit.
Comment 1 Antonio Gomes 2009-10-27 10:33:24 PDT
*** Bug 29885 has been marked as a duplicate of this bug. ***
Comment 2 Ariya Hidayat 2010-02-15 23:15:42 PST
Created attachment 48791 [details]
Patch
Comment 3 Simon Hausmann 2010-02-16 01:47:18 PST
Comment on attachment 48791 [details]
Patch

Nice!

> +void QWebFrame::scrollToAnchor(const QString &anchor)
[...]
> +    void scrollToAnchor(const QString &anchor);

Would be good to fix the & position before landing :)
Comment 4 Ariya Hidayat 2010-02-16 02:28:35 PST
> > +void QWebFrame::scrollToAnchor(const QString &anchor)
> [...]
> > +    void scrollToAnchor(const QString &anchor);
> 
> Would be good to fix the & position before landing :)

The whole file is still using Qt code style for this. Should I switch to WebKit's for this particular function only?
Comment 5 Ariya Hidayat 2010-02-16 18:30:51 PST
Manually committed in r54857: http://trac.webkit.org/changeset/54857