Can my Eclipse plugin change preferences from other plugins?

后端 未结 1 400
野性不改
野性不改 2021-01-07 01:21

I\'m working on an Eclipse plugin that needs to change some preferences defined by other plugins, e.g. the tab size in text editors. Is that possible?

相关标签:
1条回答
  • 2021-01-07 01:59

    Yes, it is possible.

    You'll need this in your preference page:

    setPreferenceStore( new ScopedPreferenceStore( new InstanceScope(), "bundle-name-of-other-plugin" ) );
    

    Or you could do something like this here.

    FYI, the preferences live here:

    pathToWorkspace\.metadata\.plugins\org.eclipse.core.runtime\.settings
    
    0 讨论(0)
提交回复
热议问题