Allegro.cc - Online Community

Allegro.cc Forums » Off-Topic Ordeals » Any good GUI lib for Windows?

Credits go to Arthur Kalliokoski, BAF, bamccaig, Karadoc ~~, ks, le_y_mistar, MiquelFire, Mokkan, Neil Walker, Simon Parzer, Thomas Harte, and yozshura for helping out!
This thread is locked; no one can reply to it. rss feed Print
 1   2 
Any good GUI lib for Windows?
FMC
Member #4,431
March 2004
avatar

I'm currently writing a simple GUI application, Windows only, and i'm in need of a proper GUI lib.
Allegro just isn't the right tool for something like this.
Win32 API makes me sick. :P
WxWidgets is too heavy for my needs (2megs hello world is ridiculous)

The problem is that out there are simply too many libs, and i don't know which one is practical.

What is has to able to do:
-create new windows
-support window resizing

I'm looking for:
-native Windows look
-easy to support resizability
-either C or C++
-possibily lightweight

I'm NOT looking for:
-portability
-GUIs that will do also do networking, threads, and make you a coffee, i need a simple GUI :P

Ideas?

[FMC Studios] - [Caries Field] - [Ctris] - [Pman] - [Chess for allegroites]
Written laws are like spiders' webs, and will, like them, only entangle and hold the poor and weak, while the rich and powerful will easily break through them. -Anacharsis
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover. -Mark Twain

Arthur Kalliokoski
Second in Command
February 2005
avatar

You've checked the stuff in the depot?
http://www.allegro.cc/resource/Libraries/GUI

They all watch too much MSNBC... they get ideas.

FMC
Member #4,431
March 2004
avatar

All of the stuff in that link is Allegro based (with the exception of WxWidgets), which i prefer to not use to avoid resolution based issues, and to be able to resize and maximize the program (which is very hard if you use Allegro). :-/

[FMC Studios] - [Caries Field] - [Ctris] - [Pman] - [Chess for allegroites]
Written laws are like spiders' webs, and will, like them, only entangle and hold the poor and weak, while the rich and powerful will easily break through them. -Anacharsis
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover. -Mark Twain

le_y_mistar
Member #8,251
January 2007
avatar

visual basic

-----------------
I'm hell of an awesome guy :)

Mokkan
Member #4,355
February 2004
avatar

Qt is nice, and you can just use GUI part of it if you want. There's also GTK...

yozshura
Member #7,420
June 2006
avatar

FLTK is quite good once you get the hang of it. It is quite difficult to compile the whole library through windows command prompt, but a bash prompt like msys makes it a lot easier(epically with compiling your programs).
http://www.fltk.org/

EDIT: just re-read your post, if it is something simple you want, this might not work for you

"Stupidity isn't punishable by death. If it was, there would be a hell of a population drop." -Anita Blake: PSN: leogorerd

ks
Member #1,086
March 2001

Simon Parzer
Member #3,330
March 2003
avatar

Quote:

Win32 API makes me sick. :P

What about MFC? Or use Windows Forms through .NET?

Neil Walker
Member #210
April 2000
avatar

As Simon, .NET is on almost every windows desktop nowadays so there is no need for a redistributable and it is so easy to produce lovely forms as it has built in anchoring/resizing, splitters, database operations, file handling, etc.

Neil.
MAME Cabinet Blog / AXL LIBRARY (a games framework) / AXL Documentation and Tutorial

wii:0356-1384-6687-2022, kart:3308-4806-6002. XBOX:chucklepie

bamccaig
Member #7,536
July 2006
avatar

I agree... Unless you have a good reason not to, I would go with .NET... :-/ And C# might be a better language to use over C/C++, depending on why you've chosen C/C++ in the first place.

BAF
Member #2,981
December 2002
avatar

FMC
Member #4,431
March 2004
avatar

I'm looking at the suggested libraries. :)

Visual Basic and C# (.net uses C#, right?) might be viable options, but:
a)i don't know how to program in either of them :P
b)i need to do some low level (read single bytes) IO from files and i don't know if those 2 languages offer instruments to do so.

Comments?

[FMC Studios] - [Caries Field] - [Ctris] - [Pman] - [Chess for allegroites]
Written laws are like spiders' webs, and will, like them, only entangle and hold the poor and weak, while the rich and powerful will easily break through them. -Anacharsis
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover. -Mark Twain

MiquelFire
Member #3,110
January 2003
avatar

I think C# does offer that. And programming in C# is not that hard to learn actually since you know C/C++. It's the switch to pure OO that may trip you up.

---
Febreze (and other air fresheners actually) is just below perfumes/colognes, and that's just below dead skunks in terms of smells that offend my nose.
MiquelFire.red
If anyone is of the opinion that there is no systemic racism in America, they're either blind, stupid, or racist too. ~Edgar Reynaldo

Karadoc ~~
Member #2,749
September 2002
avatar

I've heard that Qt is pretty good, but I don't know from experience.

-----------

Thomas Harte
Member #33
April 2000
avatar

Surely .NET isn't a complete answer? Are you not then required to pick between Windows Forms and WPF?

