Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,294 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hello in platform xamarin android i draw 3 arc to get a disk with 3 colors.I try now to draw a hole i set paint colo
thepaint.Color = Android.Graphics.Color.DarkOrange; thecanvas.DrawArc(0, 0, diameter, diameter, 0, 120, true, thepaint); thepaint.Color = Android.Graphics.Color.Indigo; thecanvas.DrawArc(0, 0, diameter, diameter, 120, 120, true, thepaint); thepaint.Color = Android.Graphics.Color.DarkCyan; thecanvas.DrawArc(0, 0, diameter, diameter,240, 120, true, thepaint); thepaint.SetStyle(Paint.Style.Fill); thepaint.Color = Android.Graphics.Color.Transparent; thecanvas.DrawCircle(diameter / 2, diameter / 2, diameter / 4, thepaint);
r
lĺ
to transparent but i don't get any result instead the black fill circle to draw a transparent hole
C#
thepaint.Color = Android.Graphics.Color.DarkOrange; thecanvas.DrawArc(0, 0, diameter, diameter, 0, 120, true, thepaint); thepaint.Color = Android.Graphics.Color.Indigo; thecanvas.DrawArc(0, 0, diameter, diameter, 120, 120, true, thepaint); thepaint.Color = Android.Graphics.Color.DarkCyan; thecanvas.DrawArc(0, 0, diameter, diameter,240, 120, true, thepaint); thepaint.SetStyle(Paint.Style.Fill); thepaint.Color = Android.Graphics.Color.Transparent; thecanvas.DrawCircle(diameter / 2, diameter / 2, diameter / 4, thepaint);
thepaint.Color = Android.Graphics.Color.DarkOrange;
thecanvas.DrawArc(0, 0, diameter, diameter, 0, 120, true, thepaint);
thepaint.Color = Android.Graphics.Color.Indigo;
thecanvas.DrawArc(0, 0, diameter, diameter, 120, 120, true, thepaint);
thepaint.Color = Android.Graphics.Color.DarkCyan;
thecanvas.DrawArc(0, 0, diameter, diameter,240, 120, true, thepaint);
thepaint.SetStyle(Paint.Style.Fill);
thepaint.Color = Android.Graphics.Color.Transparent;
thecanvas.DrawCircle(diameter / 2, diameter / 2, diameter / 4, thepaint);
thepaint.Color = Android.Graphics.Color.DarkOrange;
thecanvas.DrawArc(0, 0, diameter, diameter, 0, 120, true, thepaint);
thepaint.Color = Android.Graphics.Color.Indigo;
thecanvas.DrawArc(0, 0, diameter, diameter, 120, 120, true, thepaint);
thepaint.Color = Android.Graphics.Color.DarkCyan;
thecanvas.DrawArc(0, 0, diameter, diameter,240, 120, true, thepaint);
thepaint.SetStyle(Paint.Style.Fill);
thepaint.Color = Android.Graphics.Color.Transparent;
thecanvas.DrawCircle(diameter / 2, diameter / 2, diameter / 4, thepaint);