blob: 03ca58c9dc6f0ed10bfe887163ddc377720f4d1a [file] [log] [blame]
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="GENERATOR" content="Mozilla/4.5 [en] (WinNT; I) [Netscape]">
<meta name="Author" content="Build">
<title>Eclipse Workbench Extension Point: Perspectives</title>
</head>
<body link="#0000FF" vlink="#800080">
<center>
<h1>
Perspectives</h1></center>
<b><i>Identifier: </i></b>org.eclipse.ui.perspectives
<p><b><i>Description: </i></b>This extension point is used to add perspective
factories to the workbench.&nbsp; A perspective factory is used to define
the initial layout and visible action sets for a perspective.&nbsp; The
user can select a perspective by invoking the "Open" submenu of the "Perspective"
menu.
<p><b><i>Configuration Markup:</i></b>
<p><tt>&nbsp;&nbsp; &lt;!ELEMENT perspective (description?)></tt>
<br><tt>&nbsp;&nbsp; &lt;!ATTLIST perspective</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; id&nbsp;&nbsp;&nbsp;&nbsp; CDATA
#REQUIRED</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; name&nbsp;&nbsp; CDATA #REQUIRED</tt>
<br><tt><font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; class&nbsp;
CDATA #REQUIRED</font></tt>
<br><tt><font color="#000000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; icon&nbsp;&nbsp;
CDATA #IMPLIED</font></tt>
<br><tt><font color="#000000">&nbsp;</font>&nbsp;&nbsp; ></tt>
<br><tt>&nbsp;&nbsp;&nbsp; &lt;!ELEMENT description (#PCDATA)></tt>
<ul>
<li>
<b>id</b> - a unique name that will be used to identify this perspective.</li>
<li>
<b>name</b> - a translatable name that will be used in the workbench window
menu bar to represent this perspective.</li>
<li>
<b>class</b>&nbsp; – a fully qualified name of the class that implements
<tt>org.eclipse.ui.IPerspectiveFactory</tt>
interface.</li>
<li>
<b>icon</b> - a relative name of the icon that will be associated with
this perspective.</li>
<li>
<b>description</b> - an optional subelement whose body should contain text
providing short description of the perspective.</li>
</ul>
<b><i>Examples:</i></b>
<p>The following is an example of a perspective extension:
<p><tt>&nbsp;&nbsp; &lt;extension</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; point="org.eclipse.ui.perspectives"></tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;perspective</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
id="org.eclipse.ui.resourcePerspective"</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
name="Resource"</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
class="org.eclipse.ui.internal.ResourcePerspective"</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
icon="icons/MyIcon.gif"></tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/perspective></tt>
<br><tt>&nbsp;&nbsp;&nbsp; &lt;/extension></tt>
<p><b><i>API Information: </i></b>The value of the <tt>class</tt> attribute
must be the fully qualified name of a class that implements <tt>org.eclipse.ui.IPerspectiveFactory</tt>.
The class must supply the initial layout for a perspective when asked by
the workbench.
<p>The <tt>product.ini</tt> file is used to define the default perspective.&nbsp;
The <i>default perspective</i> is the first perspective which appears when
the product is launched after install.&nbsp; It is also used when the user
opens a page or window with no specified perspective.&nbsp; The default
perspective is defined as a property within the product.ini, as shown below.&nbsp;
The user may also override this perspective from the workbench perspectives preference page.
<p><tt>&nbsp;&nbsp;&nbsp; defaultPerspectiveId = org.eclipse.ui.resourcePerspective</tt>
<p>The perspectives which appear in the "Open" menu are shortcuts for perspective
selection.&nbsp; This set is defined by the active perspective itself,
and extensions made through the <a href="org_eclipse_ui_perspectiveExtensions.html">perspectiveExtensions</a>
extension point.
<p><b><i>Supplied Implementation: </i></b>The workbench provides a "Resource
Perspective".&nbsp; Additional perspectives may be added by plug-ins. They
are selected using the Open submenu of the Perspective menu.
<p><a href="hglegal.htm"><img SRC="ngibmcpy.gif" ALT="Copyright IBM Corporation 2000, 2001" BORDER=0 height=12 width=195></a>
</body>
</html>