dail8859/NotepadNext

Editor Context Menu Location

已關閉

#780 建立於 2025年5月27日

 (1 則留言) (0 個反應) (0 位負責人)C++ (905 個分叉)batch import
good first issue

倉庫指標

星標
 (14,479 顆星)
PR 合併指標
 (平均合併 9天 1小時) (30 天內合併 3 個 PR)

描述

Description

When right-clicking in the editor there is inconsistent behavior because some commands use the position of the mouse to determine if some things can be used (e.g. a URL), but others need the current caret position (markers).

Describe the solution you'd like

It seems most editors rely on the logic:

  • If the right click is inside a selection, do not change the selection at all, then open the context menu based on the current selection.
  • If the right click is outside the selection, place the caret as the mouse position, then open the context menu based on the new location.

Describe alternatives you've considered

None - Most editors seem to have the described behavior.

貢獻者指南