1

I want to draw an arrow using C#

I can write the following:

protected override void OnPaint(PaintEventArgs e)
{
   base.OnPaint(e);
   Pen p = new Pen(Color.Blue, 1);
   p.StartCap = System.Drawing.Drawing2D.LineCap.DiamondAnchor;
   p.EndCap = System.Drawing.Drawing2D.LineCap.DiamondAnchor;
   e.Graphics.DrawLine(p, 20, 20, 100, 100);
}

But the cap is going to be very small. Is there away to get around this problem (without changing Pen width)?

4

0 に答える 0