Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Sizing the diagram object? (Read 3323 times)
Rob
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Mar 7th, 2012
Sizing the diagram object?
Mar 8th, 2012 at 9:26pm
Print Post  
How do I specify the size of the diagram?  I see there's a Bounds member that will tell me what the current bounds are, and there's a ResizeToFit that will shrink it down (in my case, it's shrinking too much and cropping objects).   

I know the size of the diagram I'm programmatically drawing.  I set the view size appropriately.   But I can't seem to figure out a way to get rid of the scroll bar that appears, because the diagram height is way higher than I want it to be.   If I can resize to fit, is there a method to simply specify the size I want?

  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Sizing the diagram object?
Reply #1 - Mar 9th, 2012 at 1:53pm
Print Post  
You can set diagram.Bounds to a RectangleF instance on the server, or call diagram.setBounds(new MindFusion.Drawing.Rect(x,y,w,h)) on the client. ResizeToFitItems works fine from what I can see, are you sure there aren't any new items added after it's called? You might also try calling diagram.resizeToFitItems() on the client.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint