Author Topic: wxSmith  (Read 5506 times)

Offline jmccay

  • Almost regular
  • **
  • Posts: 202
wxSmith
« on: July 02, 2006, 01:18:27 am »
Under wxSmith in the CB project file, what does the <load_resource> tag do? 

   I opened a project in the June 25 (rev 2610 Unicode) nightly build of CB, and it converted the XRC file (& I chose to delete them)  I unfortunately, had the old wxTemplate xrc in the directory.  Now the project is using that file instead of my dialogs.  How do I correct this?  All the dialogs are in the file properly.

jmccay
OS: WinXP, Win98 SE, & sometimes Linux

a little light reading from the wxWidgets 2.6.2 readme: A detailed 2000-page reference manual is supplied in HTML, PDF and Windows Help form: see the docs hierarchy.

Offline byo

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 836
Re: wxSmith
« Reply #1 on: July 02, 2006, 12:30:39 pm »
Under wxSmith in the CB project file, what does the <load_resource> tag do? 

It define xrc fies which are automatically loaded when initializing application (just before creating maind window). But it works only if application code is managed by wxSmith (f.ex. it was created in wxSmith wizard). All those automatically loaded files can be edited in menu wxSmith->Configure wxSmith for current project.

Quote
   I opened a project in the June 25 (rev 2610 Unicode) nightly build of CB, and it converted the XRC file (& I chose to delete them)  I unfortunately, had the old wxTemplate xrc in the directory.  Now the project is using that file instead of my dialogs.  How do I correct this?  All the dialogs are in the file properly.

jmccay

Hmm, the only ting that has changed is that content of wxsmith/wxsmith.cfg file is not included inside .cbp file. It should not change anything inside xrc files. What do you mean by saying wxTemplate xrc ?

Offline jmccay

  • Almost regular
  • **
  • Posts: 202
Re: wxSmith
« Reply #2 on: July 04, 2006, 09:08:24 pm »
Quote
   I opened a project in the June 25 (rev 2610 Unicode) nightly build of CB, and it converted the XRC file (& I chose to delete them)  I unfortunately, had the old wxTemplate xrc in the directory.  Now the project is using that file instead of my dialogs.  How do I correct this?  All the dialogs are in the file properly.

jmccay

Hmm, the only ting that has changed is that content of wxsmith/wxsmith.cfg file is not included inside .cbp file. It should not change anything inside xrc files. What do you mean by saying wxTemplate xrc ?

   Sorry, I meant to say I left the template generated by the wxWidgets wizzard in the directory.  I upgrade from an older version of the nightly builds.  The files were generated by wxSmith, but I think my problem was that I left the old xrc file in there and it had the same class name as one of my classes.  I ended up deleting the line.  It was really wierd.  The old dialog was being loaded despite what the code had configured.  Anyways, I am now manually loading the wxs files using Load, and that works:

Code
	wxsOK = wxsOK && wxXmlResource::Get()->Load(_T("wxSmith\\mainframe.wxs"));
wxsOK = wxsOK && wxXmlResource::Get()->Load(_T("wxSmith\\editAcctdialog.wxs"));

   BTW I love wxSmith.
jmccay
OS: WinXP, Win98 SE, & sometimes Linux

a little light reading from the wxWidgets 2.6.2 readme: A detailed 2000-page reference manual is supplied in HTML, PDF and Windows Help form: see the docs hierarchy.