I have a bunch of formatted text in a UFTE which have multiple highlights and other formatting, and when I go to change the font for the whole editor only the already formatted areas pick up the change. I have used the ApplyStyles method with everything selected; I have tried to use the Apperances property, but nothing will apply the font change to the whole Control. What should I be using.
Thanks,
blair
I fixed it. Arrgh I hate this app. Too much multithreading is going on.
I did, but I need to solve this ASAP (we are dropping the update onto our production servers early next week). Here is the output from the Value property of the UTFE after calling ApplyStyles.
<p style="font-family:Tw Cen MT Condensed;"><span style="font-style:italic; font-weight:bold;">This is a <span style="color:Blue; background-color:Yellow;">User Hilited</span> section of the Document. This is a <span style="color:Lime; background-color:Red;">LifeCode® Hilited</span> section of the Document.</span></p>
If I load it into the HTML Debugger Visualizer in VS 2008 it looks right but in the UTFE the <p> tag is not being applied to the whole block. I am at a loss.
I'm not sure what the problem is then, in this case. I tried adding a few paragraphs of text, with a bunch of nested formatting in various places and still this exact code worked for me. I would first ensure that you have the latest hotfix installed, and if you still have the problem you should submit a small sample to Developer Support so that they can see if they can spot anything.
-Matt
I already tried that and it doesn't work for me. It still only applies the new style to the already formatted internal areas. I need it to work as a global setting around all of the text. Also as an FYI all of my documents are at least 2-3 pages long with a lot of formatting.
Blair,
The following code worked for me to apply the style across all my text when nothing was selected:
this.ultraFormattedTextEditor1.EditInfo.ApplyStyle("font-family:Algerian;", true);
The original value of the editor was:
ultra<span style="font-family:Arial;">For</span><span style="font-weight:bold;">matte</span><span style="font-size:+2pt;">dTex</span>tE<span style="text-decoration:underline;">ditor1</span>