Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal: Embed WebView2 Control into a Scrollviewer and disable the Chromium-style scrolling by default #5654

Open
EP012014 opened this issue Aug 10, 2021 · 7 comments
Assignees
Labels
area-Scrolling area-WebView feature proposal New feature proposal team-Rendering Issue for the Rendering team

Comments

@EP012014
Copy link

EP012014 commented Aug 10, 2021

Proposal: Embed WebView2 Control into a Scrollviewer and disable the Chromium-style scrolling by default

Summary

Due to the limited performance of Chromium WebView2 scrolling especially on touch screen or trackpad ,use UWP ScrollViewers to give a smoother scrolling similar to EdgeHTML WebView.

Rationale

  • Chromium scrolling is not smooth enough to give a good experience to touch-screen and trackpad users.
  • A ScrollViewer can give a scrolling experience similar to other UWP apps or the EdgeHTML WebView, to provide a continuous and immersive experience for al users.

WebView on Laptop trackpad

WebView2 on Laptop trackpad

  • WebView2 is not optimized for touch inputs and trackpad .

Scope

| Capability | Priority |
| Use UWP ScrollViewer instead of WebView2 default | Must |
| Disable the scroll of WebView2 | Must |

Important Notes

UWPlize the experience of WebView2!

@EP012014 EP012014 added the feature proposal New feature proposal label Aug 10, 2021
@ghost ghost added the needs-triage Issue needs to be triaged by the area owners label Aug 10, 2021
@StephenLPeters
Copy link
Contributor

@predavid and @codendone FYI

@seven-mile
Copy link

Pretty good. More radical solution is to update(rebuild) Edge's smooth scrolling experience directly, which was satisfactory when using old EdgeHTML. And I guess there must have been someone who proposed this in the FeedbackHub.

@EP012014
Copy link
Author

Pretty good. More radical solution is to update(rebuild) Edge's smooth scrolling experience directly, which was satisfactory when using old EdgeHTML. And I guess there must have been someone who proposed this in the FeedbackHub.

Using UWP-Styled ScrollViewer? That's pretty nice! But I think that needs a lot of hard work to integrate it into Chromium rendering system.

@sylveon
Copy link
Contributor

sylveon commented Aug 15, 2021

Edge itself has fairly decent handling of touchpad/touch screens already. I think a better ask would be to enable that handling in WebView 2, because AFAIK WebView 2 captures all input in it so a ScrollViewer can't work since there's no way for it to get input and recognize scroll/pan gestures.

@JaiganeshKumaran
Copy link
Contributor

JaiganeshKumaran commented Aug 23, 2021

At least make the scrollbar thumb look modern by default for all pages unless overridden by the site, it looks terrible currently.

@codendone codendone removed the needs-triage Issue needs to be triaged by the area owners label Sep 2, 2021
@codendone
Copy link
Contributor

The approach proposed here is probably not going to happen. If WebView2 drew into an enormous surface the width/height of the entire page, that would provide the desired smooth scrolling experience but would have a huge performance cost for that surface. That surface cost could be mitigated if WebView2 drew into a XAML VirtualSurfaceImageSource, which would require significant design changes and other complexities due to the WebView2 Runtime rendering outside of the app process.

It sounds like this was just one idea, though, and the core request for this proposal is "Ensure WebView2 has a smooth scrolling experience". If that is correct, then I suggest we focus this proposal on that request.

@JaiganeshKumaran I agree it would be good to have the scrollbar visuals match. Could you log that as a separate issue?

@krschau
Copy link
Contributor

krschau commented Jan 27, 2022

For reference, item for updating scrollbar look is here: #6192

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-Scrolling area-WebView feature proposal New feature proposal team-Rendering Issue for the Rendering team
Projects
None yet
Development

No branches or pull requests

8 participants