views:

56

answers:

2
+1  Q: 

hiding tab in pde

Hi, I have an editor (emf editor). And I only want one of the tabs in the editor. If I do not add the other pages, I still see one tab in the tab selection. Can I hide the tab, so the user will not see it is a multipageeditor?

A: 

No, a MultiPageEditorPart is used for more than one page, so if you want one page just simply use and EditorPart.

I'm not sure what you are trying to do? You say you have 'an EMF editor'. Is this an editor of your own devising or are you trying to override something?

arcticpenguin
it was generated by emf.it is not that simple to change it to EditorPart...
Ido
+1  A: 

Ok... found it:

//the text must be empty so it will not be shown in the tab
setPageText(index, "");

//hide the tab
CTabFolder tabFolder = (CTabFolder)super.getContainer();
tabFolder.setSingle(true);
Ido