android - Image inside custom Spinner is blurry -



android - Image inside custom Spinner is blurry -

i made custom spinner image within showed spinner default visual:

(http://i.imgur.com/f6wj4gl.png)

but arrow image blurry, , can't adjust in order remain clean image below: (http://i.imgur.com/ulmpnkz.png)

here's spinner's layout:

<spinner android:id="@+id/smeaspla" android:layout_width="match_parent" android:layout_height="wrap_content" android:drawselectorontop="true" android:background="@drawable/tk_spinner_background" android:layout_marginbottom="@dimen/margin_separator_bottom"/>

my selector (tk_spinner_background):

<?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:drawable="@drawable/tk_spinner_background_pressed" android:state_pressed="true" /> <item android:drawable="@drawable/tk_spinner_background_default" android:state_focused="true" /> <item android:drawable="@drawable/tk_spinner_background_default" /> </selector>

my spinner background (tk_spinner_background_default):

<?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item> <layer-list> <item> <shape android:shape="rectangle"> <solid android:color="@color/transparent" > </solid> <stroke android:width="3dp" android:color="@color/gray_light" > </stroke> <padding android:left="@dimen/padding_edit_text_left"> </padding> <corners android:radius="10dp" > </corners> </shape> </item> <item android:top="5dp" android:right="10dp" android:bottom="5dp"> <bitmap android:src="@drawable/ic_spinner_arrow_default" android:gravity="top|right" /> </item> </layer-list> </item> </selector>

i don't have methods in bitmap in imageview (layout_width, layout_height, scaletype, etc) alter image size...

can tell me way have more command image size in bitmap or other way this?

thanks in advance

the problem in poorly utilize of drawable folders... had images within same folder (drawable-hdpi)

don't inquire me why, devices (i tried in 5 different devices) wouldn't re-size image correctly in specific case... (probably because couldn't define size)

when separate every image correctly specific size in corresponding folder, problem solved, , image appeared correctly...

android android-layout bitmap android-spinner

Comments

Popular posts from this blog

assembly - What is the addressing mode for ld, add, and rjmp instructions? -

vowpalwabbit - Interpreting Vowpal Wabbit results: Why are some lines appended by "h"? -

Is there a way to convert an HTML page styled with Bootstrap CSS into email-compatible html? -