tags:

views:

187

answers:

1

Hi,

Is there a way that I can specify a triangle shape in an xml file?

<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="triangle">
  <stroke android:width="1dip" android:color="#FFF" />
  <solid android:color="#FFF" />
</shape>

can we do this with a path shape or something? I just need an equilateral triangle.

Thanks

A: 

I have never done this, but from what I understand you can use the PathShape class: http://developer.android.com/reference/android/graphics/drawable/shapes/PathShape.html

Justin