Skip to content

Add drag selection support to subtitle grid#10376

Merged
niksedk merged 1 commit intoSubtitleEdit:mainfrom
ivandrofly:feature/drag-select-subtitle-grid
Mar 23, 2026
Merged

Add drag selection support to subtitle grid#10376
niksedk merged 1 commit intoSubtitleEdit:mainfrom
ivandrofly:feature/drag-select-subtitle-grid

Conversation

@ivandrofly
Copy link
Copy Markdown
Member

@ivandrofly ivandrofly commented Mar 22, 2026

Summary

  • Implement drag selection on the main subtitle DataGrid, allowing users to click and drag to select a contiguous range of rows
  • Adds PointerMoved event handler that tracks the drag start row and selects all rows between the start and current pointer position
  • Existing selection modes (Ctrl+Click, Shift+Click) continue to work as before

Test plan

  • Open a subtitle file with multiple lines
  • Click on a row and drag up/down — verify contiguous rows get selected
  • Verify Ctrl+Click still toggles individual row selection
  • Verify Shift+Click still extends selection
  • Verify right-click context menu still works
  • Verify double-click action still works

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 4.6 noreply@anthropic.com

Implemented drag-selection on the subtitle grid using mouse interactions. Added pointer events handling for selection logic and updated event bindings accordingly.
@ivandrofly
Copy link
Copy Markdown
Member Author

Visual Demo

SubtitleEdit_7k5pJiHusd

@ivandrofly
Copy link
Copy Markdown
Member Author

Hope this goes in very useful feature if you want I can add setting for user to opt in

@niksedk
Copy link
Copy Markdown
Member

niksedk commented Mar 23, 2026

I do not understand this feature.... could you explain more? Where is it used?

Edit: ah, just selection, like SE 4.

@niksedk niksedk merged commit 9b089af into SubtitleEdit:main Mar 23, 2026
1 check passed
@ivandrofly ivandrofly deleted the feature/drag-select-subtitle-grid branch March 23, 2026 17:23
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