2

I have created an empty Nativescript application with tns create myApp'. However,app/App_Resources/Android/drawable-hdpi` and other directories does not contain any default system icons. Thus, I cannot use them in the application. How can I find or install default system icons?

2 Answers 2

2

However, the default system icons are called using something like this:

<ActionItem ios:systemIcon="12" android:systemIcon="ic_menu_search" tap="showSearch" ios:position="right" android:position="actionBar" />

You can find a list (unfortunately without images) at https://developer.android.com/reference/android/R.drawable.html

Sign up to request clarification or add additional context in comments.

1 Comment

How about ios.systemIcon? And it seems the android ones are the ic_ prefixed ones here - developer.android.com/reference/android/R.drawable.html - but when i use them they are always transparent in the middle, and just border, any way to get them solid colored?
2

For using your custom icons in the application, you have to add them in each drawable-XXX folder and then in your XML src="res://my_icon"

You can find more informations in the official documentation of NS : https://docs.nativescript.org/ui/ui-images#load-images-from-resource

1 Comment

How about ios.systemIcon?

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.