Dear all,
I have a small issue with the UltraTextEditor buttons. When I add a button (or many) and select the textbox portion of the control to insert text the button(s) background colour changes from the default (white) to that in the image.
I have the DisplayStyle set to Office2010 and I've tried things such as always being in edit mood and not using OS themes. I've even looked into editing the isl file (but can't seem to find the Office2010.isl only Office2010Blue.isl, silver and black). I've also put code into the Enter, Leave, BeforeEnterEditMode and BeforeExitEditMode events to check the button BackColor and it's always 'Empty'.
What I am wanting is for the buttons to behave like StateButtons, i.e. they have a pressed, unpressed and mouse over colour. I don't want the colour of the buttons to change because the control has focus. Is this possible, or will I have to take the buttons out of the editor (which is not a big deal)?
Regards and thanks.
Hi,
Office2010 supports three different themes. So there's no such thing as just Office2010. By default, I think the controls use the Blue theme.
The reason the isl file specifies a particular theme is because not all of the Infragistics WinForms controls natively support Office2010 style. So the isl file theme-specific styling to those controls.
I've set the DisplayStyle to be Office2010. Perhaps I wasn't clear in my original post, I've set the DisplayStyle of the ultraTextEditor to be Office2010. So I imagine that is the cause.
The *.isl I'm wanting to find is for that style. Is it that all three (Black, Blue and Silver) have the same ultratextEditor style hence the dropping of the colour from it's name?
If set UseAppStyling to false had no effect then you must also be setting a property on the control that is causing this. Maybe ButtonDisplayStyle or DisplayStyle on the control.
B_D said:Out of curiosity which isl file contains the style information for Office2010?
There are three:
Office2010Black.isl
Office2010Blue.isl
Office2010Silver.isl
Hi Mike,
Thanks for the suggestions, I tried both (and combined them) without success:
ultraTextEditor1.StyleLibraryName = "Dummy.isl";
ultraTextEditor1.UseAppStyling = false;
I tried this at both design and run time (in the constructor for the control which contains the ultraTextEditor).
It's no big issue to take out the buttons I was just curious if this was possibly. I did suspect it was something to do with the isl and therefore probably not fixable in code. Out of curiosity which isl file contains the style information for Office2010?
If you are loading an isl file, then nothing you do in code will have any effect. The isl file takes precedence. So if you want to change this behavior, you will probably have to modify the isl file.
Alternately, you could tell the control not to honor the isl either by setting UseAppStyling on the control to False, or by assigning a StyleLibraryName to any arbitrary string that doesn't actually exist as a loaded isl. Using StyleLibraryName you could also point some controls to a completely different isl, if you like.