无法使用视图在android中显示垂直线?
有人能告诉我我需要添加什么代码来绘制固定高度的垂直线吗?我想要垂直线,就像这个url中的刻度测量一样 这是我的密码无法使用视图在android中显示垂直线?,android,xml,draw,shape,Android,Xml,Draw,Shape,有人能告诉我我需要添加什么代码来绘制固定高度的垂直线吗?我想要垂直线,就像这个url中的刻度测量一样 这是我的密码 您可以使用可绘制资源应用不同的样式 在我找到的这个链接下,可以看到类似这样的内容,该链接为BMIAPI提供了非常好的UI。但我还是不明白你的意思。你想用这一行来划分这些视图还是什么?是的,我想用这一行来划分这些视图,但我不认为这是合适的。你能为它的UI建议其他方式吗。 <ScrollView xmlns:android="http://schemas.android.com/
您可以使用可绘制资源应用不同的样式
在我找到的这个链接下,可以看到类似这样的内容,该链接为BMIAPI提供了非常好的UI。但我还是不明白你的意思。你想用这一行来划分这些视图还是什么?是的,我想用这一行来划分这些视图,但我不认为这是合适的。你能为它的UI建议其他方式吗。
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<LinearLayout
android:id="@+id/linear_layout_one"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginLeft="5dp">
<View
android:layout_width="5dip"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/darker_gray"/>
<View
android:layout_width="5dip"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:layout_marginRight="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/darker_gray"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
<View
android:layout_width="5dip"
android:layout_height="match_parent"
android:layout_marginLeft="5dp"
android:rotation="90"
android:background="@android:color/holo_purple"/>
</LinearLayout>
</ScrollView>