dotnet / dotnet/maui

Border can set multi StrokeThickness; Frame can set multi CornerRadius

Open
#9,100 1 comment 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area-controls-border proposal/open t/enhancement ☀️
Dominant language
C#
Stars
23.3k
Forks
2k
Avg merge
1d 14h
Merged PRs (30d)
296

Description

Description

in WPF Border can set multi value of BorderThickness and CornerRadius

1

in MAUI Border only accept 1 value of StrokeThickness
Frame only accept 1 value of CornerRadius

2
Public API Changes

WPF XAML

        <Border BorderBrush="Blue" BorderThickness="1,2,3,4" CornerRadius="1,2,3,4">
            <Grid>
                <TextBlock Text="Label" />
            </Grid>
        </Border>

MAUI XAML

    <Grid BackgroundColor="Blue">
        <Grid.RowDefinitions>
            <RowDefinition />
            <RowDefinition />
        </Grid.RowDefinitions>
        <Border Stroke="Black" StrokeThickness="1,2,3,4" Grid.Row="0">
            <!-- copy from https://docs.microsoft.com/en-us/dotnet/maui/user-interface/controls/border -->
            <Border.StrokeShape>
                <RoundRectangle CornerRadius="1,2,3,4" />
            </Border.StrokeShape>
            <Grid>
                <Label Text="Label" />
            </Grid>
        </Border>
        <Frame BorderColor="Gray" CornerRadius="1,2,3,4" Grid.Row="1">
            <Label Text="Label" />
        </Frame>
    </Grid>

Intended Use-Case

Would like Border StrokeThickness can set multi value

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the MAUI Border control's StrokeThickness and Frame control's CornerRadius entry points, then compare their current single-value behavior with the WPF and MAUI XAML examples in the issue. Done means Border accepts four-sided StrokeThickness values and Frame accepts four-sided CornerRadius values consistently across supported platforms, with coverage for the new behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
frontend, mobile-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.