Here are some of the more noteworthy things available in milestone build M6 (April 1, 2005) which is now available for download. See the M6 build notes for details about bugs fixed and other changes.
Platform UI
Curry tracking
The Eclipse teams in Ottawa are now tracking the number of takeout dinners ordered from Shaan Curry House during the 3.1 release cycle.
Please keep in mind this only represents a small portion of our curry orders - we're in the process of entering data back to September 2004; the full database will be found here.
Performance vIEw
There is now a vIEw for displaying performance issues in Eclipse. Several operations throughout Eclipse now report performance to the org.eclipse.core.runtime.PerformanceStats class when time to perform an Operation is over a threshold. Performance logging occurs if you run Eclipse with the -debug option.
These performance issues are logged to an internal performance.log file (in the .metadata directory of your Eclipse workspace) for further analysis. See here for more details.
Preference page links
General support for linking preference pages allows pages with related settings to refer to each other and provide quick Access to the other page. Combined with web-style forward and backward navigation added in an earlier milestone, it is now much easIEr to work with a set of related preference pages.
Content type preference page
A new preference page to edit content types and their associated file names and character sets has been added under the General/Editors preference page.
Editor lookup based on content type
Editor lookup now takes content types into account via a new element in the org.eclipse.ui.editors extension point called contentTypeBinding. Editors may now advertise that they are capable of working on certain content types as well as their traditional file name and extensions. For M6, content type bindings take precedence over file name bindings, but we will be looking at more sophisticated policIEs for M7. Note that the various SDK editors, including the Text, Java, and Class file editors, will not take advantage of this new feature until M7.
New capabilitIEs preference page
A new capabilities preference page has been introduced in an effort to simplify management of capabilitIEs in downstream products.
Dynamic Help now available for all the dialogs
The new dynamic help that was added to the workbench window in M5 is now available in dialogs as well. When triggered by the system-specific help shortcut (F1 on Windows, Shift-F1 on Linux GTK etc.), a shell opens aligned with the dialog showing the related help information. Multi-page dialogs like wizards, preferences, launch configurations, searches, etc. trigger the help pane to update its content as you flip from page to page.
Workbench Browser support API now available
Starting from M6, the web browser support API is available to clients from IWorkbench. The API makes it straightforward to programmatically open URLs from plug-ins. URLs are opened in internal or external browsers, depending on user preferences. Browser support is pluggable and Eclipse provides an RCP-frIEndly reference implementation in the new org.eclipse.ui.browser plug-in.
In addition, the internal web browser is registered as a non-default editor for the most common Html extensions.
Platform Runtime
Single JAR plug-ins
Eclipse now provides the ability to ship a plug-in packaged as a single JAR file rather than as a directory of files. Think of this as folding the plug-in metadata (plugin.XML etc.) into its code JAR. This move has a number of benefits ranging from smaller footprint to easIEr/faster install to fitting better with the standard Java notion of JARs. More information can be found on the Core team web page.
In Eclipse 3.1 M6 all of the RCP base plug-ins and a few extra (over 25 in total) are shipped as JARs in all distributions (RCP, Platform, PDE, JDT , etc drops). For M7 we expect the vast majority of Eclipse plug-ins to be JAR'd.
JAR'd plug-ins are the new best practice for Eclipse packaging.
SWT
Strike through and underline in StyledText
Text can be underlined or a strike can be drawn through it with the new StyleRange.underline and StyleRange.strikeout fIElds.
For more details see the example snippet.
Spinner supports decimal values
The Spinner widget can display decimal values using the Spinner.setDigits() API. Decimal values can be used for the minimum, maximum, increment and selection values.
For more details see the example snippet.
Emulated table improvements
Some platforms such as Motif and Photon do not provide a native table widget and for these platforms SWT provides an emulated table implementation. In M6, this implementation was largely re-written. Many bugs were fixed and some features were enabled such as re-orderable columns and Table.showColumn().
Tree supports indices
New API has been added so that items in a Tree can be referenced by index. The index is relative to the immediate parent which for top level nodes is the Tree and for sub-nodes is the parent TreeItem. The new API includes Tree/TreeItem.indexOf(TreeItem) and Tree/TreeItem.getItem(index). In addition, you can remove the children of a tree item using TreeItem.removeAll().
Platform Text
Preference for undo history size
The undo history size can now be set for text editors; see the General > Editors > Text Editors preference page:
Ant
Mark Occurrences in the Ant editor
You can now enable the Ant editor to mark occurrences of propertIEs and targets. Mark occurrences is controlled via the Ant editor preferences and editor toolbar action.
More control over error reporting in the Ant editor
You can now set the Ant editor to ignore all buildfile problems. As well you can specify specific buildfile names that the editor should not report problems for. Both settings are controlled using the Ant editor preferences for Problems. See bug 84307 for full details
Rename in File for the Ant editor
You can now rename occurrences of propertIEs and targets within the same buildfile within the Ant editor. To activate use the editor context menu or the Alt-Shift-R keyboard shortcut when the cursor is located within the occurrence to rename.
JDT Core
J2SE5 status
Just before EclipseCON, the IBM Rational teams developing products based on Eclipse and Java technology reported that they ran the Java compiler TCK suite using the Eclipse Platform 3.1 N20050225-0010 build and verifIEd that the Eclipse Java compiler passed and is 1.5 compliant (36938).
Usage of annotation type as super interface diagnosis
In J2SE 5, the Java language allows a class to implement an annotation type. However this should be discouraged. The Java compiler optionally flags such usage.
Type parameter declaration hiding another type diagnosis
The Java compiler can optionally flag a type parameter declaration hiding another type.
Missing @Override annotation diagnosis
The Java compiler can optionally flag a method overriding a superclass method, but missing proper @Override annotation.
Incomplete enum switch statement diagnosis
The Java compiler can optionally flag incomplete enum switch statements.
Missing @Deprecated annotation diagnosis
The Java compiler now recognizes the @Deprecated annotations, and treats them equivalent to doc comment /** @deprecated */. It can optionally flag deprecated constructs missing a proper @Deprecated annotation (to encourage using annotations instead of doc comment tag).
Completion on annotation attribute
Code completion on an annotation attribute now proposes attribute names.
Completion on enum constant
Code completion on an expression inside a switch proposes enum constants if the expression is an enum.
Support for package-info.Java
Support has been added for the special source file package-info.Java, that allows annotating and documenting packages. All JDT tools (code assist, code select, search, outline, type hierarchIEs, etc.) can be used in this special compilation unit.
Code select on enum constant
Code select now returns an element if the selection is an enum constant inside a case label.
Code select in Javadoc
Code select now returns an element if the selection is a reference inside a doc comment (i.e., @see, @link, @linkplain, @throws, @exception, @param or @value tags).
Access rules on librarIEs and projects
Access rules can be defined on referenced librarIEs and projects so as to explicitly allow/disallow/discourage Access to specific types.
JDT UI
New API to create code proposals like in the Java editor
Implementing an editor for a Java-like language? You can now create code assist proposals similar to the ones proposed in the Java editor. Instantiate CompletionProposalCollector to get the same proposals as the Java editor, or subclass it to mix in your own proposals. Use CompletionProposalLabelProvider to get the images and labels right, and sort the proposals using CompletionProposalComparator.
Package: org.eclipse.jdt.ui.text.Java in the org.eclipse.jdt.ui plug-in.
Navigate to project-specific settings
The preference pages for settings that are also configurable on a per-project basis offer a link to the project specific preference page.
Javadoc locations stored in the .classpath file
The Javadoc locations that are attached to JAR files and class folders are now stored in the .classpath file so they can be shared with the team. When M6 starts up, a background job will migrate all the previously internally stored locations to the .classpath file.
The Javadoc locations are used by 'Open External Javadoc' (CTRL + F2) and by the Javadoc wizard.
Use Supertype Where Possible refactoring
The Use Supertype Where Possible refactoring has been extended with a preference that specifIEs whether type occurrences in instanceof expressions should be updated:
Infer Type Generic Arguments refactoring
The Infer Type Generic Arguments refactoring now offers two configuration options:
When the first option is enabled, the refactoring assumes that implementations of the clone() method return an object of the same type as the receiver object. In the following example, the return type of method cloneListeners() can then be inferred to be Vector
public class TestResult extends Object { protected Vector fListeners; public void addListener(TestListener listener) { fListeners.addElement(listener); } private Vector cloneListeners() { return (Vector)fListeners.clone(); }}
The second option controls the behavior when no type arguments could be inferred. In the previous example, if the refactoring is not allowed to handle the clone() method specially, then it will just infer Vector as the return type of method cloneListeners(). If you don't like unbounded wildcard types, you can opt to leave the type raw.
Filter search result matches can now be rendered differently
Filtered and unfiltered search result matches are now rendered differently in the editor. By default filtered matches are now hidden in the editor. To control the visibility and rendering of hidden search matches, change the "Filtered Search Result" annotation settings in the General > Text Editors > Annotations preference page
In the above example, matches in import statements are filtered out. They are rendered using a different color and without the search result marker (yellow arrow) in the annotation bar.
New search result filters for reference search for parameterized types
When searching for references to a parameterized type such as List
Filter incompatible matches: this filter hides all results that are not assignment compatible with the search patttern. For example when searching for List
Externalize Strings wizards supports new message bundles
The Externalize Strings wizard now supports the new Eclipse message bundle approach (described in detail here):
New Eclipse default built-in formatter profile
Although Eclipse's default code formatter profile is named Java Convention, formatting a file using this profile uses tabs for indentation instead of spaces. A new profile named Eclipse has now been added which now reflects what the default formatter options have been all along, which uses tabs for indentation. To use true Java Convention settings, simply switch the formatter profile to Java Conventions using Java > Code Style > Formatter preference page. Debug
Run and Debug from editor
You can now run and debug Java programs and Ant builds from an editor's context menu.
Javadoc attachments
You can now associate a different Javadoc location with each JAR in a JRE's librarIEs.
PDE
Manifest editor supports more OSGi bundle manifest headers
The PDE plug-in editor now exposes many interesting features of the runtime that are available only if your plug-in has a manifest.mf file. The Runtime page of the editor, for example, is the place where you can control Access to your plug-in's code on a fine-grained level.
Manifest.mf validation
PDE now flags syntactic and semantic errors in the plug-in's manifest.mf file.
Create a plug-in from existing JAR
PDE now provides a wizard that creates a plug-in from existing JAR archives. This wizard is ideal if you would like to package third-party non-Eclipse JARs as an Eclipse plug-in.
The wizard can be invoked via File > New > Project > Plug-in from existing JAR archives.
Eclipse Product Export wizard
In addition to a zip format, you can now export your Eclipse product as a directory structure. The new Eclipse Product Export wizard is invoked via File > Export > Eclipse Product or from the OvervIEw page of the Product Configuration editor.
Signed JARs
The feature and export plug-in wizards now provide you with the option to digitally sign your plug-in and feature archives for added security.