News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

WxSmith extensions

Started by hook24, July 20, 2010, 05:55:51 PM

Previous topic - Next topic

hook24

Hello I want to add the plugin to wxSmith kwxAngularMeter(kwxIndustrialControls) but i don't how. If someone could explain me how to do to add the plugin a wxSmith .
I want used to simulate a compass, if someone from any other supplement that I serve or something like compass  I appreciate.
I see in this page http://wiki.codeblocks.org/index.php?title=WxSmith_extensions_list that is available for code::block

MortenMacFly

Quote from: hook24 on July 20, 2010, 05:55:51 PM
Hello I want to add the plugin to wxSmith kwxAngularMeter(kwxIndustrialControls) but i don't how.
It's already done. please use the code of:

https://wxsmithaddons.svn.sourceforge.net/svnroot/wxsmithaddons/KWIC
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

hook24

Quote from: MortenMacFly on July 20, 2010, 08:22:07 PM
Quote from: hook24 on July 20, 2010, 05:55:51 PM
Hello I want to add the plugin to wxSmith kwxAngularMeter(kwxIndustrialControls) but i don't how.
It's already done. please use the code of:

https://wxsmithaddons.svn.sourceforge.net/svnroot/wxsmithaddons/KWIC

To get there, which is not to do after downloading the code, paste it where, if I have to compile something, sorry for the stupid question but I'm lost

seb_seb0

I have already a compiled version of wxSmithKWIC

Here is a link to download it:
http://rapidshare.com/files/408064371/wxSmithKWIC.zip

MD5: 2BF54F1F4FD68A5E1EFDF0076F20B39C

Installation notes are in the zip file.
I assume you are working on Windows, with codeblocks 10.05. (It works for me on Vista / Codeblocks 10.05)

Sebastien

kencamargo

Quote from: seb_seb0 on July 20, 2010, 10:26:29 PM
I have already a compiled version of wxSmithKWIC

Sebastien

Are there any linux prebuilt binaries?

(yes, I know, I'm lazy... <hangs head in shame>)

Ken

hook24

#5
Quote from: seb_seb0 on July 20, 2010, 10:26:29 PM
I have already a compiled version of wxSmithKWIC

Here is a link to download it:
http://rapidshare.com/files/408064371/wxSmithKWIC.zip

MD5: 2BF54F1F4FD68A5E1EFDF0076F20B39C

Installation notes are in the zip file.
I assume you are working on Windows, with codeblocks 10.05. (It works for me on Vista / Codeblocks 10.05)

Sebastien



In really I'm working in Linux ( Ubuntu 10.04)

Can somebody explain me how to do, how build the library?

seb_seb0

You can try to compile CodeBlocks from source:
http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks_from_source_on_Linux

Then, you can compile the plugin: download the archive from Cryogen's site:
http://wxsmithaddons.sourceforge.net/wxsmithkwic.html
(direct link to archive http://sourceforge.net/projects/wxsmithaddons/files/)

Extract the archive, go in the folder "wxSmithKWIC" and open the CodeBlocks project file wxSmithKWIC.cbp.
Then select target "all" and build.

It worked perfectly on Windows, it might be not so different on Linux. Just try !

Sebastien

hook24

Quote from: seb_seb0 on July 21, 2010, 09:42:36 PM
You can try to compile CodeBlocks from source:
http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks_from_source_on_Linux

Then, you can compile the plugin: download the archive from Cryogen's site:
http://wxsmithaddons.sourceforge.net/wxsmithkwic.html
(direct link to archive http://sourceforge.net/projects/wxsmithaddons/files/)

Extract the archive, go in the folder "wxSmithKWIC" and open the CodeBlocks project file wxSmithKWIC.cbp.


It worked perfectly on Windows, it might be not so different on Linux. Just try !

Sebastien

When I open, open winwods Global Variable Editor. then what i do??
thanks for your time

seb_seb0

you have to define 2 variables (menu "settings" / "global variables"):
   1 - where Code::Blocks sources are installed (variable "cb" : set it to the root source directory from codeblocks. This is the "src" directory. In this directory, you have the "codeblocks.cbp" project file).
   2 - where wxWidgets is installed. (variable "wx" : set it to the wxWidgets directory, where you have "build", "include", "src",...)

Do not change the variable names: it must be "cb" and "wx".

Then it should compile fine.

hook24

Quote from: seb_seb0 on July 22, 2010, 09:58:41 PM
you have to define 2 variables (menu "settings" / "global variables"):
  1 - where Code::Blocks sources are installed (variable "cb" : set it to the root source directory from codeblocks. This is the "src" directory. In this directory, you have the "codeblocks.cbp" project file).
  2 - where wxWidgets is installed. (variable "wx" : set it to the wxWidgets directory, where you have "build", "include", "src",...)

Do not change the variable names: it must be "cb" and "wx".

Then it should compile fine.

Dont work for me, Finally I use with Custom from wxsmith

Thanks

ollydbg

Quote from: seb_seb0 on July 21, 2010, 09:42:36 PM
You can try to compile CodeBlocks from source:
http://wiki.codeblocks.org/index.php?title=Installing_Code::Blocks_from_source_on_Linux

Then, you can compile the plugin: download the archive from Cryogen's site:
http://wxsmithaddons.sourceforge.net/wxsmithkwic.html
(direct link to archive http://sourceforge.net/projects/wxsmithaddons/files/)

Extract the archive, go in the folder "wxSmithKWIC" and open the CodeBlocks project file wxSmithKWIC.cbp.
Then select target "all" and build.

It worked perfectly on Windows, it might be not so different on Linux. Just try !

Sebastien

Hi, I just do the following:
Check out the SVN source from your sites:
And there are folders

├─KWIC
│  ├─KWICDemo
│  │  ├─KWIC
│  │  │  └─contrib
│  │  │      ├─include
│  │  │      │  └─wx
│  │  │      │      ├─KWIC
│  │  │      │      └─xrc
│  │  │      └─src
│  │  │          └─wx
│  │  │              ├─KWIC
│  │  │              └─xrc
│  │  ├─lib
│  │  ├─res
│  │  └─wxsmith
│  ├─kwxIndControlSource-0.3.0
│  │  ├─Debug
│  │  ├─Doc
│  │  ├─kwic_pch.h.gch
│  │  ├─Release
│  │  ├─res
│  │  └─wx_pch.h.gch
│  └─wxSmithKWIC
│      ├─doxygen
│      ├─images
│      └─KWIC
│          └─contrib
│              ├─include
│              │  └─wx
│              │      ├─KWIC
│              │      └─xrc
│              └─src
│                  └─wx
│                      ├─KWIC
│                      └─xrc
└─wxSmithDemo
    ├─media
    ├─wximages
    └─wxsmith

Now, I just copy the folder "wxSmithKWIC" to the cb_trunk\src\plugins\contrib
And build fine.

But when I try to use the new c::b to create a demo (adding some KWIC window), I get the error:

error: wx/KWIC/AngularMeter.h: No such file or directory


It looks like the generated code in my app is:

//(*Headers(xuchangLEDFrame)
#include "wx/KWIC/AngularMeter.h"
#include "wx/KWIC/AngularRegulator.h"
#include <wx/sizer.h>
#include <wx/menu.h>
#include <wx/panel.h>
#include <wx/frame.h>
#include <wx/statusbr.h>
//*)

So, where can I put those wx/KWIC header folders?

There is another issue:
The workspace file I opened in kwxIndControlSource-0.3.0 folder, I see many hard-coded file paths, I would suggest you change to standard like:

$(#wx.include)
$(#wx)\contrib\include


Third issue is:
I can successfully build the "Testdc" project, and when I drag the vertical bar, I see both the analog meter and linear meter will change, but there are a lot of flickers, any ideas how to eliminate the flickers?

Thanks.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

ollydbg

In the LinearRegulator.h
I suggest use:
int GetValue() { return m_nRealVal ; } ;
void SetValue(int val) ;


instead of GetVal and SetVal.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

Jenna

I'm working on the linux build-files.
I will do the same split for all the new items, like I have done fore the "old" wxSmithContribItems: build the libraries as standalone libraries and build the wxSmith-interface in a different project, so the libraries can be used without the need to build the whole wxSmith.

Once I am ready and have committed them you can build all te stuff from source with C::B's own build-system or with autotools.
In the second case, you will also get pkg-config files for the easier use of the libraries.

ollydbg

Quote from: jens on November 16, 2011, 06:02:29 PM
Once I am ready and have committed them you can build all te stuff from source with C::B's own build-system or with autotools.
This is really cool!! thanks.
PS: I'm currently start to working on a product which need KWIC components.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

ollydbg

Quote from: ollydbg on November 16, 2011, 02:35:00 PM
Third issue is:
I can successfully build the "Testdc" project, and when I drag the vertical bar, I see both the analog meter and linear meter will change, but there are a lot of flickers, any ideas how to eliminate the flickers?
The flicker issue can be simply solved by adding an empty erase background event handler function body.
EVT_ERASE_BACKGROUND (kwxAngularMeter::OnEraseBackground)
See Flicker-Free Drawing - WxWiki as a reference.
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.