Note that there are some explanatory texts on larger screens.

plurals
  1. POAndroid - Possible approach on creating custom shape buttons?
    primarykey
    data
    text
    <p>i would like to know how i will be able to create a set of buttons as shown in the image below.</p> <p><img src="https://i.stack.imgur.com/NAa3z.png" alt="Figure 1"></p> <p>i understand that imageviews can only be rectangular or square but in my case, these will be a set of custom shaped buttons that might overlap imageviews as shown in the image below.</p> <p><img src="https://i.stack.imgur.com/M6L3w.png" alt="Figure 2"></p> <p>in this image, i basically have 9 imageviews that should contain their respective images but notice that some of the image shown per imageview includes a part of an image from another imageview.</p> <p>i plan to have the on press effect which i've done before using selector like the ff:</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="true" android:drawable="@drawable/ic_1_down"/&gt; &lt;item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/ic_1_down"/&gt; &lt;item android:state_focused="true" android:drawable="@drawable/ic_1_up"/&gt; &lt;item android:state_focused="false" android:state_pressed="false" android:drawable="@drawable/ic_1_up"/&gt; &lt;/selector&gt; </code></pre> <p>but that only works for the current view as far as i know and it wont change images on the other imageviews affected. so in this case for example, </p> <p>button 1 (top left). this buttons image is connected partly to imageview 2 and imageview 4. so when pressed lets say the button turns white, i would also like to the button's part in imageview 2 and 4 to turn white. how is this done?</p> <p>appreciate any comment or suggestion.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

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