What's New in Eclipse 4.24

Here are descriptions of some of the changes of interest to plug-in developers made to the Eclipse Platform and SWT for the 4.24 release of Eclipse.

New features oriented towards end-users of the platform can be viewed in the What's New section of the Workbench User Guide.

Platform Changes

ILog can now be acquired as a service The ILog can now be acquired as service, so no need to have a Plugin activator or call Platform.getLog(...) anymore if you are in a Dependency Injection Context:

Example with E4:

@Inject ILog log;

Example with Declarative Services:

@Reference ILog log;

Of course any other way to acquire a Service (ServiceTracker, ServiceCaller, ...) will also work.

New EclipseContextFactory
.getServiceContext(Class<?>) method

There is now a new EclipseContextFactory.getServiceContext(Class<?>) method that could be used to acquire an E4 Service Context containing all OSGi services using a context class. This becomes handy in situations where you neither have an E4 context nor an OSGi context at hand (e.g. E3 legacy code) but still want to inject some fields or create injected objects.

SWT Changes

Improved Text's search/cancel buttons in Windows dark theme The Windows Text widget now supports improved search and cancel buttons in the dark theme:

On Windows 10, all the dark theme tweaks including the dark text's search and cancel buttons can be disabled using the org.eclipse.swt.internal.win32.disableCustomThemeTweaks Java property.
For Example: add this VM argument in eclipse.ini or on the command line after -vmargs: