8 Replies Latest reply on Sep 11, 2017 12:52 PM by andersborglund

    Low resolution icons in Android for 7.0.1

    andersborglund Level 1

      When building with PGB 7.0.1 the default icon.png seems to be picked, which it wasn't before. The only change made to projects was switching to 7.0.1 from 6.5.0.

       

      On iOS it seems the right icons are chosen.

       

      Has anything changed in terms of the prioritization of icons?

       

      These are the settings I use. Icons were created with Abiro PhoneGap Image Generator

       

          <icon src="icon.png" />

          <splash src="splash.png" />

       

          <platform name="ios">

              <icon src="res/icons/ios/icon-small.png" width="29" height="29"/>

              <icon src="res/icons/ios/icon-small-2x.png" width="58" height="58"/>

              <icon src="res/icons/ios/icon-40.png" width="40" height="40"/>

              <icon src="res/icons/ios/icon-40-2x.png" width="80" height="80"/>

              <icon src="res/icons/ios/icon-50.png" width="50" height="50"/>

              <icon src="res/icons/ios/icon-50-2x.png" width="100" height="100"/>

              <icon src="res/icons/ios/icon.png" width="57" height="57"/>

              <icon src="res/icons/ios/icon-2x.png" width="114" height="114"/>

              <icon src="res/icons/ios/icon-60.png" width="60" height="60"/>

              <icon src="res/icons/ios/icon-60-2x.png" width="120" height="120"/>

              <icon src="res/icons/ios/icon-60-3x.png" width="180" height="180"/>

              <icon src="res/icons/ios/icon-72.png" width="72" height="72"/>

              <icon src="res/icons/ios/icon-72-2x.png" width="144" height="144"/>

              <icon src="res/icons/ios/icon-76.png" width="76" height="76"/>

              <icon src="res/icons/ios/icon-76-2x.png" width="152" height="152"/>

       

              <splash src="res/screens/ios/screen-iphone-portrait.png" width="320" height="480"/>

              <splash src="res/screens/ios/screen-iphone-portrait-2x.png" width="640" height="960"/>

              <splash src="res/screens/ios/screen-iphone-portrait-568h-2x.png" width="640" height="1136"/>

              <splash src="res/screens/ios/screen-iphone-portrait-667h.png" width="750" height="1334"/>

              <splash src="res/screens/ios/screen-iphone-portrait-736h.png" width="1242" height="2208"/>

              <splash src="res/screens/ios/screen-ipad-portrait.png" width="768" height="1024"/>

              <splash src="res/screens/ios/screen-ipad-portrait-2x.png" width="1536" height="2048"/>

          </platform>

       

          <platform name="android">

              <icon qualifier="ldpi" src="res/icons/android/icon-36-ldpi.png"/>

              <icon qualifier="mdpi" src="res/icons/android/icon-48-mdpi.png"/>

              <icon qualifier="hdpi" src="res/icons/android/icon-72-hdpi.png"/>

              <icon qualifier="xhdpi" src="res/icons/android/icon-96-xhdpi.png"/>

              <icon qualifier="xxhdpi" src="res/icons/android/icon-144-xxhdpi.png"/>

              <icon qualifier="xxxhdpi" src="res/icons/android/icon-192-xxxhdpi.png"/>

              <splash qualifier="ldpi" src="res/screens/android/screen-ldpi-portrait.png"/>

              <splash qualifier="mdpi" src="res/screens/android/screen-mdpi-portrait.png"/>

              <splash qualifier="hdpi" src="res/screens/android/screen-hdpi-portrait.png"/>

              <splash qualifier="xhdpi" src="res/screens/android/screen-xhdpi-portrait.png"/>

          </platform>

        • 1. Re: Low resolution icons in Android for 7.0.1
          ryanskihead Adobe Employee

          Hmm try using "density" instead of "qualifer" for your android icon declarations

          • 2. Re: Low resolution icons in Android for 7.0.1
            andersborglund Level 1

            Yup, that did it.

             

            Updated:

             

            Thanks,

            Anders

            • 3. Re: Low resolution icons in Android for 7.0.1
              moshtaba

              hi dear , i want to know that i write this where ?

               

                  <icon src="icon.png" />

                  <splash src="splash.png" />

               

                  <platform name="ios">

                      <icon src="res/icons/ios/icon-small.png" width="29" height="29"/>

                      <icon src="res/icons/ios/icon-small-2x.png" width="58" height="58"/>

                      <icon src="res/icons/ios/icon-40.png" width="40" height="40"/>

                      <icon src="res/icons/ios/icon-40-2x.png" width="80" height="80"/>

                      <icon src="res/icons/ios/icon-50.png" width="50" height="50"/>

                      <icon src="res/icons/ios/icon-50-2x.png" width="100" height="100"/>

                      <icon src="res/icons/ios/icon.png" width="57" height="57"/>

                      <icon src="res/icons/ios/icon-2x.png" width="114" height="114"/>

                      <icon src="res/icons/ios/icon-60.png" width="60" height="60"/>

                      <icon src="res/icons/ios/icon-60-2x.png" width="120" height="120"/>

                      <icon src="res/icons/ios/icon-60-3x.png" width="180" height="180"/>

                      <icon src="res/icons/ios/icon-72.png" width="72" height="72"/>

                      <icon src="res/icons/ios/icon-72-2x.png" width="144" height="144"/>

                      <icon src="res/icons/ios/icon-76.png" width="76" height="76"/>

                      <icon src="res/icons/ios/icon-76-2x.png" width="152" height="152"/>

               

                      <splash src="res/screens/ios/screen-iphone-portrait.png" width="320" height="480"/>

                      <splash src="res/screens/ios/screen-iphone-portrait-2x.png" width="640" height="960"/>

                      <splash src="res/screens/ios/screen-iphone-portrait-568h-2x.png" width="640" height="1136"/>

                      <splash src="res/screens/ios/screen-iphone-portrait-667h.png" width="750" height="1334"/>

                      <splash src="res/screens/ios/screen-iphone-portrait-736h.png" width="1242" height="2208"/>

                      <splash src="res/screens/ios/screen-ipad-portrait.png" width="768" height="1024"/>

                      <splash src="res/screens/ios/screen-ipad-portrait-2x.png" width="1536" height="2048"/>

                  </platform>

               

                  <platform name="android">

                      <icon qualifier="ldpi" src="res/icons/android/icon-36-ldpi.png"/>

                      <icon qualifier="mdpi" src="res/icons/android/icon-48-mdpi.png"/>

                      <icon qualifier="hdpi" src="res/icons/android/icon-72-hdpi.png"/>

                      <icon qualifier="xhdpi" src="res/icons/android/icon-96-xhdpi.png"/>

                      <icon qualifier="xxhdpi" src="res/icons/android/icon-144-xxhdpi.png"/>

                      <icon qualifier="xxxhdpi" src="res/icons/android/icon-192-xxxhdpi.png"/>

                      <splash qualifier="ldpi" src="res/screens/android/screen-ldpi-portrait.png"/>

                      <splash qualifier="mdpi" src="res/screens/android/screen-mdpi-portrait.png"/>

                      <splash qualifier="hdpi" src="res/screens/android/screen-hdpi-portrait.png"/>

                      <splash qualifier="xhdpi" src="res/screens/android/screen-xhdpi-portrait.png"/>

                  </platform>

               

               

               

               

              this should write to html code ?!!

              • 4. Re: Low resolution icons in Android for 7.0.1
                andersborglund Level 1

                No, it's entered in config.xml.

                 

                See Customize app icons - Apache Cordova

                 

                Or see my updated template: PhoneGap Build | Abiro

                This template is for use with PhoneGap Build, but could probably be used for Cordova CLI as well.

                 

                Regards,

                Anders

                1 person found this helpful
                • 6. Re: Low resolution icons in Android for 7.0.1
                  andersborglund Level 1

                  The PGB docs still say qualifier: Icons and Splash | PhoneGap Docs

                   

                  Also, that page is out of sync with ditto Cordova docs. I doubt any file name is the same. AFAIK, there's no reason for any differences in this regard.

                  • 7. Re: Low resolution icons in Android for 7.0.1
                    ryanskihead Adobe Employee

                    Basically the declarations for icons/splash diverged between phonegap cli and phonegap build, until cli-7.0.1 when they synced back up. Docs are unclear on this, will note to get those updated.

                    • 8. Re: Low resolution icons in Android for 7.0.1
                      andersborglund Level 1

                      I have an online tool for creating icons and splash/launch screens for PhoneGap Build (and PhoneGap and Cordova in general), and I based the naming on what's described here (for the most part):

                      Customize app icons - Apache Cordova

                      Splashscreen - Apache Cordova

                       

                      I guess I made the right call for now.

                       

                      Folders are still called icons and screens, as it was requested for Visual Studio. I guess I should change that as well.

                       

                      Will you make any trade-offs vs Cordova here?