Bug 143710 - [GTK] Webkit2Gtk: no api to get and set scroll position
Summary: [GTK] Webkit2Gtk: no api to get and set scroll position
Status: RESOLVED WORKSFORME
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Linux
: P3 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-14 05:00 PDT by Jan
Modified: 2016-02-04 04:02 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan 2015-04-14 05:00:19 PDT
Currently there seems to be no way to get and set the scroll position of the webview.
This was possible in webkit1 because the webview implemented the gtk scrollable interface and could be placed inside an scrolledwindow.
It would be nice to have this functionality back with webkit2.
Comment 1 Marcos Chavarría Teijeiro (irc: chavaone) 2015-04-15 00:58:39 PDT
You can use JavaScript to get and set the scroll position. Using window.scrollTo(x,y) JS function and window.scrollX and window.scrollY properties.

https://wiki.gnome.org/Projects/WebKitGtk/ProgrammingGuide/Cookbook#Scrolling
Comment 2 Jan 2016-02-04 04:02:23 PST
I think this can be closed now.