Prevent resizing Views in a Perspective [message #447139] |
Wed, 29 March 2006 14:09  |
Eclipse User |
|
|
|
I am trying to create a top panel with a fixed height.
The following snippet gives the desired effect but it doesn't prevent the user to resize and change the height of the view. Is it possible (as in Swing BorderLayout) to set a fixed height for the top panel and leave the remaining height for the others?
<pre>
layout.addStandaloneView(Navigation.View.ID_VIEW,
false,
IPageLayout.TOP,
0.0f,
IPageLayout.ID_EDITOR_AREA);
IFolderLayout center = layout.createFolder("Center",
IPageLayout.BOTTOM,
1.0f,
IPageLayout.ID_EDITOR_AREA);
</pre>
Thanks
|
|
|
|
Re: Prevent resizing Views in a Perspective [message #447735 is a reply to message #447726] |
Thu, 13 April 2006 14:34  |
Eclipse User |
|
|
|
Its also possible to override
ApplicationWorkbenchWindowAdvisor.createWindowContents and add other
items to the Shell around the workbench area. There is an example of
this in the RCP book:
http://www.amazon.com/gp/product/0321334612/sr=8-1/qid=11449 53108/ref=pd_bbs_1/102-3050529-6118538?%5Fencoding=UTF8
The only caveat is that there is some lost functionality when you do
this. For example, I believe the fast view area on the status bar
cannot be used when this method is overriden.
Cuneyt Karul wrote:
> I don't think Eclipse supports this at all. I wanted to document the workaround I used to overcome the issue in case someone else needs it:
>
> Instead of using a view at the top position and trying to prevent users resizing it, we went with a CoolBar at the top where we added the visual components using
>
> fillCoolBar(ICoolBarManager coolBar) method in WorkbenchAdvisor implementation.
>
> We still have an issue of setting the coolbar height to an arbitrary value but, overall it served the purpose.
|
|
|
Powered by
FUDForum. Page generated in 0.09623 seconds