Tuesday, February 21st, 2006 |
|
TextField.html default in F8 different than F7 |
When publishing for Flash player 8 the html property of a TextField placed on the stage at authortime is true regardless of what you set the property in the Properties inspector.
I tried Googling this but couldn’t find any mention of it. I would consider this a rather important bug, or at least a pretty easy one to fix I’m sure.
Here are the steps to reproduce:
- Select the Text tool.
- Click on the stage so a TextField is created.
- Name the TextField instance: label
- Make sure the html property is not set - the <> button should not be depressed.
- Place the following code in the same frame as the TextField:
trace(label.html);
If you publish for Flash Player 8 the result is true.
If you pubish for Flash Player 7 the result is false.
This really screwed me up on the TextInput component, where I modified the existing component and rebuilt it. Because I published for Flash Player 8, and because the html property is defaulting to true, the text returned is always the HTML version.
Note: This is not an issue for TextFields created at runtime.










I’ve encountered another interesting bug related to flash 7/8 publishing of textfields. If you create an instance of a dynamic textfield on the stage and give it a bold formatting in the property inspector, when published to flash 8 it will ignore the bold property and show the text as normal; published to flash 7 it shows up bold as it should. Which is making me a little hesitant to publish in flash 8, to be sure.
Makes me wonder how many other bugs around the TextField object there are in Flash 8?
use setTextFormat on the specific textField, and all will be fine.
“use setTextFormat on the specific textField, and all will be fine.”
No, that wouldn’t work. setTextFormat will not change the html property nor will it fix the publising to Flash Player 8 so that the DEFAULT setting is the same as Flash Player 7 and 6. You would need to set the html property to false, but that’s not the point at all.
I know how to get around the bug, but it’s still a bug.
“If you create an instance of a dynamic textfield on the stage and give it a bold formatting in the property inspector, when published to flash 8 it will ignore the bold property and show the text as normal; published to flash 7 it shows up bold as it should. Which is making me a little hesitant to publish in flash 8, to be sure.”
sorry I was bit OT, I just tried to help the fella with his problem. (JoeFlash)
I’d agree that it’s a bit confusing with the change, especially when you regularly export to different FP’s.
Bobby666,
Sorry if I sounded like an ass. I had blinders on and missed the connection. Thanks for helping out.
I guess the point I was trying to make is that the html property is not the only property set by the property inspector that that gets negated when exporting to Flash 8; I’ve observed it happening with Bold and Italic settings as well. Which means that implementation of authortime textfields in Flash 8 is buggy (unless it’s a feature they never told us about?
I have just upgraded from Flash 7 to Flash 8 and have come across both this difference and the tabIndex bug in the View class. I also have a large component library which extends the Flash V2 components so I guess thats why we have both found the same issues. If I find any more issues I’ll let you know.