javafx.scene.control.ScrollPane Java Examples

The following examples show how to use javafx.scene.control.ScrollPane. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: HeadListPane.java    From oim-fx with MIT License 6 votes vote down vote up
private void initComponent() {

		flowPane.setPadding(new Insets(15, 10, 0, 10));
		flowPane.setVgap(10);
		flowPane.setHgap(10);
		flowPane.setPrefWrapLength(900); // 预设流面板的宽度,使得能够显示两列

		scrollPane.setBackground(Background.EMPTY);
		scrollPane.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
		scrollPane.setContent(flowPane);

		centerPane.getChildren().add(scrollPane);
		centerPane.getChildren().add(waitingPanel);

		centerPane.setStyle("-fx-background-color:rgba(255, 255, 255, 0.7)");

		this.setCenter(centerPane);
		this.showWaiting(false, WaitingPane.show_waiting);
	}
 
Example #2
Source File: SettingsView.java    From bisq with GNU Affero General Public License v3.0 6 votes vote down vote up
private void loadView(Class<? extends View> viewClass) {
    final Tab tab;
    View view = viewLoader.load(viewClass);

    if (view instanceof PreferencesView) tab = preferencesTab;
    else if (view instanceof NetworkSettingsView) tab = networkTab;
    else if (view instanceof AboutView) tab = aboutTab;
    else throw new IllegalArgumentException("Navigation to " + viewClass + " is not supported");

    if (tab.getContent() != null && tab.getContent() instanceof ScrollPane) {
        ((ScrollPane) tab.getContent()).setContent(view.getRoot());
    } else {
        tab.setContent(view.getRoot());
    }
    root.getSelectionModel().select(tab);
}
 
Example #3
Source File: PrinterConiguration.java    From BowlerStudio with GNU General Public License v3.0 6 votes vote down vote up
@Override
public void initializeUI(BowlerAbstractDevice pm) {
	NRPrinter printer = (NRPrinter)pm;
	BowlerBoardDevice delt = printer.getDeltaDevice();
	
	if (delt.isAvailable()){
		gui.setDevices(delt,printer);
	}
	if (delt.isAvailable()){
		gui.updateSettings();
	}
	
	SwingNode sn = new SwingNode();
       sn.setContent(gui);
       ScrollPane s1 = new ScrollPane();
      
       s1.setContent(sn);
       setContent(s1);
       setText("Printer Config");
	onTabReOpening();
}
 
Example #4
Source File: FilterWindow.java    From bisq with GNU Affero General Public License v3.0 6 votes vote down vote up
public void show() {
    if (headLine == null)
        headLine = Res.get("filterWindow.headline");

    width = 968;

    createGridPane();

    scrollPane = new ScrollPane();
    scrollPane.setContent(gridPane);
    scrollPane.setFitToWidth(true);
    scrollPane.setFitToHeight(true);
    scrollPane.setMaxHeight(1000);
    scrollPane.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);

    addHeadLine();
    addContent();
    applyStyles();
    display();
}
 
Example #5
Source File: JFXTextAreaSkinBisqStyle.java    From bisq with GNU Affero General Public License v3.0 6 votes vote down vote up
public JFXTextAreaSkinBisqStyle(JFXTextArea textArea) {
    super(textArea);
    // init text area properties
    scrollPane = (ScrollPane) getChildren().get(0);
    textArea.setWrapText(true);

    linesWrapper = new PromptLinesWrapper<>(
            textArea,
            promptTextFillProperty(),
            textArea.textProperty(),
            textArea.promptTextProperty(),
            () -> promptText);

    linesWrapper.init(() -> createPromptNode(), scrollPane);
    errorContainer = new ValidationPane<>(textArea);
    getChildren().addAll(linesWrapper.line, linesWrapper.focusedLine, linesWrapper.promptContainer, errorContainer);

    registerChangeListener(textArea.disableProperty(), obs -> linesWrapper.updateDisabled());
    registerChangeListener(textArea.focusColorProperty(), obs -> linesWrapper.updateFocusColor());
    registerChangeListener(textArea.unFocusColorProperty(), obs -> linesWrapper.updateUnfocusColor());
    registerChangeListener(textArea.disableAnimationProperty(), obs -> errorContainer.updateClip());

}
 
