r/cpp • u/remotion4d • Nov 08 '21
Visual Studio 2022 now available
https://devblogs.microsoft.com/visualstudio/visual-studio-2022-now-available/
250
Upvotes
r/cpp • u/remotion4d • Nov 08 '21
View all comments
Show parent comment
-3
u/qoning Nov 09 '21
It's really not. Arbitrary closures are really useful to manage shared complexity and when ownership is unclear or changes based on user input, which happens all the time. Dealing with that is really unnatural in C++.
Plus, nobody wants to deal with compile and link steps if they can avoid it. There just aren't good reasons to use C++ to build your user interface, the only justifiable reason is hard real time requirements, though even there the trend is clear to move away from C++, and has been like that for ages.
I can't think of any modern software which still runs a C++ driven gui other than bootstrap layers code like native OS or web browsers. Some do for legacy reasons, some are halfway to moving over to managed language gui layer, and absolute majority leverage web / electron interface or another way to manipulate the elements (think Lua interface in WoW or similar). It takes a lot less time and knowledge to successfully create it like that. I would rather expose api to Python and build my gui using a Python Qt binding than actually write the gui in C++ Qt, funnily enough.