Frame completed
This commit is contained in:
@@ -67,11 +67,7 @@ public partial class FrameHandler : ViewHandler<Frame, SkiaFrame>
|
||||
{
|
||||
if (frame.BorderColor != null)
|
||||
{
|
||||
handler.PlatformView.Stroke = new SKColor(
|
||||
(byte)(frame.BorderColor.Red * 255),
|
||||
(byte)(frame.BorderColor.Green * 255),
|
||||
(byte)(frame.BorderColor.Blue * 255),
|
||||
(byte)(frame.BorderColor.Alpha * 255));
|
||||
handler.PlatformView.Stroke = frame.BorderColor;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// Licensed to the .NET Foundation under one or more agreements.
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
|
||||
using Microsoft.Maui.Graphics;
|
||||
using SkiaSharp;
|
||||
|
||||
namespace Microsoft.Maui.Platform;
|
||||
@@ -8,16 +9,17 @@ namespace Microsoft.Maui.Platform;
|
||||
/// <summary>
|
||||
/// Frame control - a Border with shadow enabled by default.
|
||||
/// Mimics the MAUI Frame control appearance.
|
||||
/// Implements MAUI IFrame interface patterns.
|
||||
/// </summary>
|
||||
public class SkiaFrame : SkiaBorder
|
||||
{
|
||||
public SkiaFrame()
|
||||
{
|
||||
HasShadow = true;
|
||||
CornerRadius = 4f;
|
||||
SetPadding(10f);
|
||||
CornerRadius = 4.0;
|
||||
SetPadding(10.0);
|
||||
BackgroundColor = SKColors.White;
|
||||
Stroke = SKColors.Transparent;
|
||||
StrokeThickness = 0f;
|
||||
Stroke = Colors.Transparent;
|
||||
StrokeThickness = 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user