# Extending css parsing

**URL:** <https://forum.kirupa.com/t/extending-css-parsing/142745>\
**Category:** Uncategorized\
**Created:** [March 31, 2005, 5:45am UTC](https://forum.kirupa.com/t/extending-css-parsing/142745 "2005-03-31T05:45:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![gnative](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/gnative/32/811_2.png) [@gnative](https://forum.kirupa.com/u/gnative)\
**Post date:** [March 31, 2005, 5:45am UTC](https://forum.kirupa.com/t/extending-css-parsing/142745/1 "2005-03-31T05:45:07Z")

</div>

I’ve been looking at this code below to extend the parsing capibilities of flash.( The oringinal is found at [http://www.abdulqabiz.com/blog/archives/flash\_and\_actionscript/000065.php](http://www.abdulqabiz.com/blog/archives/flash_and_actionscript/000065.php)) along with fla and style sheet.

I’ve been trying to define a way of declaring a string with in a property in a css sheet IE .

p{  
name:String;  
}

will this enable me to do it as so far i have been having no luck

```auto
import TextField.StyleSheet;

class StyleSheetEx extends TextField.StyleSheet {
  
  // override the transform method
  function transform(style:Object):TextFormat {
	var _fmt:TextFormat = super.transform(style);
	for (var z in style) {
      if (z == "leading") {
        _fmt.leading = style[z];
		delete style[z];
        break;
      }
    }
	for(var i in _fmt) {
		trace(i + " : " + _fmt*);
	}
   	return _fmt;
  }
}
// end class definition

```

Else is there another way of writing a superclass to enhance what flash looks for the the parsing of a style sheet

Thanks  
Shane
