Hi, I am trying to format columns header setting the LabelPresenter like everyone say, the only problem is that border property doesn't work and i can't remove a bottom border that become yellow when mouse is over.
I understood that it is a style applied to theme "LunaNormal" that i don't specified but it is like default theme, I can't get why nobody had this issue!
I hope someone could help me
Thanks, Marco
Hello again,
I am glad I helped you resolve your issue. As for your question, it depends on what you are trying to achieve. If you want to override the whole style or a setting which is not exposed directly by the API it is preferable to do so in order not to lose any of the built-in functionality. Otherwise you just have to set the separate property.
Great! Now it is definitly ok.
I guess every time I need to overwrite a default style I need to do this and copy the whole style code into my application and modify it, right?
Thanks a lot,
Marco
Hello Marco,
Excuse me I didn't clarify this earlier. The Infragistics controls don't use the files provided in DefaultStyles directory for styling. They just use the same styles as in the folder and because of the animation I mentioned earlier, setting the background property, when mouse is over the label, is not enough to get the result you want, so I copied the whole style for the LabelPresenter from the DataPresenterGeneric_Express file and remove the code we discussed earlier. I attached your sample project, so that it now has the functionality you want.
Looking forward for your reply.
Hi Stefan,
I deleted everything you told me, the last part of code and the previous one from the other thread but nothing changed
Maybe I'm doing something wrong, I just open the file and delete specified code, do I have to rebuild something? Is there a way to completely erase the style applied by default?
Thanks again,
I further investigated your issue and I found out that in addition to what is described in the other forum thread you should also delete the lines for highlight and fishHeadHighlight in this code:
<Trigger Property="SortStatus" Value="Ascending"> <Setter TargetName="highlight" Property="Opacity" Value="1"/> <Setter TargetName="fishHeadHighlight" Property="Opacity" Value="1"/> <Setter TargetName="SortIndicator" Property="Visibility" Value="Visible"/> </Trigger> <Trigger Property="SortStatus" Value="Descending"> <Setter TargetName="highlight" Property="Opacity" Value="1"/> <Setter TargetName="fishHeadHighlight" Property="Opacity" Value="1"/> <Setter TargetName="SortIndicator" Property="Visibility" Value="Visible"/> </Trigger>
which is in the LabelPresenter default style, too. Please let me know if this clarify your issue or you need any further assistance on this matter.