33 references to Round
Microsoft.Maui.Graphics (6)
PointF.cs (2)
79
return new PointF(MathF.
Round
(X), MathF.
Round
(Y));
RectF.cs (4)
210
return new RectF(MathF.
Round
(X), MathF.
Round
(Y), MathF.
Round
(Width), MathF.
Round
(Height));
Microsoft.Maui.Graphics.Skia (2)
SkiaImage.cs (2)
149
canvas.DrawImage(this, dirtyRect.Left, dirtyRect.Top, MathF.
Round
(dirtyRect.Width), MathF.
Round
(dirtyRect.Height));
System.Private.CoreLib (5)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Half.cs (1)
1362
public static Half Round(Half x) => (Half)MathF.
Round
((float)x);
src\runtime\src\libraries\System.Private.CoreLib\src\System\MathF.cs (2)
168
float roundedResult =
Round
(divisionResult);
410
return
Round
(x);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\Intrinsics\Scalar.cs (1)
1475
return (T)(object)MathF.
Round
((float)(object)value);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Single.cs (1)
674
public static float Round(float x) => MathF.
Round
(x);
System.Windows.Forms (20)
System\Windows\Forms\Rendering\Button\PopupButtonColorMath.cs (6)
86
(int)MathF.
Round
(alpha * 255f),
92
=> (int)MathF.
Round
(
108
int r = (int)MathF.
Round
(baseColor.R + ((target.R - baseColor.R) * amount));
109
int g = (int)MathF.
Round
(baseColor.G + ((target.G - baseColor.G) * amount));
110
int b = (int)MathF.
Round
(baseColor.B + ((target.B - baseColor.B) * amount));
147
int gray = (int)MathF.
Round
(GetLuminance(color) * 255f);
System\Windows\Forms\Rendering\Button\PopupButtonKeyCapRenderer.cs (14)
144
int sideClearance = Math.Max(1, (int)MathF.
Round
(Metrics.SideClearanceDip * scale));
145
int pressTravel = Math.Max(1, (int)MathF.
Round
(Metrics.PressTravelDip * scale));
146
int defaultBorderIncrease = Math.Max(1, (int)MathF.
Round
(scale));
148
int rim = Math.Max(2, (int)MathF.
Round
(3f * scale));
297
int inset = metrics.BorderWidth + Math.Max(2, (int)MathF.
Round
(2f * metrics.Scale));
455
? Math.Max(1, (int)MathF.
Round
(scale))
510
int inset = Math.Max(1, (int)MathF.
Round
(1.5f * context.DeviceDpi / 96f));
540
int gap = Math.Max(2, (int)MathF.
Round
(4f * context.DeviceDpi / 96f));
748
int sideClearance = Math.Max(1, (int)MathF.
Round
(SideClearanceDip * scale));
749
int pressTravel = Math.Max(1, (int)MathF.
Round
(PressTravelDip * scale));
753
? Math.Max(1, (int)MathF.
Round
(scale))
766
(int)MathF.
Round
(press * PressTravelDip * scale),
770
int rim = Math.Max(2, (int)MathF.
Round
(3f * scale));
819
TextReliefOffset = Math.Max(1, (int)MathF.
Round
(0.8f * scale))