I'm trying to change the icon of my app in android studio.
I am importing it with Android Studio like this.
(which normally should work)
But on my mobile the App Icon looks like this.
I don't now what I'm doing wrong so any help is appreciated :)
With pngs it's kinda difficult.
You may want to try using vectors:
First
Export your logo (using for example photoshop) as a SVG
Then use this Website to convert it to xml code: http://inloop.github.io/svg2android/
Create a new drawable file and copy the code of the website into your file.
Then try creating your Launcher Icons using your drawable resource file
Related
I used to use plugin android drawable importer, it had some bugs but it worked fine. But by Android Studio 3.6.1, this plugin began to not working anymore. And now it is also not listed plugin marketplace.
Here is the thing that I want to do; I have an icon on computer. I want to import this icon to correct drawable folders with correct sizing. And sizing should be done automatically.
I know image/vector asset menus. But these do not make what I want. Vector asset menu does not provide png or jpeg. And the image asset menu does not make transparent background.
What is the correct and easiest way to do that? I am not a designer. I can not deal with every icon to every size. This is done automatically by the plugin or android studio itself.
I'm creating my applications. but i want to use android default drawables icon (calendar, camera or etc...)
some of icons can be use.
but some of cannot.
here is my code
android.R.drawable.ic_menu_camera it's okay to use.
but android.R.drawable.ic_menu_cc_am is error in Android studio
this file(ic_menu_cc_am) exists in android sdk and can jump to declaration like this.
why I can't use of this file (some of files also can't using on android studio, but file is exists!)
sorry for my bad english.
thank you.
I started using Android Studio recently and I found one thing different (notably) that unlike in Eclipse, Android Studio does not provide any option to choose app icon and its shape & size while creating a new app.
While finalizing my app development I tried to change default 'ic_launcher.png' with my own image but I am not able to change its shape (which is square by default) to circular.
So my question is - Is there any way of changing app icon shape in Android Studio ?
And if this question is already been solved on some other thread then please share that link with me. (P.S.- I tried to search with similar question here but couldn't find probable solution, therefore posting this question on my own)
Just add new Icons in all drawable folder and update the icon name in manifest file.
To change the icon shape following tool can be usefull:
http://romannurik.github.io/AndroidAssetStudio/
Sorry for the late answer first of all. Here is my answer:
While launching Android Studio 1 RC in Beta Channel, they did not add this feature of adding image assets to the app directly from the Android Studio.
But since Android Studio 1.1 update, this feature is available to use.
Here is how you get different icons:
Click on res under app directory of you project.
New --> Image Asset
Choose Asset Type (Launcher Icon | Action Bar and Tab Icons | Notification Icon).
Choose your Image from the directory and perform other necessary changes to get the icon you desire.
Click next and then select
Type Module and Res Directory and click Finish.
You will see your icons under res folder directory.
I hope this was helpful, thank you!
Previously I made some apps with Adobe Flash Builder. That's works great but is not the best choice is some cases so I start with developing Android apps with use of ADT.
Like in Flash Builder you can set several icons for different screen resolutions. I can understand why but found it is not really necessary when creating one high resolution icon, this works fine (scaling down is better than scaling up). This also avoid the extra work that is needed to create these icons, just one icon.
Long story short, I want to create just one icon, 144x144 pixels at 96dpi and tell Android to use this icon.
Also I want to point the application icon to the asset directory instead of the res/drawable directory. The reason for this is that the icon can be reused by the (web-)application and for another reason, I have made a webApp tool to create a compressed version of a webApp and put the contents in the asset directory of a Android project.
Because the webApp can also run in the browser I have already created some icons (like favicon, apple-touch-icon and apple-touch-startup-image) and want to reuse these icons in the Android project automaticly.
The idea is also to create an application project template so it is quite easy to create a android app of a webApp.
Question
Andy idea how to change the location of for example the application icon? Using a path doesn't work (it generates an error, can't compile).
android:icon="#drawable/ic_launcher"
android:icon="assets/appicon.png" #<- doesn't work
Actually found the solution myself and is pretty simple. The only thing that is a bit tricky in ADT to validate the new declaration because at first 'it says' that the declaration is invalid. The workaround is to cut (ctrl+X) the declaration, do a project clean by Project|Clean and then put it back by paste it again (ctrl+V). Weird but true ;-)
You can declare a string resource like this (in XML file):
<resources>
<string name="app_icon">assets/appicon.png</string>
</resources>
android:icon="#string/app_icon" <- this works
Then you can use just one high-res icon image as icon for all devices! Looks great! See also picture below (between red rectangle ;-)):
can anyone tell me where I get the icons native android?
I think what you are asking for is the icons that are used by the Android OS. If that's the case you can view them in the android.jar file that is installed with the SDK.
<sdk-install-path>/platforms/<any-platform>/android.jar
If you extract that jar and have a look at the res/drawable* folders you will see the icons used throughout the OS. You can also access them from within your code using:
#android:drawable/<name of drawable>
It's not clear if you want to access the icons as files or through your application. If you want the actual icons you can grab them from the source code.
The source code for Android is available here at android.googlesource.com:
https://android.googlesource.com/platform/frameworks/base.git/
Specifically:
https://android.googlesource.com/platform/frameworks/base.git/+/master/core/res/res/drawable-hdpi/
Many of the Android icons / resources are available by resource ID. The resource IDs for those are in the android.R class.
http://developer.android.com/reference/android/R.drawable.html
Material Icons seems to be a good address for a standard Icon set for android these days.
Check out http://www.yay.se/resources/android-native-icons it contains all the standard icons converted to vector graphics.