diff --git a/src/App.cpp b/src/App.cpp index 14d5ece..6d5e33f 100644 --- a/src/App.cpp +++ b/src/App.cpp @@ -335,6 +335,13 @@ auto App::init_wayland() -> void handled = true; } break; + case XKB_KEY_a: + case XKB_KEY_A: + if (ctrl) { + app->m_kbd.typing.push_back('a'); + handled = true; + } + break; default: break; } diff --git a/src/ImGui.cpp b/src/ImGui.cpp index dc0e845..a9c046e 100644 --- a/src/ImGui.cpp +++ b/src/ImGui.cpp @@ -516,7 +516,6 @@ auto ImGui::text_input(usize id, std::pmr::string &str, Rectangle rec, if (m_ctrl) { state.sel_anchor_idx = 0; state.current_rune_idx = (int)spans.size(); - state.selecting_all = true; request_refresh = true; break; } @@ -606,8 +605,6 @@ auto ImGui::text_input(usize id, std::pmr::string &str, Rectangle rec, else caret_byte = clamp_cursor(); caret_activity = true; - if (!m_shift) - state.clear_selection(); } state.caret_byte = caret_byte; diff --git a/src/ImGui.hpp b/src/ImGui.hpp index b822e64..43a3fa8 100644 --- a/src/ImGui.hpp +++ b/src/ImGui.hpp @@ -113,7 +113,6 @@ private: Rectangle caret_rect {}; bool external_change { false }; int sel_anchor_idx = -1; - bool selecting_all = false; bool has_selection(int curr_idx) const {