Eclipse-Spectrum-Theme icon indicating copy to clipboard operation
Eclipse-Spectrum-Theme copied to clipboard

Automatically suggest to switch themes upon plugin installation

Open AObuchow opened this issue 5 years ago • 5 comments

Maybe it’d be nice to make a dialog pop up when the user installs the plugin for the first time. The dialog would give the user the option to switch to Spectrum theme by clicking a single button.

This might be especially nice for users new to the plugin, or users who install the plugin but forget to swap themes.

A requirement would be that the dialog is only shown once, when the plugin is originally installed.

AObuchow avatar Jun 28 '20 01:06 AObuchow

I think #52 might be a requirement for this feature, as the preference page could contain an activator that would track the plugins initialization.

AObuchow avatar Jun 28 '20 01:06 AObuchow

Anyone have an idea on how this should be done (in terms of implementation)? @ingomohr @pyvesB

I was thinking of checking if a custom preference exists in the preference store, and if not, setting it. This preference being set will determine whether the dialog appears or not.

The issue is that this will probably occur on every new workspace... maybe there's a better way to do it.

AObuchow avatar Jul 12 '20 03:07 AObuchow

If the plugin would start automatically (which you typically don't want due to overall performance), we could hook a dialog into plug-in startup (i.e. the activator).

Maybe there is another way to run code of a plug-in without the plug-in actually being started. But I don't know about that, yet.

ingomohr avatar Jul 12 '20 10:07 ingomohr

The issue is that this will probably occur on every new workspace... maybe there's a better way to do it.

That's the behaviour if you use the instance scope, but you can have cross-workspace preferences using the configuration scope. More information here.

I'm wondering whether this should be implemented at the Platform level rather than in Spectrum alone. Wouldn't it be cool if the IDE automatically displayed "3 new themes were found, click here to open the theme preferences" in one of those new non-blocking popups?

PyvesB avatar Jul 12 '20 14:07 PyvesB

The issue is that this will probably occur on every new workspace... maybe there's a better way to do it.

That's the behaviour if you use the instance scope, but you can have cross-workspace preferences using the configuration scope. More information here.

@PyvesB thank you very much for the reference - that will make implementing this possible :)

I'm wondering whether this should be implemented at the Platform level rather than in Spectrum alone. Wouldn't it be cool if the IDE automatically displayed "3 new themes were found, click here to open the theme preferences" in one of those new non-blocking popups?

I was planning on using the new notification API for this, good idea ;) This would be really nice in Platform, although I'm not sure if there are enough people making eclipse themes to make it worth it? I would be +1 for this overall though and would be willing to implement such a feature upstream (since it'd help for Spectrum Theme's case atleast :D)

I wonder if a more generic use case/pattern could be derived from this, for upstream. Something like an extension point to make a "new plugin installed" notification appears. This would give plugin developers a chance to let users know the plugin is installed & give a link to the plugins' preferences (or some interactive tutorial perhaps).

Obviously. an issue would arise when multiple plugins are installed in one go: the user would be flooded with notifications. This could be discussed in the upstream bug, if we think it's an idea worth persuing.

AObuchow avatar Jul 12 '20 22:07 AObuchow