Example #6
Source File: FxmlControl.java    From MyBox with Apache License 2.0 6 votes vote down vote up
public static void zoomOut(ScrollPane sPane, ImageView iView, int xZoomStep,
        int yZoomStep) {
    double currentWidth = iView.getFitWidth();
    if (currentWidth == -1) {
        currentWidth = iView.getImage().getWidth();
    }
    if (currentWidth <= xZoomStep) {
        return;
    }
    iView.setFitWidth(currentWidth - xZoomStep);
    double currentHeight = iView.getFitHeight();
    if (currentHeight == -1) {
        currentHeight = iView.getImage().getHeight();
    }
    if (currentHeight <= yZoomStep) {
        return;
    }
    iView.setFitHeight(currentHeight - yZoomStep);
    FxmlControl.moveXCenter(sPane, iView);
}
 
Example #7
Source File: SessionViewerController.java    From ShootOFF with GNU General Public License v3.0 6 votes vote down vote up
private void updateCameraTabs() {
	cameraTabPane.getTabs().clear();
	cameraGroups.clear();
	eventSelectionsPerTab.clear();

	for (final String cameraName : currentSession.getEvents().keySet()) {
		final Group canvas = new Group();
		final ScrollPane scrollPane = new ScrollPane(canvas);
		scrollPane.setPrefSize(cameraTabPane.getPrefWidth(), cameraTabPane.getPrefHeight());
		scrollPane.setHbarPolicy(ScrollBarPolicy.AS_NEEDED);
		scrollPane.setVbarPolicy(ScrollBarPolicy.AS_NEEDED);
		cameraGroups.put(cameraName, new SessionCanvasManager(canvas, config));

		final Tab cameraTab = new Tab(cameraName);
		cameraTab.setContent(scrollPane);
		cameraTabPane.getTabs().add(cameraTab);
	}
}
 
Example #8
Source File: SummaryTabTest.java    From pdfsam with GNU Affero General Public License v3.0 6 votes vote down vote up
@Test
public void onLoad() throws Exception {
    File file = folder.newFile();
    SummaryTab victim = new SummaryTab();
    Set<Node> properties = ((ScrollPane) victim.getContent()).getContent().lookupAll(".info-property-value");
    assertNotNull(properties);
    assertFalse(properties.isEmpty());
    List<ChangeListener<? super String>> listeners = initListener(properties);
    PdfDocumentDescriptor descriptor = PdfDocumentDescriptor.newDescriptorNoPassword(file);
    WaitForAsyncUtils.waitForAsyncFx(2000, () -> victim.requestShow(new ShowPdfDescriptorRequest(descriptor)));
    fillDescriptor(descriptor);
    descriptor.moveStatusTo(PdfDescriptorLoadingStatus.REQUESTED);
    descriptor.moveStatusTo(PdfDescriptorLoadingStatus.LOADING);
    descriptor.moveStatusTo(PdfDescriptorLoadingStatus.LOADED);
    assertInfoIsDisplayed(listeners, descriptor);
}
 
Example #9
Source File: CommentBoxVBoxer.java    From marathonv5 with Apache License 2.0 6 votes vote down vote up
private Node createTextArea(boolean selectable, boolean editable) {
    textArea = new TextArea();
    textArea.setPrefRowCount(4);
    textArea.setEditable(editable);
    textArea.textProperty().addListener((observable, oldValue, newValue) -> {
        item.setText(textArea.getText());
    });
    textArea.setText(item.getText());
    ScrollPane scrollPane = new ScrollPane(textArea);
    scrollPane.setFitToWidth(true);
    scrollPane.setFitToHeight(true);
    scrollPane.setHbarPolicy(ScrollBarPolicy.NEVER);
    scrollPane.setVbarPolicy(ScrollBarPolicy.ALWAYS);
    HBox.setHgrow(scrollPane, Priority.ALWAYS);
    return scrollPane;
}
 
Example #10
Source File: FxDisplay.java    From testing-video with GNU General Public License v3.0 6 votes vote down vote up
@Override
public void start(Stage stage) throws Exception {
    Parent pane = root.get();

    double width = size.width;
    double height = size.height;

    VBox box = new VBox(pane);
    VBox.setVgrow(pane, ALWAYS);
    box.setMinSize(width, height);
    box.setPrefSize(width, height);
    box.setMaxSize(width, height);

    box.setBackground(new Background(new BackgroundFill(fill, null, null)));

    var scroll = new ScrollPane(box);
    var scene = new Scene(scroll);

    stage.setScene(scene);
    stage.show();
}
 
Example #11
Source File: SimplePopups.java    From pmd-designer with BSD 2-Clause "Simplified" License 6 votes vote down vote up
public static void showAboutPopup(DesignerRoot root) {
    Alert licenseAlert = new Alert(AlertType.INFORMATION);
    licenseAlert.setWidth(500);
    licenseAlert.setHeaderText("About");

    ScrollPane scroll = new ScrollPane();
    TextArea textArea = new TextArea();

    String sb =
        "PMD core version:\t\t\t" + PMDVersion.VERSION + "\n"
            + "Designer version:\t\t\t" + Designer.getCurrentVersion()
            + " (supports PMD core " + Designer.getPmdCoreMinVersion() + ")\n"
            + "Designer settings dir:\t\t"
            + root.getService(DesignerRoot.DISK_MANAGER).getSettingsDirectory() + "\n"
            + "Available languages:\t\t"
            + AuxLanguageRegistry.getSupportedLanguages().map(Language::getTerseName).collect(Collectors.toList())
            + "\n";

    textArea.setText(sb);
    scroll.setContent(textArea);

    licenseAlert.getDialogPane().setContent(scroll);
    licenseAlert.showAndWait();
}
 
Example #12
Source File: ProposalDisplay.java    From bisq with GNU Affero General Public License v3.0 6 votes vote down vote up
@SuppressWarnings("Duplicates")
public ScrollPane getView() {
    ScrollPane scrollPane = new ScrollPane();
    scrollPane.setFitToWidth(true);
    scrollPane.setFitToHeight(true);

    AnchorPane anchorPane = new AnchorPane();
    scrollPane.setContent(anchorPane);

    gridPane.setHgap(5);
    gridPane.setVgap(5);

    ColumnConstraints columnConstraints1 = new ColumnConstraints();
    columnConstraints1.setPercentWidth(100);

    gridPane.getColumnConstraints().addAll(columnConstraints1);

    AnchorPane.setBottomAnchor(gridPane, 10d);
    AnchorPane.setRightAnchor(gridPane, 10d);
    AnchorPane.setLeftAnchor(gridPane, 10d);
    AnchorPane.setTopAnchor(gridPane, 10d);
    anchorPane.getChildren().add(gridPane);

    return scrollPane;
}
 
Example #13
Source File: Canvas.java    From latexdraw with GNU General Public License v3.0 6 votes vote down vote up
@Override
public void setZoom(final double x, final double y, final double z) {
	if(z <= getMaxZoom() && z >= getMinZoom() && !MathUtils.INST.equalsDouble(z, zoom.getValue())) {
		final double oldZoom = zoom.get();
		final ScrollPane sp = getScrollPane();
		zoom.setValue(z);
		setScaleX(z);
		setScaleY(z);

		if(MathUtils.INST.isValidPt(x, y) && sp != null) {
			sp.layout();

			final double newX = x / oldZoom * z;
			final double newY = y / oldZoom * z;
			final double gapX = newX - x;
			final double gapY = newY - y;
			final double gapInH = gapX / (getWidth() - sp.getViewportBounds().getWidth());
			final double gapInV = gapY / (getHeight() - sp.getViewportBounds().getHeight());

			sp.setHvalue(sp.getHvalue() + gapInH);
			sp.setVvalue(sp.getVvalue() + gapInV);
		}
		setModified(true);
	}
}
 
Example #14
Source File: QueryPageListPane.java    From oim-fx with MIT License 6 votes vote down vote up
private void initComponent() {
	this.getChildren().add(listRootPane);
	//this.setAlignment(Pos.BOTTOM_CENTER);

	flowPane.setPadding(new Insets(15, 10, 0, 10));
	flowPane.setVgap(10);
	flowPane.setHgap(10);
	flowPane.setPrefWrapLength(900); // 预设流面板的宽度,使得能够显示两列

	scrollPane.setBackground(Background.EMPTY);
	scrollPane.setHbarPolicy(ScrollPane.ScrollBarPolicy.NEVER);
	scrollPane.setContent(flowPane);

	centerPane.getChildren().add(scrollPane);
	centerPane.getChildren().add(waitingPanel);

	centerPane.setStyle("-fx-background-color:rgba(255, 255, 255, 0.7)");

	listRootPane.setCenter(centerPane);
	listRootPane.setBottom(page);
	listRootPane.setStyle("-fx-background-color:rgba(255, 255, 255, 0.9)");
	VBox.setVgrow(listRootPane, Priority.ALWAYS);
	this.showWaiting(false, WaitingPane.show_waiting);
	this.setPage(0, 1);
}
 
Example #15
Source File: TestLaTeXDraw.java    From latexdraw with GNU General Public License v3.0 6 votes vote down vote up
@Test
public void testMoveViewPort(final FxRobot robot) {
	Platform.runLater(() -> {
		try {
			app.getMainStage().showAndWait();
		}catch(final IllegalStateException ignored) {
			// Already visible
		}
	});
	WaitForAsyncUtils.waitForFxEvents();
	final ScrollPane pane = robot.lookup("#scrollPane").query();
	final double hvalue = pane.getHvalue();
	final double vvalue = pane.getVvalue();
	robot.drag("#canvas", MouseButton.MIDDLE).dropBy(100d, 200d);
	WaitForAsyncUtils.waitForFxEvents();
	assertThat(hvalue).isGreaterThan(pane.getHvalue());
	assertThat(vvalue).isGreaterThan(pane.getVvalue());
}
 
Example #16
Source File: QueryPhasePane.java    From constellation with Apache License 2.0 6 votes vote down vote up
/**
 * Expand the named plugin (and the section it's in) and scroll it to a
 * visible position.
 * <p>
 * All other plugins and sections will be unexpanded.
 *
 * @param pluginName the name of the plugin to expand.
 */
public void expandPlugin(final String pluginName) {
    setHeadingsExpanded(false, true);
    for (final Node node : dataSourceList.getChildrenUnmodifiable()) {
        final HeadingPane headingPane = (HeadingPane) node;
        for (final DataSourceTitledPane tp : headingPane.getDataSources()) {
            if (pluginName.equals(tp.getPlugin().getName())) {
                headingPane.setExpanded(true);
                tp.setExpanded(true);
                final ScrollPane sp = (ScrollPane) getParent().getParent().getParent();
                Platform.runLater(() -> {
                    sp.setHvalue(0);
                    final double v = Math.min(headingPane.getLayoutY() + tp.getLayoutY() + tp.getHeight() / 2, getHeight());
                    sp.setVvalue(v);
                });
                break;
            }
        }
    }
}
 
Example #17
Source File: ImagesBrowserController.java    From MyBox with Apache License 2.0 5 votes vote down vote up
public void moveUp(int index) {
    ScrollPane sPane = imageScrollList.get(index);
    if (sPane == null) {
        return;
    }
    FxmlControl.setScrollPane(sPane, sPane.getHvalue(), 40);
}
 
Example #18
Source File: JFXRepresentation.java    From phoebus with Eclipse Public License 1.0 5 votes vote down vote up
/** Ctrl-Wheel zoom gesture help function
 *  Store scroll offset of scrollContent (scroll_body Group) in a scroller (model_root ScrollPane) before zoom
 */
private Point2D figureScrollOffset(final Node scrollContent, final ScrollPane scroller)
{
    double extraWidth = scrollContent.getLayoutBounds().getWidth() - scroller.getViewportBounds().getWidth();
    double hScrollProportion = (scroller.getHvalue() - scroller.getHmin()) / (scroller.getHmax() - scroller.getHmin());
    double scrollXOffset = hScrollProportion * Math.max(0, extraWidth);
    double extraHeight = scrollContent.getLayoutBounds().getHeight() - scroller.getViewportBounds().getHeight();
    double vScrollProportion = (scroller.getVvalue() - scroller.getVmin()) / (scroller.getVmax() - scroller.getVmin());
    double scrollYOffset = vScrollProportion * Math.max(0, extraHeight);
    return new Point2D(scrollXOffset, scrollYOffset);
}
 
Example #19
Source File: ImagesBrowserController.java    From MyBox with Apache License 2.0 5 votes vote down vote up
public void moveDown(int index) {
    ScrollPane sPane = imageScrollList.get(index);
    if (sPane == null) {
        return;
    }
    FxmlControl.setScrollPane(sPane, sPane.getHvalue(), -40);
}
 
Example #20
Source File: FailureNoteVBoxer.java    From marathonv5 with Apache License 2.0 5 votes vote down vote up
private Node createTextArea(boolean selectable, boolean editable) {
    textArea.setPrefRowCount(4);
    textArea.setEditable(editable);
    textArea.textProperty().addListener((observable, oldValue, newValue) -> {
        item.setText(textArea.getText());
    });
    textArea.setText(item.getText());
    ScrollPane scrollPane = new ScrollPane(textArea);
    scrollPane.setFitToWidth(true);
    scrollPane.setHbarPolicy(ScrollBarPolicy.NEVER);
    scrollPane.setVbarPolicy(ScrollBarPolicy.ALWAYS);
    HBox.setHgrow(scrollPane, Priority.ALWAYS);
    return scrollPane;
}
 
Example #21
Source File: CodeEditor.java    From ARMStrong with Mozilla Public License 2.0 5 votes vote down vote up
private List<Node> getVisibleElements(ScrollPane pane) {
	List<Node> visibleNodes = new ArrayList<Node>();
	Bounds paneBounds = pane.localToScene(pane.getBoundsInParent());
	if (pane.getContent() instanceof Parent) {
		for (Node n : ((Parent) pane.getContent()).getChildrenUnmodifiable()) {
			Bounds nodeBounds = n.localToScene(n.getBoundsInLocal());
			if (paneBounds.intersects(nodeBounds)) {
				visibleNodes.add(n);
			}
		}
	}
	return visibleNodes;
}
 
Example #22
Source File: App.java    From java-ml-projects with Apache License 2.0 5 votes vote down vote up
private Node buildCenterPane() {
	Canvas canvas = new Canvas(CANVAS_WIDTH, CANVAS_HEIGHT);
	ScrollPane spCanvas = new ScrollPane(canvas);
	gc = canvas.getGraphicsContext2D();
	gc.setFill(Color.LIGHTGOLDENRODYELLOW);
	gc.fillRect(0, 0, canvas.getWidth(), canvas.getHeight());
	return spCanvas;
}
 
Example #23
Source File: PanelFocusTest.java    From HubTurbo with GNU Lesser General Public License v3.0 5 votes vote down vote up
private void panelFocus_firstPanel_firstPanelShown(PanelControl panelControl)
    throws IllegalAccessException {
    /**
     * Testing First Panel is shown (i.e. scrollbar is set to left end)
     * and on focus upon Opening Board
     * ================================================================
     */
    // Setup:
    // 1. Save a board
    traverseHubTurboMenu("Boards", "Save as");
    PlatformEx.waitOnFxThread();
    ((TextField) GuiTest.find(IdGenerator.getBoardNameInputFieldIdReference())).setText("Board 1");
    clickOn("OK");
    awaitCondition(() -> 1 == panelControl.getNumberOfSavedBoards());
    // 2. Create a new panel so that scroll bar is on the left
    pushKeys(CREATE_RIGHT_PANEL);
    awaitCondition(() -> panelControl.getCurrentlySelectedPanel().get() ==
        panelControl.getPanelCount() - 1);
    // 3. Open board
    pushKeys(SWITCH_BOARD);

    // Abort saving changes to current board
    waitUntilNodeAppears("No");
    clickOn("No");

    // Check that first panel is on focus
    awaitCondition(() -> 0 == panelControl.getCurrentlySelectedPanel().get());
    // Check that first panel is shown by checking scrollbar position
    ScrollPane panelsScrollPaneReflection =
        (ScrollPane) FieldUtils.readField(panelControl, "panelsScrollPane", true);
    assertEquals(0, panelsScrollPaneReflection.getHvalue(), 0.001);
}
 
Example #24
Source File: QuestSplitPanel_Controller.java    From Path-of-Leveling with MIT License 5 votes vote down vote up
void resetBorder(boolean scrollToTop) {
    container.setStyle(null);
    if (scrollToTop && container.getParent().getParent().getParent().getParent() instanceof ScrollPane) {
        ScrollPane parent = (ScrollPane) container.getParent().getParent().getParent().getParent();
        parent.setVvalue(parent.getVmin());
    }
}
 
