Recommendations for a GUI Library?

Whether you're a newbie or an experienced programmer, any questions, help, or just talk of any language will be welcomed here.

Moderator: Coders of Rage

Post Reply
XianForce
Chaos Rift Devotee
Chaos Rift Devotee
Posts: 767
Joined: Wed Oct 29, 2008 8:36 pm

Recommendations for a GUI Library?

Post by XianForce »

Hey guys, I've been wanting to try to make a level editor for some time now, I made a real simple one, but I wanna make one that looks nice and such, so can any of you recommend a GUI Library? I don't care much about cross platform support, I use Windows, though, so it needs to work with windows. Also I'd prefer It be a C/C++ Library, but that's not completely necessary.

Thanks guys =p
User avatar
Pickzell
Chaos Rift Junior
Chaos Rift Junior
Posts: 233
Joined: Sat May 16, 2009 10:21 am

Re: Recommendations for a GUI Library?

Post by Pickzell »

Why not just make your own? Plus if making a GUI in C/++ is to hard for you then you can make it in a game specific language.
I'm an altogether bad-natured Cupid.
gordon
Chaos Rift Cool Newbie
Chaos Rift Cool Newbie
Posts: 60
Joined: Mon May 04, 2009 2:38 pm

Re: Recommendations for a GUI Library?

Post by gordon »

I've heard good things about wxwidgets
User avatar
dani93
Chaos Rift Newbie
Chaos Rift Newbie
Posts: 38
Joined: Mon Apr 13, 2009 9:38 am
Location: Austria

Re: Recommendations for a GUI Library?

Post by dani93 »

I'm trying Qt at the moment. It is pretty easy to creaty a GUI with it.

Example code to create a button:

Code: Select all

// include Qt-files
#include <QApplication>             
#include <QPushButton>
 
int main (int argc, char *argv[])
{
 
  // pass arguments to Qt
  QApplication app (argc, argv);    
  // create a new button with the text "button text"
  QPushButton *button = new QPushButton ("button text");  
 
  // connect a slot to a signal ("set a callback" in other libraries like GTK+)
  // if the button is clicked, the application quits
  QObject::connect (button, SIGNAL (clicked ()), &app, SLOT(quit ())); 
 
  // show the button
  button -> show ();

  // run the application
  return app.exec ();
 
}
In my opinion it is much easier than GTK+, cause you can use C++-constructors and methods. And if you don't like it, you can use "Qt-Creator" to create GUIs graphically and then use them in your application.
I started learning Qt because I want a GUI (menubar etc.) around a SDL application. But it looks like it only works with OpenGL...

Link:
http://qt.nokia.com/
XianForce
Chaos Rift Devotee
Chaos Rift Devotee
Posts: 767
Joined: Wed Oct 29, 2008 8:36 pm

Re: Recommendations for a GUI Library?

Post by XianForce »

Pickzell wrote:Why not just make your own? Plus if making a GUI in C/++ is to hard for you then you can make it in a game specific language.

Erm, it has nothing to do with it being hard... its just a waste of my time.

If there's already a good GUI library, why make my own?

That just distracts from the real goal of making a level editor -.-
User avatar
M_D_K
Chaos Rift Demigod
Chaos Rift Demigod
Posts: 1087
Joined: Tue Oct 28, 2008 10:33 am
Favorite Gaming Platforms: PC
Programming Language of Choice: C/++
Location: UK

Re: Recommendations for a GUI Library?

Post by M_D_K »

wxWidgets is very good :)
Pickzell wrote:Why not just make your own? Plus if making a GUI in C/++ is to hard for you then you can make it in a game specific language.
There really is no point in rolling your own, as avansc would say "work smarter, not harder".
Gyro Sheen wrote:you pour their inventory onto my life
IRC wrote: <sparda> The routine had a stack overflow, sorry.
<sparda> Apparently the stack was full of shit.
User avatar
Netwatcher
Chaos Rift Junior
Chaos Rift Junior
Posts: 378
Joined: Sun Jun 07, 2009 2:49 am
Current Project: The Awesome Game (Actual title)
Favorite Gaming Platforms: Cabbage, Ground beef
Programming Language of Choice: C++
Location: Rehovot, Israel

Re: Recommendations for a GUI Library?

Post by Netwatcher »

I'd give it to wxWidgets, my personal choice with it would be Python but you can use it with C++ too.

wxWidgets home
Pickel wrote:Why not just make your own? Plus if making a GUI in C/++ is to hard for you then you can make it in a game specific language.
He's trying to write a level editor not to reinvent the wheel :shock:

(EDIT: lol, noticed it's a reference to "Rolling your own"... did I just made a pun?)
"Programmers are the Gods of their tiny worlds. They create something out of nothing. In their command-line universe, they say when it’s sunny and when it rains. And the tiny universe complies."
-Derek Powazek, http://powazek.com/posts/1655

blip.fm DJ profile - http://blip.fm/Noobay
current code project http://sourceforge.net/projects/vulcanengine/
Post Reply