I would like to create my own GUI toolkit. So without using GTK, wx, SDL or anything else. What are the steps? Do I need to use X libraries? If so, can you point me to a good X guide?
Thanks in advance...
I would like to create my own GUI toolkit. So without using GTK, wx, SDL or anything else. What are the steps? Do I need to use X libraries? If so, can you point me to a good X guide?
Thanks in advance...
Why do you want to do this? It's a *lot* of work. Yes, you could probably just use the X API directly, but it's very complicated. The little experience I have with X indicates to me that it always tries to do things in the most generic way possible, which is great for the low-level graphics toolkit it is supposed to be, but very difficult to actually write simple end-user code for.
I'd actually suggest using the SDL. wxWidgets and GTK+ are actual GUI toolkits and if you want to create your own, this would probably get in your way. But the SDL is very low-level: you basically get the ability to set pixels, blit bitmaps, detect mouse and keyboard input, and not much else. I actually wrote my own GUI toolkit in the SDL at one point (it's called xuni, see my signature or go straight to xuni), so it certainly can be done. It was a lot of fun, too.
The SDL is cross-platform and fairly low overhead, plus it's popular on Linux systems. If you want to use it this tutorial is a great place to start: Lazy Foo' Productions
dwk
Seek and ye shall find. quaere et invenies.
"Simplicity does not precede complexity, but follows it." -- Alan Perlis
"Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
"The only real mistake is the one from which we learn nothing." -- John Powell
Other boards: DaniWeb, TPS
Unofficial Wiki FAQ: cpwiki.sf.net
My website: http://dwks.theprogrammingsite.com/
Projects: codeform, xuni, atlantis, nort, etc.
I know, it is hard to find material on this. Check this out