Verified Owner
Top Description Constructors Methods
org.jabref.gui.util

public Class DialogPaneWithoutButtonBar

extends DialogPane
Class Inheritance
Annotations
@NullMarked
Imports
javafx.scene.Node, javafx.scene.control.DialogPane, org.jspecify.annotations.NullMarked, .Nullable

A dialog pane that places its buttons itself instead of leaving them to the button bar.

The button types stay declared - ButtonType.CLOSE is what lets Escape and the window's close button close the dialog, and DialogPane#lookupButton keeps working, because the pane fills its button nodes from a listener on the button types rather than from the bar. Only the bar itself is gone, so a dialog that shows its own buttons has no unused node in the scene graph.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected @Nullable Node
createButtonBar()

Overrides javafx.scene.control.DialogPane.createButtonBar.

This method can be overridden by subclasses to provide the button bar.

Inherited from javafx.scene.control.DialogPane:
computeMinHeightcomputeMinWidthcomputePrefHeightcomputePrefWidthcontentPropertycontentTextPropertycreateButtoncreateDetailsButtonexpandableContentPropertyexpandedPropertygetButtonTypesgetClassCssMetaDatagetContentgetContentTextgetCssMetaDatagetExpandableContentgetGraphicgetHeadergetHeaderBargetHeaderTextgraphicPropertyheaderBarPropertyheaderPropertyheaderTextPropertyisExpandedlayoutChildrenlookupButtonsetContentsetContentTextsetExpandableContentsetExpandedsetGraphicsetHeadersetHeaderBarsetHeaderText

Constructor Detail

DialogPaneWithoutButtonBarback to summary
public DialogPaneWithoutButtonBar()

Method Detail

createButtonBarback to summary
protected @Nullable Node createButtonBar()

Overrides javafx.scene.control.DialogPane.createButtonBar.

Doc from javafx.scene.control.DialogPane.createButtonBar.

This method can be overridden by subclasses to provide the button bar. Note that by overriding this method, the developer must take on multiple responsibilities:

  1. The developer must immediately iterate through all button types and call createButton(ButtonType) for each of them in turn.
  2. The developer must add a listener to the button types list, and when this list changes update the button bar as appropriate.
  3. Similarly, the developer must watch for changes to the expandable content property, adding and removing the details button (created via createDetailsButton() method).

The default implementation of this method creates and returns a new ButtonBar instance.

Annotations
@Override