Hi guys,
I need to make StrokeThickness bigger for the relation of the selected tasks. What I want is to make easier for the user to understand each task's dependencies. How can I do it?
Best regards
Paolo
3 Answers, 1 is accepted
0
Hello Paolo,
Thank you for the attached image.
After searching for a possible solution I think I manage to found one. What you can try is to subscribe to the SelectionChanged event. In the event handler, you can get the currently selected task and its dependencies. Then you can find all RelationContainers using ChildrenOfType<T>() method and get the desired one which has the same dependency as the selected task. The final step is to get the Path element with x:Name = ArrowPath and set its StrokeThickness property. I am attaching a sample project which demonstrates this approach.
Hope I was able to help you.
Regards,
Dinko
Progress Telerik
Thank you for the attached image.
After searching for a possible solution I think I manage to found one. What you can try is to subscribe to the SelectionChanged event. In the event handler, you can get the currently selected task and its dependencies. Then you can find all RelationContainers using ChildrenOfType<T>() method and get the desired one which has the same dependency as the selected task. The final step is to get the Path element with x:Name = ArrowPath and set its StrokeThickness property. I am attaching a sample project which demonstrates this approach.
Hope I was able to help you.
Regards,
Dinko
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Paolo
Top achievements
Rank 1
answered on 19 Dec 2018, 01:18 PM
Hi Dinko,
first of all, thank you for your response. While I was waiting for a response I find another approch, using the HighlightedItemsSource property. When I select and event I populate that property with the event's dependencies and "voiltà " my user knows everything. I will try your solution to see which one is better.
Question: how can i change the background color of the highlighted objects? I cannot find the style to override....
Best regards
Paolo
0
Hello Paolo,
Indeed you can use the HighlightedItemsSource. Changing the highlighted items background could be possible by overriding the default template of the EventContainers. You can take a look at the Editing Control Templates help article which describes how you can get the default template of the controls. In the extracted template you can navigate to a Border with x:Name="HighlightVisual" and change its Background and BorderBrush properties.
Regards,
Dinko
Progress Telerik
Indeed you can use the HighlightedItemsSource. Changing the highlighted items background could be possible by overriding the default template of the EventContainers. You can take a look at the Editing Control Templates help article which describes how you can get the default template of the controls. In the extracted template you can navigate to a Border with x:Name="HighlightVisual" and change its Background and BorderBrush properties.
Regards,
Dinko
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.