Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic ResizeToFitItems doesn't show all diagram items (Read 1877 times)
Rich Cassell
Junior Member
**
Offline


I Love MindFusion!

Posts: 63
Joined: Sep 19th, 2012
ResizeToFitItems doesn't show all diagram items
Mar 28th, 2013 at 9:47am
Print Post  
Hi,

I apologise if this has been asked in the past; i've had a flick through previous posts and found things similar but not exactly what i'm struggling with.

Basically, i am using a treeLayout and after calling Arrange on the diagram i am then calling doc.ResizeToFitItems(5). This works fine in that it moves everything into the viewable area (i.e. moves it down and right so that it's not out of bounds), obviously with a gap of 5.

The problem is, i actually want it to resize the panel so that all items can be seen at the same time. I.e. The scroll bars are not needed. I use the DiagramView zoom facility so after an Arrange i can zoom out until i can see all of the items and the scrollbars disappear - but i'd like it to do this automatically after an Arrange - what am i missing?

Any help would be great!

Cheers,
Rich
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: ResizeToFitItems doesn't show all diagram items
Reply #1 - Mar 28th, 2013 at 10:15am
Print Post  
Hi,

Try also calling DiagramView.ZoomToFit().

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Rich Cassell
Junior Member
**
Offline


I Love MindFusion!

Posts: 63
Joined: Sep 19th, 2012
Re: ResizeToFitItems doesn't show all diagram items
Reply #2 - Mar 28th, 2013 at 10:27am
Print Post  
Hi Stoyan,

Works a treat! Smiley Thanks very much.

Rich
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint