We are facing issue with drag indicator of telerik grid view header cell. Previously when we used to drag header cell to reorder columns, the drag indicator was showing copy of header cell attached to cursor and which was semi transparent.
Now we have implemented silverlight implicit styling. So in application resources we have implicit style for Grid and Rectangle. After this change, drag indicator is showing solid colors. It is not coming semi transparent.
I guess the template for drag indicator is inbuilt created in telerik. Do we have feature where we can set template for drag indicator explicitly? or is there any other work around for this issue?
6 Answers, 1 is accepted
When you define styles in App.xaml they are applied to all rectangles and all grids in this application. However you may override this behavior by creating a simple targeted at a Rectangle element on a RadGridView level and it will be applied to these elements residing in the grid. Thus the style defined in the Application's Resources will be ignored. Please try the following makrup and let me know how this works for you:
Also you may submit a new support ticket where you can attach sample application where we can see what is going on.
All the best,
the Telerik team
Thanks for reply.
I tried given solution, but it didn't work for me. As i see, the drag element always refer to resources under Application file and not local resources. As it seems this element get added to Root container and not in user control or gridview control. Hence it takes styles from parent which is application root. I have also tried creating implicit DraggedElement style which is used for drag indicator. Even after removing all contents in ControlTemplate of DraggedElement style it uses implicit style of grid for its background. The Background setter property of this style is set to Transparent and seems to be not working.
The DataContext assigned is dummy data context assigned from Blend.
Generally in RadGridView and all its parts the Grid layout control is used in the templates (and within its internal logic) of RadGridView and you may see that even with this style that the DraggedElement stays bluish in some kind. Do you actually need to use this implicit style targeted at Grid control? In my opinion it is better to remove it from App.xaml in order to avoid any future issues that you might already have.
Please let me know how this works for you!
the Telerik team
Unfortunately removing implicit style is not possible, since this is large scale application and already in production. This change will need lot of changes and testing again. So is there any possible way to tackle this.
Like i see in silverlight data grid, dragged indicator is never moves beyond its header boundaries. Is there any other property in telerik grid view which gives same behavior. In that case its parent will be grid control and not application container. That should resolve this issue.
I have prepared simple application that demonstrate how to achieve the desired behavior throughout the application. Please have a look at the sample project and let me know if this fits into your scenario.Regards,
the Telerik team
Thanks for sample. I've checked the given sample application and it is working fine. However it will take time to implement it in actual project, because we will need to see performance impact and impact on other drag and drop elements. Also as you have mentioned previously, we are getting more issues with other controls like telerik popup control because of implicit styling. So i am going to open support ticket for all other issues at once.
Thanks for your support