SlideShare a Scribd company logo
1 of 44
Download to read offline
Styling Adobe Flex 2
                                James Whittaker




Friday, 12 October 2007
A bit of history

                     • Interactive Developer @ Egg since 2006
                     • Previously QinetiQ & Helyx (MoD)
                     • IT & Multimedia degree
                     • Developer - Flex 2 application for Prudential


Friday, 12 October 2007
Why bother styling ?

                     • Corporate branding
                     • Marketing
                     • Differentiate your application
                     • User experience & usability
                     • Remove any reference to Flex !

Friday, 12 October 2007
Styling in the wild




Friday, 12 October 2007
Volkswagen




                          http://www.vw.co.uk/used_cars/find
Friday, 12 October 2007
Volkswagen




                          http://www.vw.co.uk/used_cars/find
Friday, 12 October 2007
Virtual Ubiquity




                          http://www.virtualubiquity.com
Friday, 12 October 2007
Virtual Ubiquity




                          http://www.virtualubiquity.com
Friday, 12 October 2007
Virtual Ubiquity




                          http://www.virtualubiquity.com
Friday, 12 October 2007
Scrapblog




                          http://www.scrapblog.com
Friday, 12 October 2007
Scrapblog




                          http://www.scrapblog.com
Friday, 12 October 2007
Sliderocket




                          http://www.sliderocket.com
Friday, 12 October 2007
Sliderocket




                          http://www.sliderocket.com
Friday, 12 October 2007
Sliderocket




                          http://www.sliderocket.com
Friday, 12 October 2007
Nice, how can we get our
                      apps to look that good ?



Friday, 12 October 2007
What can we use ?

                     • Themes
                     • CSS
                     • Programmatic skins
                     • Graphical skins
                     • Custom components

Friday, 12 October 2007
What is a theme?

                     • At least one CSS file
                     • Programmatic skin (AS3) classes
                     • Graphical skin assets (PNG, SWF etc)
                     • Themes can be compiled as a SWC
                     • Easily distributed

Friday, 12 October 2007
The Halo theme

                     • Smart, corporate visual design
                     • Functional
                     • Visually complete for quick prototyping
                     • Use as an example & override
                                        but...


Friday, 12 October 2007
http://www.flickr.com/photos/dancunningham/




Friday, 12 October 2007
http://www.flickr.com/photos/dancunningham/




                          ! BORING !

Friday, 12 October 2007
What can we do?

                     • Use CSS for style changes
                     • Visual skins - SWF, PNG, JPG
                     • Embed fonts
                     • Program custom skin classes
                     • Use some cool graphics!

Friday, 12 October 2007
CSS in Flex 2

                     • Differences to CSS for XHTML
                     • Used to set styles not properties
                     • You can’t set size or position - they are
                          properties not styles
                     • Setting padding will drive you crazy!
                     • Runtime changing of CSS
Friday, 12 October 2007
Using CSS


                     • Inline with <Style><Style> tags
                     • As MXML attribute < color=”#CC0000”>
                     • External using <Style source=”myStyle.css”
                     • Using ActionScript setStyle()

Friday, 12 October 2007
Applying CSS


         • To the whole application   Application {
                                      }




         • To components ( or custom components )     NewTextLabel {
                                                      }




         • Using class - selectors.rightButton {
                                  }




Friday, 12 October 2007
Use the style explorer




            http://examples.adobe.com/flex2/consulting/styleexplorer/Flex2StyleExplorer.html


Friday, 12 October 2007
Use the style explorer




            http://examples.adobe.com/flex2/consulting/styleexplorer/Flex2StyleExplorer.html


Friday, 12 October 2007
Custom fonts
                    /*-------------------------------------------
                    
    =Fonts
                    ---------------------------------------------*/

                    @font-face {
                                                                      Application {
                    
    src:local(quot;arialquot;);
                    
    fontWeight:normal;                              
 fontFamily: myArial;
                                                                         
 color: #333333;
                    
    fontFamily: myArial;
                    }                                                 
    font-size: 12;
                                                                      }
                    @font-face {
                    
    src:local(quot;arialquot;);
                    
    fontWeight:bold;
                    
    fontFamily: myArial;
                    }




                     • New declaration for differing font weights
                     • Careful, embedded fonts increase SWF size
                     • Better for displaying within SWF
