[ Prev ] [ Index ] [ Next ]

OpenOffice

Created Tuesday 4/9/2007

This document is an overview of the OpenOffice suite, which includes Word Processor (oowriter), Spreadsheet (oocalc), Slide Manager and Presentation (ooimpress), Drawing tool (oodraw) as well as the centeral office suite (ooofice). A basic overview with tips and notes are presented along with examples for the OpenOffice macro environment, which includes support for Visual Basic and Javascript.

The OpenOffice suite is mostly compatible with the Microsoft Office \reg \trade suite of appliations and the various OpenOffice applications are capable of reading (and writing) a wide variety of Microsoft Office formats.

1. Word processing

The OpenOffice word processor, called oowriter, is very similar in its UI to Microsoft Word and as such its basically the same to operate. Setting formats for Page, Paragraph and Character should be familiar to anyone using versions of Word going way back to verion 1.0.

2. Spreadsheet

The OpenOffice spreadsheet program, called oocalc, is very similar in its UI to Microsoft Excel. Data are presented in the typical row/column format and formulae can be entered into individual cells. A complex set of functions are available and the OpenOffice spreadsheets supports multiple sheets, document and object embedding, database connectivity and similar.

3. Presentation

The OpenOffice spreadsheet program, called ooimpress, is very similar in its UI to Powerpoint.

4. Maths

The OpenOffice program, called oomath, is much like the Math Editor in Microsoft word. Expressions, equations &c. can be entered and then imported into other (openoffice) applications like the word processor (oowriter).

5. Drawing

The OpenOffice program, called oodraw, is similar to Visio. A drawing can use templates, which are configured to provide familar shapes and constructs from diagramming techiques such ER, UML, schematics and etc. Objects in the diagram have nodes to which connectors are added, such that a box can connect to a line object (or more commonly a box connects to a box). Connectors can be given a name, a direction and a multiplicity.

6. Office Central

The central office management tool is ooofice. This is the application from which a new Spreadsheet, Document or Presentation can be created.

7. Macro language

The OpenOffice suite uses a common macro language amongst its applications. There are many similarities between the Visual Basic of Microsoft Office and that of OpenOffice. The macro editor and IDE are a little different to Microsoft's but the the essence is the same, in that dialogs are created (i.e., forms) onto which controls are placed, a nd events are attached to the controls. Each control has a property sheet within which static properties, such as text (caption), font, color and etc can be set. The properties of Form controls can also be set programatically.

The Macro environent for OpenOffice makes a clear separation between the UI components (called Dialogs) and executable macro code (i.e., the Visual Basic or Javascript code). Typically, a macro is created in a Library and given a name, with the Main macro being the entry point. Macro scripts can invoke dialogs by using the "LoadDialog" function. The following codelet shows a macro stub (which would perhaps be the entire contents of a Main macro). This macro loads a dialog called Dialog1" and programatically sets the values for a combo box (a control called ComboBox1). The dialog Dialog1** is then opened and the macro ends.

REM ***** OpenOffice BASIC :: Main *****
Sub Main
    rem print "hello, world"; <<< DEBUG: "print" causes text to appear in a dialog
rem Load dialog and store a copy of the model
Dlg = LoadDialog("Standard", "Dialog1")
DialogModel = Dlg.Model
rem Apply properties to components of the model
With DialogModel
    .ComboBox1.Enabled = true
    rem .ComboBox2.Enabled = false
End With
REM Apply properties programmattically to a control.
rem first off, get the control 
oComboBox = oDialog.getControl("ComboBox1") 
REM remove all old items from the list 
nCount = oComboBox.getItemCount() 
oComboBox.removeItems( 0, nCount ) 
REM add new items to the list 
sItems = Array( "Item1", "Item2", "Item3", "Item4", "Item5" ) 
oComboBox.addItems( sItems, 0 ) 
rem DialogModel.lstCurrencies.TabIndex = 2
Dlg.GetControl("ComboBox1").SetFocus()
Dlg.Execute
Rem Get rid of the dialog resources. This is not strictly necessary in this context.   
Dlg.Dispose
    End Sub

8. Digital Signatures

Digital certificates must be in a certificate store (cert8.db) and, in addition, the variableMOZILLA_CERTIFICATE_FOLDER must point to the directory containing hte certificate store. E.g.,

bash $ export MOZILLA_CERTIFICATE_FOLDER=/home/foo/.thunderbird/y4xk1md0.default/

Stuart Moorfoot \copy 4 September 2007 foo@bund.com.au


No backlinks to this page.