Defining an intro part

The IIntroPart interface and the org.eclipse.ui.intro extension point make up the generic mechanism that can be used to create your own intro support for a given product. The main purpose of this extension is to define the class that implements IIntroPart and to specify the binding between a product id and an intro part. For example, the following contribution defines a hypothetical intro part to be shown by the workbench on startup:

   <extension  
         point="org.eclipse.ui.intro">
      <intro
            class="com.example.SampleIntroPart"
            id="someId"
            icon="someIcon.png">
      </intro>
      <introProductBinding
            introId="someId"
            productId="com.example.someProductId">
      </introProductBinding>
   </extension>
This contribution first defines the intro part and assigns it the id "someId". It then binds this intro part to a product whose id is "com.example.someProductId". On platform startup, the class specified in the class attribute will be instantiated by the workbench and presented to the user as the introduction to the product. This is the lowest level integration into the IIntroPart interface.

The platform supplies its own IIntroPart implementation called CustomizableIntroPart that allows for the content and presentation of the intro to be customized. Below is the snippet that defines the intro part for the workbench. We won't go over the mechanics of implementing an intro part since we want to focus on defining the intro content. (See the extension point documentation and javadoc referenced above for more detail if you need it.)

   <extension  
         point="org.eclipse.ui.intro">
      <intro
            class="org.eclipse.ui.intro.config.CustomizableIntroPart"
            id="org.eclipse.platform.intro">
      </intro>
      <introProductBinding
            introId="org.eclipse.platform.intro"
            productId="org.eclipse.platform">
      </introProductBinding>
   </extension>
The above contribution defines the CustomizableIntroPart as the intro part to be used for the Eclipse SDK platform. The rest of this discussion shows you how to use and extend this part.