Skip to content

Conversation

@cjmayo
Copy link

@cjmayo cjmayo commented Sep 16, 2025

wxWidgets 3.3 has stopped defining in global scope all operators
including "+" on wx types, causing some string concatenations to fail.

All the constants from ImGui used by marker_by_type() are of type
wchar_t. Stop returning them as type char.

PrusaSlicer-version_2.9.3/src/slic3r/GUI/Search.cpp:253:62: error: no match for ‘operator+’ (operand types are ‘char’ and ‘const std::wstring’ {aka ‘const std::__cxx11::basic_string<wchar_t>’})
  253 |         return  marker_by_type(opt.type, printer_technology) +
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
      |                               |
      |                               char
  254 |                 opt.category_local + sep +
      |                 ~~~~~~~~~~~~~~~~~~
      |                     |
      |                     const std::wstring {aka const std::__cxx11::basic_string<wchar_t>}

wxWidgets Changelog:
https://raw.githubusercontent.com/wxWidgets/wxWidgets/v3.3.0/docs/changes.txt

C++ isn't my first language so please take this as an illustration of the issue and check carefully.

wxWidgets 3.3 has stopped defining in global scope all operators
including "+" on wx types, causing some string concatenations to fail.

All the constants from ImGui used by marker_by_type() are of type
wchar_t. Stop returning them as type char.

PrusaSlicer-version_2.9.3/src/slic3r/GUI/Search.cpp:253:62: error: no match for ‘operator+’ (operand types are ‘char’ and ‘const std::wstring’ {aka ‘const std::__cxx11::basic_string<wchar_t>’})
  253 |         return  marker_by_type(opt.type, printer_technology) +
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
      |                               |
      |                               char
  254 |                 opt.category_local + sep +
      |                 ~~~~~~~~~~~~~~~~~~
      |                     |
      |                     const std::wstring {aka const std::__cxx11::basic_string<wchar_t>}
@cjmayo cjmayo changed the title Fix building with wxWidgets 3.3 Fix compiling with wxWidgets 3.3 Sep 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant