Questions tagged «draw»

30
Android绘图分隔线/分隔线在布局中?
这个问题的答案是社区的努力。编辑现有答案以改善此职位。它目前不接受新的答案或互动。 我想在布局的中间画一条线,并将其用作其他项(如TextView)的分隔符。为此有一个好的小部件。我真的不想使用图像,因为很难将其他组件与之匹配。我希望它也能相对定位。谢谢
684 android  layout  draw 

2
Android:如何为LinearLayout绘制边框
我有三个文件。XML,绘图功能和主要活动。LinearLayout我的XML文件中有一些。 <LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1"> <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1" android:background="#ef3" android:id="@+id/img01"/> <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1" android:background="#E8A2B4" android:id="@+id/img02"/> </LinearLayout> 这是绘制函数: public class getBorder extends TextView { public getBorder(Context context) { super(context); } @Override protected void onDraw(Canvas canvas) { super.onDraw(canvas); Paint paint = new Paint(); paint.setColor(android.graphics.Color.RED); canvas.drawLine(0, 0, this.getWidth() - 1, …



13
在Google地图上画一条线/路径
我已经很忙了很长时间,发现如何在HelloMapView中的地图上的两个(GPS)点之间绘制一条线,但是没有运气。 谁能告诉我该怎么做。 假设我使用扩展MapView的HelloMapView。我需要使用覆盖层吗?如果是这样,我是否必须覆盖叠加层的onDraw()方法并在此处画一条线?我实际上尝试了这些事情,但没有结果。 先感谢您!

3
仅使用XAML绘制纯色三角形
是否可以仅使用XAML来绘制实心三角形(而不是解决方案背后的代码)? 三角形应类似于下图所示,以表示排序方向Ascending/Descending以及图表控件上的排序按钮: 编辑:解决方案,感谢SpeziFish: 上升: <Polygon Points="0,0 8,5, 0,10" Stroke="Black" Fill="Black" /> 降序: <Polygon Points="8,0 0,5, 8,10" Stroke="Black" Fill="Black" />
80 .net  wpf  xaml  draw 


1
如何在Google地图中使用标记和折线的中点绘制多边形
我想在地图上绘制自由手多边形。我从简单的Google地图开始,然后绘制多边形,它可以正常工作,但现在我正在寻找用户如何通过单击地图上的点并在地图上的点中间拉伸标记来绘制多边形多边形。 现在我的多边形地图看起来像: 我想实现: 这是我的代码: public class MapActivity extends FragmentActivity implements OnMapReadyCallback { private GoogleMap mMap; Button save_field; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_map); // Retrieve the content view that renders the map. SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager() .findFragmentById(R.id.map); mapFragment.getMapAsync(this); FrameLayout Frame_map = (FrameLayout) findViewById(R.id.frame_map); Button btn_draw_State = (Button) …
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.