MS Windows Programming Tips for Mac / Unix Developers

I have several years of experience working with Unix command-line tools (without GUI experience) in python, C and C ++ and have only recently moved to the GUI world (Cocoa only and IOS only). I learned quite a lot of objective-C, and I understood how cocoa MVC works. However, one of the applications I'm developing requires a version for Windows, and I was wondering what a good place to start would be given that I have absolutely no experience in developing Windows.

I was thinking about using Visual C ++ 2010 Express as my development platform (because it's free and because I don't need to learn C ++). My application is relatively simple, it will have only two windows and spends most of the time in the background. However, it will need to communicate with the OS (load dll, etc.) and the online server (HTTP methods), and I'm not sure if the version of Visual C ++ Express gives me access to the required APIs. Are Windows Forms Applications Enough? Am I really wrong? Do I need to learn C #? Any advice would be appreciated.

+7
windows programming-languages visual-c ++ winforms development-environment
source share
5 answers

If you are already satisfied with proper C ++, you will like Visual Studio C ++ express. Given that you are not creating a complex graphical interface, you do not even need to plunge into managed code. C ++ express allows you to create the right console consoles and graphical applications. You also do not need to install the SDK platform - it is part of VS C ++ express.

Unmanaged with C ++, you will be able to exchange source files between your various projects. managed C ++, despite the C ++ in the title, is actually a language that is enough to work if you have to deal with iso C ++ at the same time.

-

Note. The native windows API is C api, not C ++. Therefore, it does not provide a rich set of classes in a consistent structure for the solution. On the other hand, while, large, it is actually quite simple to work.

Also: given that you are already familiar with Mac development, there is an LGPL (iirc) package called CFLite, which is built on windows and implements the C api that underlies Cocoa's Objective-C API.

If you use your abstractions, you can share most of the code between windows and Mac (and other platforms).

Other C ++ IDEs you might consider:

  • Code :: Blocks
  • QT creator

both of them can be configured to use the MCCW GCC port for windows.

+3
source share

you will be better off with C ++ than C # if you need more “low level” things. Downloading dlls (i.e. libs) is simple (pragma comment lib ...), as well as transmitting and transmitting via HTTP.

So, VC ++ with a window shape will suffice, and that is "very C ++".

You have access to all the global APIs, and only two lines are required to download a specific apis, such as http: one to include the wininet header and the other lib (libs are actually “links” to the dll).

+2
source share

If you are on the C ++ Express path, you need to install the Windows SDK separately and configure it for use in Visual Studio. And you cannot use MFC.

However, I would suggest C # because it looks like stitching small toy bricks. Easier to debug and maintain. The problem with C # is that it has so many library functions that you cannot know what has already been done for the function. But here's why we are here :-) If you feel that something you want to do should already exist, then ask a question about it. One notable feature C # lacks is zip archives (it has something similar, but not quite). For zips, you can use public libraries like SharpZipLib or DotNetZip .

+1
source share

If I were you, I would not quickly enter a completely new API. Have you considered using Python on Windows? Most of the Python packages I've seen are also available on Windows, so you will feel right at home. And if you need a GUI, you can choose wxPython, pyGTK or something like that.

For specific Windows stuff, you can always use ctypes. Especially if they are as simple as loading a DLL.

+1
source share

Do you think you're approaching Adobe AIR? It allows you to deploy to Mac, Linux, Windows, iOS, etc. Communication with and starting your own processes became possible with 2.0, and the last 2.5 SDK can focus on Android OS and TVs. with your experience, you can instantly get ActionScript3 / MXML.

In addition, there are several free IDEs that you can use with the Flex SDK and AIR. or, if you're a student or low-income developer, you can get a free copy of Flash Builder 4 from Adobe: http://www.adobe.com/devnet-archive/flex/free/


edit: I believe that deploying AIR applications on the iPhone requires Flash Professional CS5, which includes the iPhone package. at the same time, I read that AIR and other cross-compilers for iOS are very slow, so it’s best to develop natively in Objective-C for iOS.

0
source share

All Articles