JScrollPane does not update its scroll to go down to follow the caret position because of Image in JEditorPane
问题 I have a JTabbedPane which two tabs including two JScrollPane . Each JScrollPane is including a JEditorPane . If there is no image in the editor, there is no problem. When there is an image, the scroll does not go down to follow the caret position for the first editor, it's like the image gains always the caret beside it after loading at the end of loading the editor.. Here is my code: public class CaretPositionForJEditorPane { JTabbedPane tabs; JScrollPane scrollPane1; JEditorPane editor1;