Yes, a plain UITextField has the same white box. 
Here's a link:
http://therichardsonnyc.com/images/TestFlex.swf

I can't even see it on my mac. 

If I used getStyle(), I'd have to do that for every property I wanted
to set on the TextFormat object. 
textFormat.bold = css.getStyle("fontWeight"); 
etc. 

Thanks for your help, Alex.

--- In [email protected], Alex Harui <[EMAIL PROTECTED]> wrote:
>
> Does a plain UITextFIeld also have the white box?  Can you post a
simple test case?
> 
> Instead of reading the factory, why not just call getStyle() on  the
 cssstyledecl.  We have equivalent code in UITextField
> 
> From: [email protected] [mailto:[EMAIL PROTECTED]
On Behalf Of giannif17
> Sent: Thursday, September 11, 2008 3:25 PM
> To: [email protected]
> Subject: [flexcoders] Re: Regular TextField styling.
> 
> 
> There is a subtle translucent white box surrounding my Label
> component. You can hardly see it, but it's there. It's pretty much
> invisible on my mac, but on my pc you can see it more clearly. Our
> designers are quite picky about it. A good comparison is a canvas with
> backgroundColor white, and backgroundAlpha ".01".
> 
> I don't see a ready event for the factory on CSSStyleDeclaration, all
> the properties I need are actually in a protected var called
> overrides, because when the stylesheet loads, setStyle is called.
> There won't ever be a factory. If I could just get at that overrides
> property...
> 
> Any help is appreciated.
> 
> --- In
[email protected]<mailto:flexcoders%40yahoogroups.com>, Alex
Harui <aharui@> wrote:
> >
> > UITextField is just a subclass of TextField. What doesn't it do
> correctly? I'm not sure what you mean by transparent box.
> >
> > If factory is null, you should run that code when the factory is
> ready. There should be an event for that.
> >
> > From:
[email protected]<mailto:flexcoders%40yahoogroups.com>
[mailto:[email protected]<mailto:flexcoders%40yahoogroups.com>]
> On Behalf Of giannif17
> > Sent: Thursday, September 11, 2008 2:10 PM
> > To: [email protected]<mailto:flexcoders%40yahoogroups.com>
> > Subject: [flexcoders] Regular TextField styling.
> >
> >
> > The UITextFields that are used in Flex Text components have some
> > rendering issues that the basic ActionScript TextFields don't have.
> >
> > I want to use TextField, and set its style based on a style that's
> > available in the StyleManager, but can't make the connection.
> >
> > This is what I did, it works in my test app, but not in my production
> > app, because the factory is null (I'm loading the CSS swf at runtime).
> >
> > Is there another way to achieve this:
> > var css:CSSStyleDeclaration =
> > StyleManager.getStyleDeclaration(".myTextField");
> > var f:Function = css.factory;
> > var styleObj:Object = new f();
> > var s:StyleSheet = new StyleSheet();
> > var fmt:TextFormat = s.transform(styleObj);
> > var tf:TextField = new TextField();
> > tf.defaultTextFormat = fmt;
> >
> > I'm hoping there's a simple way to do this that I'm just overlooking.
> >
> > Oh, and the UITextFields have a slight transparent box around them
> > when using embedded fonts. If anyone knows how to fix that, I'd
> > definitely prefer that solution.
> >
>


Reply via email to