첨부 소스 코드는 나눔고딕코딩 폰트를 사용합니다.
728x90
반응형
728x170

[TestLibrary 프로젝트]

▶ CircleButton.cs

namespace TestLibrary.Controls
{
    public class CircleButton : Button
    {
        ...
    }
}

 

728x90

 

[TestProject 프로젝트]

▶ AssemblyInfo.cs

using TestLibrary.Controls;

[assembly: Preserve]

[assembly: XmlnsDefinition("http://dscore.com/schemas/controls", "TestLibrary.Controls")]

 

반응형

 

▶ MainPage.xaml

<ContentPage x:Class="TestProject.MainPage"
    xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
    xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
    xmlns:library="http://dscore.com/schemas/controls">
    <StackLayout
        HorizontalOptions="Center"
        VerticalOptions="Center">
        <library:CircleButton
            CircleDiameter="100"
            BorderColor="Black"
            BackgroundColor="Fuchsia"
            Text="+" />
        <controls:CircleButton
            Margin="0,10,0,0"
            CircleDiameter="70"
            BorderColor="Silver"
            BackgroundColor="Teal"
            Text="-" />
    </StackLayout>
</ContentPage>
728x90
반응형
그리드형(광고전용)
Posted by icodebroker

댓글을 달아 주세요