Friday, 12 October 2007
Tip - CSS Organisation
                     • CSS files can become large
                     • Navigation can be tricky
                     • Techniques from HTML CSS
                              /*-------------------------------------------
                              
    =Containers
                              ---------------------------------------------*/



                     • Use search and the first character (=C)
                     • Remember cascading !
Friday, 12 October 2007
Applying styles with AS


                     • Primary example is HTML text
                     • Use StyleSheet object in ActionScript
                     • SetStyle
                     • Apply the StyleSheet to the component

Friday, 12 October 2007
public class StyledText extends Text
                          
    {
                          
    
     private var style:StyleSheet = new StyleSheet();



                          override protected function childrenCreated():void
                              
{
                                 
    
   super.childrenCreated();
                          
    
     
    /* Set up the new stylesheet for the HTML text   */
   
   
                          
    
     
                          
    
     
    var aLink:Object = new Object();
                          
    
     
    aLink.color = quot;#CC0000quot;;
                          
    
     
    aLink.textDecoration = quot;underlinequot;;
                          
    
     
                          
    
     
    var aHover:Object = new Object();
                          
    
     
    aHover.color = quot;#003366quot;;
                          
    
     
    aHover.textDecoration = quot;underlinequot;;
                          
    
     
                          
    
     
    var aActive:Object = new Object();
                          
    
     
    aActive.color = quot;#003366quot;;
                          
    
     
    aActive.textDecoration = quot;underlinequot;;
                          
    
     
                          
    
     
    /* Apply styles */
                          
    
     
    style.setStyle(quot;a:linkquot;, aLink);
                          
    
     
    style.setStyle(quot;a:hoverquot;, aHover);
                          
    
     
    style.setStyle(quot;a:activequot;, aActive);
                          
    
     
    textField.condenseWhite = true;

                                         /* Apply Link listener */
                          
    
    
    this.addEventListener(TextEvent.LINK,linkHandler);
                              
}




Friday, 12 October 2007
HTML Text example

                   • Styled links with HTML behavior
                   • Not full HTML
                   • Can’t set styles with external CSS by default



Friday, 12 October 2007
Skins



                                         http://www.flickr.com/photos/youghal/




                     • Graphical ( SWF, PNG etc )
                     • Programmatic AS3 classes
                     • Applied using CSS
Friday, 12 October 2007
Graphical skin assets
                     • Best to use SWF from Flash
                      • Least file size
                      • Only one file
                      • Easy to use & reference
                      • Use Scale 9 for perfect corners !
                      • Each element as a symbol

Friday, 12 October 2007
Scale 9

                     • Native to Flash, Fireworks & Illustrator
                     • Can be specified in CSS
                     • Has limitations
                     • Watch non-vector images for jagged lines
                          on resize



Friday, 12 October 2007
Scale 9




Friday, 12 October 2007
Styling a button

                     • Set skin for all affected button states
                     • Use an Embed to embed the assets in the
                          main SWF at compile time
                     • State Scale 9 properties or use symbol
                          name ( # )



Friday, 12 October 2007
example




Friday, 12 October 2007
Programmatic Skins

                     • All Halo skins are programmatic
                     • Use Flash drawing API
                     • Can achieve complex results
                     • Smaller file size & faster at runtime
                     • Apply using ClassReference in CSS
                     • Need to know ActionScript
Friday, 12 October 2007
General tips


Friday, 12 October 2007
• Use HBox & VBox for layout - easy to style
                          & extend
                     • Build adaptable components like headers &
                          links
                     • Set naming conventions for MXML, CSS
                          and Assets
                     • Set the default namespace to be blank,
                          loosing the mx: , more like XAML



Friday, 12 October 2007
Resources

                     • http://www.scalenine.com - skins themes
                     • http://www.famfamfam.com - free icons
                     • http://flexdeveloper.eu
                     • http://xd.adobe.com - experience design
                     • http://www.adobe.com/devnet/flex

Friday, 12 October 2007
This presentation is released under Creative Commons
                                      share alike 3.0
                          http://creativecommons.org/licenses/by-sa/2.5/deed.en_GB




                                        http://flexdeveloper.eu/fuguk

                                       http://www.jameswhittaker.com




Friday, 12 October 2007
Thanks
                          Now it’s Q & A time




Friday, 12 October 2007
Friday, 12 October 2007

More Related Content

Viewers also liked

Ce Physics 2000 Paper1(E)
Ce Physics 2000 Paper1(E)Ce Physics 2000 Paper1(E)
Ce Physics 2000 Paper1(E)kit3217
 
Ce Physics 1998 Paper2(E)
Ce Physics 1998 Paper2(E)Ce Physics 1998 Paper2(E)
Ce Physics 1998 Paper2(E)kit3217
 
FITC-review-FUGUK
FITC-review-FUGUKFITC-review-FUGUK
FITC-review-FUGUKjmwhittaker
 
Chemistry 2004 Paper1
Chemistry 2004 Paper1Chemistry 2004 Paper1
Chemistry 2004 Paper1kit3217
 
Ce Physics 2003 Paper1+2(E)
Ce Physics 2003 Paper1+2(E)Ce Physics 2003 Paper1+2(E)
Ce Physics 2003 Paper1+2(E)kit3217
 
Flash Camp - Degrafa & FXG
Flash Camp - Degrafa & FXGFlash Camp - Degrafa & FXG
Flash Camp - Degrafa & FXGjmwhittaker
 
Powerpoint Presentation - Landscape Drawings
Powerpoint Presentation - Landscape DrawingsPowerpoint Presentation - Landscape Drawings
Powerpoint Presentation - Landscape Drawingssuehwa96
 
Landscape architecture drawings Presentation
Landscape architecture drawings PresentationLandscape architecture drawings Presentation
Landscape architecture drawings PresentationLovie Tey
 

Viewers also liked (9)

Ce Physics 2000 Paper1(E)
Ce Physics 2000 Paper1(E)Ce Physics 2000 Paper1(E)
Ce Physics 2000 Paper1(E)
 
Ce Physics 1998 Paper2(E)
Ce Physics 1998 Paper2(E)Ce Physics 1998 Paper2(E)
Ce Physics 1998 Paper2(E)
 
FITC-review-FUGUK
FITC-review-FUGUKFITC-review-FUGUK
FITC-review-FUGUK
 
Chemistry 2004 Paper1
Chemistry 2004 Paper1Chemistry 2004 Paper1
Chemistry 2004 Paper1
 
Ce Physics 2003 Paper1+2(E)
Ce Physics 2003 Paper1+2(E)Ce Physics 2003 Paper1+2(E)
Ce Physics 2003 Paper1+2(E)
 
Flash Camp - Degrafa & FXG
Flash Camp - Degrafa & FXGFlash Camp - Degrafa & FXG
Flash Camp - Degrafa & FXG
 
Powerpoint Presentation - Landscape Drawings
Powerpoint Presentation - Landscape DrawingsPowerpoint Presentation - Landscape Drawings
Powerpoint Presentation - Landscape Drawings
 
Landscape architecture drawings Presentation
Landscape architecture drawings PresentationLandscape architecture drawings Presentation
Landscape architecture drawings Presentation
 
5 Type Of Architecture Design Process
5 Type Of Architecture Design Process 5 Type Of Architecture Design Process
5 Type Of Architecture Design Process
 

Similar to Flex User Group - Skinning Presentation

Performance & Responsive Web Design
Performance & Responsive Web DesignPerformance & Responsive Web Design
Performance & Responsive Web DesignZach Leatherman
 
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style Guides
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style GuidesAdvanced Front End Architecture in D8: Sass, Gulp, & Living Style Guides
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style GuidesAidan Foster
 
Auto tools
Auto toolsAuto tools
Auto tools祺 周
 
Styling components with JavaScript
Styling components with JavaScriptStyling components with JavaScript
Styling components with JavaScriptbensmithett
 
Refresh Tallahassee: The RE/MAX Front End Story
Refresh Tallahassee: The RE/MAX Front End StoryRefresh Tallahassee: The RE/MAX Front End Story
Refresh Tallahassee: The RE/MAX Front End StoryRachael L Moore
 
Html Css
Html CssHtml Css
Html Csspumas26
 
OSML and OpenSocial 0.9
OSML and OpenSocial 0.9OSML and OpenSocial 0.9
OSML and OpenSocial 0.9MySpaceDevTeam
 
Css3 and gwt in perfect harmony
Css3 and gwt in perfect harmonyCss3 and gwt in perfect harmony
Css3 and gwt in perfect harmonyArcbees
 
Learn Sass and Compass quick
Learn Sass and Compass quickLearn Sass and Compass quick
Learn Sass and Compass quickBilly Shih
 
Web applications with Catalyst
Web applications with CatalystWeb applications with Catalyst
Web applications with Catalystsvilen.ivanov
 
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}Eric Carlisle
 
CSS Less framework overview, Pros and Cons
CSS Less framework overview, Pros and ConsCSS Less framework overview, Pros and Cons
CSS Less framework overview, Pros and ConsSanjoy Kr. Paul
 
Developing Your Ultimate Package
Developing Your Ultimate PackageDeveloping Your Ultimate Package
Developing Your Ultimate PackageSimon Collison
 
Optaros Surf Code Camp Lab 2
Optaros Surf Code Camp Lab 2Optaros Surf Code Camp Lab 2
Optaros Surf Code Camp Lab 2Jeff Potts
 
New Elements & Features in CSS3
New Elements & Features in CSS3New Elements & Features in CSS3
New Elements & Features in CSS3Jamshid Hashimi
 
Syntactically awesome stylesheets (Sass)
Syntactically awesome stylesheets (Sass)Syntactically awesome stylesheets (Sass)
Syntactically awesome stylesheets (Sass)Tahmina Khatoon
 

Similar to Flex User Group - Skinning Presentation (20)

Professional Css
Professional CssProfessional Css
Professional Css
 
Performance & Responsive Web Design
Performance & Responsive Web DesignPerformance & Responsive Web Design
Performance & Responsive Web Design
 
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style Guides
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style GuidesAdvanced Front End Architecture in D8: Sass, Gulp, & Living Style Guides
Advanced Front End Architecture in D8: Sass, Gulp, & Living Style Guides
 
Auto tools
Auto toolsAuto tools
Auto tools
 
Styling components with JavaScript
Styling components with JavaScriptStyling components with JavaScript
Styling components with JavaScript
 
Refresh Tallahassee: The RE/MAX Front End Story
Refresh Tallahassee: The RE/MAX Front End StoryRefresh Tallahassee: The RE/MAX Front End Story
Refresh Tallahassee: The RE/MAX Front End Story
 
Html Css
Html CssHtml Css
Html Css
 
OSML and OpenSocial 0.9
OSML and OpenSocial 0.9OSML and OpenSocial 0.9
OSML and OpenSocial 0.9
 
Css3 and gwt in perfect harmony
Css3 and gwt in perfect harmonyCss3 and gwt in perfect harmony
Css3 and gwt in perfect harmony
 
Accelerated Stylesheets
Accelerated StylesheetsAccelerated Stylesheets
Accelerated Stylesheets
 
Learn Sass and Compass quick
Learn Sass and Compass quickLearn Sass and Compass quick
Learn Sass and Compass quick
 
Web applications with Catalyst
Web applications with CatalystWeb applications with Catalyst
Web applications with Catalyst
 
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}
The New UI - Staying Strong with Flexbox, SASS, and {{Mustache.js}}
 
CSS Less framework overview, Pros and Cons
CSS Less framework overview, Pros and ConsCSS Less framework overview, Pros and Cons
CSS Less framework overview, Pros and Cons
 
Developing Your Ultimate Package
Developing Your Ultimate PackageDeveloping Your Ultimate Package
Developing Your Ultimate Package
 
Optaros Surf Code Camp Lab 2
Optaros Surf Code Camp Lab 2Optaros Surf Code Camp Lab 2
Optaros Surf Code Camp Lab 2
 
New Elements & Features in CSS3
New Elements & Features in CSS3New Elements & Features in CSS3
New Elements & Features in CSS3
 
CSS3
CSS3CSS3
CSS3
 
Syntactically awesome stylesheets (Sass)
Syntactically awesome stylesheets (Sass)Syntactically awesome stylesheets (Sass)
Syntactically awesome stylesheets (Sass)
 
HTML::Mason by example
HTML::Mason by exampleHTML::Mason by example
HTML::Mason by example
 

Recently uploaded

Cannabis Legalization World Map: 2024 Updated
Cannabis Legalization World Map: 2024 UpdatedCannabis Legalization World Map: 2024 Updated
Cannabis Legalization World Map: 2024 UpdatedCannaBusinessPlans
 
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan CytotecJual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan CytotecZurliaSoop
 
Arti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdfArti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdfwill854175
 
Cracking the 'Career Pathing' Slideshare
Cracking the 'Career Pathing' SlideshareCracking the 'Career Pathing' Slideshare
Cracking the 'Career Pathing' SlideshareWorkforce Group
 
Falcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business PotentialFalcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business PotentialFalcon investment
 
Organizational Transformation Lead with Culture
Organizational Transformation Lead with CultureOrganizational Transformation Lead with Culture
Organizational Transformation Lead with CultureSeta Wicaksana
 
New 2024 Cannabis Edibles Investor Pitch Deck Template
New 2024 Cannabis Edibles Investor Pitch Deck TemplateNew 2024 Cannabis Edibles Investor Pitch Deck Template
New 2024 Cannabis Edibles Investor Pitch Deck TemplateCannaBusinessPlans
 
Dr. Admir Softic_ presentation_Green Club_ENG.pdf
Dr. Admir Softic_ presentation_Green Club_ENG.pdfDr. Admir Softic_ presentation_Green Club_ENG.pdf
Dr. Admir Softic_ presentation_Green Club_ENG.pdfAdmir Softic
 
Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024Marel
 
Mckinsey foundation level Handbook for Viewing
Mckinsey foundation level Handbook for ViewingMckinsey foundation level Handbook for Viewing
Mckinsey foundation level Handbook for ViewingNauman Safdar
 
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai KuwaitThe Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwaitdaisycvs
 
Phases of Negotiation .pptx
 Phases of Negotiation .pptx Phases of Negotiation .pptx
Phases of Negotiation .pptxnandhinijagan9867
 
BeMetals Investor Presentation_May 3, 2024.pdf
BeMetals Investor Presentation_May 3, 2024.pdfBeMetals Investor Presentation_May 3, 2024.pdf
BeMetals Investor Presentation_May 3, 2024.pdfDerekIwanaka1
 
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)Adnet Communications
 
Rice Manufacturers in India | Shree Krishna Exports
Rice Manufacturers in India | Shree Krishna ExportsRice Manufacturers in India | Shree Krishna Exports
Rice Manufacturers in India | Shree Krishna ExportsShree Krishna Exports
 
Pre Engineered Building Manufacturers Hyderabad.pptx
Pre Engineered  Building Manufacturers Hyderabad.pptxPre Engineered  Building Manufacturers Hyderabad.pptx
Pre Engineered Building Manufacturers Hyderabad.pptxRoofing Contractor
 
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All TimeCall 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Timegargpaaro
 
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAI
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAIGetting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAI
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAITim Wilson
 
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...meghakumariji156
 

Recently uploaded (20)

Cannabis Legalization World Map: 2024 Updated
Cannabis Legalization World Map: 2024 UpdatedCannabis Legalization World Map: 2024 Updated
Cannabis Legalization World Map: 2024 Updated
 
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan CytotecJual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
Jual Obat Aborsi ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan Cytotec
 
!~+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUD...
!~+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUD...!~+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUD...
!~+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUD...
 
Arti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdfArti Languages Pre Seed Teaser Deck 2024.pdf
Arti Languages Pre Seed Teaser Deck 2024.pdf
 
Cracking the 'Career Pathing' Slideshare
Cracking the 'Career Pathing' SlideshareCracking the 'Career Pathing' Slideshare
Cracking the 'Career Pathing' Slideshare
 
Falcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business PotentialFalcon Invoice Discounting: Unlock Your Business Potential
Falcon Invoice Discounting: Unlock Your Business Potential
 
Organizational Transformation Lead with Culture
Organizational Transformation Lead with CultureOrganizational Transformation Lead with Culture
Organizational Transformation Lead with Culture
 
New 2024 Cannabis Edibles Investor Pitch Deck Template
New 2024 Cannabis Edibles Investor Pitch Deck TemplateNew 2024 Cannabis Edibles Investor Pitch Deck Template
New 2024 Cannabis Edibles Investor Pitch Deck Template
 
Dr. Admir Softic_ presentation_Green Club_ENG.pdf
Dr. Admir Softic_ presentation_Green Club_ENG.pdfDr. Admir Softic_ presentation_Green Club_ENG.pdf
Dr. Admir Softic_ presentation_Green Club_ENG.pdf
 
Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024Marel Q1 2024 Investor Presentation from May 8, 2024
Marel Q1 2024 Investor Presentation from May 8, 2024
 
Mckinsey foundation level Handbook for Viewing
Mckinsey foundation level Handbook for ViewingMckinsey foundation level Handbook for Viewing
Mckinsey foundation level Handbook for Viewing
 
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai KuwaitThe Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
The Abortion pills for sale in Qatar@Doha [+27737758557] []Deira Dubai Kuwait
 
Phases of Negotiation .pptx
 Phases of Negotiation .pptx Phases of Negotiation .pptx
Phases of Negotiation .pptx
 
BeMetals Investor Presentation_May 3, 2024.pdf
BeMetals Investor Presentation_May 3, 2024.pdfBeMetals Investor Presentation_May 3, 2024.pdf
BeMetals Investor Presentation_May 3, 2024.pdf
 
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
Lundin Gold - Q1 2024 Conference Call Presentation (Revised)
 
Rice Manufacturers in India | Shree Krishna Exports
Rice Manufacturers in India | Shree Krishna ExportsRice Manufacturers in India | Shree Krishna Exports
Rice Manufacturers in India | Shree Krishna Exports
 
Pre Engineered Building Manufacturers Hyderabad.pptx
Pre Engineered  Building Manufacturers Hyderabad.pptxPre Engineered  Building Manufacturers Hyderabad.pptx
Pre Engineered Building Manufacturers Hyderabad.pptx
 
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All TimeCall 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
Call 7737669865 Vadodara Call Girls Service at your Door Step Available All Time
 
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAI
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAIGetting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAI
Getting Real with AI - Columbus DAW - May 2024 - Nick Woo from AlignAI
 
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
Escorts in Nungambakkam Phone 8250092165 Enjoy 24/7 Escort Service Enjoy Your...
 

Flex User Group - Skinning Presentation

  • 1. Styling Adobe Flex 2 James Whittaker Friday, 12 October 2007
  • 2. A bit of history • Interactive Developer @ Egg since 2006 • Previously QinetiQ & Helyx (MoD) • IT & Multimedia degree • Developer - Flex 2 application for Prudential Friday, 12 October 2007
  • 3. Why bother styling ? • Corporate branding • Marketing • Differentiate your application • User experience & usability • Remove any reference to Flex ! Friday, 12 October 2007
  • 4. Styling in the wild Friday, 12 October 2007
  • 5. Volkswagen http://www.vw.co.uk/used_cars/find Friday, 12 October 2007
  • 6. Volkswagen http://www.vw.co.uk/used_cars/find Friday, 12 October 2007
  • 7. Virtual Ubiquity http://www.virtualubiquity.com Friday, 12 October 2007
  • 8. Virtual Ubiquity http://www.virtualubiquity.com Friday, 12 October 2007
  • 9. Virtual Ubiquity http://www.virtualubiquity.com Friday, 12 October 2007
  • 10. Scrapblog http://www.scrapblog.com Friday, 12 October 2007
  • 11. Scrapblog http://www.scrapblog.com Friday, 12 October 2007
  • 12. Sliderocket http://www.sliderocket.com Friday, 12 October 2007
  • 13. Sliderocket http://www.sliderocket.com Friday, 12 October 2007
  • 14. Sliderocket http://www.sliderocket.com Friday, 12 October 2007
  • 15. Nice, how can we get our apps to look that good ? Friday, 12 October 2007
  • 16. What can we use ? • Themes • CSS • Programmatic skins • Graphical skins • Custom components Friday, 12 October 2007
  • 17. What is a theme? • At least one CSS file • Programmatic skin (AS3) classes • Graphical skin assets (PNG, SWF etc) • Themes can be compiled as a SWC • Easily distributed Friday, 12 October 2007
  • 18. The Halo theme • Smart, corporate visual design • Functional • Visually complete for quick prototyping • Use as an example & override but... Friday, 12 October 2007
  • 20. http://www.flickr.com/photos/dancunningham/ ! BORING ! Friday, 12 October 2007
  • 21. What can we do? • Use CSS for style changes • Visual skins - SWF, PNG, JPG • Embed fonts • Program custom skin classes • Use some cool graphics! Friday, 12 October 2007
  • 22. CSS in Flex 2 • Differences to CSS for XHTML • Used to set styles not properties • You can’t set size or position - they are properties not styles • Setting padding will drive you crazy! • Runtime changing of CSS Friday, 12 October 2007
  • 23. Using CSS • Inline with <Style><Style> tags • As MXML attribute < color=”#CC0000”> • External using <Style source=”myStyle.css” • Using ActionScript setStyle() Friday, 12 October 2007
  • 24. Applying CSS • To the whole application Application { } • To components ( or custom components ) NewTextLabel { } • Using class - selectors.rightButton { } Friday, 12 October 2007
  • 25. Use the style explorer http://examples.adobe.com/flex2/consulting/styleexplorer/Flex2StyleExplorer.html Friday, 12 October 2007
  • 26. Use the style explorer http://examples.adobe.com/flex2/consulting/styleexplorer/Flex2StyleExplorer.html Friday, 12 October 2007
  • 27. Custom fonts /*------------------------------------------- =Fonts ---------------------------------------------*/ @font-face { Application { src:local(quot;arialquot;); fontWeight:normal; fontFamily: myArial; color: #333333; fontFamily: myArial; } font-size: 12; } @font-face { src:local(quot;arialquot;); fontWeight:bold; fontFamily: myArial; } • New declaration for differing font weights • Careful, embedded fonts increase SWF size • Better for displaying within SWF Friday, 12 October 2007
  • 28. Tip - CSS Organisation • CSS files can become large • Navigation can be tricky • Techniques from HTML CSS /*------------------------------------------- =Containers ---------------------------------------------*/ • Use search and the first character (=C) • Remember cascading ! Friday, 12 October 2007
  • 29. Applying styles with AS • Primary example is HTML text • Use StyleSheet object in ActionScript • SetStyle • Apply the StyleSheet to the component Friday, 12 October 2007
  • 30. public class StyledText extends Text { private var style:StyleSheet = new StyleSheet(); override protected function childrenCreated():void { super.childrenCreated(); /* Set up the new stylesheet for the HTML text */ var aLink:Object = new Object(); aLink.color = quot;#CC0000quot;; aLink.textDecoration = quot;underlinequot;; var aHover:Object = new Object(); aHover.color = quot;#003366quot;; aHover.textDecoration = quot;underlinequot;; var aActive:Object = new Object(); aActive.color = quot;#003366quot;; aActive.textDecoration = quot;underlinequot;; /* Apply styles */ style.setStyle(quot;a:linkquot;, aLink); style.setStyle(quot;a:hoverquot;, aHover); style.setStyle(quot;a:activequot;, aActive); textField.condenseWhite = true; /* Apply Link listener */ this.addEventListener(TextEvent.LINK,linkHandler); } Friday, 12 October 2007
  • 31. HTML Text example • Styled links with HTML behavior • Not full HTML • Can’t set styles with external CSS by default Friday, 12 October 2007
  • 32. Skins http://www.flickr.com/photos/youghal/ • Graphical ( SWF, PNG etc ) • Programmatic AS3 classes • Applied using CSS Friday, 12 October 2007
  • 33. Graphical skin assets • Best to use SWF from Flash • Least file size • Only one file • Easy to use & reference • Use Scale 9 for perfect corners ! • Each element as a symbol Friday, 12 October 2007
  • 34. Scale 9 • Native to Flash, Fireworks & Illustrator • Can be specified in CSS • Has limitations • Watch non-vector images for jagged lines on resize Friday, 12 October 2007
  • 35. Scale 9 Friday, 12 October 2007
  • 36. Styling a button • Set skin for all affected button states • Use an Embed to embed the assets in the main SWF at compile time • State Scale 9 properties or use symbol name ( # ) Friday, 12 October 2007
  • 38. Programmatic Skins • All Halo skins are programmatic • Use Flash drawing API • Can achieve complex results • Smaller file size & faster at runtime • Apply using ClassReference in CSS • Need to know ActionScript Friday, 12 October 2007
  • 39. General tips Friday, 12 October 2007
  • 40. • Use HBox & VBox for layout - easy to style & extend • Build adaptable components like headers & links • Set naming conventions for MXML, CSS and Assets • Set the default namespace to be blank, loosing the mx: , more like XAML Friday, 12 October 2007
  • 41. Resources • http://www.scalenine.com - skins themes • http://www.famfamfam.com - free icons • http://flexdeveloper.eu • http://xd.adobe.com - experience design • http://www.adobe.com/devnet/flex Friday, 12 October 2007
  • 42. This presentation is released under Creative Commons share alike 3.0 http://creativecommons.org/licenses/by-sa/2.5/deed.en_GB http://flexdeveloper.eu/fuguk http://www.jameswhittaker.com Friday, 12 October 2007
  • 43. Thanks Now it’s Q & A time Friday, 12 October 2007