简体   繁体   中英

Android Actionbar Icon Drawable

As you probably know, there are some icons on Github from Google to use. I wanted to implement a actionbar icon and saw this here(google.com/design) and this(dev.android.com) .

  • google.com/design tells me to use a 24dp icon
  • dev.android.com sais I should use a 32dp icon

I myself implemented the 24dp one since it had a 24dp icon in the provided icons of Google. I put the icon in every folder by hand including xxxhdpi, xxhdpi, xhdpi, hdpi, mdpi but as you can see below the list-icon should be bigger as it is right now. (the list-icon ist the one below the battery icon)

So I checked out IO Schedule and there they have a 96px x 96px icon in a xxhdpi folder which totally confused me.

  1. which information is true? How should I implement my Icons? What's best practice?
  2. Any advice on automate all the icon versions? thanks

24dp列表图标

Use 24dp icons. This will give you following real image sizes:

  • mdpi icons are 24x24 (base)
  • hdpi icons are 36x36 (1,5x base)
  • xhdpi icons are 48x48 (2x base)
  • xxhdpi icons are 72x72 (3x base)
  • xxxhdpi icons are 96x96 (4x base)

In correct folders these will produce a 24dp image on appropriate screens.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM