你知道怎么在LinearLayout上画线吗?为了创建一个LinearLayout,我使用了一个xml资源:
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main_layout);
LinearLayout linear = (LinearLayout)findViewById(R.id.linearlayout);
//I wanna draw line on "linear"
}有可能吗?
发布于 2009-12-24 00:31:10
我在一个图像编辑工具中创建了一个图像,它是我想要的颜色的2x2像素正方形。然后,在代码中,我创建了一个ImageView并将该图像设置为源。最后,我将ImageView的高度设置为FitContent,将宽度设置为FillParent,这给了我一条水平线。
https://stackoverflow.com/questions/1951213
复制相似问题