Resize views in a perspective [message #460293] |
Tue, 19 December 2006 04:43  |
Eclipse User |
|
|
|
Hi,
Can any one suggest me ways to resize view in a perspective
programatically.
i have even used perspective class and perspective extension point in my
plugin.xml.Still the view is not coming correctly.I have given
ipagelayout.top|ipagelayout.left but the view is not coming at the
specified position.
i also want to resize my view size in the perspective.
Thanks in advance
krishna
|
|
|
Re: Resize views in a perspective [message #460306 is a reply to message #460293] |
Tue, 19 December 2006 07:40  |
Eclipse User |
|
|
|
A view always takes a percentage of the "relative" view. ex: if you want
an editor and 3 views of equal size down the side:
String editorArea = layout.getEditorArea();
addView(String viewId, int relationship, float ratio,
String refId);
layout.addView(IPageLayout.ID_BOOKMARKS, IPageLayout.RIGHT,
(float) 0.33, editorArea);
layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.BOTTOM,
(float) 0.66, IPageLayout.ID_BOOKMARKS);
layout.addView(IPageLayout.ID_TASK_LIST, IPageLayout.BOTTOM,
(float) 0.5, IPageLayout.ID_OUTLINE);
Bookmarks is 33% of the editor area. Outline is 66% of Bookmarks. Then
Tasks is 50% of Outline.
Later,
PW
|
|
|
Powered by
FUDForum. Page generated in 0.05234 seconds