public int getHorizontalDivider() { int location = horizontalSplitPane.getSize().width - horizontalSplitPane.getInsets().left - horizontalSplitPane.getDividerSize() - horizontalSplitPane.getRightComponent().getWidth(); double width = indexingFrame.getWidth(); double proportionalLocation = location / width; // horizontalSplitPane.setDividerLocation(proportionalLocation); return location; }
public int getVerticalDivider() { int location = verticalSplitPane.getSize().height - verticalSplitPane.getInsets().bottom - verticalSplitPane.getDividerSize() - verticalSplitPane.getBottomComponent().getHeight(); double height = indexingFrame.getHeight(); double proportionalLocation = location / height; // verticalSplitPane.setDividerLocation(proportionalLocation); // double check = verticalSplitPane.getDiv return location; }