Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Plugins development => Topic started by: Xaviou on October 21, 2013, 04:23:40 pm

Title: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: Xaviou on October 21, 2013, 04:23:40 pm
Hi.

Here is a quick patch to allow the creation of projects using wxWidgets-3.0.x

If one can test.
I think there are thing to improve (for example, libs "wxDbGrid", "wxOdbc", are no more available with wx-3.0), but it is working yet.

Regards
Xav'
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: Xaviou on October 21, 2013, 08:26:04 pm
And for those who want to test it, attached is a modified version of the script file.

You must place this file in the following :
<CodeBlocks_Install_Dir>\share\CodeBlocks\templates\wizard\wxwidgets\

Regards

Xav'
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: ollydbg on October 22, 2013, 03:58:05 am
Hi, Xaviou.
Some off topic, I see your site: http://mywxstuff.olympe.in/?/libs/wx300.html offer some pre-build libraries for various compilers and wx versions, that is helpful to wx beginners or some one who is lazy to build wx libraries.  :)

I suggest you should state which compiler version is used, I mean: for TDM-GCC 4.7.1 or TDM-GCC 4.8.1, do you mean the 32bit, sjlj version?

Thanks.
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: Xaviou on October 22, 2013, 10:03:13 am
Hi.

Same on me  :-[ but I have to say that I don't really know because I've never specified something like this while compiling.
I always use the default parameters do build my libs (so, I gather that sjlj is used for both 32 and 64 bits).

But you're right : this must be precised as I will soon provide official binaries of the next 3.0.0-rc2 release (https://groups.google.com/d/msg/wx-dev/Fqm95EiPr-I/9ezEoDRq_x4J) (and surely for the final 3.0.0 version).
I think I should also precise that this is the default behaviour, for people who doesn't care of this (like me).
And I think I should also precise that the 32 bits binaries are for the 32 bits version of the compiler (and not for the 64 bits version despite the fact it is able to compile 32 bits applications).

Thank-you for pointing this : I'll update the page as soon as possible.

Regards

Xav'
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: stahta01 on November 13, 2013, 03:25:43 pm
Hi.

Same on me  :-[ but I have to say that I don't really know because I've never specified something like this while compiling.
I always use the default parameters do build my libs (so, I gather that sjlj is used for both 32 and 64 bits).

The SJLJ is based on the Compiler Used.

IIRC, The standard MinGW GCC using Dwarf2.
The normal TDM  MinGW GCC uses SJLJ.

If I do the below command in the Compiler bin folder.
Code
gcc -v

Two of the many things I get is this
Code
--enable-sjlj-exceptions
Code
gcc version 4.8.1 (tdm-1)

Tim S.
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: Andriy on November 30, 2013, 01:04:38 am
Thank you, Xaviou! Code::Blocks + wxWidgets 3.0.0 is what I needed.
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: bongbang on December 24, 2013, 10:57:31 pm
Is this supposed to add a wxWidgets-3.0.x option in the wizard? If so, it isn't working for me after putting the patch in the specified folder.
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: oBFusCATed on December 28, 2013, 04:01:35 pm
C::B 13.12 should have this already...
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: stahta01 on January 19, 2014, 08:16:31 am
I have been testing the Scripted Wizard when CB is built with wxWidgets 3.0 and found an issue.

This patch fixes the Intro display screen (for CB Plugin Wizard) from being cut-off to soon.
I have tested with wxWidgets 3.0 32 bit only on Windows.

I have only tested the CB Plugin Wizard; too tired to test the others tonight.
 

Code
Index: src/plugins/scriptedwizard/infopanel.cpp
===================================================================
--- src/plugins/scriptedwizard/infopanel.cpp (revision 9575)
+++ src/plugins/scriptedwizard/infopanel.cpp (working copy)
@@ -27,7 +27,7 @@
  //(*Initialize(InfoPanel)
  Create(parent, id, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("id"));
  BoxSizer1 = new wxBoxSizer(wxVERTICAL);
- lblIntro = new wxStaticText(this, ID_STATICTEXT1, _("Welcome to the new console application wizard!\n\n\n\n\n\n\n\n\n\n\n\n\n\n"), wxDefaultPosition, wxDefaultSize, wxST_NO_AUTORESIZE, _T("ID_STATICTEXT1"));
+ lblIntro = new wxStaticText(this, ID_STATICTEXT1, _("Welcome to the new console application wizard!\n\n\n\n\n\n\n\n\n\n\n\n\n\n"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT1"));
  BoxSizer1->Add(lblIntro, 1, wxALL|wxEXPAND|wxALIGN_LEFT|wxALIGN_TOP, 8);
  chkSkip = new wxCheckBox(this, ID_CHECKBOX1, _("Skip this page next time"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX1"));
  chkSkip->SetValue(false);
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: MortenMacFly on January 19, 2014, 07:39:48 pm
This patch fixes the Intro display screen (for CB Plugin Wizard) from being cut-off to soon.
You patched a wxSmith code portion. This is no good, or should at least also include the actual change to be done in the wxs file... :)
Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: stahta01 on January 19, 2014, 08:36:15 pm
This patch fixes the Intro display screen (for CB Plugin Wizard) from being cut-off to soon.
You patched a wxSmith code portion. This is no good, or should at least also include the actual change to be done in the wxs file... :)

OK, will try to figure out wxSmith well enough to find out where to do the changes; or split the code off.
It depends on the reason this method "SetIntroText" exists in the class "InfoPanel".
It might is easier to redo/restructure the class to fix it instead of just changing the constant to zero.

As it is the method "SetIntroText" fails wxWidgets 3.0 looks like they fixed a 2.8 bug that causes it to fail.

Will likely be a few weeks for me to learn enough wxWidgets/wxSmith to find the correct place to fix it.

Just wish to verify "//(*Initialize(InfoPanel)" this comment is what says its a wxSmith issue, correct?

Tim S.

Title: Re: Updating Scripted Wizard for wxWidgets-3.0.0
Post by: stahta01 on January 19, 2014, 09:10:25 pm
I have gotten the wxSmith file added to the CB Project.
Now, I have to figure out how to edit it.

@MortenMacFly: Can you verify this is the right way to add the file and its the right file to add?
Looks like, I did NOT need to add the .wxs file like the debug ones were. I just needed to find the correct wxSmith GUI to do the changes.

Tim S.

Figured out how to do the changes from http://wiki.codeblocks.org/index.php?title=Wxsmith_tutorial:_Working_with_items#wxPanel (http://wiki.codeblocks.org/index.php?title=Wxsmith_tutorial:_Working_with_items#wxPanel)


Code
Index: src/wxsmith/InfoPanel.wxs
===================================================================
--- src/wxsmith/InfoPanel.wxs (revision 9582)
+++ src/wxsmith/InfoPanel.wxs (working copy)
@@ -6,7 +6,6 @@
  <object class="sizeritem">
  <object class="wxStaticText" name="ID_STATICTEXT1" variable="lblIntro" member="yes">
  <label>Welcome to the new console application wizard!&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;&#x0A;</label>
- <style>wxST_NO_AUTORESIZE</style>
  </object>
  <flag>wxALL|wxEXPAND|wxALIGN_LEFT|wxALIGN_TOP</flag>
  <border>8</border>




Tim S.