我想创建矩形可绘制然后旋转它,使右上方看起来倾斜,我最终将覆盖圆角图像,努力创建下面的图像的副本,使用一些drawable
我希望与xml一起使用,但它只是倾斜而且边缘永远不会触及另一面
$file="config/data.txt";
$fopen = fopen($file, r);
$fread = fread($fopen,filesize($file));
fclose($fopen);
$remove = "\n";
$split = explode($remove, $fread);
$servers[] = null;
$tab = "|";
foreach ($split as $string)
{
$row = explode($tab, $string);
array_push($servers,$row);
}
创建一个绘制形状的自定义Drawable:但我又失败了,会不会有任何帮助?谢谢
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item >
<rotate
android:fromDegrees="19.5"
android:toDegrees="-19.5"
android:pivotX="-50%"
android:pivotY="0%"
>
<shape
android:shape="rectangle" >
<solid
android:color="@android:color/black" />
</shape>
</rotate>
</item>