Using Flex 4 with the Flex 3 ‘Halo’ Theme
With Flex 4 comes “Spark”: a much more “flexible” (haha), and in my opinion much less beautiful theme than the one in Flex 3. Of course, you can use Spark to create all sorts of beautiful things, but if you’re looking for something pretty out of the box, it’s not that.
The Flex 3 theme is called “Halo”, and as described here, you can still use it in your application with the inclusion of a compiler argument:
-theme=${flexlib}/themes/Halo/halo.swc
However, I found that there is an annoying bug whereby a warning message is now shown when you compile the application.
frameworks/libs/framework.swc$defaults.css(488): Warning: The style 'dropShadowVisible' is only supported by type 'mx.controls.List' with the theme(s) 'spark'.
I realize it’s a deplorable hack, but my simple solution is as follows. Open framework.swc (it’s just a zip file), and edit defaults.css. Comment out or delete line 488, save it back to framework.swc, and voilà! No more nasty warning.











1 comment
Hi, thanks very much for the tip, it helped me with a similar problem with version 4.5.1 of the Flex SDK – I kept getting the warning “The style ‘backgroundColor’ is only supported by type
‘spark.components.Panel’ with the theme(s) ‘spark, mobile’ until I edited defaults.css in frameworks/libs/spark.swc. I don’t know why I was getting this warning – Google didn’t show me anyone else with the same problem. But anyway, it’s fixed now. That ‘-theme=…’ snippet was a lifesaver too (and what brought me here). Cheers!
Leave a Comment