Skip to content

Visibility Issues: Incomplete Label Display on macOS and IOS When Padding is Applied #19007

@NirmalKumarYuvaraj

Description

@NirmalKumarYuvaraj

Description

In macOS and iOS, a visibility issue arises when a label fails to display fully when padding is applied to it. The label is completely visible when the padding is removed. Additionally, top and bottom padding occupy more space than mentioned. I have attached images for your reference.

Code Snippet

 <Grid RowDefinitions="Auto" ColumnDefinitions="100" >
     <Label Background="Red"
             Text=".NET Multi-platform App UI (.NET MAUI) is a cross-platform framework for creating mobile and desktop apps with C# and XAML."
                Padding="20"
                />
 </Grid>

Output

  • With Padding

With Padding

  • Without Padding

Without Padding

Steps to Reproduce

  1. Create a MAUI App.
  2. Establish a Grid Layout featuring ColumnDefinitions set to 100 and RowDefinitions set to Auto.
  3. Embed a Label within the Grid Layout, assigning it a lengthy text value. Apply a padding of 20 along with a background.
  4. Observe that the text may not be entirely visible due to the specified parameters.

Link to public reproduction project repository

No response

Version with bug

8.0.3

Is this a regression from previous behavior?

Not sure, did not test other versions

Last version that worked well

Unknown/Other

Affected platforms

iOS, macOS

Affected platform versions

No response

Did you find any workaround?

No response

Relevant log output

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions