Change size of Panel window



Hi everyone,

I have a panel that opens in a new window. The point is this window has some default size that cuts off my content.

And I don’t see how to change the window size. I tried to set static width/height for my control, but it seems like panel window does not react to content size.

Does anybody know if there is a way to set an initial size for the panel window so content would be fully displayed?

I use RhinoCommon Rhino.UI.Panels class to show/hide the panel.


(Dale Fugier) #4

Hi @Yuliya,

What are you using for your panel class? Windows.Forms, WPF, or Eto?

The host panel container does not care about the panel size, it is a modeless, docking container and can be morphed into many shapes and sizes depending on where the user moves the panel. The best practice it to use a scrolling panel as your top level control.

– Dale

(Przemysław Doliwa) #5

I know topic is old but think it relates to my question. Is there any way to set min width to panel ? lets say my ui overlaps at 150px and it doesn’t make sense to use it in that form so i want to have it always not less than for eg. 200px

(Dale Fugier) #6

Hi @D-W,

Because panels can be docked in other panel, and those other panels will be of differing sizes, its best to make the controls in you panel size correctly in all situations.

Or am I confused by your question?

– Dale

(Przemysław Doliwa) #7

No i think you know what i mean but when i have 6 butons in horizontal alignment 3 are docked to left 3 to right when panel is @ 150px they starts to ovelap so i thought easiest way to prevent this would be setting min width. Anyway i think no matter what kind of panel options but for eg when panel is 50px wide theres no way to use there any option.

(Dale Fugier) #8

Hi @D-W,

Are you using Eto, WinForms, etc.?

– Dale

(Przemysław Doliwa) #9

@dale WinForms with WPF host but i’m concidering now to switch to WPF entirely - I don’t use Eto cause i need to support v5 still.

Btw. is there any difference in handling wpf in rhino ?

(Dale Fugier) #10

Difference compared to WPF outside of Rhino? No.

– Dale