Skip to content

Selecting and copying text with cursor highlight #284

@supreme-gg-gg

Description

@supreme-gg-gg

Is your feature request related to a problem? Please describe.
In opencode, you can just highlight a text with cursor (including multiline) and it auto copies to your clipboard. Not a super common use case feature but would be nice-to-have for some people. Again, we're not building coding CLI here, but even a messenger TUI can benefit from easier text copying.

Image

Describe the solution you'd like

  1. Detect mouse highlight events (medium)
  2. Find out the text underneath it (hard, not entirely sure how, this would be easy to do for input bar, but might be hard otherwise)
  3. Copy to clipboard automatically (easy)

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
This would build upon the work in #279. However, that PR did not directly support mouse highlight events, only scrolling and clicking. Figuring out what text is highlighted will be non-trivial if we want the user to be able to highlight any messages sent. I'll post my thoughts below if any come up.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions