英文:
Target ID for XML Perspective
问题
I want my views to be available only when the XML perspective is chosen. I know I can specify this by changing the target ID of the view in the plugin.xml file, but I cannot find the target ID for the XML perspective. Does anyone know the target ID for the XML perspective?
英文:
I am creating an eclipse PDE plugin with multiple views. I want my views to be available only when the XML perspective is chosen. I know I can specify this by changing the target ID of the view in the plugin.xml file, but I cannot find the target ID for the XML perspective. Does anyone know the target ID for the XML perspective?
<extension
point="org.eclipse.ui.perspectiveExtensions">
<perspectiveExtension
targetID="org.eclipse.jdt.ui.JavaPerspective">
<view
id="asher.views.id.SampleView"
relative="org.eclipse.ui.views.ProblemView"
relationship="right"
ratio="0.5">
</view>
</perspectiveExtension>
答案1
得分: 0
你的视图将始终在每个视角中可用,但你要查找的 ID 是 "org.eclipse.wst.xml.ui.perspective"。你可以在 https://github.com/eclipse/webtools.sourceediting/blob/9a52e4d9b40b6340b0e2c72ee523bf603881cfb1/xml/bundles/org.eclipse.wst.xml.ui/plugin.xml#L1489 找到它的声明。
英文:
Your view will always be available in every perspective, but the ID you're looking for is "org.eclipse.wst.xml.ui.perspective". You can find where it's declared at https://github.com/eclipse/webtools.sourceediting/blob/9a52e4d9b40b6340b0e2c72ee523bf603881cfb1/xml/bundles/org.eclipse.wst.xml.ui/plugin.xml#L1489
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论