[]
        
(Showing Draft Content)

IPane

Interface IPane


public interface IPane
Represents a worksheet pane.

An IPane provides access to the scroll position and activation state of a pane in a worksheet view. You can obtain an IPane from the active pane by calling IWorksheet.getActivePane(), or from the pane collection returned by IWorksheet.getPanes().


 worksheet.splitPanes(2, 2);
 IPane pane = worksheet.getActivePane();
 pane.setScrollRow(3);
 pane.setScrollColumn(2);
 
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Activates this pane.
    int
    Gets the index of this pane within the collection of panes on the worksheet.
    int
    Gets the index of the leftmost visible column in the pane or worksheet.
    int
    Gets the number of the row that appears at the top of the pane or worksheet.
    void
    setScrollColumn(int value)
    Sets the index of the leftmost visible column in the pane or worksheet.
    void
    setScrollRow(int value)
    Sets the number of the row that appears at the top of the pane or worksheet.
  • Method Details

    • activate

      boolean activate()
      Activates this pane.

      You cannot activate a frozen pane.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       boolean activated = pane.activate();
       
      Returns:
      true if the pane is activated.
      Throws:
      IllegalStateException - if this pane cannot be activated.
    • getIndex

      int getIndex()
      Gets the index of this pane within the collection of panes on the worksheet.

      This index identifies the pane's position in the IWorksheet.getPanes() collection.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       int index = pane.getIndex();
       
      Returns:
      The zero-based index of this pane within the pane collection.
    • getScrollColumn

      int getScrollColumn()
      Gets the index of the leftmost visible column in the pane or worksheet.

      Use this method to determine the current horizontal scroll position of a split pane.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       pane.setScrollColumn(3);
       int scrollColumn = pane.getScrollColumn();
       
      Returns:
      The index of the leftmost visible column in the pane or worksheet.
    • setScrollColumn

      void setScrollColumn(int value)
      Sets the index of the leftmost visible column in the pane or worksheet.

      Use this method to set the horizontal scroll position of a split pane.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       pane.setScrollColumn(3);
       
      Parameters:
      value - The index of the leftmost visible column in the pane or worksheet.
    • getScrollRow

      int getScrollRow()
      Gets the number of the row that appears at the top of the pane or worksheet.

      Use this method to determine the current vertical scroll position for a pane after the worksheet has been split or scrolled.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       pane.setScrollRow(5);
       int scrollRow = pane.getScrollRow();
       
      Returns:
      The row number that is currently displayed at the top of the pane or worksheet.
    • setScrollRow

      void setScrollRow(int value)
      Sets the number of the row that appears at the top of the pane or worksheet.

      Use this method to set the vertical scroll position for a pane after the worksheet has been split or scrolled.

      
       worksheet.splitPanes(2, 2);
       IPane pane = worksheet.getPanes().get(0);
       pane.setScrollRow(5);
       
      Parameters:
      value - The row number that is currently displayed at the top of the pane or worksheet.