How to create vector drawables for android?

前端 未结 7 838
闹比i
闹比i 2021-01-29 19:11

I am new to VectorDrawables.

I can see that the default vector drawables provided with android studio like ic_menu_gallery,

7条回答
  •  猫巷女王i
    2021-01-29 20:04

    Step 1 The first step is to convert it into SVG format - For black and white SVG convertor there are many tools but there are very few good tools for coloured conversion. https://www.autotracer.org/ is one of the best and it worked for me. Convert and download the SVG file. Step 2- In the ' Android Studio ' Go to drawables folder and right click to select New - Vector Asset

    Step 3 - Choose the downloaded SVG file from Step 1. The android Studio

    Step 4 - Dont forget to set navigationView.setItemIconTintList(null); as null in case the coloured icons are being used in a navigation drawer/view.

    Cheers!!

提交回复
热议问题