How Do I Add A Vertical Separator Line Between 3 Displayed Values?
I have 3 values displayed consecutively on the screen and I need to add 2-3 vertical separator lines between all of them.The issue is everytime I add a view/ divider between them t
Solution 1:
As @Gru says, you can get the black line using a View between layout1 and layout2andlayout2 and layout3.
As you point out, this will be on the left edge of the contents of layout2 and layout3. To separate this out a bit, an easy solution is to add the line:
android:paddingLeft="20dp"to layout1, layout2 and layout3, whilst removing it from the top LinearLayout. This won't achieve precise centring, but it will give an equal text to left edge for each block, which I think will look about right.
Solution 2:
Place this in between each value you have mentioned in your question.
<View android:layout_height="fill_parent"
android:layout_width="2px"
android:background="#000000"/>
should give you a black bar in between values.
Post a Comment for "How Do I Add A Vertical Separator Line Between 3 Displayed Values?"