Skip to content

2026.1.1#90

Merged
hoxi merged 4 commits intocomod:masterfrom
hoxi:2026_1_1
Apr 3, 2026
Merged

2026.1.1#90
hoxi merged 4 commits intocomod:masterfrom
hoxi:2026_1_1

Conversation

@hoxi
Copy link
Copy Markdown
Collaborator

@hoxi hoxi commented Apr 3, 2026

  • Small bugfixes to 2026.1 release
  • Improvements to gutter popup diff

hoxi added 4 commits March 31, 2026 22:58
- GitScopeFileStatusProvider: use live ChangeListManager.getStatus() instead
  of cached localChangesMap so scope color is restored immediately after undo
- LineStatusGutterMarkerRenderer/ScopeLineStatusMarkerRenderer: derive normal
  and hover thickness from lineMarkerAreaWidth (via getGutterArea() reflection)
  instead of hardcoded pixel values, fixing incorrect size on Linux
- ScopeLineStatusMarkerRenderer: fix updateHoverState bounds to match paint/
  canDoAction exactly; add mouseEntered to recover stuck hover state; add
  EditorFactoryListener for split editors; remove spurious invokeLater from
  installMouseListeners to fix timing race that left reopened files without
  mouse listeners
- MyLineStatusTrackerImpl: wrap FileDocumentManager.getDocument() in
  runReadAction() to comply with IntelliJ threading rules
- Gutter popup: use setBorderColor() on ComponentPopupBuilder so the popup
  window border is consistent across themes; add right padding to scope name
  label so text is not clipped against the panel edge when no diff is shown

Fixes comod#88
Fixes comod#89
Mirrors IntelliJ's own VCS gutter popup behaviour
(LineStatusMarkerPopupPanel.installMasterEditorWordHighlighters):

- Line-level background highlight (dimmed 'ignored' variant) is added to the
  current editor lines covered by the open range so the diff context is
  immediately visible without scrolling the popup
- Word-level inline highlights are layered on top for MODIFIED ranges,
  using the same ComparisonManager word diff already computed for the popup
  diff panel (offset2 = current-file side)
- DELETED ranges are skipped — no current lines exist to highlight
- All highlighters are scoped to a child Disposable of the popup lifetime
  and auto-removed when the popup closes
- On prev/next navigation the per-range child disposable is replaced so the
  highlights always track the currently displayed range
- Popup window border is now set via setBorderColor() on the builder for
  consistent appearance across themes; scope name label gets right padding
  so text does not sit flush against the panel edge when no diff is shown
- Bump pluginVersion to 2026.1.1
- Upgrade Gradle wrapper to 9.4.1
- Add CHANGELOG entry for fixes in comod#88 and comod#89
Split the 1034-line ScopeLineStatusMarkerRenderer into three files
following the same separation of concerns used by IntelliJ's own
LineStatusMarkerRenderer / LineStatusMarkerPopupPanel split:

- ScopeGutterHighlighterManager: owns the RangeHighlighter, error-stripe
  marks, gutter repaint, and the anonymous LineStatusGutterMarkerRenderer
  subclass (analogous to LineStatusMarkerRenderer)
- ScopeGutterPopupPanel: builds the popup UI, toolbar actions, editor
  highlights, and rollback/copy operations (analogous to
  LineStatusMarkerPopupPanel); entirely original code, not derived from
  IntelliJ
- ScopeLineStatusMarkerRenderer: trimmed to a pure orchestrator — hover
  state, mouse listeners, filler management, and public API only
- rangeContainsY extracted as a package-level function in
  LineStatusGutterMarkerRenderer.kt so both the hover tracker and the
  gutter renderer can share it without a cross-class dependency
- NOTICE updated to reflect the new file boundaries

Also positions the gutter popup just below the last line of the clicked
range so the changed text stays visible. Prev/next navigation does not
reposition the window.
@hoxi hoxi self-assigned this Apr 3, 2026
@hoxi hoxi requested a review from comod April 3, 2026 13:46
@hoxi hoxi merged commit 4b5bfe6 into comod:master Apr 3, 2026
1 check passed
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.

1 participant