3 ms·
Windows API is pure C. GTK is pure C. And these are quite serious (and not exactly obscure) development frameworks.
by DrJokepu 17y ago
Windows API is pure C. GTK is pure C. And these are quite serious (and not exactly obscure) development frameworks.
- markessien 17y agoThe Windows API is an array of functions that can be called the same from C as from C++. Microsoft provides several object oriented wrappers for this API, and it's very rare that any significantly large application is not calling the API over some kind of wrapper.
- DrJokepu 17y agoNo, I think it's C. It's written in C and was (at least initially) designed to be called from C code. I think #ifdef __cplusplus followed by extern "C" doesn't make a C API C/C++. Also the fact that there are several Microsoft and third-party wrappers out there doesn't make it any less C, at least in my opinion.
- markessien 17y agoI did not say it's C++. It's C, but it's rare that it's used directly as C.
- wheels 17y agoAnd, uh ... POSIX. The weapon of choice for UNIX black-belts.
- iroach 17y agoYes but the C++ based MFC wrappers for Win32 make Windows development much easier.
- chancho 17y agoHave you subclassed any GObjects lately? Or otherwise implemented custom GTK widgets? If so, you might know why GTKmm exists (nevermind that PyGTK, GTK# etc are arguably the intended ways to use GTK.) There is a good reason everyone in the Linux world screamed with glee when Nokia LGPLed Qt, and C++ (even the basic stuff) is a big part of that reason.
- vorador 17y agoNo qt is the reason. qt is well designed and thought, contrary to gtk. And it's not because qt was written in C++.
- joezydeco 17y agoI'll second that. Qt is a beautiful toolkit. It's just enough C++ to be useful, and avoids all the templates and obnoxious flotsam that makes that language such a horror. Signals and slots work great, and other tools (qmake for example) are a pleasure to use.