I’m having a problem with extra lines being added to my text anytime the stylesheet is applied?? Check this out and please let me know what the problem is.
Here’s the actionscript:
this.createTextField(“bodytxt”, 0, 50, 30, 430, 200);
bodytxt.html = true;
bodytxt.border = true;
bodytxt.wordWrap = true;
bodytxt.multiline = true;
var format = new TextField.StyleSheet();
var path = “stylesheet.css”;
var quick = “<p align=‘center’>TESTING CENTER<br /><strong>TESTING BOLD</strong><br /><u><font color=’#ff0000’>TESTING RED UNDERLINE</font></u><br /><em>TESTING ITALIC</em><br />Just regular text</p>”;
format.load(path);
format.onLoad = function(loaded) {
if (loaded) {
trace(“css loaded”);
bodytxt.styleSheet = format;
bodytxt.htmlText = quick;
} else {
bodytxt.htmlText = “Error loading CSS file!”;
}
};
Here’s the css:
b, strong {font-weight: bold; color: #396780;}
i, em {font-style: italic;}