From 14c3152ac9c68cc20b114d2598affb0454f6d1aa Mon Sep 17 00:00:00 2001 From: YuSanka Date: Mon, 20 Feb 2023 14:27:31 +0100 Subject: [PATCH] Fix for #9795 - Text emboss input dialog doesn't allow pasting in text from clipboard --- src/slic3r/GUI/ImGuiWrapper.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/slic3r/GUI/ImGuiWrapper.cpp b/src/slic3r/GUI/ImGuiWrapper.cpp index 8908a5ef9d..6b85af966d 100644 --- a/src/slic3r/GUI/ImGuiWrapper.cpp +++ b/src/slic3r/GUI/ImGuiWrapper.cpp @@ -1082,7 +1082,7 @@ void ImGuiWrapper::search_list(const ImVec2& size_, bool (*items_getter)(int, co // The press on Esc key invokes editing of InputText (removes last changes) // So we should save previous value... std::string str = search_str; - ImGui::InputTextEx("", NULL, search_str, 40, search_size, ImGuiInputTextFlags_AutoSelectAll, NULL, NULL); + ImGui::InputTextEx("", NULL, search_str, 240, search_size, ImGuiInputTextFlags_AutoSelectAll, NULL, NULL); edited = ImGui::IsItemEdited(); if (edited) hovered_id = 0; @@ -2056,7 +2056,11 @@ const char* ImGuiWrapper::clipboard_get(void* user_data) const char* res = ""; if (wxTheClipboard->Open()) { - if (wxTheClipboard->IsSupported(wxDF_TEXT)) { + if (wxTheClipboard->IsSupported(wxDF_TEXT) +#if wxUSE_UNICODE + || wxTheClipboard->IsSupported(wxDF_UNICODETEXT) +#endif // wxUSE_UNICODE + ) { wxTextDataObject data; wxTheClipboard->GetData(data);