Skip to content

Importing App Icon

Add the Application Launcher icon with ease

Introduction

The App Icon Importer utility allows you to easily import the Application Launcher icon into the Android and iOS projects of your solution from a single image file, that is imported in all the required densities and metadata to describe the icons.

Using the App Icon Importer

The importer tool is presented as a dialog that can be invoked from several places in Visual Studio IDE. The more straighforward is from the MFractor main menu:

Important

The MFractor App Icon Importer tool menu option will only be available if the solution has at least one Xamarin.Android or Xamarin.iOS project.

The tool can also be invoked from the context menu of an Android or iOS project, in the Add submenu you should find the option for App Icon:

The App Icon Importer dialog Window allows you to load the single image that you use to generate all the required files for the Application icon.

There are a few requirements that should be met to be able to import and get the best results:

  • The image must be a square ratio (1:1): the icons for either platform are in square ratio, which means that they have the same width and height. The tool cannot import images that are in this ratio because resizing it would squash its contents.
  • The image must be at least 1024x1024: although you can use a smaller image, using one that is at least 1024 pixels wide and tall ensures that all the images are downscaled without loss of quality. Also, it fits the higher image size on iOS (App Store icon).

The App Icon importer was thought to as very straighforward as possible, for this reason there only a few options available:

Selecting Target Projecs

The Target Projects section on the left pane lists all the projects on the current opened solution and allows you to select to which projects the icon will be imported to. By default, all projects are selected.

Creating Adaptive Icons

Newer versions of Android uses Adaptative Icons,

Resource Name and Locations

The App Icon Importer uses standard conventions for naming and placing the image files of the application icon. This varies depending on the platform:

  • Android launcher icons are imported to the mipmap Resources folders for the ldpi, mdpi, hdpi, xhdpi, xxhdpi and xxxhdpi density folders with the file name icon.png.

Note

Android adaptive launcher icons are currently not supported on this first iteration of the icon importer. We're planning on adding it support on future versions of MFractor.

Note

We've chosen to simplify the app icon importer implementation by using standard conventions. If you find you need further customization please leave a feedback at our GitHub issues page, so we can consider future improvements for this feature.

Comments