Connection manipulation points

6 posts, 0 answers
  1. Gerhardt
    Gerhardt avatar
    7 posts
    Member since:
    Jul 2012

    Posted 26 Jul 2012 Link to this post

    Hi.

    I'd like to be able to add more manipulation points to a RadDiagramConnection programmatically. Is this possible and how would I go about doing it?

    Regards.
  2. Alex Fidanov
    Admin
    Alex Fidanov avatar
    636 posts

    Posted 26 Jul 2012 Link to this post

    Hello Gerhardt,

     We have been considering this since the beta release of the diagrams. Currently, we have exposed manipulation points only for the start and end points. We are planning to provide manipulation points also for the corners and the straight parts of a polyline connection. I am not sure if we will be able to squeeze this feature for this release, but we are definitely going to plan this for next release.

    I think it would be possible to create this manually on your side. The connection uses the ConnectionPoints collection property to store its route information. If you want to be able to modify the connection with manipulation points, you would have to modify the points in the ConnectionPoints collection. However, you would need a custom router, that will take into consideration that the points have been modified and should not be re-routed. You can see how to create and wire a custom router in our online OrgChart example. You can use the IsModified property as a flag for this. Finally, if you want to be able to manipulate the connection from the UI, you would have to create an adorner, similar to the other adorners in the diagram.

    Please let us know if you have further questions on need any other directions, if you want to take this path and decide to implement this feature.

    Greetings,
    Alex Fidanov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. UI for WPF is Visual Studio 2017 Ready
  4. Gerhardt
    Gerhardt avatar
    7 posts
    Member since:
    Jul 2012

    Posted 26 Jul 2012 Link to this post

    Than you for your reply Alex.

    Can you please elaborate on the following: "you would need a custom router, that will take into consideration that the points have been modified and should not be re-routed"

    I've had a look at the OrgChart example but I don't exaclty know what to look for.
    Regards.
  5. Alex Fidanov
    Admin
    Alex Fidanov avatar
    636 posts

    Posted 27 Jul 2012 Link to this post

    Hi,

     The router gets hooked up to the diagram through the Diagram.RoutingService.Router property. You can see this in the OrgChartExample.xaml.cs file. For a custom router, you must implement the IRouter interface and its GetRoutePoints method. Another option is to subclass one of our built-in routers (like GridRouter, OrgTreeRouter) and override the GetRoutePoints.

    Kind regards,
    Alex Fidanov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  6. Gerhardt
    Gerhardt avatar
    7 posts
    Member since:
    Jul 2012

    Posted 27 Jul 2012 Link to this post

    Thanks Alex.

    I have a few other questions as well, must I log support tickets for each of them, or can I just continue asking them on this thread?

    Regards.
  7. Alex Fidanov
    Admin
    Alex Fidanov avatar
    636 posts

    Posted 27 Jul 2012 Link to this post

    Hi,

     I think that it would be best to continue this as private conversation through the support ticket system. Usually, it is better to have a separate ticket for each stand-alone question, but if they are tightly coupled, it is acceptable to be in one ticket.

    Kind regards,
    Alex Fidanov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top
UI for WPF is Visual Studio 2017 Ready