Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Sephnroth Win32 API tutorial

Author
Message
AtomR
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Portugal
Posted: 17th Feb 2010 13:02
Hi,
I was searching the forums for how to use the windows api within DarkGDK and found a post where Sephnroth posts a tutorial about it. From the coments it seems to be very good but when following the links the webpage no longer exists. Is there anyone here that has the tutorial that could send me or post here.

Here is the thread I found
http://forum.thegamecreators.com/?m=forum_view&t=54893&b=22

If not can u direct me to any good tutorial to integrate windows, buttons, lists, checkboxes etc in DarkGDK as the search didn't help much in that regard. I did find Jason P Sage OOP GUI but to be honest I can't wrap my head around it XD

Thanks

Take care
AtomR
Mireben
16
Years of Service
User Offline
Joined: 5th Aug 2008
Location:
Posted: 17th Feb 2010 13:37
You can download the tutorial from here:

http://forumfiles.thegamecreators.com/?i=1519001

I found the link in this thread:

http://forum.thegamecreators.com/?m=forum_view&t=137633&b=22

I am at present writing a program with Dark GDK plus Windows API interface. In fact, apart from integrating a menu on top of the Dark GDK window (which the above tutorial should tell you how to do), the rest is pretty standard Windows API stuff, so I ended up browsing the MSDN site a lot for API reference. There is also another Windows API tutorial here for starters, if you are interested, but this is general, not GDK:

http://www.winprog.org/tutorial/

Mista Wilson has also managed to put a Dark GDK window into an MDI application:

http://forum.thegamecreators.com/?m=forum_view&t=152825&b=22

I hope that helps.
AtomR
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Portugal
Posted: 17th Feb 2010 14:24 Edited at: 17th Feb 2010 18:05
Thank you so much. I will take a look at this later today but i'm pretty sure it will be very helpful.

[edit]
I was following the tutorial and I can't add a resource file. I have VC++ 2008 express edition but never really realized what this meant. It seems that you can't add resource files in express editions. Does that mean I can't use winapi?

Take care
AtomR
entomophobiac
21
Years of Service
User Offline
Joined: 1st Nov 2002
Location: United States
Posted: 17th Feb 2010 15:14
To be perfectly honest, I'd suggest a .NET solution rather than running headlong into the WIN_API, which is an insanely bloated stack of libraries and a pain to work with.

Fire up a C# Express edition and fiddle around with the forms functionality right after you've gone through the tutorials for the WIN_API and you'll see exactly what I mean.

If there's a need to integrate the GDK into the tool you're making, you're always better off going for the .NET version. It's not prohibitively costly and the worth of what little money you must put down is minute compared to the pains you'll be saving yourself from.
Mireben
16
Years of Service
User Offline
Joined: 5th Aug 2008
Location:
Posted: 17th Feb 2010 20:03 Edited at: 17th Feb 2010 20:05
You can add a resource file but you need to write it by hand. I just added a file called resource.rc to the project (and a resource.h which contains the constants) and if you write it in the correct format, it will compile. You will need to edit the .rc file with Notepad though, because if you try to open it in the project, Visual Studio will complain.

Of course it is a lot more work than doing it with a visual form builder, because you need to calculate the coordinates of the window elements, but it can be done if you are patient. I don't like .NET so I'm willing to go along with this inconvenience.
AtomR
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Portugal
Posted: 18th Feb 2010 00:52
Thank you for the replies. Doing it without a visual form builder is no problem because that is exactly how i was doing it on DBPro with David Sage's twilight gui plugin. I just need something to substitute that plugin so I can port my project to DarkGDK.
But if i can get VC++ professional edition will it come with a form builder or is that only available in C#. Because I can get Visual Studio 2008 Professional Edition through MSDN Academic Aliance. I downloaded the express edition because it was 700mb and i thought it would cover everything but if a form builder comes in professional i will gladly download the 3gb XD

Take care
AtomR
Mireben
16
Years of Service
User Offline
Joined: 5th Aug 2008
Location:
Posted: 18th Feb 2010 11:06
I haven't used the professional edition but it should have an editor because the product page mentions "integrated drag-and-drop designer" and the Forger tutorial also mentions the "VC++ resource editor". But it's better if someone who knows the product confirms this. I posted only because I forgot to mention one thing yesterday: you can also find external visual resource editors on the internet which may be an alternative.
Amnzero
15
Years of Service
User Offline
Joined: 1st Aug 2009
Location:
Posted: 18th Feb 2010 11:37
VC++ Express now comes with a visual forms designer for .NET/CLR projects only, and to some extent dialogs. The same is true for VS 2008 Pro. The only difference between the two versions of VS is that The express version will only support C++. The Pro Version supports C#, VB.NET, Web Deveopment, and a miriad of other options, bells, and wistles.

[url="http://neovance.com/"][/url]

Login to post a reply

Server time is: 2024-10-02 01:41:44
Your offset time is: 2024-10-02 01:41:44