Actually a question.
Why with languages ​​like C #, VBasic in MSVS when creating a Win project, FormBuilder immediately appears and you can drag the mouse quickly to wrap up the form and describe the necessary event handlers, and have the pros been deprived of this opportunity? Well, that is there is wxWidgets , for example, MFC , Qt , but writing with a pens a graphical interface, somehow, hmm, is not clearly something. It would be wise to automate this process before working with the mouse, I think.
Why did this happen and what were the historical prerequisites for that? Is there any \ IDE library (with support for modern compilers) that somehow fixes the current situation?
It's just, well, really, somehow reluctant to me to write a class hierarchy with inheritance on wxWidgets when I need to create an application with three buttons and a couple of Edit'ов to count overhead, for example.

  • As far as I know, C ++ was not created to draw the form, then throw controls on it, but what turned out to be compiled. For this there is Delphi. Well, creating a form in wxWidgets takes not so much time. - Alexey Lobanov

4 answers 4

MFC is one of the first libraries for the GUI, the first version of EMNIP was released in 93, in parallel with it appeared like 2 drops of water similar to wxWidges. Both did not have graphic editors, and both are more likely to resemble a macro wrapper over the API (although OOP and MVC are there, in what form the floating ones know xA). Whether historically it was so or this is the malicious intent of the developers, you need to look at the autobiography;).

By sabzh - for wxWidgets there are several live and neochen editors, incl. plugin for code :: blocks. In MFC, besides the built-in dialog editor, I did not see it.

Shl. Libraries closer to the API can hardly be found, which is why their performance is high. There is an opinion that editors will be harmful for them.

    Why cheated? Never cheated.

    1. There is a C ++ Builder. Essentially the same Delphi, but C ++ is used as the programming language.
    2. In MSVS, you can also program "visually". But there really the form editor does not appear immediately, but you need to call it yourself. Then the code is quietly written there. Those. just slip your standard event handlers. In MFC, it makes sense to inherit from the base classes of controls only when you extend their functionality. Well, or override the behavior of the control.
    • C ++ builder, which is 96? - PaulD
    • "Visually" in MSVS, only buttons are dragged into the resource dialogs, and event handlers are created for them. The rest is handles. - Dith
    • @ pol500 "C ++ Builder 96" not only, there are new versions, for example C ++ Builder XE2 (appeared earlier this year, seemingly), Builders as well as Delphi are actively supported by Embarcadero - Alexey Lobanov
    • @ pol500, meaning C ++ Builder as an Embarcadero product, the successor to Borland / Inprise. @Dith Regarding the buttons in MSVC - I think is wrong. I did not notice any problems with elements like checkboxes, radio buttons, menus, text boxes and combo boxes. Say that you can’t do it with a half a dozen, without writing it with handles. - gecube

    Why did this happen and what were the historical prerequisites for that?

    The reasons are simple. Previously, computers were not so powerful. It is terrible to think when something like that was not a mouse, but there were no other usual things. When this interface was generally only a text and graphics editor was not needed. C # created those times when many people did not even remember when windows did not exist.

    and the advantages of such an opportunity cheated? you need to understand that the “pluses” is a wider language than just creating gui. If for c ++ programs you need gui, then you just take the appropriate library. And it can be a convenient (and this is very subjective) editor.

    In addition, think about how to standardize the graphical interface for different platforms, on the pros, because not only under Windows they write.

    Therefore, C ++ nobody infringed. Just the opposite.

    • @KoVadim, not C #, but C ++. C #, as you know, appeared after the creation of the .net platform ...> how to standardize the graphical interface for different platforms Write your cross-platform library. Like for example Qt. By the way, a successful (relatively) attempt by Borland to do something like this is called Kylix. But it's kind of like Delphi, but under Linux :-) - gecube
    • read carefully my phrase. There was meant that with # it appeared when windows was a common thing. - KoVadim
    • OK, I agree, I read diagonally, but still the phrase is crooked =) - gecube

    For Qt, there is a very convenient tool for visual interface creation: Qt Creator and Qt Disigner. Even for GTK there is a program called Glade. So, C ++ is not deprived of anything. Quite the contrary.

    Yes, and pens in Qt to write the interface is not so difficult.