@@ -455,7 +455,8 @@ void ScreenshotTool::HandleShortcutsInput()
455455 if (m_on_complete)
456456 m_on_complete (SavingOp::File, Ok (GetFinalImage ()));
457457
458- if (ImGui::Shortcut (ImGuiKey_C | ImGuiMod_Ctrl | ImGuiMod_Shift, ImGuiInputFlags_RouteGlobal))
458+ if (ImGui::Shortcut (ImGuiKey_C | ImGuiMod_Ctrl | (g_config->File .ctrl_c_copy_img ? 0 : ImGuiMod_Shift),
459+ ImGuiInputFlags_RouteGlobal) && !ui_blocks_selection ())
459460 if (m_on_complete)
460461 m_on_complete (SavingOp::Clipboard, Ok (GetFinalImage ()));
461462}
@@ -1084,7 +1085,7 @@ void ScreenshotTool::DrawMenuItems()
10841085 if (m_on_complete)
10851086 m_on_complete (SavingOp::File, Ok (GetFinalImage ()));
10861087
1087- if (ImGui::MenuItem (" Copy Image" , " CTRL+SHIFT+C" ))
1088+ if (ImGui::MenuItem (" Copy Image" , g_config-> File . ctrl_c_copy_img ? " CTRL+C " : " CTRL+SHIFT+C" ))
10881089 if (m_on_complete)
10891090 m_on_complete (SavingOp::Clipboard, Ok (GetFinalImage ()));
10901091
@@ -1506,7 +1507,7 @@ void ScreenshotTool::DrawAnnotationToolbar()
15061507
15071508static void draw_preference_edit_config (const std::function<void ()>& refresh_models_func, bool window_just_opened)
15081509{
1509- static std::string new_font;
1510+ static std::string new_font;
15101511 static Result<std::string> r = get_config_image_out_fmt ();
15111512
15121513 ImGui::SeparatorText (" Edit default config" );
@@ -1588,6 +1589,10 @@ static void draw_preference_edit_config(const std::function<void()>& refresh_mod
15881589 ImGui::SameLine ();
15891590 HelpMarker (" When enabled, annotations are included in the region passed to the text extractor." );
15901591
1592+ ImGui::Checkbox (" Use CTRL+C to copy image##config_ctrl_c_copy_img" , &g_config->File .ctrl_c_copy_img );
1593+ ImGui::SameLine ();
1594+ HelpMarker (" Shortcut to use when copying the image selection.\n If disabled, the shortcut will be CTRL+SHIFT+C." );
1595+
15911596 // --- Image output format section ---
15921597 ImGui::Dummy (ImVec2 (0 , 8 ));
15931598 ImGui::Separator ();
0 commit comments