dail8859/NotepadNext

Editor Context Menu Location

クローズ

#780 opened on 2025/05/27

 (1 件のコメント) (0 件のリアクション) (0 人の担当者)C++ (905 件のフォーク)batch import
good first issue

Repository metrics

Stars
 (14,479 個のスター)
PR merge metrics
 (平均マージ 9d 1h) (30d で 3 merged PRs)

説明

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.

コントリビューターガイド