Example #25
Source File: DaoView.java    From bisq with GNU Affero General Public License v3.0 5 votes vote down vote up
private void loadView(Class<? extends View> viewClass) {

        if (selectedTab != null && selectedTab.getContent() != null) {
            if (selectedTab.getContent() instanceof ScrollPane) {
                ((ScrollPane) selectedTab.getContent()).setContent(null);
            } else {
                selectedTab.setContent(null);
            }
        }

        View view = viewLoader.load(viewClass);
        if (view instanceof BsqWalletView) {
            selectedTab = bsqWalletTab;
            bsqWalletView = (BsqWalletView) view;
        } else if (view instanceof GovernanceView) {
            selectedTab = proposalsTab;
        } else if (view instanceof BondingView) {
            selectedTab = bondingTab;
        } else if (view instanceof BurnBsqView) {
            selectedTab = burnBsqTab;
        } else if (view instanceof MonitorView) {
            selectedTab = monitorTab;
        } else if (view instanceof NewsView) {
            selectedTab = daoNewsTab;
        } else if (view instanceof EconomyView) {
            selectedTab = factsAndFiguresTab;
        }

        selectedTab.setContent(view.getRoot());
        root.getSelectionModel().select(selectedTab);
    }
 
Example #26
Source File: MessageStage.java    From marathonv5 with Apache License 2.0 5 votes vote down vote up
@Override
public Parent getContentPane() {
    BorderPane root = new BorderPane();
    root.setId("message-stage");
    root.setCenter(new ScrollPane(textArea));
    root.setBottom(buttonBar);
    return root;
}
 
Example #27
Source File: BaseInfoTab.java    From pdfsam with GNU Affero General Public License v3.0 5 votes vote down vote up
BaseInfoTab() {
    setClosable(false);
    grid.getStyleClass().add("info-props");
    grid.setAlignment(Pos.TOP_CENTER);
    ColumnConstraints column1 = new ColumnConstraints();
    column1.setPercentWidth(25);
    ColumnConstraints column2 = new ColumnConstraints();
    column2.setPercentWidth(75);
    grid.getColumnConstraints().addAll(column1, column2);
    ScrollPane scroll = new ScrollPane(grid);
    scroll.setFitToHeight(true);
    scroll.setFitToWidth(true);
    setContent(scroll);
}
 
Example #28
Source File: SettingsSidebarSkin.java    From phoenicis with GNU Lesser General Public License v3.0 5 votes vote down vote up
/**
 * {@inheritDoc}
 */
@Override
protected ScrollPane createMainContent() {
    final SettingsSidebarToggleGroup sidebarToggleGroup = new SettingsSidebarToggleGroup(
            tr("Settings"), getControl().getItems(), getControl().selectedItemProperty());

    return createScrollPane(sidebarToggleGroup);
}
 
Example #29
Source File: HighlightOptions.java    From LogFX with GNU General Public License v3.0 5 votes vote down vote up
public static Dialog showHighlightOptionsDialog( HighlightOptions highlightOptions ) {
    ScrollPane pane = new ScrollPane( highlightOptions );
    pane.setHbarPolicy( ScrollPane.ScrollBarPolicy.NEVER );
    Dialog dialog = new Dialog( new ScrollPane( highlightOptions ) );
    dialog.setSize( 850.0, 260.0 );
    dialog.setTitle( "Highlight Options" );
    dialog.setResizable( false );
    dialog.makeTransparentWhenLoseFocus();
    dialog.show();
    return dialog;
}
 
Example #30
Source File: UI.java    From HubTurbo with GNU Lesser General Public License v3.0 5 votes vote down vote up
private Parent createRootNode() {

        VBox top = new VBox();

        panelsScrollPane = new ScrollPane(panels);
        panelsScrollPane.getStyleClass().add("transparent-bg");
        panelsScrollPane.setFitToHeight(true);
        panelsScrollPane.setVbarPolicy(ScrollBarPolicy.NEVER);
        HBox.setHgrow(panelsScrollPane, Priority.ALWAYS);
        menuBar = new MenuControl(this, panels, panelsScrollPane, prefs, mainStage);
        menuBar.setUseSystemMenuBar(true);

        HBox detailsBar = new HBox();
        detailsBar.setAlignment(Pos.CENTER_LEFT);
        apiBox.getStyleClass().add("text-grey");
        apiBox.setTooltip(new Tooltip("Remaining calls / Minutes to next refresh"));
        detailsBar.getChildren().add(apiBox);

        top.getChildren().addAll(menuBar, detailsBar);

        BorderPane root = new BorderPane();
        root.setTop(top);
        root.setCenter(panelsScrollPane);
        root.setBottom((HTStatusBar) status);

        notificationPane = new NotificationPane(root);

        return notificationPane;
    }