If I have understood what's going on then I'd say WPF is likely to look a lot better. It seems to finally do away with Microsoft's trademark font nastiness.

bamccaig
Member #7,536
July 2006
avatar

I recommend C#/.NET over VB/.NET, especially if you like C/C++ since C# is a C-like language. C# allows you to do lower-level stuff (I don't know if reading bytes is really considered low-level, however), but it forces you to acknowledge what it calls unsafe code. You probably won't need unsafe code for what you're doing though. Reading bytes from files is possible with standard file IO, IIRC.

For example, Reading binary data in C# (I don't know if this is the best way to do it though).

Neil Walker
Member #210
April 2000
avatar

Quote:

Visual Basic and C# (.net uses C#, right?) might be viable options, but:
a)i don't know how to program in either of them :P
b)i need to do some low level (read single bytes) IO from files and i don't know if those 2 languages offer instruments to do so.

1. If you know java, .net, php, etc. you know c#, however it isn't the language you need to learn, more the api. But if you get stuck, google usually finds the code you want.

2. yes, they have byte readers

Also, visual studio does the job of almost all your gui coding, so you only need to code your backend stuff.

Neil.
MAME Cabinet Blog / AXL LIBRARY (a games framework) / AXL Documentation and Tutorial

wii:0356-1384-6687-2022, kart:3308-4806-6002. XBOX:chucklepie

FMC
Member #4,431
March 2004
avatar

OK, I'm convinced! :)
I just downloaded visual studio express.
It's a little confusing but i guess tinkering with it for some time will help.

Besides i know Java and C\C++ so the language itself shouldn't be much of a problem.

Cookies!

[FMC Studios] - [Caries Field] - [Ctris] - [Pman] - [Chess for allegroites]
Written laws are like spiders' webs, and will, like them, only entangle and hold the poor and weak, while the rich and powerful will easily break through them. -Anacharsis
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover. -Mark Twain

BAF
Member #2,981
December 2002
avatar

C# uses .NET, yes. .NET isn't too bad to use once you get going, I taught myself C# and .NET without prior knowledge of either just by fiddling around in Visual C#. Once you get used to the naming conventions of .NET a little, you can just about guess what anything is named and how to use it, intellisense helps a lot in that aspect too.

Reading bytes isn't really low level, as others have said, that's fully possible in C#.

And as far as making your GUI, basically you design it and plugin the event code, all the low end GUI crap is done by VS.

Cody Harris
Member #4,406
March 2004
avatar

I like Qt, but I haven't used it for win32 apps, only Linux and OSX apps.

---------------------------------
Homepage - Art (Photography)
I'm QBasicer on #allegro on Freenode.

Neil Walker
Member #210
April 2000
avatar

If your tinkering with it now, just try and remember that almost everything you want to do with the gui will be configurable in the properties rather than requiring code, such as auto-resizing controls to fit the window, setting up splitter windows, etc.

Neil.
MAME Cabinet Blog / AXL LIBRARY (a games framework) / AXL Documentation and Tutorial

wii:0356-1384-6687-2022, kart:3308-4806-6002. XBOX:chucklepie

FMC
Member #4,431
March 2004
avatar

Reading single bytes isn't really low level, but some high level language doesn't let you do this directly.
Furthermore i'll need to do some flag stuff on the byte and again some high level languages would make it harder. :)

Anyway Visual C# is actually pretty nice, and after playing with it i can only recommend it for any kind of Windows GUI development, it's a real time saver.

[FMC Studios] - [Caries Field] - [Ctris] - [Pman] - [Chess for allegroites]
Written laws are like spiders' webs, and will, like them, only entangle and hold the poor and weak, while the rich and powerful will easily break through them. -Anacharsis
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore. Dream. Discover. -Mark Twain

axilmar
Member #1,204
April 2001

I used to like Qt, but the restriction of signals/slots not being templates has started getting on my nerves. You can't connect anything else with Qt signals, and you can't use Boost with it because Qt has a "#define signals protected", and Boost has a namespace "signals".

The fact is there isn't a simple GUI library for C++ that:

a) offers GUI only and nothing else.

b) does not rely on preprocessing; Qt requires the MOC and wxWidgets requires writing macros for message maps.

c) follows C++ established principles, like using boost::shared_ptr or boost::bind.

d) has a simple interface; MFC is a mess, and also has message maps.

Thomas Fjellstrom
Member #476
June 2000
avatar

Quote:

I used to like Qt, but the restriction of signals/slots not being templates has started getting on my nerves. You can't connect anything else with Qt signals, and you can't use Boost with it because Qt has a "#define signals protected", and Boost has a namespace "signals".

You can turn that off and use QT_SIGNALS or something similar instead ::)

--
Thomas Fjellstrom - [website] - [email] - [Allegro Wiki] - [Allegro TODO]
"If you can't think of a better solution, don't try to make a better solution." -- weapon_S
"The less evidence we have for what we believe is certain, the more violently we defend beliefs against those who don't agree" -- https://twitter.com/neiltyson/status/592870205409353730

axilmar
Member #1,204
April 2001

I don't think I can do that in version 3.0.5 (commercial, used for commercial purposes); it's in a later version.

 1   2 


Go to: