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

scrollToPosition and scrollToRow do not seem to work #16

Open
tlaukkan opened this issue Sep 26, 2013 · 4 comments
Open

scrollToPosition and scrollToRow do not seem to work #16

tlaukkan opened this issue Sep 26, 2013 · 4 comments
Labels

Comments

@tlaukkan
Copy link

Configured poms to AceEditor 0.8.7 and Vaadin 7.1.6. Updated, cleaned and compiled widgetsets. Cleaned browser history and restarted web container. Invoking the following does not seem to have any effect on scrolling:

editor.setValue(builder.toString());
editor.scrollToPosition(lastCursor);

Same with editor.scrollToRow(). Have I forgotten something or maybe a bug?

@ahn
Copy link
Owner

ahn commented Sep 26, 2013

Looks like a bug.

I guess the bug occurs when you set the text value and scroll position on the same server visit, as in your example. In that case the client-side editor first scrolls to the position (or may do nothing if the text was empty before), and after that sets the text.

I'll take a look at it at some point.

@ahn ahn closed this as completed in ea3ee9c Sep 27, 2013
@tlaukkan
Copy link
Author

I could get the scroll to work with previous version if I had earlier loaded text. The setting text + scrolling does not work with 0.8.8 either for some reason.

@ahn ahn reopened this Sep 30, 2013
@tlaukkan
Copy link
Author

tlaukkan commented Oct 2, 2013

This is the project I used Ace Editor for. Made the hole thing possible really: https://vaadin.com/directory#addon/groom-code-review-site

@ahn
Copy link
Owner

ahn commented Oct 3, 2013

Groom looks sweet. I'll take a closer look at it at some point. :)

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

No branches or pull requests

2 participants