Writing UNO Components
OpenOffice.org can be extended by UNO components. UNO components are shared libraries or jar files with the ability to instantiate objects that can integrate themselves into the UNO environment. A UNO component can access existing features of OpenOffice.org, and it can be used from within OpenOffice.org through the object communication mechanisms provided by UNO.
OpenOffice.org provides many entry points for these extensions.
- Arbitrary objects written in Java or C++ can be called from the user interface, display their own GUI, and work with the entire application.
- Calc Add-Ins can be used to create new formula sets that are presented in the formula autopilot.
- Chart Add-Ins can insert new Chart types into the charting tool.
- New database drivers can be installed into the office to extend data access.
- Entire application modules are exchangeable, for instance the linguistics module.
- It is possible to create new document types and add them to the office. For instance, a personal information manager could add message, calendar, task and journal document components, or a project manager could support a new project document.
- Developers can leverage the OpenOffice.org XML file format to read and write new file formats through components.
From OpenOffice.org 1.1.0 there is comprehensive support for component extensions. The entire product cycle of a component is now covered:
- The design and development of components has been made easier by adding wizards for components to the NetBeans IDE. You can find more detailed info under http://wiki.services.openoffice.org/wiki/OpenOffice_NetBeans_Integration.
- Components can integrate themselves into the user interface, using simple configuration files. You can add new menus, toolbar items, and help items for a component simply by editing XML configuration files.
- Components are deployed with the Extension Manager. See chapter Extensions.
- Last but not least, this is not the only way to add features to the office. Learning how to write components and how to use the OpenOffice.org API at the same time teaches you the techniques used in the OpenOffice.org code base, thus enabling you to work with the existing OpenOffice.org source code, extend it or introduce bug fixes.
Components are the basis for all of these extensions. This chapter teaches you how to write UNO components. It assumes that you have at least read the chapter First Steps and—depending on your target language—the section about the Java or C++ language binding in Professional UNO.
Download as a PDF or ODT
|Content on this page is licensed under the Public Documentation License (PDL).|