Embedded Components Tutorial - Page 7
To recap, the four stages are:
- Convert your application to a shared library
This requires only a change to the Makefile.am file
- Add the skeleton KParts code
This requires two files to be added to the project, and two minor changes to the Makefile.am and your application's .desktop file
- Add in your own code
This is probably the hardest step.. where you integrate your existing code into the KParts interface.
- Connect GUI elements to control your code
This is where you insert items into the toolbar and edit menu to allow the user to control your component.
In general, you can copy over the files and just change all references to 'aktion' and 'Aktion' to your own app naming convention.
The only thing that is totally app specific is in the AktionPart class. Wherever you see references to the widget object, that's where you need to insert your app specific things.
- Pay attention to the .desktop file
If you wonder why Konqueror isn't embedding your app, it's almost surely because something is wrong with your .desktop file. Pay close attention to that section in the tutorial.
- Make sure your app has a pre-existing "view" class
This is probably the most important point in this tutorial. If you app already has a existing view class that provides a coherent interface to your apps UI functionality, then everything is trivial. If your code is ad-hoc, then this could be a nightmare.
Original location of this tutorial:
Tutorial pages packaged up (no source)
Source package for the base aKtion 1.99:
Source package for the finished (component) aKtion 1.99:
Official aKtion! homepage
Sample AVI file for testing (needs to be unzipped)
Plugins needed for xanim/aktion to play sample AVI file (Intel
[ Edit ]