How can I set an icon for my Android application?
Right-click on the shortcut and select “Properties” from the dropdown menu. Navigate to the “Shortcut” tab. Select “Change Icon” at the bottom of the window.
If you intend on your application being available on a large range of devices, you should place your application icon into the different res/drawable...
folders provided. In each of these folders, you should include a 48dp sized icon:
drawable-ldpi
(120 dpi, Low density screen) - 36px x 36px drawable-mdpi
(160 dpi, Medium density screen) - 48px x 48px drawable-hdpi
(240 dpi, High density screen) - 72px x 72px drawable-xhdpi
(320 dpi, Extra-high density screen) - 96px x 96px drawable-xxhdpi
(480 dpi, Extra-extra-high density screen) - 144px x 144px drawable-xxxhdpi
(640 dpi, Extra-extra-extra-high density screen) - 192px x 192px You may then define the icon in your AndroidManifest.xml
file as such:
<application android:icon="@drawable/icon_name" android:label="@string/app_name" > .... </application>
Add an application launcher icon with automatic sizing.
(Android studio)
Go to menu File* → New → Image Assets → select launcher icon → choose image file.
It will automatically re-size.
Done!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With