Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

[cmv3] Ensure inline widgets are scrolled to be fully visible when opened, and ... #2397

Merged
merged 1 commit into from
Dec 19, 2012

Conversation

njx
Copy link

@njx njx commented Dec 18, 2012

...ensure cursor within inline widget remains visible on selection change

@gruehle

Note that this relies on a new feature of scrollIntoView(), the ability to scroll a specific rectangle to be visible, which Marijn just added upstream and is already merged into our upstream-master branch of CodeMirror.

…nd ensure cursor within inline widget remains visible on selection change
@ghost ghost assigned gruehle Dec 18, 2012
left: cursorCoords.left - inlineLineSpaceOffset.left,
top: cursorCoords.top - hostLineSpaceTop,
right: cursorCoords.left - inlineLineSpaceOffset.left,
bottom: cursorCoords.bottom - hostLineSpaceTop
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that we can use the hostEditor's lineSpace here now because the new scrolling mechanism in v3 still has the lineSpace always be the full height of the virtual document (instead of just a small window around the viewport as in our original version).

gruehle added a commit that referenced this pull request Dec 19, 2012
[cmv3] Ensure inline widgets are scrolled to be fully visible when opened, and ...
@gruehle gruehle merged commit 223ebf4 into cmv3 Dec 19, 2012
@gruehle gruehle deleted the nj/cmv3-scrollIntoView branch December 19, 2012 00:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants