Add "Find Class" action to the layout spy - #2400
Open
vogella wants to merge 2 commits into
Open
Conversation
vogella
force-pushed
the
layout-spy-find-class
branch
from
July 7, 2026 14:24
9ce7e6a to
2cd94fe
Compare
vogella
force-pushed
the
layout-spy-find-class
branch
from
July 30, 2026 17:09
2cd94fe to
6e99b9f
Compare
vogella
marked this pull request as ready for review
July 30, 2026 17:43
Replace the single-level child table and the up/down navigation with a TreeViewer that shows the full SWT control hierarchy, so ancestors, siblings and descendants are visible at once and any node can be selected directly. The layout and diagnostics panels are driven by the tree selection: the layout panel shows the selected control's own layout and the diagnostics panel shows its geometry. The diagnostics output now also reports monitor zoom, display DPI, the size in device pixels and the font, and warns when a size does not map to whole device pixels or when the control sits on a monitor whose zoom differs from its shell. This makes the spy usable for analysing HiDPI and per-monitor scaling problems, not just plain layout issues. A context menu on the tree copies the diagnostics of the selected node and its children to the clipboard, mirroring the CSS spy, so the data can be pasted into bug reports.
Adds a "Find Class" button that hides the spy, lets the user click any control, and then reports the owning e4 application-model element and its implementing class (contribution URI and bundle), unwrapping 3.x compatibility parts to reveal the real view/editor class. Reuses the shell-hiding behaviour of Select Control so the workbench window is not hidden when the spy runs as a part. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
vogella
force-pushed
the
layout-spy-find-class
branch
from
August 2, 2026 18:17
6e99b9f to
88a23fe
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Find Class button to the layout spy. It hides the spy, lets the user click any control, and then shows the owning e4 application-model element and its implementing class in a copyable field.
Reported for the clicked control:
getObject()), unwrapping 3.xCompatibilityPartto reveal the real view/editor classResolution uses the e4 SWT renderer widget-data key
modelElement(AbstractPartRenderer.OWNING_ME); no new bundle dependencies (MUIElement/MContributioncome from the already-requiredorg.eclipse.e4.ui.model.workbench).Note
Stacked on #2388 (shares
LayoutSpyDialog). Review/merge #2388 first; this branch already contains its changes and the diff narrows to this feature once #2388 lands.