Page 1 of 1

hi! I'm new here! pls help

Posted: Tue May 23, 2017 7:03 pm
by yiyoascen
Hi everyone, I have been studying C++ for this semester at college (somehow my teacher thinks it's a good idea to force all of his students into wxWidgets without explaining it himself), so I need to build a calculator using wxWidgets, but I can't understand the documentation at all and don't know really where to start...

I've already downloaded it and codeblocks just for this class, and I find C++ really confusing for my second semester, and the teacher is really into NOT explaining things that he considers basic. Where can I start to understand this framework for someone who understands more about python, html and css with js

Re: hi! I'm new here! pls help

Posted: Tue May 23, 2017 7:39 pm
by coderrc
read this
download that,

create your GUI
let it generate the C++

eta: when you have a specific question, the people here are super helpful. But for nebulous questions like "how do I shot code?" will probably not get you very far.

Re: hi! I'm new here! pls help

Posted: Tue May 23, 2017 7:59 pm
by DavidHart

I hate to disagree with another poster, but:
The wx book at was published in 2005. While many parts of it still apply, it's not the best place for a new user to start.

DialogBlocks, though fine in itself, is equivalent to the CodeBlocks that you already have. You certainly don't need both.

My advice is different. First, download the wxWidgets source-code if you haven't already (you may have downloaded only a binary package). Then look at the samples in its samples/ directory; in particular start with 'minimal'. That's a very simple sample, but it shows the basics of all wx programs. It's also fairly well commented. Examine the source-code, then build and run it.

Next, you need to understand sizers, the wx layout mechanism. See this tutorial first, then the sizer overview. That mentions wxGridSizer, which you may use as the basis for the numerical bit of the display.

All that should at least get you started ;) .



Re: hi! I'm new here! pls help

Posted: Tue May 23, 2017 8:23 pm
by doublemax
Learning wxWidgets without knowing C++ first will be challenging.

In addition to what the others said, i'd like to recommend this tutorial:

Parallel to this, study the "minimal" sample, like David said. It's important to have at least a basic understanding of the "anatomy" of a wxWidgets application.

Unlike the others, i would not recommend to start with a GUI editor. I think it's preferable to learn how a GUI is built with code before you learn to use a GUI editor. As you're familiar with HTML, CSS and JS, you probably build your GUI more or less "by hand", too.

And if you know how table-based layouts were built in HTML1, wxSizers work very similar.

Re: hi! I'm new here! pls help

Posted: Tue May 23, 2017 8:26 pm
You said that this is you second semester studying C++. So you should already have some exposure to the language.
Just do whatever David told you - get the sources and try to understand the minimal sample, then sizers. For the sizers there is a layout sample. So after going thru the tutorial check the sample by running it and check the code for it.

Good luck!

Re: hi! I'm new here! pls help

Posted: Wed May 24, 2017 12:34 pm
by MagickPanda
imo visual basic or plain visual C++ is more friendly than wxwidgets for a beginner's calculater application. :lol:

Re: hi! I'm new here! pls help

Posted: Fri May 26, 2017 10:57 am
by nandakishore
No Problem please go through the following tutorial learn about classes , objects and inheritance. ... bjects.htm
that is enough to start with wxWidgets.

Then open samples of wxWidgets in visual studio run the project called "minimal" by making it as "set as current project".
and obeserve the output.
Now start debugging by F10 analyse each and every line how it is making output.
Thats it.

Once you know how to debug patiently you will understand everything in this programming world.