是否可以将一些 View 放置到布局的底部(1),然后将另一个 View 放置到剩余空间的左侧部分(2)?
整个面积为 3。
最佳答案
是的,看看IPageLayout
JavaDoc 。它应该在您的透视图的 IPerspectiveFactory.createInitialLayout(IPageLayout)
中设置。稍微修改一下给出的示例:
public void createInitialLayout(IPageLayout layout) {
// Get the editor area.
String editorArea = layout.getEditorArea();
// Bottom left: Outline view and Property Sheet view
IFolderLayout bottom = layout.createFolder("bottom", IPageLayout.BOTTOM,
0.25f, editorArea);
bottom.addView(IPageLayout.ID_OUTLINE);
// Top left: Project Explorer view and Bookmarks view placeholder
IFolderLayout topLeft = layout.createFolder("topLeft", IPageLayout.LEFT, 0.25f,
editorArea);
topLeft.addView(IPageLayout.ID_PROJECT_EXPLORER);
topLeft.addPlaceholder(IPageLayout.ID_BOOKMARKS);
}
关于java - 如何占用Eclipse UI中的可用空间?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20957507/