Sign in to follow this  
guest42

A very specific widget library

Recommended Posts

Hey everyone. I made a little game in Java, complete with editors. Now I want to rewrite and improve the engine with C and OpenGL. I've done a lot of it, but I want to start building the editors and I need widgets: text boxes, buttons, etc. It has to follow a couple specifications. It needs to be in C, work cross platform (I am working on a Mac, my friend who may help me is working in Windows), and must be based off OpenGL or a common OpenGL toolkit (GLUT, SDL, etc). I thought it would be easy enough to find a library, but it seems like most of them are in C++, which is frustrating because I've managed to do the entire thing in C so far. I did find something called Open Tool Kit, which looks like what I need, but it doesn't compile in Mac because Mac doesn't have the glx.h header. So I'm looking for a solution. And I'd appreciate avoiding the obvious "Stop working with Mac" or "Use C++" unless there really is no other way. Thanks for your time and consideration.

Share this post


Link to post
Share on other sites
Quote:
Original post by guest42
It has to follow a couple specifications. It needs to be in C, work cross platform (I am working on a Mac, my friend who may help me is working in Windows), and must be based off OpenGL or a common OpenGL toolkit (GLUT, SDL, etc).

You'll have a very hard time finding something like this. All halfway modern GUI toolkits are designed for OO languages, and rightfully so. The only C ones that come to mind are Gtk and Agar. The former is well known, but it will make you want to shoot yourself after a couple of days working with it, and the latter is something really obscure that turned up on a Google search. It's also an exceptionally bad looking UI...

Quote:
Original post by guest42
So I'm looking for a solution. And I'd appreciate avoiding the obvious "Stop working with Mac" or "Use C++" unless there really is no other way.

I won't say "use C++". However I will say "don't use C". C is probably the worst choice you could've made for something like this. Why do you want to stay with it so badly ? There are lots of very good multiplatform UI toolkits available for languages that aren't completely obsolete. In my opinion, you should definitely rethink your choice of language.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this