Sascha is right, the Image Navigator view [1] implements the 
berry::ISizeProvider interface [2]. As far as I understand the code, it just 
constrains the height of the view and intentionally is flexible in its width. 
The interface allows for restrictions in both directions though. There's also a 
hint in the documentation of the berry::IViewPart interface [3]. However, the 
documentation states that it is still a *preferred* size and it is not 
guaranteed. For example, it wont work if there are multiple views (with 
constraints?) in the same stack.

[1] 
https://github.com/MITK/MITK/blob/master/Plugins/org.mitk.gui.qt.imagenavigator/src/internal/QmitkImageNavigatorView.cpp#L154
[2] 
https://github.com/MITK/MITK/blob/1056bf6d459b18b9996e2cd9f44f588a704810f8/Plugins/org.blueberry.ui.qt/src/berryISizeProvider.h
[3] 
https://github.com/MITK/MITK/blob/1056bf6d459b18b9996e2cd9f44f588a704810f8/Plugins/org.blueberry.ui.qt/src/berryIViewPart.h#L61
________________________________________
Von: Pukhlikov Mikhail [mikhail.pukhli...@outlook.com]
Gesendet: Freitag, 30. Oktober 2015 13:42
An: Sascha Zelzer; mitk-users@lists.sourceforge.net
Betreff: Re: [mitk-users] is it possible to make static width for pugin

Hello

But image navigator scales like other plugins

________________________________
Date: Fri, 30 Oct 2015 12:32:31 +0000
Subject: Re: [mitk-users] is it possible to make static width for pugin
From: sascha.zel...@gmail.com
To: mikhail.pukhli...@outlook.com
CC: mitk-users@lists.sourceforge.net; s.kislins...@dkfz-heidelberg.de


It is possible in BlueBerry. I don't remember the exact location. Either in the 
view extension point or the PageLayout class used in an application Window 
advisor. Look at the image navigator view for an example.

Am 30.10.2015 13:12 schrieb "Pukhlikov Mikhail" 
<mikhail.pukhli...@outlook.com<mailto:mikhail.pukhli...@outlook.com>>:
Thanks

but sadly parent->setMaximumWidth doesn't help and parent->parentWidget returns 
Access violation - I need some way to have *static* plugin - is the only way to 
achieve it is to modify blueberry?

________________________________
From: s.kislins...@dkfz-heidelberg.de
To: mikhail.pukhli...@outlook.com<mailto:mikhail.pukhli...@outlook.com>; 
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Date: Fri, 30 Oct 2015 12:57:00 +0100
Subject: RE: [mitk-users] is it possible to make static width for pugin


Hi,



it is not possible or at least shouldn’t be possible by design. Views are 
framed within BlueBerry controls which make up a *flexible* UI framework. 
However, there might be possibilities to circumvent that. Have you tried to set 
a maximum size for your top-level widget?



Best,

Stefan


From: Pukhlikov Mikhail 
[mailto:mikhail.pukhli...@outlook.com<mailto:mikhail.pukhli...@outlook.com>]
Sent: Freitag, 30. Oktober 2015 11:17
To: mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
Subject: [mitk-users] is it possible to make static width for pugin

Hello

Can I create plugin with static width? unresizeable

Thank you

------------------------------------------------------------------------------

_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net<mailto:mitk-users@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/mitk-users

------------------------------------------------------------------------------
_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to