I'm developing a big application in Qt. There are some classes/components that do not offer the performance I need, so I want to use a native solution.
I installed Visual Studio 2010 with MFC, and I actually know the location of the library with open source.
How can I link my Qt app to MFC and use some of its classes?
Related
When creating a new project on Windows Visual Studio using C++, one of the options for a default template is the Windows Desktop Application. What libraries does this utilize?
I just started learning C++. I don't know what a DLL vs a LIB is, but I just need a name of the correct library so I can do research via YouTube into how to use it.
i have been a C# developer for a long-time now so i have huge experience with Winforms. i wanted to start VC++ development so that i can write native apps.
I know C++ very well. The problem is i have made test projects in VS2010, Win32 Application, MFC Applications and all, it doesn't provide a Visual Designer like there is for VC# Winforms and VC++ Winforms as well. i want to have a Visual designer for Native App Development like for Win32 Apps.
Is it possible?
How to do it?
There is a dialog designer for MFC. Provided you setup your project correctly, you can use the designer to layout your MFC windows. See this answer for details.
For other libraries, there are other options, as well. For example, Qt Creator allows you to visually design Qt windows via Qt Designer.
I am new to Visual Studio 2008 (.NET Framework 3.5) and am Developing a Windows Form application.
Starting the IDE, the only options for a New Project are under the categories:
Visual Basic
Visual C#
Visual C++
I did Visual C++ -> CLR -> Windows Forms Application
However, the template code is in the "Visual C++" syntx.
How do I create a new GUI project with plain vanilla C/C++ using Visual Studio 2008?
Please note, the last time I did this was with MFC in Visual Studio C++ 6.0
If I am missing the underlying principal please explain.
Thank You!
Example: http://msdn.microsoft.com/en-us/library/ms235634%28v=vs.90%29.aspx
Long story short - you cannot.
Windows Forms is a .NET framework and not a C++ framework. This in turn means that you cannot use C++ to work with it. What Microsoft did is invented their own language that is C++-ish, but compiles into CLI bytecode (likely with native code mix-in, but I am not sure). Before it was "Managed C++", now it is C++/CLI (what you have linked as an example is not C++, but C++/CLI).
For plain C++ projects you have to choose "Win32 Project", "Win32 Console Application" or "Empty Project".. But then you cannot work with Windows Forms. Your options would be to use other GUI libraries like GTK, Qt, WxWidgets. There are tons of GUI frameworks. Or perhaps you would prefer sticking with Win32 API. My personal choice is Qt. And no Visual Studio at all.
Hope it clarifies things a bit for you. Good luck!
The "Visual" is just the name of the product. It's not a different language. c++/cli however, is a different language, and that's what you're seeing. If you want to make a Windows Form application, you will have to use .net. C++/cli is a .net language, C++ is not. You can make actual C++ applications with Visual C++, just not Windows Form applications.
First, there is no such thing as "Visual C++", in terms of a language. There is C++/CLI, which is a sort of variation of C++ that has extensions for building .NET libraries and programs using a C++-like language.
Windows Forms is a technology based on the CLR: common language runtime. AKA: .NET. You cannot build a Windows Forms application with just ISO C++. At some point, you have to talk to the CLR, which is at minimum going to require some COM support. And you'd probably be better off with C++/CLI and doing it that way.
Visual in this case means Windows Programming. And that include designing GUI (Graphical User Interface) for your application which will work in Windows environment. The language itself is C++.
You have two options available to develop Window Application.
Use Window API's only
Use a frame such as MFC,WPF etc
The language is always C++ but it has accommodation for Windows and therefore Visual C++.
Btw if you want plain C/C++, choose Visual C++ and start a console application. Make sure you select empty project.
I would like to create a windows forms application in C++, but I don't want to use .NET framework.
I also don't want to code everything from scratch. I'd like to have a toolbox such as the one in Visual Studio. Could you recommend some editor/compiler for this task?
Any help would be greatly appreciated!
You might want to look up MFC or the Qt framework. both have a nice GUI editor and integrate with visual studio (MFC actually comes with visual studio)
Winforms is a strictly .NET thing so whatever you do, it won't be Winforms.
in the C++ world many frameworks to develop GUI layer exist,and if your application must be cross platform the popular choice could be wxWidgets or Qt,and I suggest you Qt.
If you are Pro Microsoft you have WTL and MFC and I suggest you WTL.
I'm learning C++, and know a little bit of Visual Basic and an Delphi.
But I want to know, is there some program like Delphi, but for C++. Something where you can drag a button to a form, double click it, the like in Delphi and VB: opens a code editor and you edit the code of the button, but with a similar code of C++?
I'm using Windows Vista.
Yes, if you use MFC within Visual Studio.
MFC is Visual Studio's C++ class library for writing Windows programs, and for an MFC form Visual Studio behaves exactly as you describe.
As of Visual Studio 2008 with an upgrade pack you can create Office 2007 style applications, and Visual Studio style applications, using MFC.
There used to be "C++ Builder", a C++ version of Delphi, I don't know if this product is still being developed or not.
UPDATE: to summarize information from the comments, C++ Builder is actively developed and the product page is http://www.embarcadero.com/products/cbuilder/
You can have the following IDEs with GUI designers for free;
Visual Studio 2008 express from Microsoft
Qt Creator from Nokia
Eclipse with Qt plugin from community :)
C++ Builder from Embarcadero
(previously CodeGear, previously
Borland)
Have fun with C++!
There are other packages besides MFC that do GUI stuff, but I don't think they plug-in to Visual Studio. I must confess, I have never been a fan of MFC. I find it ugly and painful, so I can't really recommend it.
Qt has a designer, as does GTK. I haven't used the Qt designer, but the GTK one works well. It can be found here: http://glade.gnome.org/ You can get glade for Windows here: http://gladewin32.sourceforge.net/
It can be hassle to set these up, though.
Honestly, while I like C++ a lot, writing GUIs for Windows is not where it excels. I would recommend that you look at C# instead. You can still interface with C++ if you need to, but it makes writing Windows GUIs so much nicer.