Author Topic: Few simple questions....  (Read 3741 times)

Offline MariuszP

  • Multiple posting newcomer
  • *
  • Posts: 29
Few simple questions....
« on: August 08, 2006, 05:53:19 pm »
Hello,
I'm begining to think about writing plugin that would allow me to create task in cb and link them with projects, files and so on. That would allow me to create some basis for group work group system that I have in mind. But first I would like to know if there is a way to be notified when user opens some file, switches visible files in tabbed nawigation or makes some project active.

Another thing is cb sdk. I'v got sdk from berlios repository, but honestly it looks completely different from sdk that I downloaded from cb website. Where should I point to includes? Maybe somebody could also point me to libs, or eventually send them to me.

Btw: Which version of wxWidgets should I use for development?

Actually article in wiki about plugin development seems to be a little bit outdated.

Offline thomas

  • Administrator
  • Lives here!
  • *****
  • Posts: 3979
Re: Few simple questions....
« Reply #1 on: August 08, 2006, 06:16:38 pm »
But first I would like to know if there is a way to be notified when (1)user opens some file, (2)switches visible files in tabbed nawigation or (3)makes some project active.
(1)cbEVT_EDITOR_OPEN
(2)cbEVT_EDITOR_ACTIVATED
(3)cbEVT_PROJECT_ACTIVATE
All found in sdk_events.h.

Quote
Another thing is cb sdk. I'v got sdk from berlios repository, but honestly it looks completely different from sdk that I downloaded from cb website. [...]
Use the folder sdk that is found in your working copy checked out with svn. Otherwise, you're building a plugin for RC2, which is quite pointless.

Quote
Btw: Which version of wxWidgets should I use for development?
2.6.3
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Offline MariuszP

  • Multiple posting newcomer
  • *
  • Posts: 29
Re: Few simple questions....
« Reply #2 on: August 08, 2006, 06:21:35 pm »
I'v used svn://svn.berlios.de/codeblocks/trunk/src/sdk to get sdk. If this is what You meant then according to what You wrote I should point include directory to root of sdk folder.

Thanx for the answers.

Offline thomas

  • Administrator
  • Lives here!
  • *****
  • Posts: 3979
Re: Few simple questions....
« Reply #3 on: August 08, 2006, 06:52:18 pm »
I'v used svn://svn.berlios.de/codeblocks/trunk/src/sdk to get sdk.
That's the right one.

Please do note that you will need compatible import libraries for codeblocks.dll and wxmsw26_custom.dll too, if you want to build a plugin.
I am not aware of any import libraries compatible with the nightly builds being available for download (but I may be wrong). If you ask Killerbot, he might put them up though.

Alternatively, you may want to check out the complete source tree, not just the sdk folder (go one directory up) and build Code::Blocks from source. It only takes like 5 minutes alltogether (if you have a working wxWidgets), so that should not be an issue.

It is also possible to make import libs from the dlls coming with the nightly builds, but that is a pain. Lastly, it is possible to use auto-import, too, but that is almost as much pain (and sometimes, it fails too).
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Offline MariuszP

  • Multiple posting newcomer
  • *
  • Posts: 29
Re: Few simple questions....
« Reply #4 on: August 10, 2006, 08:33:27 am »
Well, actually I decided to do the development under linux. I'v installed cb on Ubuntu and everything works fine. I'm using latest night build. Actually there were some issues with libpng (wrong version) during installation but cb is quite usuable. I'm not sure if i'm developing right now for rc2 or rc3 but I guess that it doesn't make much difference right now because when final version comes to life I will have to adjust project to match final version.

Anyway - I wanted to know how can I add additional tab to notebook that is located at the bottom of the cb ( I mean one that Log window is located within).

I saw some time ago cb api documentation. But I cannot find it right now. Can anybody point me to documantation to sdk.

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4291
    • Code::Blocks IDE
Re: Few simple questions....
« Reply #5 on: August 10, 2006, 08:37:14 am »
http://prdownload.berlios.de/codeblocks/codeblocks_sdk_doc_r2801.chm.
Or, you can generate it yourself with doxygen. Just feed it the src/sdk.doxy file.
Be patient!
This bug will be fixed soon...