Articles in this section
Category / Section

Zoom the Diagram based on the Focus Point

1 min read

In diagram control, to Resize the model there are more number of options available. Those options are differentiated by the Type and constraint (enabling/disabling “SizeToContent” property) which are listed in below.

 

Model’s LogicalSize property

 

Using Model’s LogicalSize property we can Assign/Resize the size of the Model type as System.Drawing.SizeF. The following code illustrates to resize the Model.

 

[C#]

 

diagram1.Model.LogicalSize = new SizeF(500, 500);

 

[VB]

 

diagram1.Model.LogicalSize = new SizeF(500, 500)

 

Model’s DocumentSize property

 

This property is also used to Assign/Resize the size of the Model type as Syncfusion.Windows.Forms.Diagram.PageSize . The following code illustrates to resize the Model.

 

[C#]

 

diagram1.Model.DocumentSize = new PageSize(500, 500);

 

[VB]

 

diagram1.Model.DocumentSize = new PageSize(500, 500)

 

Model’s MinimumSize Property

 

This property is used to set the minimum size of the Model under the type of System.Drawing.SizeF. But this property is used only when the Model’s SizeToContent property is enabled. Otherwise, it is not considered by the diagram. The following code illustrates to how to set minimum size value.

 

[C#]

 

diagram1.Model.MinimumSize = new SizeF(300, 300);

 

[VB]

 

diagram1.Model.MinimumSize = new SizeF(300, 300)

 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied