Skip to content

Add options to dock/float views in preferences - #2297

Open
sol695510 wants to merge 119 commits into
masterfrom
enhancement/docked-or-floated-pref
Open

sol695510 wants to merge 119 commits into
masterfrom
enhancement/docked-or-floated-pref

Conversation

@sol695510

Copy link
Copy Markdown
Collaborator

Prerequisites

  • Reviewed the checklist

  • Reviewed feedback from the "Sonar Cloud" bot. Note that you have to wait
    for the "CI / Unit Tests") to complete first. Failed Unit tests can be
    debugged by adding the label "verbose logging" to the GitHub PR.

Description of the Change

Added a tab in the options for Constellation preferences to set whether a view is docked or a floating window when opened.

Alternate Designs

N/A

Why Should This Be In Core?

Adds functionality to Core.

Benefits

Allows users to customize their Constellation start up setup.

Possible Drawbacks

N/A

Verification Process

  1. Navigate to Setup > Options > CONSTELLATION > View.
  2. Select checkboxes to set views to open views as floating windows, or deselect to open docked.
  3. Select Apply.
  4. When opened, views will open docked or floating as specified in the preferences.

Additionally during Step 2 if the selections are altered the Apply button will enable, then if the selections are returned to how they appeared when the options menu was opened, the Apply button will disable.

Applicable Issues

#1970

@sol695510 sol695510 added the enhancement New feature or request label Apr 30, 2025
@mimosa2
mimosa2 self-requested a review July 1, 2025 23:54

@mimosa2 mimosa2 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did try this. Some views don't float correctly. I tried with Attribute editor and Table view since these are in the selection list. After dragging them to a new location they seem to dock even after the change in setting.
I have also noticed that float/dock options available (Netbeans functionality) by right clicking each view tabs. The changes are remembered when opening Constellation next time. (see attached)
So there may be a possibility of having two different settings for a same view ? (e.g. float setting from Netbeans and dock setting from Constellation -> Preferences. Which one take the precedence? )

TableView_DockFloat

Also help page is not available for this enhancement. Help button displays a default page.

@sonarqubecloud

sonarqubecloud Bot commented Sep 2, 2025

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
4.4% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@Delphinus8821
Delphinus8821 self-requested a review September 8, 2025 03:40

@Delphinus8821 Delphinus8821 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like it works with some of the views and they are able to be resized when floating now which is good.

The issue that was occurring when opening the Data Access View seems to be back. I made the DAV float using the preferences and then when I opened the view it did this

Image

It is now continuously throwing that exception. The exception window is blank but this is what I could see in the logs

[2026-06-22 10:15:06.584Z] SEVERE [global]: java.lang.IndexOutOfBoundsException: Index -1 out of bounds for length 3 at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:100) at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:106) at java.base/jdk.internal.util.Preconditions.checkIndex(Preconditions.java:302) at java.base/java.util.Objects.checkIndex(Objects.java:385) at java.base/java.util.ArrayList.get(ArrayList.java:427) at javafx.base/com.sun.javafx.collections.ObservableListWrapper.get(ObservableListWrapper.java:88) at javafx.base/com.sun.javafx.collections.VetoableListDecorator.get(VetoableListDecorator.java:314) at javafx.graphics/javafx.scene.Parent.updateCachedBounds(Parent.java:1705) at javafx.graphics/javafx.scene.Parent.recomputeBounds(Parent.java:1649) at javafx.graphics/javafx.scene.Parent.doComputeGeomBounds(Parent.java:1502) at javafx.graphics/javafx.scene.Parent at javafx.graphics/com.sun.javafx.scene.ParentHelper.computeGeomBoundsImpl(ParentHelper.java:84) at javafx.graphics/com.sun.javafx.scene.layout.RegionHelper.superComputeGeomBoundsImpl(RegionHelper.java:78) at javafx.graphics/com.sun.javafx.scene.layout.RegionHelper.superComputeGeomBounds(RegionHelper.java:62) at javafx.graphics/javafx.scene.layout.Region.doComputeGeomBounds(Region.java:3301) at javafx.graphics/javafx.scene.layout.Region at javafx.graphics/com.sun.javafx.scene.layout.RegionHelper.computeGeomBoundsImpl(RegionHelper.java:89) at javafx.graphics/com.sun.javafx.scene.NodeHelper.computeGeomBounds(NodeHelper.java:117) at javafx.graphics/javafx.scene.Node.updateGeomBounds(Node.java:3812) at javafx.graphics/javafx.scene.Node.getGeomBounds(Node.java:3774) at javafx.graphics/javafx.scene.Node.getLocalBounds(Node.java:3722) at javafx.graphics/javafx.scene.Node.updateTxBounds(Node.java:3876) at javafx.graphics/javafx.scene.Node.getTransformedBounds(Node.java:3668) at javafx.graphics/javafx.scene.Node.updateBounds(Node.java:776) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1836) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1834) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1834) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1834) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1834) at javafx.graphics/javafx.scene.Parent.updateBounds(Parent.java:1834) at javafx.graphics/javafx.scene.Scene at javafx.graphics/com.sun.javafx.tk.Toolkit.lambda at java.base/java.security.AccessController.doPrivileged(AccessController.java:400) at javafx.graphics/com.sun.javafx.tk.Toolkit.runPulse(Toolkit.java:400) at javafx.graphics/com.sun.javafx.tk.Toolkit.firePulse(Toolkit.java:430) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:592) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:572) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulseFromQueue(QuantumToolkit.java:565) at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.lambda at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher at javafx.graphics/com.sun.glass.ui.win.WinApplication._runLoop(Native Method) at javafx.graphics/com.sun.glass.ui.win.WinApplication.lambda at java.base/java.lang.Thread.run(Thread.java:1583)

@Quasar985 Quasar985 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works as intended, just a few finals and possibly unneeded functions

@Quasar985

Copy link
Copy Markdown
Collaborator

I forgot that I also found a bug where if you open the help page for view preferences, it also opens the help page for Data Access View Category Preferences. Not sure if this is a problem with your PR or not though

@antares1470 antares1470 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's also a number of code blocks starting with a whitespace line. If you're able to remove those, that would be good.

@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
43.7% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants