Implement character index for point (#23989)
Fixes #22939 Fixes #23970 Supersedes https://github.com/zed-industries/zed/pull/23469 Release Notes: - Fixed a bug where Zed could crash with certain input sources on macOS --------- Co-authored-by: Louis Brunner <louis.brunner.fr@gmail.com> Co-authored-by: ben <ben@zed.dev>
This commit is contained in:
parent
7da60995cc
commit
cfe0932c0a
9 changed files with 221 additions and 129 deletions
|
@ -229,9 +229,10 @@ pub fn deploy_context_menu(
|
|||
cx,
|
||||
),
|
||||
None => {
|
||||
let character_size = editor.character_size(window);
|
||||
let menu_position = MenuPosition::PinnedToEditor {
|
||||
source: source_anchor,
|
||||
offset: editor.character_size(window),
|
||||
offset: gpui::point(character_size.width, character_size.height),
|
||||
};
|
||||
Some(MouseContextMenu::new(
|
||||
menu_position,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue