Chapter 4 Restricting Functionality in StarOffice
You can restrict the functionality of StarOffice program modules for individual
users, groups, or across a network. If you want, you can also apply different restrictions
to different users.
To easily restrict StarOffice functionality as well as to administer StarOffice settings
for users on a network, use the Java Desktop System Configuration Manager. This tool is available for Solaris, Linux,
and Windows. For more information on this tool, see the Java Desktop System
Configuration Manager Release 1.1 Administration Guide at http://docs.sun.com/app/docs. You can find this guide on the StarOffice Enterprise CD.
You can also create a command configuration file in XML format to restrict the
availability of menu commands in a StarOffice program.
Creating a Command Configuration File
The creation of a command configuration file is a three-step process:
-
Determine the command names of the features that you want to restrict
-
Create an XML configuration file
-
Copy the configuration file to the appropriate location in the StarOffice installation
directory
To Create a Command Configuration File
Steps
-
Determine the command name(s) for the feature(s) that you want to restrict.
Note –
See Appendix A, Index of UNO Command Names for StarOffice 8 for a list of the command names in StarOffice.
-
In a text editor, create an XML configuration file.
-
Ensure that the file has the following structure:
<?xml version="1.0" encoding="UTF-8" ?>
<oor:node oor:name="Commands" oor:package="org.openoffice.Office"
xmlns:oor="http://openoffice.org/2001/registry"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<node oor:name="Execute">
<node oor:name="Disabled">
<node oor:name="CommandName" oor:op="replace">
<prop oor:name="Command">
<value>CommandName</value>
</prop>
</node>
</node>
</node>
</oor:node>
Note –
The Commands.xcu file uses the following schema:
<?xml version='1.0' encoding='UTF-8'?>
<oor:component-schema oor:name="Commands"
oor:package="org.openoffice.Office" xml:lang="en-US"
xmlns:oor="http://openoffice.org/2001/registry"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<templates>
<group oor:name="CommandType">
<prop oor:name="Command" oor:type="xs:string"/>
</group>
</templates>
<component>
<group oor:name="Execute">
<set oor:name="Disabled" oor:node-type="CommandType"/>
</group>
</component>
</oor:component-schema>
-
Create a separate node for each feature that you want to restrict.
-
In each node, replace the term CommandName with
the command name of the feature.
-
Save the file as Commands.xcu.
Example 4–1 Sample Commands.xcu File
The following Commands.xcu file disables the ability to
customize menus in StarOffice. To apply this restriction to all users, copy the
file to the <SO network dir>/share/registry/data/org/openoffice/Office directory.
<?xml version="1.0" encoding="UTF-8" ?>
<oor:node oor:name="Commands"
oor:package="org.openoffice.Office"
xmlns:oor="http://openoffice.org/2001/registry"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<node oor:name="Execute">
<node oor:name="Disabled">
<node oor:name="ConfigureDialog" oor:op="replace">
<prop oor:name="Command">
<value>ConfigureDialog</value>
</prop>
</node>
<node oor:name="ConfigureToolboxVisible" oor:op="replace">
<prop oor:name="Command">
<value>LoadToolBox</value>
</prop>
</node>
</node>
</node>
</oor:node>
For a list as well as a description of command names, see Appendix A, Index of UNO Command Names for StarOffice 8 .
To Apply a Command Configuration File
You can apply a command configuration file to StarOffice on Solaris, Linux,
and Windows.
Steps
-
Exit all StarOffice applications.
On Windows, ensure that
you exit the StarOffice Quickstarter in the system tray.
-
Copy the Commands.xcu file to the appropriate directory.
-
To apply the configuration to all users on the network, copy the Commands.xcu file to the following directory:
<SO
network dir>/share/registry/data/org/openoffice/Office
-
To apply the configuration to a specific user on the network, copy the Commands.xcu file to the following directory:
<SO
workstat dir>/user/registry/data/org/openoffice/Office
The configuration is applied when you restart StarOffice.