Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » Maximizing/Minimizing views
Maximizing/Minimizing views [message #559925] Mon, 20 September 2010 12:05 Go to next message
Sun Volland is currently offline Sun VollandFriend
Messages: 29
Registered: September 2010
Junior Member

My E4 RCP app is built using an XMI model, and I would like to add the maximize/minimize functionnalities to views in a particular view stack.

How can I achieve this in E4 ?

thanks in advance,
Re: Maximizing/Minimizing views [message #625692 is a reply to message #559925] Wed, 22 September 2010 10:04 Go to previous message
Sun Volland is currently offline Sun VollandFriend
Messages: 29
Registered: September 2010
Junior Member
Me again, I finally found the solution by looking at how the Eclipse SDK model was setup.

First I added the following addons to my application model :
  <addons elementId="MinMax Addon" contributionURI="platform:/plugin/org.eclipse.e4.ui.workbench.addons.swt/org.eclipse.e4.ui.workbench.addons.minmax.MinMaxAddon"/>
  <addons elementId="DnD Addon" contributionURI="platform:/plugin/org.eclipse.e4.ui.workbench.addons.swt/org.eclipse.e4.ui.workbench.addons.dndaddon.DnDAddon"/>
  <addons elementId="Cleanup Addon" contributionURI="platform:/plugin/org.eclipse.e4.ui.workbench.addons.swt/org.eclipse.e4.ui.workbench.addons.cleanupaddon.CleanupAddon"/>

Note that these are provided by the org.eclipse.e4.ui.workbench.addons.swt bundle.

Strangely only adding the MinMaxAddon is not enough. I got the minimize/maximize icons on the stacks, but the behaviour is broken.

Then I defined the editor stack (the stack that can be maximized) in my E4 xmi model by :
- setting the id of the corresponding PartStack to org.eclipse.ui.editorss
- adding an EditorStack tag to it

And now it works !

However It seems that there is little redrawing bug when maximizing/restoring the editor stack : the restored stacks do not always render their tabs correctly. Moving the sash does instantly redraw the tabs.
I get the same bug in my Eclipse E4 SDK install, so I guess it has nothing to do with my app (running on Linux SuSE SLED 11.0 32 bits with KDE)
Previous Topic:Popup Menu for Parts
Next Topic:How to create an editor in e4
Goto Forum:

Current Time: Sun Jun 13 12:39:04 GMT 2021

Powered by FUDForum. Page generated in 0.01296 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top