all groups > flash actionscript > september 2005 >
You're in the

flash actionscript

group:

CSS Verification?



Re: CSS Verification? Christopher Hayes
9/13/2005 3:28:55 PM
flash actionscript: Flash doesn't support a background color.

Check this out for the CSS properties Flash DOES support:

http://www.actionscript.org/tutorials/beginner/css_in_flash/index.shtml


- Chris Hayes

Re: CSS Verification? Christopher Hayes
9/13/2005 4:16:06 PM
However, the TextArea Component supports background colors.

Add a TextArea Component to your movie and then in the properties window
click on the questionmark and then Help on This Component. (or just search
for TextArea in help) . This will give you a list of supported properties.

- Chris

CSS Verification? Raconteur
9/13/2005 6:19:41 PM
Hi all,

I have an HTML file that I am loading into a multiline textbox in MX. I want
to attach a style-sheet to the textbox so I can have each line of text
alternate between no backgroun color and a set bg color.

My stylesheet contains:

.alternating {
background-color: "#DDDDDD";
}

In my HTML file I have:

<span class="alternating">Some text here</span>

And I am loading my stylesheet in the first frame of the scene with:

var styles = new TextField.StyleSheet();
styles.load("styles.css");
myTxtBox.styleSheet = styles;

Should this work or not? I do not get any color at all. I have even tried
altering the <P> tag in the CSS to color red but that doesn't seem to work
either, which makes me think that I am probably doing something wrong.

Anyone have any ideas or any examples of this working?

Cheers,

Chris



Re: CSS Verification? Raconteur
9/13/2005 10:58:47 PM
Hi Christopher,

Thanks for the info. It sounds like (I haven't looked yet) the TextArea
control supports a general background color. Is that right?

Basically what I am trying to do is make some text more readable by having
each line appear in an alternating color, so I either need a table control, or
some way to mark up the HTML to handle it.

Any ideas?

Cheers,

Chris
Re: CSS Verification? Christopher Hayes
9/14/2005 10:09:49 AM
You may be able to do it using TexFormat.tabStop. Checkout this for more
info: http://www.emllabs.com/article.php?articleId=104

I would look at V2Components.com...they have an XHTML TableRenderer that
would solve your problem. There are other components out there also.

It may be able to be done in the Flash TextArea component, but don't have
the time to try it out right now.

Good Luck,

Chris


AddThis Social Bookmark Button