diff options
author | supermerill <merill@free.fr> | 2021-11-09 16:41:15 +0300 |
---|---|---|
committer | supermerill <merill@free.fr> | 2021-11-09 16:42:00 +0300 |
commit | 4e266a5806afd4bd872a171a6e8490948209cade (patch) | |
tree | 180a696a07c57c510ab4a81067619a78d6f2abd6 | |
parent | 5b03c19bae012d6e581cbdb9477de725725ed219 (diff) |
Try fix wxwidget problem with '<' and '>'
supermerill/SuperSlicer#1837
-rw-r--r-- | src/slic3r/GUI/UnsavedChangesDialog.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/slic3r/GUI/UnsavedChangesDialog.cpp b/src/slic3r/GUI/UnsavedChangesDialog.cpp index d56e82d80..c3b1071ee 100644 --- a/src/slic3r/GUI/UnsavedChangesDialog.cpp +++ b/src/slic3r/GUI/UnsavedChangesDialog.cpp @@ -922,8 +922,14 @@ static wxString get_string_value(std::string opt_key, const DynamicPrintConfig& config.opt<ConfigOptionFloats>(opt_key)->get_at(opt_idx); return double_to_string(val, opt->precision); } - case coString: - return from_u8(config.opt_string(opt_key)); + case coString: { + //character '<' '>' create strange problems for wxWidget, so remove them (only for the display) + std::string str = config.opt_string(opt_key); + boost::erase_all(str, "<"); + boost::erase_all(str, ">"); + return from_u8(str); + } + case coStrings: { const ConfigOptionStrings* strings = config.opt<ConfigOptionStrings>(opt_key); if (strings) { |