Author Topic: hello world gui  (Read 14592 times)

Offline jimw54321

  • Single posting newcomer
  • *
  • Posts: 2
hello world gui
« on: May 27, 2016, 09:47:04 pm »
Hi,

I would like to learn how to create a simple GUI application. Am very overwhelmed with all the project types; no idea how to proceed.

Ultimately I would like simple window with a button to popup another window.  Another button will exit the application.  Can someone help me get started creating a trivial "hello world" gui window?

Thanks,

Jim

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: hello world gui
« Reply #1 on: May 27, 2016, 10:21:47 pm »
remember: Codeblocks is not a gui framework. Codeblocks is also no compiler or other library.... Codeblocks is just a IDE (https://en.wikipedia.org/wiki/Integrated_development_environment)

For creating windows you have to use a gui framework like wxWidgets, FLTK or QT. You have to install this framework by yourself...

I would recommend wxWidgets, because if you want to use QT it is easier if you use QT creator...

We don't know what operating system you are using but if you are using windows you will find TONS of videos on youtube how to easily install and use wxWidgets with codeblocks...
https://www.youtube.com/results?search_query=codeblocks%20wxWidgets

This type of general question is hard (and senseless)  to answer, and you will find better help if you ask specific questions, that can't be googled easily....

greetings

Offline jimw54321

  • Single posting newcomer
  • *
  • Posts: 2
Re: hello world gui
« Reply #2 on: May 28, 2016, 04:32:16 am »
Quite right, that was a poorly worded question.

I know this is not a compiler, but thought it had the templates for GUI built in.  Should be fine after I get done downloading wxWidgets.

Thanks.

Offline spectrum2me

  • Single posting newcomer
  • *
  • Posts: 8
Re: hello world gui
« Reply #3 on: June 02, 2016, 10:01:41 pm »
I was curious about this as well. Is there anything for C++ that is similar to Visual basic?
I would also like to know how to C++ a gui from scratch. I would imagine it would be thousands of lines of code?

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: hello world gui
« Reply #4 on: June 04, 2016, 12:19:53 pm »
I was curious about this as well. Is there anything for C++ that is similar to Visual basic?
There are literally 100 of GUI libraries out there for c++

just a view platform independent:
wxWidgets, QT, FLTK, GTK....
https://en.wikipedia.org/wiki/List_of_platform-independent_GUI_libraries#C_.2F_C.2B.2B_packages

It is up to you what you want to deal with...

If you want a graphical editor for designing GUIs especially with codeblocks you have to stick with wxWidgets. There you can create GUIs like with Visual Studio...
Googeling for 2 sek will give you tutorials like:
http://wiki.codeblocks.org/index.php?title=WxSmith_tutorial:_Hello_world
https://www.youtube.com/watch?v=42jJDAfFVfI
...