Hi,
I had a similar problem in the past where I had to reassign the data
provider to the combo box - I can't remember exactly what I was doing,
but something to do with hiding / disabling the box messed up the
display of embedded fonts, etc.
Anyway, try that - it might help - hope so.
Glen
Margo Powell wrote:
I think I am missing something really simple.I have been spinning my
wheels this afternoon trying to figure out why my embedded text
disappears when I set my combobox.enabled = false;
If I use default text and disable the combobox, the text appears with
some alpha effect. If I embed text and disable the combobox , the text
disappears.
_Scenario using default text:_
To test, I just place a combobox in a flash page. I add a couple of
items to the combobox and name the combobox test_cb.
test_cb.addEventListener(Event.CHANGE, changeHandler);
function changeHandler(event:Event):void {
test_cb.enabled = false;
}
Everything works hunky dory. The combobox is disabled AND the selected
text item is still visible.
_Scenario using embedded text:_
In my library I create a new font (in my case i used arial bold 12)
and named it ComboFont. Linkage settings to be exported for
actionscript and in frame 1.
In my actions layer:
// Create a new instance of the Font1 symbol from the document's library.
var myFont:Font = new ComboFont();
var myFormat:TextFormat = new TextFormat();
myFormat.font = myFont.fontName;
test_cb.setStyle("embedFonts", true);
test_cb.setStyle("textFormat", myFormat);
// Set dropdown style for comboBox
test_cb.textField.setStyle("embedFonts", true);
test_cb.textField.setStyle("textFormat", myFormat);
test_cb.dropdown.setRendererStyle("embedFonts", true);
test_cb.dropdown.setRendererStyle("textFormat", myFormat);
test_cb.addEventListener(Event.CHANGE, changeHandler);
function changeHandler(event:Event):void {
test_cb.enabled = false;
}
The font looks like it has been embedded, it is much darker.
When the combobox is disabled after an item has been selected, the
text is NOT visible.
I would appreciate any help!
Thanks
Margo
------------------------------------------------------------------------
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders