We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Symbol resizing

Thread ID:

Created:

Updated:

Platform:

Replies:

18643 Sep 6,2004 08:18 AM UTC Oct 14,2004 05:19 PM UTC WinForms 4
loading
Tags: Diagram
Georg Schmidt
Asked On September 6, 2004 08:18 AM UTC

How do I control resizing of different shapes (Lines, RoundRect, ...) in a customized symbol? Thanks for help.

Administrator [Syncfusion]
Replied On September 8, 2004 12:29 PM UTC

Hi Georg, The Model''s BoundsChanged event is fired whenever any node is resized and you can use this event to do what you are seeking. You can refer to the sample posted in this posting for more details. Regards, Arun

Administrator [Syncfusion]
Replied On October 14, 2004 10:38 AM UTC

If I do not want to drag-move a link node(but let click to select it), How do I put code in (what) event ? Thanks, >Hi Georg, > >The Model''s BoundsChanged event is fired whenever any node is resized and you can use this event to do what you are seeking. > >You can refer to the sample posted in this posting for more details. > >Regards, >Arun >

Administrator [Syncfusion]
Replied On October 14, 2004 12:33 PM UTC

Hi You can set the Link''s EditStyle.AllowMove property to false to prevent links from being moved. Here is a code snippet: //Custom Link protected Link CreateLink(PointF[] pts) { Link link = new Link(Link.Shapes.Line, pts); link.EndPoints.LastEndPointDecorator = new EndPointDecorator(EndPointVisuals.ClosedArrow); // Links cannot be moved link.EditStyle.AllowMove = false; return link; } //Create and Register the Link Tool for the custom link Tool linkTool = this.diagram1.Controller.GetTool("LinkTool"); ((LinkTool)linkTool).LinkFactory = new LinkFactory(this.CreateLink); this.diagram1.Controller.RegisterTool(linkTool); //Activate the Link Tool this.diagram1.ActivateTool("LinkTool"); Regards Arun

Administrator [Syncfusion]
Replied On October 14, 2004 05:19 PM UTC

Thank you! It works. >Hi > >You can set the Link''s EditStyle.AllowMove property to false to prevent links from being moved. Here is a code snippet: > >//Custom Link >protected Link CreateLink(PointF[] pts) >{ >Link link = new Link(Link.Shapes.Line, pts); >link.EndPoints.LastEndPointDecorator = new EndPointDecorator(EndPointVisuals.ClosedArrow); >// Links cannot be moved >link.EditStyle.AllowMove = false; >return link; > >} > >//Create and Register the Link Tool for the custom link >Tool linkTool = this.diagram1.Controller.GetTool("LinkTool"); >((LinkTool)linkTool).LinkFactory = new LinkFactory(this.CreateLink); >this.diagram1.Controller.RegisterTool(linkTool); > >//Activate the Link Tool >this.diagram1.ActivateTool("LinkTool"); > >Regards >Arun >

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;