I created a product of my RCP-Plugin-project. In my RCP-Plugin-project I have implemented an own perspective for my plugin to start with. Running my plugin as application
, everything works fine and I can see my perspective.
To set my perspective as default I have added a 'property' preferenceCustomization
to the plugin.xml
of my product. The code of related plugin_customization.ini
is the following:
org.eclipse.ui/SHOW_PROGRESS_ON_STARTUP = false
org.eclipse.ui/defaultPerspectiveId=de.cau.cs.bdd.perspective
The plugin.xml
of the application:
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<extension
point="org.eclipse.ui.perspectives">
<perspective
class="bdd.klighd.Perspective"
fixed="true"
id="de.cau.cs.bdd.perspective"
name="BDD Perspective">
</perspective>
</extension>
<extension
point="de.cau.cs.kieler.klighd.diagramSyntheses">
<diagramSynthesis
class="de.cau.cs.kieler.klighd.syntheses.GuiceBasedSynthesisFactory:bdd.klighd.BDDDiagramSynthesis"
id="bdd.klighd.BDDDiagramSynthesis">
</diagramSynthesis>
</extension>
<extension
point="de.cau.cs.kieler.klighd.ui.view.controller">
<controller
class="bdd.klighd.BDDEditorViewController">
</controller>
</extension>
<extension
point="org.eclipse.ui.editors">
<editor
class="bdd.klighd.BDDEditor"
default="true"
id="bdd.klighd.BDDEditor"
name="BDDEditor">
</editor>
</extension>
<extension
point="org.eclipse.ui.commands">
<command
defaultHandler="bdd.klighd.CallBDDEditor"
id="bdd.klighd.openBDDEditor"
name="Open BDDEditor">
</command>
</extension>
<extension
point="de.cau.cs.kieler.klighd.ui.view.editor">
<editor
controllerID="bddcontroller"
editorID="bdd.klighd.BDDEditor">
</editor>
</extension>
<extension
point="org.eclipse.ui.elementFactories">
<factory
class="bdd.klighd.ElementFactory"
id="bdd.klighd.factory">
</factory>
</extension>
<extension
point="org.eclipse.ui.perspectiveExtensions">
<perspectiveExtension
targetID="de.cau.cs.bdd.perspective">
<hiddenMenuItem id="org.eclipse.ui.run"></hiddenMenuItem>
<hiddenMenuItem id="navigate"></hiddenMenuItem>
<hiddenMenuItem id="file"></hiddenMenuItem>
<hiddenMenuItem id="project"></hiddenMenuItem>
<hiddenMenuItem id="window"></hiddenMenuItem>
<hiddenMenuItem id="help"></hiddenMenuItem>
<hiddenMenuItem id="edit"></hiddenMenuItem>
<hiddenMenuItem id=" org.eclipse.search.menu"></hiddenMenuItem>
</perspectiveExtension>
</extension>
</plugin>
The plugin.xml
of the product:
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<extension
id="product"
point="org.eclipse.core.runtime.products">
<product
application="org.eclipse.ui.ide.workbench"
name="BDDProduct">
<property
name="appName"
value="BDDProduct">
</property>
<property
name="rendererFactoryUri"
value="bundleclass://swt.renderer/swt.renderer.RendererFactory">
</property>
<property
name="preferenceCustomization"
value="plugin_customization.ini">
</property>
</product>
</extension>
</plugin>
Oddly enough launching my product I obtain an empty eclipse-window and the property preferenceCustomization
has disappeared.
Does anybody know why this could happen? And how to fix it?
To preserve the preferenceCustomization
property when you synchronize the product add this to the end of the .product
file:
<preferencesInfo>
<targetfile overwrite="false" path="/my-project/plugin_customization.ini"/>
</preferencesInfo>
<cssInfo>
</cssInfo>
I discovered this when I was researching the purpose of the Customization
tab in the product view.
(tested on Eclipse Neon.2 - 4.6.2)