i have a compiler project and i have used c++ , flex and bison in it so bison and flex produce .cpp files to me and i can compile and run them but i want to make a gui to my project so i want to learn a technique to make a gui (in java or qt) to write input to my project and get output
Your question isn't very clear...
QT is, among other things, a GUI toolkit for C++. There is a very useful set of tutorials to get you started.
There are ways to call executables from within an application (should it be a GUI or a CLI). But your approach is likely to be difficult to put into place and even more to maintain. This is even truer if you want your GUI to be portable.
There seems to be a bit of a language barrier, so let me attempt to state what I think I understand before providing my answer.
It appears that you're in a Compilers class, and your project is to write a C++ compiler. You've chosen to program this project using C++
, with the help of bison
and flex
. Now that your project is effectively complete, you'd like to add a GUI to it (I guess in some way making steps towards it becoming an IDE).
Writing a GUI in C++ isn't as easy as I'd like for it to be. From friends that have had to do the same thing in their compilers and graphics classes, I hear that this book is a good start for using Qt
to make GUI programs in C++
. With regard to programming the GUI in Java, you'll probably be using the swing
library; and I always just read the javadocs (linked). But again, I haven't done that since University.
Hope that helps some! Good luck!
One hurdle to watch out for is that many GUIs are platform dependent, so they are specific to one platform. There are some, such as wxWidgets and QT, which work on multiple platforms. You'll need to have a GUI that will work on the class computer and your own.