Class NavigableTextPane

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, Scrollable

public class NavigableTextPane extends JTextPane
Author:
tuc
See Also:
  • Constructor Details

    • NavigableTextPane

      public NavigableTextPane()
    • NavigableTextPane

      public NavigableTextPane(StyledDocument doc)
  • Method Details

    • getLineOffset

      public int getLineOffset(int line) throws BadLocationException
      Throws:
      BadLocationException
    • scrollLineToVisible

      public void scrollLineToVisible(int line, int margin)
      scroll the specified line into view, with a margin of 'margin' pixels above and below
    • scrollLineToVisible

      public void scrollLineToVisible(int line)
      scroll the specified line into the middle third of the view
    • scrollLinesToVisible

      public void scrollLinesToVisible(int startLine, int endLine, Collection<Integer> otherLines)
      scroll the specified primary lines into view, along with as many of the other lines as is convenient