wxBook Projekt

This forum is reserved for everything you want to talk about. It could be about programming, opinions, open source programs, development in general, or just cool stuff to share!
Post Reply

Do you like the wxWidgets book?

Total votes: 14

In need of some credit
In need of some credit
Posts: 6
Joined: Wed Jan 05, 2005 8:51 pm

wxBook Projekt

Post by AllektoSoftware » Wed Aug 31, 2005 3:35 pm

Hi everyvody,

does anybody have experience with the new book about wxWidgets? I've just bought it recently and worked through the first 70 pages.

Looks pretty interesting and it seems to be a good help for a wxWidgets developer.

Somehow there are quite a few errors, like this one for example. This code within the book should demonstrate the wxNotebook:

Code: Select all

    wxNotebook *notebook = new wxNotebook(this, wxID_ANY,                          wxDefaultPosition, wxDefaultSize);
	wxImageList *imageList = new wxImageList(16,16,true, 3);
	wxPanel1 *window1 = new wxPanel(notebook, wxID_ANY);
	wxPanel2 *window2 = new wxPanel(notebook, wxID_ANY);
	wxPanel3 *window3 = new wxPanel(notebook, wxID_ANY);
	notebook->AddPage(window1, wxT("Tab One"), true,0);
	notebook->AddPage(window2, wxT("Tab two"), false,1);
	notebook->AddPage(window3, wxT("Tab three"), false,2);

First of all this code cannot be compiled because there are no wxPanel1 2 and 3. It should read like wxPanel *Panel1 ...

After correcting the code, the application compiles, but just crashes, because they try to give the tabs images, when there is no connection to an wxImageList defined.

This line is missing:

Code: Select all

That's pretty annoying, especially for newbies that i guess are wondering why the examples do not work.

I hope that there aren't many mistakes like this later on, in the more complicated examples. But anyhow i guess it's a must have for a wxWidgets developer.



Filthy Rich wx Solver
Filthy Rich wx Solver
Posts: 236
Joined: Sat Sep 04, 2004 1:49 pm
Location: Ohio, USA

Post by KevinHock » Wed Aug 31, 2005 4:15 pm

This is definitely incorrect, thanks for spotting it, an apologies. We certainly would appreciate hearing any "bugs" in the book because they can be corrected for subsequent reprints, and we can also add a note to the book page under Errata.

The example in question is on page 73.

User avatar
Earned a small fee
Earned a small fee
Posts: 19
Joined: Wed Sep 29, 2004 8:07 am
Location: Edinburgh, UK

Post by Julian » Wed Aug 31, 2005 5:02 pm

Yes indeed, apologies, and please point out any other problems so we can update the book in future reprints. I'll add corrections to the Errata section of the wxBook page at:


We did spend ages proof-reading but after a point it's hard to see the wood for the trees...


Try DialogBlocks for rapid dialog creation, and more:

Earned some good credits
Earned some good credits
Posts: 115
Joined: Tue May 31, 2005 2:17 pm

Post by Chr » Wed Aug 31, 2005 6:07 pm

okay, there is another error (error? better: something which can be correct for reprints)
On page 63 and p.64 are shown two times the same pictures (the MDI-Demo, and NOT the wxMiniframe)
wxWidgets is nice

Post Reply