so far you guys are only pointing me to libraries. are there really no tutorials / discussions on how to go about creating your own GUI system? id rather learn the basic idea on how they work and then design around that because if i ever decide to use another language for a project and need a GUI system, i can have enough knowledge to create a fairly basic one, then if i need more advanced features that i cannot create myself, then id use a GUI library. i just need an understanding of how a system would be structured, so i could add on the individual tools such as the buttons, checkboxes,sliders etc. myself.
A gui system is, depending on the degree of functionality, eigther far too complicated and broad for a tutorial, or so simplistic that anyone with the knowledge of how to display an image and check if mouse coordinates are within a given rectangle can figure it out himself. Additionally, you'll learn the basics by using any existing libary. Qt e.g. uses signal/slots and events for gui functionallity. If you've used that a while, implementing your own such system is trivial. But if you really want to design an own gui libary, why don't you just start out? Sorry to be a downer here, but if you can't get the start here yourself, you should definately not be making a gui libary, but start out by studying and using an existing one. There is no reasong for you to reinvent the wheel, let alone the "square wheel". Thrust me, unless you really badly want to learn how gui systems work internally, just are wasting your time. The time it will take you to write most elements any complete gui libary supports, you could have learnt how to use existing libaries in ten different langueges and would have ended up with something far more usefull, I'm not even kidding.
If you still want to roll your own, look for "sigal/slots", "event driven programming", "composition". Those are the tools you are going to need to design a good gui libary. Then start by adding your own basic gui elements. Start with something simple as a text label or buttons, using composition. Use signals and slots to bind functionallity to those elements. Delegate input via events. Don't care if you get it right. Just write how it works best for your current needs, just can still post code here and ask questions if you get stuck on specifiy parts. Way better to help you than just asking for a guide/tutorial on how to make a gui itself.