Let’s say I have some view called “My View”.
I know I can create a category, “My Category”, and place my view inside it.
I’d like to create a subfolder/category inside “My Category” called “Sub Folder” and place my view inside it.
Then the view would be found through the “Show View” popup as follows:
My Category -> Sub Folder -> My View
I know you can do this with exports/imports, but it doesn’t seem like you can with views.
Here is a sample plugin.xml
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<extension
point="org.eclipse.ui.views">
<category
name="My Category"
id="My_Category">
</category>
<category
id="My_Sub_Folder"
name="Sub Folder"
parentCategory="My_Category">
</category>
<view
name="My View"
icon="icons/sample.gif"
category="My_Sub_Folder"
class="sample_plugin.views.SampleView"
id="sample_plugin.views.SampleView">
</view>
</extension>
</plugin>
However, when I use the plugin.xml above, the view category does not show up and the view is found in the “Other” category. If I change the view category back to “My_Category”, the view shows up in the parent category.
(revised answer)
You can set up a parent category hierarchy, but the Show View menu will not respect this.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=92894
So the answer is effectively no.
Here is the documentation on setting up the useless parent category:
http://help.eclipse.org/helios/topic/org.eclipse.platform.doc.isv/reference/extension-points/org_eclipse_ui_views.html