views:

904

answers:

6

Hello all i like to write GUI software ( i have no experience in GUI programming ) i need it to be small as possible and fast GUI and native Look and Feel in one self contained exe . only on windows from windows 2000 to windows 7 ( or what ever it called ) . what will be the best choice ? win32 api or wxWidgets?

+2  A: 

Win32, you won't need wxWidgets in your distribution package(it will be small). It's harder, but I think it's better..

Svetlozar Angelov
+2  A: 

use wxwidgets. Its simpler as compared to win32 api.. also have a look on QT it is easier and richer.

Umair Ahmed
Good as Qt is, it won't fulfill the OP's criteria of "small", as it must include a pile of Qt DLLs or an enormous statically linked library.
Paul Dixon
agreed i missed the "small" point.
Umair Ahmed
A: 

With Windows 7, much of the GUI API is not directly available to Win32 applications. Instead, you need WPF (Windows Presentation Foundation) to access some of the new GUI elements, which means you would have to write the application in C#.

Of course, if you target anything from Windows 2000, then WPF is out of question.

Martin v. Löwis
Is there example of Windows 7 features not available through WinAPI? I beleive that from WinAPI you have access to any Windows feature.
Kirill V. Lyadvinsky
simple win32 api gui application will not work on windows 7 ?
It will certainly work on Windows 7. However, some of the advanced GUI features are not easily available to Win32 application (in particular all the WPF controls that build on DirectX).
Martin v. Löwis
+1  A: 

If you have a non-free version of Visual Studio available, probably your best choice is to use MFC (Microsoft Foundation Classes). This is essentially using the Windows API, but in more of a C++ way.

Matthew Talbert
i have the free version of visual studio
MFC is horrid. It uses hacks everywhere because it was written before the Microsoft C++ compiler had exception support.
Ben Voigt
+1  A: 

You should take a look at the Windows Template Library (WTL).

Rob
from what i read it based on atl and i have the free vc version so it not going to work
+2  A: 

I had to make a similar choice about two years ago. I chose Win32 API. There is a certain pride in mastering the old school way of doing things.

Btw, the Windows API has a reputation of being dirty and badly designed. I disagree with this. I find it extremely flexible yet consistent (for about 90% since backwards compatibility patches do pollute it a bit).

StackedCrooked
The API is anything but consistent. For example for returning a string there are various different ways used to return the length of the string on success or the necessary buffer size on failure. It looks like every developer group had their own preferred way of doing this, and they were all allowed to have their way.
mghie