...
- #How can I launch the Eclipse web browser from my plugin?
- #How can my view save data via Eclipse main menu (FILE => Save or Save As...)?
- #How can I notify Eclipse about the change in "dirty"-ness of my WorkbenchPart?
- #What happens when a view is closed?
- #How do I access a file in the plugin programmatically?
- #How can I manipulate the main workbench menu at runtime?
- #How do I open an error dialog?
- #How do I set a retargetable action?
Deployment
- #How do I configure #What should I know about my plugin to build configuration?
- #In build.properties, I specified to build a JAR file from my plugin sources. When I deploy my plugin, a class can not be found. What am I doing wrong?
- #How do I generate Javadoc with links to APIs on the web?
- #Should I deploy my pure Java plugin as a JAR file or as a directory?
...
Link verified by Sergei Chevtsov, 06-11-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.pde.doc.user/guide/tasks/pde_source_generation.htm
A source feature is useful for delivering source code to a developer via Eclipse infrastructure.
...
Answered by Sergei Chevtsov, 06-08-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.jdt.doc.isv/guide/jdt_api_compile.htm
Eclipse uses its own Java compiler that is more flexible than Sun's.
...
Link verified by Sergei Chevtsov, 08-16-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.platform.doc.isv/reference/misc/bundle_manifest.html
Your MANIFEST.MF file will NOT contain the element "Eclipse-LazyStart: true", and the plugin will be activated when the Eclipse platform starts.
...
1. Check out the project "external" from our CVS.
2. Copy your JAR file and, if applicable, the corresponding ZIP file with source code to the top directory of "external".
Some guidelines about naming source ZIP files: http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.pde.doc.user/guide/tools/preference_pages/source_code_locations.htm
3. Open the MANIFEST.MF file from the META-INF directory of "external".
4. Choose the RUNTIME tab at the bottom of your editor.
5. Click on ADD... in the "Classpath" section and select the new JAR file.
6. Click on ADD.. in the "Exported Packages" section and select all desired packages.
7. Optional: in the build path configuration dialog of the project, attach source from the ZIP file and specify Javadoc location of the library
8. Commit "external" to CVS.
...
Answered by Sergei Chevtsov, 06-13-2007
http://help.eclipse.org/help32help33/nftopic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/ui/ISaveablePart.html
Your view must implement ISaveablePart.
Note #1: An editor already implements ISaveablePart.
Note #2: I am not saying that this always is the correct way to save data from a view.
...
Answered by Sergei Chevtsov, 06-14-2007
Basically, use FileLocator .
Similar methods in other classes are deprecated and call FileLocator anyway.
To get a Bundle instance associated with the desired plugin, use ((Plugin)myPlugin).getBundle().
If you can't access the instance of the desired Plugin, then (in addition to yelling at the plugin developer ) use Platform.getBundle(symbolicName) where "symbolicName" is specified in the plugin's MANIFEST.MF file.
Finally, use new Path(myPath), where "myPath" is relative to the plugin's top directory, to get an instance of IPath.
...
Answered by Sergei Chevtsov, 07-25-2007
Use ErrorDialog, e.g.:
ErrorDialog.openError(shell, title, null, new Status(IStatus.ERROR, pluginId, IStatus.OK, localizedMessage, exception));
Note: localizedMessage must not be null!
...
How do I
...
set a retargetable action?
Answered by Sergei Chevtsov, 0810-2122-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.platform.doc.isv/reference/misc/index.htmlguide/wrkAdv_retarget_setting.htm
Use getViewSite().getActionBars().setGlobalActionHandler(IAction).
...
What should I know about my plugin build configuration?
Answered by Sergei Chevtsov, 09-06-2007
Pay special attention to where your class files will land.Pay special attention to how your classes are treated during the build process!
...
In build.properties, I specified to build a JAR file from my plugin sources. When I deploy my plugin, a class can not be found. What am I doing wrong?
...
Answered by Sergei Chevtsov, 07-20-2007
0. If your Javadoc has already been generated using this method:
- 1. Remove existing Javadoc files.
- 2. Go to step 4.
1. Use the Export Wizard to generate Javadoc for your classes. Check "Save the settings as an Ant script" on the last page.
Note: The generated Ant script will have hard-coded classpath, i.e. if you have a required plugin checked out into your workspace, the script won't work next time, unless you check that plugin out, too. To avoid headache, we advise that you close all projects, except the one that you generate JavaDoc for.
2. Open javadoc.xml.
3. For each external API, add the following line as child of <javadoc> element:
<link href="url to the API directory on the web" />
Some of the most common URLs are:
JDK => http://java.sun.com/j2se/1.5.0/docs/api/
Eclipse => http://help.eclipse.org/help32help33/nftopic/org.eclipse.platform.doc.isv/reference/api/
SEAL plugin => http://www.slac.stanford.edu/grp/lcls/controls/docs/physics/sealPLUGIN_NAME/javadoc/
...
Answered by Sergei Chevtsov, 06-13-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.platform.doc.isv/guide/swt_threading.htm
You can only access SWT widgets from a UI thread.
...
Link verified by Sergei Chevtsov, 07-11-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.platform.doc.isv/reference/misc/runtime-options.html
Some of the most useful options are: clean, console, debug (note: it actually enables tracing only), nl, noSplash, password, vm, vmArgs.
...
Link verified by Sergei Chevtsov, 06-11-2007
http://help.eclipse.org/help32help33/index.jsp?topic=/org.eclipse.pde.doc.user/guide/tasks/pde_feature_generating_ant.htm
It uses build.properties from your plugin's top directory.
...