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

AvaloniaEdit works incorrectly with every value of AllowScrollBelowDocument #141

Closed
Takoooooo opened this issue Jul 16, 2021 · 4 comments · Fixed by #254
Closed

AvaloniaEdit works incorrectly with every value of AllowScrollBelowDocument #141

Takoooooo opened this issue Jul 16, 2021 · 4 comments · Fixed by #254

Comments

@Takoooooo
Copy link
Contributor

Takoooooo commented Jul 16, 2021

How it works in Avalonia with the default value(true).
http://g.recordit.co/WMkRcE7Fxf.gif

How it works in WPF with value = true.
http://g.recordit.co/6h5W3Ea404.gif

How it works in Avalonia with value = false.
http://g.recordit.co/9KJGzvPYy9.gif

Fixed by #139 . Fixed behaviour https://recordit.co/8q2rA25T9I

How it works in WPF with value = false.
http://g.recordit.co/3SBqf65cD5.gif

@Takoooooo
Copy link
Contributor Author

Takoooooo commented Jul 19, 2021

Ok I somewhy can't repro anymore the behaviour in WPF with value = true from above. Current behaviour
https://recordit.co/DdFcAp3QS2 which matches well with our behaviour in Avalonia

@Takoooooo
Copy link
Contributor Author

Ok I somewhy can't repro anymore the behaviour in WPF with value = true from above. Current behaviour
https://recordit.co/DdFcAp3QS2 which matches well with our behaviour in Avalonia

It's reproducible only when you scroll with your mouse, not scrollbar.I'm not sure we need to port this also. That behaviour is bad IMO

@Takoooooo
Copy link
Contributor Author

Ok I somewhy can't repro anymore the behaviour in WPF with value = true from above. Current behaviour
https://recordit.co/DdFcAp3QS2 which matches well with our behaviour in Avalonia

It's reproducible only when you scroll with your mouse, not scrollbar.I'm not sure we need to port this also. That behaviour is bad IMO

So current plan is to port the behaviour from WPF and additionally to make it consistent between scrollbar and mouse scrolling

@danipen
Copy link
Collaborator

danipen commented Jul 29, 2021

@Takoooooo, agree.

Note that other editors (VSCode, Sublime), behaves in that way. They allow scrolling below document by default, and they behave in this way:

  • When using Mouse/Scrollbar, the editor allows to display extra space, so the last document line in displayed the first viewport position.
  • When using the arrow keys (or Ctrl+END), the last line is placed in the last viewport line (no extra space is displayed in this case).

Demo: https://www.loom.com/share/aa99e5381fe34efbb2d22d4caa673c74

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants