Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to use Icons and Splash Screen in Phonegap

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 542
    Comment on it

    Icons and splashes both are specified to some platform like android, iOS, windows, blackberry. We can define a icon or splash for a particular platform by the following ways:

    By specifying the platform attribute:
     

    1. <icon src="icon-60@3x.png" platform="ios" width="180" height="180" />

     By giving icon or splash inside a tag named platform:
     

    1. <platform name="ios">
    2. <icon src="icon-60@3x.png" width="180" height="180" />
    3. </platform>

    Icons:

    You can find icon tag inside your config.xml file. It must have the following attributes:
    src: It identifies the path of the image file.
    width and height

    For iOS:

    1. <!-- iPhone 6 / 6+ -->
    2. <icon src="icon-60@3x.png" platform="ios" width="180" height="180" />
    3.  
    4. <!-- iPhone / iPod Touch -->
    5. <icon src="icon-60.png" platform="ios" width="60" height="60" />
    6. <icon src="icon-60@2x.png" platform="ios" width="120" height="120" />
    7.  
    8. <!-- iPad -->
    9. <icon src="icon-76.png" platform="ios" width="76" height="76" />
    10. <icon src="icon-76@2x.png" platform="ios" width="152" height="152" />
    11.  
    12. <!-- Settings Icon -->
    13. <icon src="icon-small.png" platform="ios" width="29" height="29" />
    14. <icon src="icon-small@2x.png" platform="ios" width="58" height="58" />
    15.  
    16. <!-- Spotlight Icon -->
    17. <icon src="icon-40.png" platform="ios" width="40" height="40" />
    18. <icon src="icon-40@2x.png" platform="ios" width="80" height="80" />

    For Android:

    1. <icon src="ldpi.png" platform="android" qualifier="ldpi" />
    2. <icon src="mdpi.png" platform="android" qualifier="mdpi" />
    3. <icon src="hdpi.png" platform="android" qualifier="hdpi" />
    4. <icon src="xhdpi.png" platform="android" qualifier="xhdpi" />
    5. <icon src="xxhdpi.png" platform="android" qualifier="xxhdpi" />
    6. <icon src="fr-xxhdpi.png" platform="android" qualifier="fr-xxhdpi" />

    Splash screens:
    This is also inside your config.xml file. It can have attributes like src, height, width.

    1. <splash src="splash/ios/Default-568h@2x~iphone.png" platform="ios" width="320" height="480" />

     

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Reset Password
Fill out the form below and reset your password: