junichi11 commented on code in PR #5759:
URL: https://github.com/apache/netbeans/pull/5759#discussion_r1155125666
##########
php/php.editor/src/org/netbeans/modules/php/editor/indent/FmtOptions.java:
##########
@@ -569,8 +574,9 @@ public void run() {
} else {
LOGGER.warning(String.format("Can't format %s; it's not
BaseDocument.", doc)); //NOI18N
}
+ pane.setCaretPosition(caretPosition);
pane.setIgnoreRepaint(false);
- pane.scrollRectToVisible(visibleRectangle);
+ SwingUtilities.invokeLater(() ->
pane.scrollRectToVisible(visibleRectangle));
Review Comment:
Because the preview pane is scrolled to the caret position when we change
options after we scroll it anywhere.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists