Skip to content

refactor: replace the deprecated breakpoint ruler actions in the Check, Check Configuration and Format UIs - #1618

Open
joaodinissf wants to merge 3 commits into
masterfrom
chore/ignore-deprecated-ui-extensions
Open

joaodinissf wants to merge 3 commits into
masterfrom
chore/ignore-deprecated-ui-extensions

Conversation

@joaodinissf

@joaodinissf joaodinissf commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Removes 24 PDE warnings on the deprecated org.eclipse.ui.editorActions and org.eclipse.ui.popupMenus extension points in check.ui, checkcfg.ui and xtext.format.ui. Nothing is suppressed.

Where the warnings come from

Xtext's XbaseGeneratorFragment2 writes the same block for every Xbase language: action delegates for the ruler double-click, toggle, enable or disable and properties. That is 8 warnings per bundle. The generator has no option to leave the block out, and Xtext's own Xbase languages and examples still carry it.

The 3 remaining warnings come from the Deploy and Undeploy menu in check.ui. They are left to a separate PR that removes the unused Check project support.

The change

One commit per part:

  1. Check Configuration loses its breakpoint adapter and ruler actions. A check configuration infers no executable code, so a breakpoint in it could never be hit.

  2. Check and Format install their ruler actions in code. A new BreakpointRulerActionContributor in xtext.ui is an Xtext IActionContributor:

    • it sets the public debug UI ToggleBreakpointAction as the ruler double-click action;
    • it adds enable or disable and properties actions based on RulerBreakpointAction.

    A BreakpointRulerMenu dynamic contribution shows the three actions in the ruler menu. Both UI modules bind the contributor. The breakpoint adapter that creates the breakpoints is unchanged.

  3. Tests for the ruler actions of all three editors.

xtext.ui gains optional dependencies on org.eclipse.debug.core and org.eclipse.debug.ui. xtext.ui, check.ui, checkcfg.ui and xtext.format.ui get a micro version bump.

Behaviour changes

  • The ruler of a .checkcfg editor no longer offers breakpoints.
  • The Enable/Disable Breakpoint and Breakpoint Properties menu labels no longer show the modifier-click hints of the JDT delegates.
  • plugin.xml_gen keeps the generated deprecated block. plugin.xml is maintained by hand, and regenerating with the CheckCfg workflow left it unchanged.

Testing

  • Eclipse with Temurin 21: after a full rebuild, the Problems view shows no warnings from the breakpoint ruler actions and no errors.
  • Manual checks in a runtime workbench:
    • In Format and Check editors, double-clicking the ruler toggles a breakpoint, and the ruler menu offers Toggle, Disable or Enable, and Properties once each.
    • The Check Configuration ruler has no breakpoint entries.
  • Maven on this branch, with Temurin 21: clean verify with checkstyle:check, pmd:check, pmd:cpd-check and spotbugs:check passes, including the version baseline check. 494 tests ran with no failures or errors, and 2 were skipped.

🤖 Generated with Claude Code

@joaodinissf
joaodinissf marked this pull request as ready for review November 6, 2026 00:54
@joaodinissf

Copy link
Copy Markdown
Collaborator Author

We're reworking this, so it doesn't need a review as it is. Moving it back to draft.

Posted by Claude Code on behalf of @joaodinissf.

@joaodinissf
joaodinissf removed the request for review from rubenporras November 6, 2026 07:45
@joaodinissf
joaodinissf marked this pull request as draft November 6, 2026 07:45
@rubenporras

Copy link
Copy Markdown
Member

I wonder if this is true. If it is so that Xtext writes block unconditionally that point to deprecated stuff, probably a PR for Xtext is better

@rubenporras rubenporras left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

see my last comment

@joaodinissf
joaodinissf force-pushed the chore/ignore-deprecated-ui-extensions branch from c42ca4b to 8462b20 Compare November 21, 2026 15:05
@joaodinissf joaodinissf changed the title chore: ignore deprecated extension warnings in the check and format UIs refactor: replace the deprecated UI extensions in the Check, Check Configuration and Format UIs Nov 21, 2026
@joaodinissf

joaodinissf commented Nov 21, 2026 •

Copy link
Copy Markdown
Collaborator Author

You were right: suppressing the warnings was the wrong fix. I've reworked the PR to replace each deprecated entry with its supported equivalent, so nothing is ignored any more.

The root cause is in Xtext: XbaseGeneratorFragment2 writes the deprecated block for every Xbase language. The replacement here uses only public API, so it could later be proposed to Xtext.

(Comment left by Claude at João's request.)

@joaodinissf
joaodinissf marked this pull request as ready for review November 21, 2026 15:05
joaodinissf and others added 3 commits November 21, 2026 16:10
The Check Configuration UI registered the Xbase breakpoint adapter and
the ruler actions that the Xtext generator emits for every Xbase
language, on the deprecated org.eclipse.ui.editorActions and
org.eclipse.ui.popupMenus extension points.

A check configuration infers no executable code, so a breakpoint in it
can never be hit. The adapter and both ruler contributions are removed;
the editor ruler no longer offers to toggle breakpoints.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The Check and Format UIs contributed their ruler breakpoint actions the
way the Xtext generator emits them for Xbase languages: action
delegates on the deprecated org.eclipse.ui.editorActions and
org.eclipse.ui.popupMenus extension points.

A new BreakpointRulerActionContributor in com.avaloq.tools.ddk.xtext.ui
is an Xtext IActionContributor that installs the public debug UI
ToggleBreakpointAction as the ruler double-click action, plus enable or
disable and properties actions built on RulerBreakpointAction. A
BreakpointRulerMenu dynamic contribution on org.eclipse.ui.menus shows
the three actions in the ruler context menu. Both UI modules bind the
contributor. The breakpoint adapter that creates the breakpoints is
unchanged.

Behaviour is unchanged apart from the enable or disable and properties
menu labels, which no longer show the modifier-click hints of the JDT
delegates. com.avaloq.tools.ddk.xtext.ui gains optional dependencies on
org.eclipse.debug.core and org.eclipse.debug.ui.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ck Configuration editors

BreakpointRulerActionsTest opens Check, Format and Check Configuration
editors and checks which ruler actions and ruler menu entries each one
gets, and that the enable or disable and properties actions follow a
breakpoint on the ruler line.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@joaodinissf
joaodinissf force-pushed the chore/ignore-deprecated-ui-extensions branch from 8462b20 to 6e8e29e Compare November 21, 2026 15:37
@joaodinissf joaodinissf changed the title refactor: replace the deprecated UI extensions in the Check, Check Configuration and Format UIs refactor: replace the deprecated breakpoint ruler actions in the Check, Check Configuration and Format UIs Nov 21, 2026

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants