Bug 318670 - [Workbench] Not all settings copied when switching workspace and "Copy settings" marked
Summary: [Workbench] Not all settings copied when switching workspace and "Copy settin...
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows Server 2003
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform UI Triaged CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks: 318952
  Show dependency tree
 
Reported: 2010-07-02 04:24 EDT by Lars Svensson CLA
Modified: 2020-07-05 05:52 EDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Svensson CLA 2010-07-02 04:24:36 EDT
Build Identifier: 

When creating new workpace and copying working set some settings is not copied 
If I select File->Switch Workspace->Other and creates a new workspace I canalso check "Copy settings->Workspace Layout".

Many things are copied, but I have noticed a few settings that I loose:

*  In Ctrl+H Serach: Visible tabs (after using Customized) and file name patterns of filename (*.java, *.xml ...) 
* "Wrap search" in Ctrl+F and previously launched (Fixed in Helios)
* Question "Always save resources before launching" forgets that I said checked "Remember my descision" 
* Prompt on exit Eclipse is back, and also forgets that I said checked "Remember my descision" 
* Also "Remember my descision" about associated perspectives is lost

Reproducible: Always
Comment 1 Lars Svensson CLA 2010-07-02 04:25:53 EDT
(In reply to comment #0)
> * "Wrap search" in Ctrl+F and previously launched (Fixed in Helios)


This one is OK. But the four others is still broken.
Comment 2 Ayushman Jain CLA 2010-07-02 05:17:15 EDT
(In reply to comment #0)
> *  In Ctrl+H Serach: Visible tabs (after using Customized) and file name
> patterns of filename (*.java, *.xml ...) 

I don't think this setting is intended to be copied through the "Copy settings->Workspace Layout" option. This should be controlled via workspace\.metadata\.plugins\org.eclipse.jdt.ui\ .Not sure if copying workspace layout also copies jdt/ui settings stored here.

Moving to Platform/UI for comment.
Comment 3 Paul Webster CLA 2010-07-05 10:34:17 EDT
I believe any feature that wants to allow this must use the org.eclipse.ui.preferenceTransfer extension point so their preferences can be copied across properly.

PW
Comment 4 Paul Webster CLA 2010-07-05 10:35:59 EDT
The implication is that the provider of each preference you would like copied needs to have a bug.

you can move these back to Platform/UI:

* Prompt on exit Eclipse is back, and also forgets that I said checked
"Remember my descision" 
* Also "Remember my descision" about associated perspectives is lost


and open bugs about the other ones (not platform UI or IDE).

PW
Comment 5 Ayushman Jain CLA 2010-07-06 02:25:27 EDT
(In reply to comment #4)
> The implication is that the provider of each preference you would like copied
> needs to have a bug.

Opened bugs 318593 and 318592 corresponding to points 1 and 3, respectively. 

Moving back to Platform/UI for points 4 and 5.
Comment 6 Dani Megert CLA 2010-07-06 02:30:23 EDT
>I believe any feature that wants to allow this must use the
>org.eclipse.ui.preferenceTransfer extension point so their preferences can be
>copied across properly.
As you can see in the switch dialog, Platform UI only offers 'Workbench Layout' and 'Working Sets'. I can't find any of those categories when using export or import which is based on preferenceTransfer. Hence I would assume that either only layout and working sets can be copied or the platform offers a mechanism (API or extension point) where clients can add additional stuff.

>Opened bugs 318593 and 318592 corresponding to points 1 and 3, respectively. 
These bugs don't seem related.
Comment 7 Paul Webster CLA 2010-07-06 08:31:26 EDT
(In reply to comment #6)
> >I believe any feature that wants to allow this must use the
> >org.eclipse.ui.preferenceTransfer extension point so their preferences can be
> >copied across properly.
> As you can see in the switch dialog, Platform UI only offers 'Workbench Layout'
> and 'Working Sets'. I can't find any of those categories when using export or
> import which is based on preferenceTransfer. 

It's the org.eclipse.ui.preferenceTransfer/settingsTransfer element (different from transfer which is used in the preferences import/export).

PW
Comment 8 Dani Megert CLA 2010-07-06 08:46:03 EDT
>It's the org.eclipse.ui.preferenceTransfer/settingsTransfer element (different
>from transfer which is used in the preferences import/export).
Ah I see. Thanks for the education.

I think comment 1 is wrong i.e. I can't see that Find/Replace settings are honored and it would be wrong if that's the case.

Also, preferences are not transferred either - again expected.
Comment 9 Paul Webster CLA 2011-04-01 10:56:40 EDT
OK, it's actually different than I thought.

Switch workspace is only providing "Transfer settings".  Things like the layout (workbench.xml) and workingsets (workingsets.xml) are examples, and settingsTransfer is the mechanism that allows a plugin to export the data it keeps in its plugin state location to another workspace.

There's no mechanism currently that includes preferences from switch locations.

The correct place to add them would be org.eclipse.ui.internal.ide.ChooseWorkspaceWithSettingsDialog.  Presumably the PreferenceTransferManager.getPreferenceTransfers() could be added to the settings check boxes, and added to the processing.


But the settings transfers are execute from the old eclipse.  AFAICT we would want the settings transfer to create the transfered preferences in their correct location at <newWorkspace>/.metadata/.plugins/org.eclipse.core.runtime/.settings which executing an Import in the new eclipse will do correctly.

I'm moving this to 3.8

PW
Comment 10 Dani Megert CLA 2011-06-09 02:43:21 EDT
I think there are two issues here:
1) preferences (see WONTFIX bug 132733)
2) dialog settings (this bug)

For 1) me might be able to reuse the preference transfers we already have for import/export.
Comment 11 John Cortell CLA 2012-04-03 16:28:21 EDT
(In reply to comment #10)
> I think there are two issues here:
> 1) preferences (see WONTFIX bug 132733)
> 2) dialog settings (this bug)
> 
> For 1) me might be able to reuse the preference transfers we already have for
> import/export.

We view this as an important feature for our commercial product.

Perspective customizations should also be transferable.
Comment 12 Paul Webster CLA 2012-04-04 08:12:29 EDT
Do to resource constraints, we won't be looking at this for 3.8.  Patches are welcome however.

http://wiki.eclipse.org/Platform_UI/How_to_Contribute

PW
Comment 13 John Cortell CLA 2012-04-04 08:18:27 EDT
(In reply to comment #12)
> Do to resource constraints, we won't be looking at this for 3.8.  Patches are
> welcome however.
> 
> http://wiki.eclipse.org/Platform_UI/How_to_Contribute
> 
> PW

Fair enough. "Put up or shut up" is the mantra for much of open source, and is a reasonable, an even expected, response. I'll try to get the time and go-ahead to pursue this and contribute the solution if I do.
Comment 14 Eclipse Genie CLA 2020-07-05 05:52:35 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.