I have an ImageButton and want to scale the button in different sizes which means an image is not the right choice. So I was thinking of an ImageButton with a custom Shape as source.
I want the button to look like this:
I started with this, but got stuck with the rotate stuff:
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle" >
<stroke
android:width="2dp"
android:color="@color/red" />
<rotate
android:fromDegrees="90"
android:toDegrees="135" >
<shape android:shape="line" >
<stroke
android:width="2dp"
android:color="@color/red" >
</stroke>
</shape>
</rotate>
<padding
android:bottom="7dp"
android:left="7dp"
android:right="7dp"
android:top="7dp" />
</shape>
This however does not rotate as I expect it to. Maybe I am completely wrong and need a push in the right direction. :-) Thanks.