Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

Some editor DOM operations stop working correctly after a certain number of lines #13459

Open
maxbrunsfeld opened this issue Dec 16, 2016 · 3 comments

Comments

@maxbrunsfeld
Copy link
Contributor

maxbrunsfeld commented Dec 16, 2016

Scrollbar

We render a scrollbar by creating a div with a height that reflects the editor's screen line count. Unfortunately DOM nodes' heights seem to be bounded:

max-height

Reported by @ungb and @Ben3eeE

Decoration rendering

Absolutely-positioned elements like cursors stop rendering correctly after a certain number of lines. It seems that DOM nodes' top property has a hard upper bound.

/cc @nathansobo @as-cii Any ideas on how to solve this?

@nathansobo
Copy link
Contributor

We could render the scrollbar ourselves but I'm not keen to deal with that.

@maxbrunsfeld
Copy link
Contributor Author

Yeah, I agree. Maybe we could shrink the scrollbar view and its scrollTop proportionally, in order to keep its scroll position correct. It would distort the size of the scrollbar itself (making it taller than it would otherwise be), but that might not be so bad.

@nathansobo
Copy link
Contributor

Great idea about doing it proportional. That's the way to go.

@maxbrunsfeld maxbrunsfeld changed the title Scrollbar incorrectly bottoms out at fixed number of lines Some editor DOM operations stop working correctly after a certain number of lines May 31, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants