Note that there are some explanatory texts on larger screens.

plurals
  1. POAndroid: Custom spinner help
    text
    copied!<p>I am following <a href="http://www.gersic.com/blog.php?id=57" rel="nofollow noreferrer">this</a> tutorial on how to create custom spinners. Near the begining it instructs you to navigate to: *android.jar\res\drawable-finger* But for some reason I can't find the "drawable-finger" folder in my android.jar. I thought it may have to do with the API level so I changed it from 1.6 to 2.1 to no avail. I went around this and put them in the drawable folder thinking I could just work around it but then the spinner has the image stretched and malformed instead of repeating the image in the x direction. Any ideas?</p> <p>Thanks!</p> <p>EDIT: Here is the code Spinner</p> <pre><code> &lt;Spinner android:id="@+id/catspinner" android:layout_marginLeft="15dip" android:layout_marginRight="15dip" android:layout_width="fill_parent" android:layout_centerHorizontal="true" android:layout_height="wrap_content" android:layout_centerVertical="true" android:drawSelectorOnTop="true" android:background="@drawable/spinnerbackground"/&gt; </code></pre> <p>code for the spinner background:</p> <pre><code> &lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;selector xmlns:android="http://schemas.android.com/apk/res/android"&gt; &lt;item android:state_focused="true" android:state_pressed="false" android:drawable="@drawable/myspinner_select" /&gt; &lt;item android:state_focused="true" android:state_pressed="true" android:drawable="@drawable/myspinner_press" /&gt; &lt;item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/myspinner_press" /&gt; &lt;item android:drawable="@drawable/myspinner_normal" /&gt; &lt;/selector&gt; </code></pre> <p>it looks like this<img src="https://i.stack.imgur.com/6S95v.jpg" alt="enter image description here"></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload