Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sapphire » How to hide outline from SapphireEditorForXml?
How to hide outline from SapphireEditorForXml? [message #1033874] Thu, 04 April 2013 14:48 Go to next message
Joshua Spaulding is currently offline Joshua Spaulding
Messages: 16
Registered: April 2013
Junior Member
How do I autohide the outline from the editor when it is loaded?
Re: How to hide outline from SapphireEditorForXml? [message #1033882 is a reply to message #1033874] Thu, 04 April 2013 14:59 Go to previous messageGo to next message
Konstantin Komissarchik is currently offline Konstantin Komissarchik
Messages: 940
Registered: July 2009
Senior Member
From MasterDetailsEditorPage object (that's the form page in the editor), call getPart().state().getContentOutlineState().setVisible( false ).

- Konstantin
Re: How to hide outline from SapphireEditorForXml? [message #1033895 is a reply to message #1033882] Thu, 04 April 2013 15:19 Go to previous messageGo to next message
Joshua Spaulding is currently offline Joshua Spaulding
Messages: 16
Registered: April 2013
Junior Member
Thanks for the response. Where and when would I call this code? My xml file is loaded from a custom navigator. The SapphireEditorForXml is associated to the content type of my xml file so I never directly call the Editor.
Re: How to hide outline from SapphireEditorForXml? [message #1033976 is a reply to message #1033895] Thu, 04 April 2013 18:00 Go to previous messageGo to next message
Konstantin Komissarchik is currently offline Konstantin Komissarchik
Messages: 940
Registered: July 2009
Senior Member
Maybe subclass SapphireEditorForXml, override createFormPages() and do this step in there?
Re: How to hide outline from SapphireEditorForXml? [message #1036578 is a reply to message #1033976] Mon, 08 April 2013 11:09 Go to previous messageGo to next message
Joshua Spaulding is currently offline Joshua Spaulding
Messages: 16
Registered: April 2013
Junior Member
Thanks. I'm getting an error though when I try to extend that class. I'm not sure this is a related issue but do you know the cause?

the hierarchy of the type <myclass> is inconsistent
Re: How to hide outline from SapphireEditorForXml? [message #1036663 is a reply to message #1036578] Mon, 08 April 2013 13:10 Go to previous messageGo to next message
Konstantin Komissarchik is currently offline Konstantin Komissarchik
Messages: 940
Registered: July 2009
Senior Member
This Java error typically means there is an issue with your plugin's manifest. Make sure that you included "org.eclipse.sapphire.modeling" and "org.eclipse.sapphire.ui" in your manifest's required bundles.

- Konstantin
Re: How to hide outline from SapphireEditorForXml? [message #1036704 is a reply to message #1033874] Mon, 08 April 2013 14:02 Go to previous messageGo to next message
Joshua Spaulding is currently offline Joshua Spaulding
Messages: 16
Registered: April 2013
Junior Member
Yes, I was missing two dependencies. To subclass SapphireEditorForXml, I had to include the following which are required by the editor:

org.eclipse.ui.forms
org.eclipse.wst.sse.ui

Thanks.
Re: How to hide outline from SapphireEditorForXml? [message #1036909 is a reply to message #1036704] Mon, 08 April 2013 20:49 Go to previous message
Joshua Spaulding is currently offline Joshua Spaulding
Messages: 16
Registered: April 2013
Junior Member
I ended up subclassing SapphireEditor; very similar to the PurchaseOrder example. Everything is working now. Thanks for your help.
Previous Topic:ValueProperty bind to XML text
Next Topic:Implementing multiple Services on the same Property?
Goto Forum:
  


Current Time: Sat Aug 23 03:43:15 EDT 2014

Powered by FUDForum. Page generated in 0.07396 seconds